summaryrefslogtreecommitdiff
path: root/include/d/d_stage.h
blob: d01e0243d79c3df13c14dac9a762690c22c0796c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
#ifndef D_D_STAGE_H
#define D_D_STAGE_H

#include "SSystem/SComponent/c_lib.h"
#include "d/d_kankyo.h"
#include "d/d_kankyo_data.h"
#include "f_op/f_op_actor_mng.h"
#include "global.h"

enum StageType {
    /* 0x0 */ ST_FIELD,
    /* 0x1 */ ST_DUNGEON,
    /* 0x2 */ ST_ROOM,
    /* 0x3 */ ST_BOSS_ROOM,
    /* 0x4 */ ST_CASTLE_TOWN,
    /* 0x5 */ ST_CLOUD_SEA,
};

// made up name
struct dStage_nodeHeader {
    /* 0x0 */ u32 m_tag;
    /* 0x4 */ int m_entryNum;
    /* 0x8 */ u32 m_offset;
};

// made up name
struct dStage_fileHeader {
    /* 0x0 */ int m_chunkCount;
    /* 0x4 */ dStage_nodeHeader m_nodes[1]; // Variable length
};

struct stage_vrboxcol_info_class {
    /* 0x00 */ color_RGB_class sky_col;
    /* 0x03 */ color_RGB_class kumo_top_col;
    /* 0x06 */ color_RGB_class kumo_bottom_col;
    /* 0x09 */ GXColor kumo_shadow_col;
    /* 0x0D */ GXColor kasumi_outer_col;
    /* 0x11 */ GXColor kasumi_inner_col;
};  // Size: 0x18

// Virt
struct stage_vrbox_info_class {
    /* 0x00 */ color_RGB_class field_0x0;
    /* 0x03 */ color_RGB_class field_0x3;
    /* 0x06 */ color_RGB_class field_0x6;
    /* 0x09 */ GXColor field_0x9;
    /* 0x0D */ GXColor field_0xd;
    /* 0x11 */ GXColor field_0x11;
};  // Size: 0x15

// TRES
struct stage_tresure_data_class {
    /* 0x00 */ char name[8];
    /* 0x08 */ fopAcM_prmBase_class base;
};  // Size: 0x20

struct stage_tresure_class {
    /* 0x00 */ int num;
    /* 0x04 */ stage_tresure_data_class* m_entries;
};

// STAG
struct stage_stag_info_class {
    /* 0x00 */ f32 mNear;
    /* 0x04 */ f32 mFar;
    /* 0x08 */ u8 mCameraType;
    /* 0x09 */ u8 field_0x09;
    /* 0x0A */ u16 field_0x0a;
    /* 0x0C */ u32 field_0x0c;
    /* 0x10 */ u32 field_0x10;
    /* 0x14 */ u8 field_0x14[6];  // usually all 0xFF
    /* 0x1A */ s16 mGapLevel;
    /* 0x1C */ s16 mRangeUp;
    /* 0x1E */ s16 mRangeDown;
    /* 0x20 */ f32 field_0x20;
    /* 0x24 */ f32 field_0x24;
    /* 0x28 */ u8 mMsgGroup;
    /* 0x2A */ u16 mStageTitleNo;
    /* 0x2C */ u8 mParticleNo[16];
};  // Size: 0x3C

class dStage_stagInfo_c {
public:
    enum {
        /* 0x1 */ UB_D_MAP = 1,
    };
};

// SCLS
struct stage_scls_info_class {
    /* 0x0 */ char mStage[8];
    /* 0x8 */ u8 mStart;
    /* 0x9 */ s8 mRoom;
    /* 0xA */ u8 field_0xa;
    /* 0xB */ u8 field_0xb;
    /* 0xC */ u8 mWipe;

    char* getStage() { return mStage; }

    int getRoom() { return mRoom; }
};  // Size: 0xD

struct stage_scls_info_dummy_class {
    /* 0x00 */ int num;
    /* 0x04 */ stage_scls_info_class* m_entries;
};

// LGT
struct stage_pure_lightvec_info_class {
    /* 0x00 */ Vec position;
    /* 0x0C */ f32 radius;
    /* 0x10 */ f32 directionX;
    /* 0x14 */ f32 directionY;
    /* 0x18 */ f32 spotCutoff;
    /* 0x1C */ u8 spot_type;
    /* 0x1D */ u8 dist_atten_type;
    /* 0x1E */ u8 flags;
    /* 0x1F */ u8 switch_no;
};  // Size: 0x20

// COLO
struct stage_pselect_info_class {
    /* 0x0 */ u8 palette_id[8];
    /* 0x8 */ f32 change_rate;
};  // Size: 0xC

// LGHT
struct stage_plight_info_class {
    /* 0x00 */ Vec position;
    /* 0x0C */ f32 power;
    /* 0x10 */ u8 field_0x10[0x18 - 0x10];
    /* 0x18 */ color_RGB_class color;
    /* 0x1B */ u8 fluctuation;
};  // Size: 0x1C

// PAL
struct stage_palette_info_class {
    /* 0x00 */ color_RGB_class actor_amb_col;
    /* 0x03 */ color_RGB_class bg_amb_col[4];
    /* 0x0F */ color_RGB_class plight_col[6];
    /* 0x21 */ color_RGB_class fog_col;
    /* 0x24 */ f32 fog_start_z;
    /* 0x28 */ f32 fog_end_z;
    /* 0x2C */ u8 vrboxcol_id;
    /* 0x2D */ u8 bg_light_influence;
    /* 0x2E */ u8 cloud_shadow_density;
    /* 0x2F */ u8 unk_0x2f;
    /* 0x30 */ u8 bloom_tbl_id;
    /* 0x31 */ u8 BG1_amb_alpha;
    /* 0x32 */ u8 BG2_amb_alpha;
    /* 0x33 */ u8 BG3_amb_alpha;
};  // Size: 0x34

struct stage_map_info_class {
    /* 0x00 */ u8 field_0x0[0x35];
    /* 0x35 */ u8 field_0x35;
    /* 0x36 */ u8 field_0x36[2];
};  // Size: 0x38

struct stage_map_info_dummy_class {
    /* 0x0 */ int num;
    /* 0x4 */ stage_map_info_class* m_entries;
};

// Env
struct stage_envr_info_class {
    /* 0x0 */ u8 pselect_id[65];
};  // Size: 0x41

// CAMR / RCAM
struct stage_camera2_data_class {
    /* 0x00 */ char m_cam_type[16];
    /* 0x10 */ u8 m_arrow_idx;
    /* 0x11 */ u8 field_0x11;
    /* 0x12 */ u8 field_0x12;
    /* 0x13 */ u8 field_0x13;
    /* 0x14 */ u16 field_0x14;
    /* 0x16 */ u16 field_0x16;
};  // Size: 0x18

struct stage_camera_class {
    /* 0x0 */ int num;
    /* 0x4 */ stage_camera2_data_class* m_entries;
};

// AROB / RARO
struct stage_arrow_data_class {
    /* 0x00 */ f32 posX;
    /* 0x04 */ f32 posY;
    /* 0x08 */ f32 posZ;
    /* 0x0C */ s16 angleX;
    /* 0x0E */ s16 angleY;
    /* 0x10 */ s16 angleZ;
    /* 0x12 */ s16 field_0x12;
};  // Size: 0x14

struct stage_arrow_class {
    /* 0x00 */ int num;
    /* 0x04 */ stage_arrow_data_class* m_entries;
};

// ACT
struct stage_actor_data_class {
    /* 0x00 */ char name[8];
    /* 0x08 */ fopAcM_prmBase_class base;
};  // Size: 0x20

struct stage_actor_class {
    /* 0x0 */ int num;
    /* 0x4 */ stage_actor_data_class* m_entries;
};

// TGSC / SCOB / TGDR / Door
struct stage_tgsc_data_class {
    /* 0x00 */ char name[8];
    /* 0x08 */ fopAcM_prmBase_class base;
    /* 0x20 */ fopAcM_prmScale_class scale;
};  // Size: 0x24

STATIC_ASSERT(sizeof(stage_tgsc_data_class) == 0x24);

struct stage_tgsc_class {
    /* 0x00 */ int num;
    /* 0x04 */ stage_tgsc_data_class* m_entries;
};

// MPAT
struct map_path_class {
    /* 0x0 */ int num;
    /* 0x4 */ void* m_entries;
};

// RTBL
struct roomRead_data_class {
    /* 0x0 */ u8 num;
    /* 0x1 */ u8 field_0x1;
    /* 0x2 */ u8 field_0x2;
    /* 0x4 */ u8* m_rooms;
};  // Size: 0x8

struct roomRead_class {
    /* 0x0 */ int num;
    /* 0x4 */ roomRead_data_class** m_entries;
};

// MEM
struct dStage_MemoryMap_c {
    /* 0x0 */ int m_num;
    /* 0x4 */ u32* field_0x4;
};

// MEC
struct dStage_MemoryConfig_data {
    /* 0x0 */ u8 m_roomNo;
    /* 0x1 */ u8 m_blockID;
};  // Size: 0x2

struct dStage_MemoryConfig_c {
    /* 0x0 */ int m_num;
    /* 0x4 */ dStage_MemoryConfig_data* field_0x4;
};

// PATH / RPAT
struct dPath;
struct dStage_dPath_c {
    /* 0x0 */ int num;
    /* 0x4 */ dPath* m_path;
};

// PPNT / RPPN
struct dStage_dPnt_c {
    /* 0x0 */ int num;
    /* 0x4 */ u32 m_pnt_offset;
};  // Size: 0x8

// MULT
struct dStage_Mult_info {
    /* 0x0 */ f32 mTransX;
    /* 0x4 */ f32 mTransY;
    /* 0x8 */ s16 mAngle;
    /* 0xA */ u8 mRoomNo;
};  // Size: 0xC

class dStage_Multi_c {
public:
    /* 0x0 */ int num;
    /* 0x4 */ dStage_Mult_info* m_entries;
};

// SOND
struct stage_sound_data {
    /* 0x00 */ char field_0x0[8];
    /* 0x08 */ Vec field_0x8;
    /* 0x14 */ u8 field_0x14;
    /* 0x15 */ u8 field_0x15;
    /* 0x16 */ u8 field_0x16;
    /* 0x17 */ u8 field_0x17;
    /* 0x18 */ u8 field_0x18;
    /* 0x19 */ u8 field_0x19;
    /* 0x1A */ u8 field_0x1a;
};  // Size: 0x1C

struct dStage_SoundInfo_c {
    /* 0x0 */ int num;
    /* 0x4 */ stage_sound_data* entries;
};

// FILI
class dStage_FileList_dt_c {
public:
    /* 0x00 */ u32 mParameters;
    /* 0x04 */ f32 mSeaLevel;
    /* 0x08 */ f32 field_0x8;
    /* 0x0C */ f32 field_0xc;
    /* 0x10 */ u8 field_0x10[10];
    /* 0x1A */ u8 mDefaultCamera;
    /* 0x1B */ u8 mBitSw;
    /* 0x1C */ u16 mMsg;
};  // Size: 0x20

// FILI
class dStage_FileList2_dt_c {
public:
    /* 0x00 */ f32 mLeftRmX;
    /* 0x04 */ f32 mInnerRmZ;
    /* 0x08 */ f32 mRightRmX;
    /* 0x0C */ f32 mFrontRmZ;
    /* 0x10 */ u8 mMinFloorNo;
    /* 0x11 */ u8 mMaxFloorNo;
    /* 0x12 */ u8 field_0x12;
    /* 0x13 */ u8 field_0x13;
    /* 0x14 */ f32 field_0x14;
    /* 0x18 */ f32 field_0x18;
    /* 0x1C */ s16 field_0x1c;
};  // Size: 0x20

struct dStage_FileList2_c {
    /* 0x0 */ int num;
    /* 0x4 */ dStage_FileList2_dt_c* entries;
};

// FLOR
struct dStage_FloorInfo_dt_c {
    // Copied from TWW, may not be right
    /* 0x00 */ int field_0x00;
    /* 0x04 */ u8 floorNo;
    /* 0x05 */ s8 field_0x05[14];
}; // Size: 0x14

struct dStage_FloorInfo_c {
    /* 0x00 */ int num;
    /* 0x04 */ dStage_FloorInfo_dt_c* m_entries;
};

// LBNK
class dStage_Lbnk_dt_c {
public:
    /* 0x0 */ u8 bank;
    /* 0x1 */ u8 bank2;
    /* 0x2 */ u8 field_0x2;
};

struct dStage_Lbnk_c {
    /* 0x0 */ int num;
    /* 0x4 */ dStage_Lbnk_dt_c* entries;
};

struct dStage_Elst_dt_c {
    /* 0x0 */ u8 m_layerTable[15];
};  // Size: 0xF

struct dStage_Elst_c {
    /* 0x0 */ int m_entryNum;
    /* 0x4 */ dStage_Elst_dt_c* m_entries;
};

// DMAP
struct dStage_DMap_dt_c {
    // Copied from TWW, may not be right
    /* 0x00 */ int field_0x00;
    /* 0x04 */ int field_0x04;
    /* 0x08 */ int field_0x08;
    /* 0x0C */ f32 offsetY;
};  // Size: 0x10

struct dStage_DMap_c {
    /* 0x00 */ int num;
    /* 0x04 */ dStage_DMap_dt_c* entries;
};

/**
 * dStage_MapEvent
 * Section Magic: "REVT"
 *
 * For STB/ZEV events, an event name is specified for data
 * For MapTool events, other data is specified instead
 */
// using packing to make sure event_name doesn't get aligned
// field_0x1a / switch_no might be part of maptool data? unsure
#pragma push
#pragma pack(1)
struct dStage_MapEvent_dt_c {
    /* 0x00 */ u8 type;
    /* 0x01 */ u8 field_0x1;
    /* 0x02 */ u8 field_0x2;
    /* 0x03 */ u8 field_0x3;
    /* 0x04 */ u8 field_0x4;
    /* 0x05 */ u8 field_0x5;
    /* 0x06 */ u8 priority;
    /* 0x07 */ u8 field_0x7;
    /* 0x08 */ u8 field_0x8;
    /* 0x09 */ u8 field_0x9;
    /* 0x0A */ u8 field_0xA;
    /* 0x0B */ u8 field_0xB;
    /* 0x0C */ u8 field_0xC;
    union {
        /* 0x0D */ char event_name[13];
        struct {
            /* 0x0D */ u8 field_0xd[0x14 - 0xD];
            /* 0x14 */ u16 field_0x14;
            /* 0x16 */ u8 field_0x16;
            /* 0x17 */ u8 field_0x17;
            /* 0x18 */ u8 sound_type;
            /* 0x19 */ u8 field_0x19;
        } maptool;
    } data;
    /* 0x1A */ u8 field_0x1a;
    /* 0x1B */ u8 switch_no;
};  // SIZE = 0x1C
#pragma pack()
#pragma pop

enum dStage_MapEvent_dt_type {
    dStage_MapEvent_dt_TYPE_MAPTOOLCAMERA,
    dStage_MapEvent_dt_TYPE_ZEV,
    dStage_MapEvent_dt_TYPE_STB,
};

struct dStage_MapEventInfo_c {
    /* 0x0 */ int num;
    /* 0x4 */ dStage_MapEvent_dt_c* m_entries;
};

class dStage_dt_c {
public:
    dStage_dt_c() {}
    void setRoomNo(s8 roomNo) { mRoomNo = roomNo; }
    s8 getRoomNo() { return mRoomNo; }

    /* vt[ 2] */ virtual void init(void) = 0;
    /* vt[ 3] */ virtual void setCamera(stage_camera_class*) = 0;
    /* vt[ 4] */ virtual stage_camera_class* getCamera(void) const = 0;
    /* vt[ 5] */ virtual void setArrow(stage_arrow_class*) = 0;
    /* vt[ 6] */ virtual stage_arrow_class* getArrow(void) const = 0;
    /* vt[ 7] */ virtual void setPlayer(stage_actor_class*) = 0;
    /* vt[ 8] */ virtual stage_actor_class* getPlayer(void) const = 0;
    /* vt[ 9] */ virtual void setPlayerNum(u16) = 0;
    /* vt[10] */ virtual u16 getPlayerNum(void) const = 0;
    /* vt[11] */ virtual void setRoom(roomRead_class*) = 0;
    /* vt[12] */ virtual roomRead_class* getRoom(void) const = 0;
    /* vt[13] */ virtual void setMapInfo(stage_map_info_class*) = 0;
    /* vt[14] */ virtual stage_map_info_class* getMapInfo(void) const = 0;
    /* vt[15] */ virtual stage_map_info_class* getMapInfo2(int) const = 0;
    /* vt[16] */ virtual void setMapInfoBase(stage_map_info_dummy_class*) = 0;
    /* vt[17] */ virtual stage_map_info_dummy_class* getMapInfoBase(void) const = 0;
    /* vt[18] */ virtual void setPaletteInfo(stage_palette_info_class*) = 0;
    /* vt[19] */ virtual stage_palette_info_class* getPaletteInfo(void) const = 0;
    /* vt[20] */ virtual void setPselectInfo(stage_pselect_info_class*) = 0;
    /* vt[21] */ virtual stage_pselect_info_class* getPselectInfo(void) const = 0;
    /* vt[22] */ virtual void setEnvrInfo(stage_envr_info_class*) = 0;
    /* vt[23] */ virtual stage_envr_info_class* getEnvrInfo(void) const = 0;
    /* vt[24] */ virtual void setVrboxInfo(stage_vrbox_info_class*) = 0;
    /* vt[25] */ virtual stage_vrbox_info_class* getVrboxInfo(void) const = 0;
    /* vt[26] */ virtual void setVrboxcolInfo(stage_vrboxcol_info_class*) = 0;
    /* vt[27] */ virtual stage_vrboxcol_info_class* getVrboxcolInfo(void) const = 0;
    /* vt[28] */ virtual void setPlightInfo(stage_plight_info_class*) = 0;
    /* vt[29] */ virtual stage_plight_info_class* getPlightInfo(void) const = 0;
    /* vt[30] */ virtual void setPaletteNumInfo(int) = 0;
    /* vt[31] */ virtual int getPaletteNumInfo(void) const = 0;
    /* vt[32] */ virtual void setPselectNumInfo(int) = 0;
    /* vt[33] */ virtual int getPselectNumInfo(void) const = 0;
    /* vt[34] */ virtual void setEnvrNumInfo(int) = 0;
    /* vt[35] */ virtual int getEnvrNumInfo(void) const = 0;
    /* vt[36] */ virtual void setVrboxNumInfo(int) = 0;
    /* vt[37] */ virtual int getVrboxNumInfo(void) const = 0;
    /* vt[38] */ virtual void setVrboxcolNumInfo(int) = 0;
    /* vt[39] */ virtual int getVrboxcolNumInfo(void) const = 0;
    /* vt[40] */ virtual void setPlightNumInfo(int) = 0;
    /* vt[41] */ virtual int getPlightNumInfo(void) const = 0;
    /* vt[42] */ virtual void setLightVecInfo(stage_pure_lightvec_info_class*) = 0;
    /* vt[43] */ virtual stage_pure_lightvec_info_class* getLightVecInfo(void) const = 0;
    /* vt[44] */ virtual void setLightVecInfoNum(int) = 0;
    /* vt[45] */ virtual int getLightVecInfoNum(void) const = 0;
    /* vt[46] */ virtual void setStagInfo(stage_stag_info_class*) = 0;
    /* vt[47] */ virtual stage_stag_info_class* getStagInfo(void) const = 0;
    /* vt[48] */ virtual void setSclsInfo(stage_scls_info_dummy_class*) = 0;
    /* vt[49] */ virtual stage_scls_info_dummy_class* getSclsInfo(void) const = 0;
    /* vt[50] */ virtual void setPntInfo(dStage_dPnt_c*) = 0;
    /* vt[51] */ virtual dStage_dPnt_c* getPntInf(void) const = 0;
    /* vt[52] */ virtual void setPathInfo(dStage_dPath_c*) = 0;
    /* vt[53] */ virtual dStage_dPath_c* getPathInf(void) const = 0;
    /* vt[54] */ virtual void setPnt2Info(dStage_dPnt_c*) = 0;
    /* vt[55] */ virtual dStage_dPnt_c* getPnt2Inf(void) const = 0;
    /* vt[56] */ virtual void setPath2Info(dStage_dPath_c*) = 0;
    /* vt[57] */ virtual dStage_dPath_c* getPath2Inf(void) const = 0;
    /* vt[58] */ virtual void setSoundInf(dStage_SoundInfo_c*) = 0;
    /* vt[59] */ virtual dStage_SoundInfo_c* getSoundInf(void) const = 0;
    /* vt[60] */ virtual void setSoundInfCL(dStage_SoundInfo_c*) = 0;
    /* vt[61] */ virtual dStage_SoundInfo_c* getSoundInfCL(void) const = 0;
    /* vt[62] */ virtual void setMapEventInfo(dStage_MapEventInfo_c*) = 0;
    /* vt[63] */ virtual dStage_MapEventInfo_c* getMapEventInfo(void) const = 0;
    /* vt[64] */ virtual void setFileList2Info(dStage_FileList2_dt_c*) = 0;
    /* vt[65] */ virtual dStage_FileList2_dt_c* getFileList2Info(void) const = 0;
    /* vt[66] */ virtual void setFileListInfo(dStage_FileList_dt_c*) = 0;
    /* vt[67] */ virtual dStage_FileList_dt_c* getFileListInfo(void) const = 0;
    /* vt[68] */ virtual void setFloorInfo(dStage_FloorInfo_c*) = 0;
    /* vt[69] */ virtual dStage_FloorInfo_c* getFloorInfo(void) const = 0;
    /* vt[70] */ virtual void setMemoryConfig(dStage_MemoryConfig_c*) = 0;
    /* vt[71] */ virtual dStage_MemoryConfig_c* getMemoryConfig(void) const = 0;
    /* vt[72] */ virtual void setMemoryMap(dStage_MemoryMap_c*) = 0;
    /* vt[73] */ virtual dStage_MemoryMap_c* getMemoryMap(void) const = 0;
    /* vt[74] */ virtual void setMulti(dStage_Multi_c*) = 0;
    /* vt[75] */ virtual dStage_Multi_c* getMulti(void) const = 0;
    /* vt[76] */ virtual void setOldMulti(void) = 0;
    /* vt[77] */ virtual void resetOldMulti(void) = 0;
    /* vt[78] */ virtual dStage_Multi_c* getOldMulti(void) const = 0;
    /* vt[79] */ virtual void setLbnk(dStage_Lbnk_c*) = 0;
    /* vt[80] */ virtual dStage_Lbnk_c* getLbnk(void) const = 0;
    /* vt[81] */ virtual void setTresure(stage_tresure_class*) = 0;
    /* vt[82] */ virtual stage_tresure_class* getTresure(void) const = 0;
    /* vt[83] */ virtual void setDMap(dStage_DMap_c*) = 0;
    /* vt[84] */ virtual dStage_DMap_c* getDMap(void) const = 0;
    /* vt[85] */ virtual void setDrTg(stage_tgsc_class*) = 0;
    /* vt[86] */ virtual stage_tgsc_class* getDrTg(void) const = 0;
    /* vt[87] */ virtual void setDoor(stage_tgsc_class*) = 0;
    /* vt[88] */ virtual stage_tgsc_class* getDoor(void) const = 0;
#if DEBUG
    virtual void setUnit(void*) = 0;
    virtual void* getUnit() = 0;
#endif
    /* vt[89] */ virtual void setMapPath(void*) = 0;
    /* vt[90] */ virtual void* getMapPath(void) = 0;
    /* vt[91] */ virtual void setElst(dStage_Elst_c*) = 0;
    /* vt[92] */ virtual dStage_Elst_c* getElst(void) = 0;

private:
    /* 0x04 */ s8 mRoomNo;
};

void dStage_SetErrorStage();
void dStage_SetErrorRoom();

class dStage_roomDt_c : public dStage_dt_c {
public:
    dStage_roomDt_c() {}
    void initFileList2(void);

    virtual void init(void);
    virtual void setCamera(stage_camera_class* i_Camera) { mCamera = i_Camera; }
    virtual stage_camera_class* getCamera(void) const { return mCamera; }
    virtual void setArrow(stage_arrow_class* i_Arrow) { mArrow = i_Arrow; }
    virtual stage_arrow_class* getArrow(void) const { return mArrow; }
    virtual void setPlayer(stage_actor_class* i_Player) { mPlayer = i_Player; }
    virtual stage_actor_class* getPlayer(void) const { return mPlayer; }
    virtual void setPlayerNum(u16 i_PlayerNum) { mPlayerNum = i_PlayerNum; }
    virtual u16 getPlayerNum(void) const { return mPlayerNum; }
    virtual void setRoom(roomRead_class* i_Room) {
        UNUSED(i_Room);
        dStage_SetErrorRoom();
        OSReport("Room non room data !!\n");
        JUT_ASSERT(2095, FALSE);
    }
    virtual roomRead_class* getRoom(void) const {
        OSReport("Room non room data !!\n");
        JUT_ASSERT(2100, FALSE);
        return 0;
    }
    virtual void setMapInfo(stage_map_info_class* i_MapInfo) { mMapInfo = i_MapInfo; }
    virtual stage_map_info_class* getMapInfo(void) const { return mMapInfo; }
    virtual stage_map_info_class* getMapInfo2(int) const;
    virtual void setMapInfoBase(stage_map_info_dummy_class* i_MapInfoBase) { mMapInfoBase = i_MapInfoBase; }
    virtual stage_map_info_dummy_class* getMapInfoBase(void) const { return mMapInfoBase; }
    virtual void setPaletteInfo(stage_palette_info_class* i_PaletteInfo) {
        UNUSED(i_PaletteInfo);
        dStage_SetErrorRoom();
        OSReport("Room non palet data !!\n");
        JUT_ASSERT(2126, FALSE);
    }
    virtual stage_palette_info_class* getPaletteInfo(void) const {
        OSReport("Room non palet data !!\n");
        JUT_ASSERT(2130, FALSE);
        return 0;
    }
    virtual void setPselectInfo(stage_pselect_info_class* i_PselectInfo) {
        UNUSED(i_PselectInfo);
        dStage_SetErrorRoom();
        OSReport("Room non pselect data !!\n");
        JUT_ASSERT(2137, FALSE);
    }
    virtual stage_pselect_info_class* getPselectInfo(void) const {
        OSReport("Room non pselect data !!\n");
        JUT_ASSERT(2141, FALSE);
        return 0;
    }
    virtual void setEnvrInfo(stage_envr_info_class* i_EnvrInfo) {
        UNUSED(i_EnvrInfo);
        dStage_SetErrorRoom();
        OSReport("Room non envr data !!\n");
        JUT_ASSERT(2148, FALSE);
    }
    virtual stage_envr_info_class* getEnvrInfo(void) const {
        OSReport("Room non envr data !!\n");
        JUT_ASSERT(2152, FALSE);
        return 0;
    }
    virtual void setVrboxInfo(stage_vrbox_info_class* i_VrboxInfo) { mVrboxInfo = i_VrboxInfo; }
    virtual stage_vrbox_info_class* getVrboxInfo(void) const { return mVrboxInfo; }
    virtual void setVrboxcolInfo(stage_vrboxcol_info_class* i_VrboxcolInfo) { mVrboxcolInfo = i_VrboxcolInfo; }
    virtual stage_vrboxcol_info_class* getVrboxcolInfo(void) const { return mVrboxcolInfo; }
    virtual void setPlightInfo(stage_plight_info_class* i_PlightInfo) {
        UNUSED(i_PlightInfo);
        dStage_SetErrorRoom();
        OSReport("Room non plight data !!\n");
        JUT_ASSERT(2174, FALSE);
    }
    virtual stage_plight_info_class* getPlightInfo(void) const {
        OSReport("Room non plight data !!\n");
        JUT_ASSERT(2178, FALSE);
        return 0;
    }
    virtual void setPaletteNumInfo(int i_PaletteNumInfo) {
        UNUSED(i_PaletteNumInfo);
        dStage_SetErrorRoom();
        OSReport("Room non palette num data !!\n");
        JUT_ASSERT(2186, FALSE);
    }
    virtual int getPaletteNumInfo(void) const {
        OSReport("Room non palette num data !!\n");
        JUT_ASSERT(2190, FALSE);
        return 0;
    }
    virtual void setPselectNumInfo(int i_PselectNumInfo) {
        UNUSED(i_PselectNumInfo);
        dStage_SetErrorRoom();
        OSReport("Room non pselect num data !!\n");
        JUT_ASSERT(2197, FALSE);
    }
    virtual int getPselectNumInfo(void) const {
        OSReport("Room non pselect num data !!\n");
        JUT_ASSERT(2201, FALSE);
        return 0;
    }
    virtual void setEnvrNumInfo(int i_EnvrNumInfo) {
        UNUSED(i_EnvrNumInfo);
        dStage_SetErrorRoom();
        OSReport("Room non envr num data !!\n");
        JUT_ASSERT(2208, FALSE);
    }
    virtual int getEnvrNumInfo(void) const {
        OSReport("Room non envr num data !!\n");
        JUT_ASSERT(2212, FALSE);
        return 0;
    }
    virtual void setVrboxNumInfo(int i_VrboxNumInfo) { mVrboxNumInfo = i_VrboxNumInfo; }
    virtual int getVrboxNumInfo(void) const { return mVrboxNumInfo; }
    virtual void setVrboxcolNumInfo(int i_VrboxcolNumInfo) { mVrboxcolNumInfo = i_VrboxcolNumInfo; }
    virtual int getVrboxcolNumInfo(void) const { return mVrboxcolNumInfo; }
    virtual void setPlightNumInfo(int i_PlightNumInfo) {
        UNUSED(i_PlightNumInfo);
        dStage_SetErrorRoom();
        OSReport("Room non plight num data !!\n");
        JUT_ASSERT(2223, FALSE);
    }
    virtual int getPlightNumInfo(void) const {
        OSReport("Room non plight num data !!\n");
        JUT_ASSERT(2227, FALSE);
        return 0;
    }
    virtual void setLightVecInfo(stage_pure_lightvec_info_class* i_LightVecInfo) { mLightVecInfo = i_LightVecInfo; }
    virtual stage_pure_lightvec_info_class* getLightVecInfo(void) const { return mLightVecInfo; }
    virtual void setLightVecInfoNum(int i_LightVecInfoNum) { mLightVecInfoNum = i_LightVecInfoNum; }
    virtual int getLightVecInfoNum(void) const { return mLightVecInfoNum; }
    virtual void setStagInfo(stage_stag_info_class* i_StagInfo) {
        UNUSED(i_StagInfo);
        dStage_SetErrorRoom();
        OSReport("Room non stag data !!\n");
        JUT_ASSERT(2256, FALSE);
    }
    virtual stage_stag_info_class* getStagInfo(void) const {
        OSReport("Room non stag data !!\n");
        JUT_ASSERT(2260, FALSE);
        return 0;
    }
    virtual void setSclsInfo(stage_scls_info_dummy_class* i_SclsInfo) { mSclsInfo = i_SclsInfo; }
    virtual stage_scls_info_dummy_class* getSclsInfo(void) const { return mSclsInfo; }
    virtual void setPntInfo(dStage_dPnt_c* i_PntInfo) {
        UNUSED(i_PntInfo);
        dStage_SetErrorRoom();
        OSReport("Room non Pnt data !\n");
        JUT_ASSERT(2281, FALSE);
    }
    virtual dStage_dPnt_c* getPntInf(void) const {
        OSReport("Room non Pnts data !\n");
        JUT_ASSERT(2285, FALSE);
        return 0;
    }
    virtual void setPathInfo(dStage_dPath_c* i_PathInfo) {
        UNUSED(i_PathInfo);
        dStage_SetErrorRoom();
        OSReport("Room non Path data !\n");
        JUT_ASSERT(2292, FALSE);
    }
    virtual dStage_dPath_c* getPathInf(void) const {
        OSReport("Room non Path data !\n");
        JUT_ASSERT(2296, FALSE);
        return 0;
    }
    virtual void setPnt2Info(dStage_dPnt_c* i_Pnt2Info) { mPnt2Info = i_Pnt2Info; }
    virtual dStage_dPnt_c* getPnt2Inf(void) const { return mPnt2Info; }
    virtual void setPath2Info(dStage_dPath_c* i_Path2Info) { mPath2Info = i_Path2Info; }
    virtual dStage_dPath_c* getPath2Inf(void) const { return mPath2Info; }
    virtual void setSoundInf(dStage_SoundInfo_c* i_SoundInf) { mSoundInf = i_SoundInf; }
    virtual dStage_SoundInfo_c* getSoundInf(void) const { return mSoundInf; }
    virtual void setSoundInfCL(dStage_SoundInfo_c* i_SoundInfCL) { mSoundInfCL = i_SoundInfCL; }
    virtual dStage_SoundInfo_c* getSoundInfCL(void) const { return mSoundInfCL; }
    virtual void setMapEventInfo(dStage_MapEventInfo_c* i_MapEventInfo) { mMapEventInfo = i_MapEventInfo; }
    virtual dStage_MapEventInfo_c* getMapEventInfo(void) const { return mMapEventInfo; }
    virtual void setFileList2Info(dStage_FileList2_dt_c* i_FileList2Info) { mFileList2Info = i_FileList2Info; }
    virtual dStage_FileList2_dt_c* getFileList2Info(void) const { return mFileList2Info; }
    virtual void setFileListInfo(dStage_FileList_dt_c* i_FileListInfo) { mFileListInfo = i_FileListInfo; }
    virtual dStage_FileList_dt_c* getFileListInfo(void) const { return mFileListInfo; }
    virtual void setFloorInfo(dStage_FloorInfo_c* i_FloorInfo) { mFloorInfo = i_FloorInfo; }
    virtual dStage_FloorInfo_c* getFloorInfo(void) const { return mFloorInfo; }
    virtual void setMemoryConfig(dStage_MemoryConfig_c* i_MemoryConfig) {
        UNUSED(i_MemoryConfig);
        OSReport("Room non memory config data!\n");
        JUT_ASSERT(2414, FALSE);
    }
    virtual dStage_MemoryConfig_c* getMemoryConfig(void) const {
        OSReport("Room non memory config data!\n");
        JUT_ASSERT(2423, FALSE);
        return 0;
    }
    virtual void setMemoryMap(dStage_MemoryMap_c* i_MemoryMap) {
        UNUSED(i_MemoryMap);
        OSReport("Room non memory map data!\n");
        JUT_ASSERT(2433, FALSE);
    }
    virtual dStage_MemoryMap_c* getMemoryMap(void) const {
        OSReport("Room non memory map data!\n");
        JUT_ASSERT(2442, FALSE);
        return 0;
    }
    virtual void setMulti(dStage_Multi_c* i_Multi) {
        UNUSED(i_Multi);
        OSReport("Room non multi data!\n");
        JUT_ASSERT(2452, FALSE);
    }
    virtual dStage_Multi_c* getMulti(void) const {
        OSReport("Room non multi data!\n");
        JUT_ASSERT(2457, FALSE);
        return 0;
    }
    virtual void setOldMulti(void) {
        OSReport("Room non old multi data!\n");
        JUT_ASSERT(2462, FALSE);
    }
    virtual void resetOldMulti(void) {
        OSReport("Room non old multi data!\n");
        JUT_ASSERT(2467, FALSE);
    }
    virtual dStage_Multi_c* getOldMulti(void) const {
        OSReport("Room non old multi data!\n");
        JUT_ASSERT(2472, FALSE);
        return 0;
    }
    virtual void setLbnk(dStage_Lbnk_c* i_Lbnk) { mLbnk = i_Lbnk; }
    virtual dStage_Lbnk_c* getLbnk(void) const { return mLbnk; }
    virtual void setTresure(stage_tresure_class* i_Tresure) { mTresure = i_Tresure; }
    virtual stage_tresure_class* getTresure(void) const { return mTresure; }
    virtual void setDMap(dStage_DMap_c* i_DMap) {
        UNUSED(i_DMap);
        OS_REPORT("Room non DMap data\n");
        JUT_ASSERT(2508, FALSE);
    }
    virtual dStage_DMap_c* getDMap(void) const {
        OS_REPORT("Room non DMap data\n");
        JUT_ASSERT(2513, FALSE);
        return 0;
    }
    virtual void setDrTg(stage_tgsc_class* i_DrTg) { mDrTg = i_DrTg; }
    virtual stage_tgsc_class* getDrTg(void) const { return mDrTg; }
    virtual void setDoor(stage_tgsc_class* i_Door) { mDoor = i_Door; }
    virtual stage_tgsc_class* getDoor(void) const { return mDoor; }
#if DEBUG
    virtual void setUnit(void* i_Unit) { mUnit = i_Unit; }
    virtual void* getUnit() { return mUnit; }
#endif
    virtual void setMapPath(void* i_MapPath) {
        UNUSED(i_MapPath);
        OSReport("stage non 2d map path data !!\n");
        JUT_ASSERT(2557, FALSE);
    }
    virtual void* getMapPath(void) {
        OSReport("stage non 2d map path data !!\n");
        JUT_ASSERT(2561, FALSE);
        return 0;
    }
    virtual void setElst(dStage_Elst_c* i_Elst) {
        UNUSED(i_Elst);
        dStage_SetErrorRoom();
        OSReport("Room non envLayserSet data\n");
        JUT_ASSERT(2572, FALSE);
    }
    virtual dStage_Elst_c* getElst(void) {
        dStage_SetErrorRoom();
        OSReport("Room no Elst Data!!\n");
        return 0;
    }

public:
    /* 0x08 */ stage_pure_lightvec_info_class* mLightVecInfo;
    /* 0x0C */ int mLightVecInfoNum;
    /* 0x10 */ stage_map_info_class* mMapInfo;
    /* 0x14 */ stage_map_info_dummy_class* mMapInfoBase;
    /* 0x18 */ stage_vrbox_info_class* mVrboxInfo;
    /* 0x1C */ stage_vrboxcol_info_class* mVrboxcolInfo;
    /* 0x20 */ dStage_FileList2_dt_c* mFileList2Info;
    /* 0x24 */ dStage_FileList_dt_c* mFileListInfo;
    /* 0x28 */ stage_actor_class* mPlayer;
    /* 0x2C */ dStage_dPnt_c* mPnt2Info;
    /* 0x30 */ dStage_dPath_c* mPath2Info;
    /* 0x34 */ stage_camera_class* mCamera;
    /* 0x38 */ stage_arrow_class* mArrow;
    /* 0x3C */ dStage_MapEventInfo_c* mMapEventInfo;
    /* 0x40 */ dStage_SoundInfo_c* mSoundInf;
    /* 0x44 */ dStage_SoundInfo_c* mSoundInfCL;
    /* 0x48 */ stage_scls_info_dummy_class* mSclsInfo;
    /* 0x4C */ dStage_Lbnk_c* mLbnk;
    /* 0x50 */ stage_tresure_class* mTresure;
    /* 0x54 */ stage_tgsc_class* mDrTg;
    /* 0x58 */ stage_tgsc_class* mDoor;
    /* 0x5C */ dStage_FloorInfo_c* mFloorInfo;
#if DEBUG
    /* 0x60 */ void* mUnit;
#endif
    /* 0x60 */ u16 mPlayerNum;
    /* 0x62 */ u16 field_0x62;
    /* 0x64 */ int mVrboxNumInfo;
    /* 0x68 */ int mVrboxcolNumInfo;
};  // Size: 0x6C

class dStage_stageDt_c : public dStage_dt_c {
public:
    dStage_stageDt_c() {}

    /* vt[ 2] */ virtual void init(void);
    /* vt[ 3] */ virtual void setCamera(stage_camera_class* i_Camera) { mCamera = i_Camera; }
    /* vt[ 4] */ virtual stage_camera_class* getCamera(void) const { return mCamera; }
    /* vt[ 5] */ virtual void setArrow(stage_arrow_class* i_Arrow) { mArrow = i_Arrow; }
    /* vt[ 6] */ virtual stage_arrow_class* getArrow(void) const { return mArrow; }
    /* vt[ 7] */ virtual void setPlayer(stage_actor_class* i_Player) { mPlayer = i_Player; }
    /* vt[ 8] */ virtual stage_actor_class* getPlayer(void) const { return mPlayer; }
    /* vt[ 9] */ virtual void setPlayerNum(u16 i_PlayerNum) { mPlayerNum = i_PlayerNum; }
    /* vt[10] */ virtual u16 getPlayerNum(void) const { return mPlayerNum; }
    /* vt[11] */ virtual void setRoom(roomRead_class* i_Room) { mRoom = i_Room; }
    /* vt[12] */ virtual roomRead_class* getRoom(void) const { return mRoom; }
    /* vt[13] */ virtual void setMapInfo(stage_map_info_class* i_MapInfo) { mMapInfo = i_MapInfo; }
    /* vt[14] */ virtual stage_map_info_class* getMapInfo(void) const { return mMapInfo; }
    /* vt[15] */ virtual stage_map_info_class* getMapInfo2(int) const;
    /* vt[16] */ virtual void setMapInfoBase(stage_map_info_dummy_class* i_MapInfoBase) { mMapInfoBase = i_MapInfoBase; }
    /* vt[17] */ virtual stage_map_info_dummy_class* getMapInfoBase(void) const { return mMapInfoBase; }
    /* vt[18] */ virtual void setPaletteInfo(stage_palette_info_class* i_PaletteInfo) { mPaletteInfo = i_PaletteInfo; }
    /* vt[19] */ virtual stage_palette_info_class* getPaletteInfo(void) const { return mPaletteInfo; }
    /* vt[20] */ virtual void setPselectInfo(stage_pselect_info_class* i_PselectInfo) { mPselectInfo = i_PselectInfo; }
    /* vt[21] */ virtual stage_pselect_info_class* getPselectInfo(void) const { return mPselectInfo; }
    /* vt[22] */ virtual void setEnvrInfo(stage_envr_info_class* i_EnvrInfo) { mEnvrInfo = i_EnvrInfo; }
    /* vt[23] */ virtual stage_envr_info_class* getEnvrInfo(void) const { return mEnvrInfo; }
    /* vt[24] */ virtual void setVrboxInfo(stage_vrbox_info_class* i_VrboxInfo) { mVrboxInfo = i_VrboxInfo; }
    /* vt[25] */ virtual stage_vrbox_info_class* getVrboxInfo(void) const { return mVrboxInfo; }
    /* vt[26] */ virtual void setVrboxcolInfo(stage_vrboxcol_info_class* i_VrboxcolInfo) { mVrboxcolInfo = i_VrboxcolInfo; }
    /* vt[27] */ virtual stage_vrboxcol_info_class* getVrboxcolInfo(void) const { return mVrboxcolInfo; }
    /* vt[28] */ virtual void setPlightInfo(stage_plight_info_class* i_PlightInfo) { mPlightInfo = i_PlightInfo; }
    /* vt[29] */ virtual stage_plight_info_class* getPlightInfo(void) const { return mPlightInfo; }
    /* vt[30] */ virtual void setPaletteNumInfo(int i_PaletteNumInfo) { mPaletteNumInfo = i_PaletteNumInfo; }
    /* vt[31] */ virtual int getPaletteNumInfo(void) const { return mPaletteNumInfo; }
    /* vt[32] */ virtual void setPselectNumInfo(int i_PselectNumInfo) { mPselectNumInfo = i_PselectNumInfo; }
    /* vt[33] */ virtual int getPselectNumInfo(void) const { return mPselectNumInfo; }
    /* vt[34] */ virtual void setEnvrNumInfo(int i_EnvrNumInfo) { mEnvrNumInfo = i_EnvrNumInfo; }
    /* vt[35] */ virtual int getEnvrNumInfo(void) const { return mEnvrNumInfo; }
    /* vt[36] */ virtual void setVrboxNumInfo(int i_VrboxNumInfo) { mVrboxNumInfo = i_VrboxNumInfo; }
    /* vt[37] */ virtual int getVrboxNumInfo(void) const { return mVrboxNumInfo; }
    /* vt[38] */ virtual void setVrboxcolNumInfo(int i_VrboxcolNumInfo) { mVrboxcolNumInfo = i_VrboxcolNumInfo; }
    /* vt[39] */ virtual int getVrboxcolNumInfo(void) const { return mVrboxcolNumInfo; }
    /* vt[42] */ virtual void setLightVecInfo(stage_pure_lightvec_info_class* i_LightVecInfo) {
        UNUSED(i_LightVecInfo);
        dStage_SetErrorStage();
        OSReport("stage non LightVec data !!\n");
        JUT_ASSERT(3003, FALSE);
    }
    /* vt[43] */ virtual stage_pure_lightvec_info_class* getLightVecInfo(void) const {
        OSReport("stage non LightVec data !!\n");
        JUT_ASSERT(3007, FALSE);
        return 0;
    }
    /* vt[44] */ virtual void setLightVecInfoNum(int i_LightVecInfoNum) { 
        UNUSED(i_LightVecInfoNum);
        dStage_SetErrorStage();
        OSReport("stage non LightVecNum data !!\n");
        JUT_ASSERT(3014, FALSE);
    }
    /* vt[45] */ virtual int getLightVecInfoNum(void) const {
        OSReport("stage non LightVecNum data !!\n");
        JUT_ASSERT(3018, FALSE);
        return 0;
    }
    /* vt[40] */ virtual void setPlightNumInfo(int i_PlightNumInfo) { mPlightNumInfo = i_PlightNumInfo; }
    /* vt[41] */ virtual int getPlightNumInfo(void) const { return mPlightNumInfo; }
    /* vt[46] */ virtual void setStagInfo(stage_stag_info_class* i_StagInfo) { mStagInfo = i_StagInfo; }
    /* vt[47] */ virtual stage_stag_info_class* getStagInfo(void) const { return mStagInfo; }
    /* vt[48] */ virtual void setSclsInfo(stage_scls_info_dummy_class* i_SclsInfo) { mSclsInfo = i_SclsInfo; }
    /* vt[49] */ virtual stage_scls_info_dummy_class* getSclsInfo(void) const { return mSclsInfo; }
    /* vt[50] */ virtual void setPntInfo(dStage_dPnt_c* i_PntInfo) { mPntInfo = i_PntInfo; }
    /* vt[51] */ virtual dStage_dPnt_c* getPntInf(void) const { return mPntInfo; }
    /* vt[52] */ virtual void setPathInfo(dStage_dPath_c* i_PathInfo) { mPathInfo = i_PathInfo; }
    /* vt[53] */ virtual dStage_dPath_c* getPathInf(void) const { return mPathInfo; }
    /* vt[54] */ virtual void setPnt2Info(dStage_dPnt_c* i_Pnt2Info) { mPnt2Info = i_Pnt2Info; }
    /* vt[55] */ virtual dStage_dPnt_c* getPnt2Inf(void) const { return mPnt2Info; }
    /* vt[56] */ virtual void setPath2Info(dStage_dPath_c* i_Path2Info) { mPath2Info = i_Path2Info; }
    /* vt[57] */ virtual dStage_dPath_c* getPath2Inf(void) const { return mPath2Info; }
    /* vt[58] */ virtual void setSoundInf(dStage_SoundInfo_c* i_SoundInf) { mSoundInf = i_SoundInf; }
    /* vt[59] */ virtual dStage_SoundInfo_c* getSoundInf(void) const { return mSoundInf; }
    /* vt[60] */ virtual void setSoundInfCL(dStage_SoundInfo_c* i_SoundInfCL) { mSoundInfCL = i_SoundInfCL; }
    /* vt[61] */ virtual dStage_SoundInfo_c* getSoundInfCL(void) const { return mSoundInfCL; }
    /* vt[62] */ virtual void setMapEventInfo(dStage_MapEventInfo_c* i_MapEventInfo) { mMapEventInfo = i_MapEventInfo; }
    /* vt[63] */ virtual dStage_MapEventInfo_c* getMapEventInfo(void) const { return mMapEventInfo; }
    /* vt[64] */ virtual void setFileList2Info(dStage_FileList2_dt_c* list) {
        UNUSED(list);
        dStage_SetErrorStage();
        OSReport("stage non filelist2 data!\n");
        JUT_ASSERT(3123, FALSE);
    }
    /* vt[65] */ virtual dStage_FileList2_dt_c* getFileList2Info(void) const {
        OSReport("stage non filelist2 data!\n");
        JUT_ASSERT(3127, FALSE);
        return 0;
    }
    /* vt[66] */ virtual void setFileListInfo(dStage_FileList_dt_c* list) {
        UNUSED(list);
        dStage_SetErrorStage();
        OSReport("stage non filelist data!\n");
        JUT_ASSERT(3138, FALSE);
    }
    /* vt[67] */ virtual dStage_FileList_dt_c* getFileListInfo(void) const {
        OSReport("stage non filelist data!\n");
        JUT_ASSERT(3142, FALSE);
        return 0;
    }
    /* vt[68] */ virtual void setFloorInfo(dStage_FloorInfo_c* i_FloorInfo) { mFloorInfo = i_FloorInfo; }
    /* vt[69] */ virtual dStage_FloorInfo_c* getFloorInfo(void) const { return mFloorInfo; }
    /* vt[70] */ virtual void setMemoryConfig(dStage_MemoryConfig_c* i_MemoryConfig) { mMemoryConfig = i_MemoryConfig; }
    /* vt[71] */ virtual dStage_MemoryConfig_c* getMemoryConfig(void) const { return mMemoryConfig; }
    /* vt[72] */ virtual void setMemoryMap(dStage_MemoryMap_c* i_MemoryMap) { mMemoryMap = i_MemoryMap; }
    /* vt[73] */ virtual dStage_MemoryMap_c* getMemoryMap(void) const { return mMemoryMap; }
    /* vt[74] */ virtual void setMulti(dStage_Multi_c* i_Multi) { mMulti = i_Multi; }
    /* vt[75] */ virtual dStage_Multi_c* getMulti(void) const { return mMulti; }
    /* vt[76] */ virtual void setOldMulti(void) { mOldMulti = mMulti; }
    /* vt[77] */ virtual void resetOldMulti(void) { mOldMulti = NULL; }
    /* vt[78] */ virtual dStage_Multi_c* getOldMulti(void) const { return mOldMulti; }
    /* vt[79] */ virtual void setLbnk(dStage_Lbnk_c* lbnk) {
        UNUSED(lbnk);
        dStage_SetErrorStage();
        OSReport("stage non Lbnk data!\n");
        JUT_ASSERT(3231, FALSE);
    }
    /* vt[80] */ virtual dStage_Lbnk_c* getLbnk(void) const {
        OSReport("stage non Lbnk data!\n");
        JUT_ASSERT(3238, FALSE);
        return 0;
    }
    /* vt[81] */ virtual void setTresure(stage_tresure_class* i_Tresure) { mTresure = i_Tresure; }
    /* vt[82] */ virtual stage_tresure_class* getTresure(void) const { return mTresure; }
    /* vt[83] */ virtual void setDMap(dStage_DMap_c* i_DMap) { mDMap = i_DMap; }
    /* vt[84] */ virtual dStage_DMap_c* getDMap(void) const { return mDMap; }
    /* vt[85] */ virtual void setDrTg(stage_tgsc_class* i_DrTg) { mDrTg = i_DrTg; }
    /* vt[86] */ virtual stage_tgsc_class* getDrTg(void) const { return mDrTg; }
    /* vt[87] */ virtual void setDoor(stage_tgsc_class* i_Door) { mDoor = i_Door; }
    /* vt[88] */ virtual stage_tgsc_class* getDoor(void) const { return mDoor; }
#if DEBUG
    virtual void setUnit(void* i_Unit) {
        UNUSED(i_Unit);
        OSReport("stage non unit list data !!\n");
        JUT_ASSERT(3321, 0);
    }
    virtual void* getUnit() {
        OSReport("stage non unit list data !!\n");
        JUT_ASSERT(3325, 0);
        return 0;
    }
#endif
    /* vt[89] */ virtual void setMapPath(void* i_MapPath) { return; }
    /* vt[90] */ virtual void* getMapPath(void) { return NULL; }
    /* vt[91] */ virtual void setElst(dStage_Elst_c* i_Elst) { mElst = i_Elst; }
    /* vt[92] */ virtual dStage_Elst_c* getElst(void);

    s16 getWorldRollAngleX() const { return (s16)mWorldRollAngleX; }
    s16 getWorldRollDirAngleY() const { return mWorldRollDirAngleY; }

public:
    /* 0x08 */ stage_camera_class* mCamera;
    /* 0x0C */ stage_arrow_class* mArrow;
    /* 0x10 */ stage_actor_class* mPlayer;
    /* 0x14 */ roomRead_class* mRoom;
    /* 0x18 */ stage_map_info_class* mMapInfo;
    /* 0x1C */ stage_map_info_dummy_class* mMapInfoBase;
    /* 0x20 */ stage_palette_info_class* mPaletteInfo;
    /* 0x24 */ stage_pselect_info_class* mPselectInfo;
    /* 0x28 */ stage_envr_info_class* mEnvrInfo;
    /* 0x2C */ stage_vrbox_info_class* mVrboxInfo;
    /* 0x30 */ stage_vrboxcol_info_class* mVrboxcolInfo;
    /* 0x34 */ stage_plight_info_class* mPlightInfo;
    /* 0x38 */ dStage_MapEventInfo_c* mMapEventInfo;
    /* 0x3C */ u32 mPaletteNumInfo;
    /* 0x40 */ u32 mPselectNumInfo;
    /* 0x44 */ u32 mEnvrNumInfo;
    /* 0x48 */ u32 mVrboxNumInfo;
    /* 0x4C */ int mVrboxcolNumInfo;
    /* 0x50 */ u32 mPlightNumInfo;
    /* 0x54 */ u16 mPlayerNum;
    /* 0x56 */ s16 mWorldRollAngleX;
    /* 0x58 */ s16 mWorldRollDirAngleY;
    /* 0x5A */ u16 field_0x5a;
    /* 0x5C */ stage_stag_info_class* mStagInfo;
    /* 0x60 */ stage_scls_info_dummy_class* mSclsInfo;
    /* 0x64 */ dStage_dPnt_c* mPntInfo;
    /* 0x68 */ dStage_dPath_c* mPathInfo;
    /* 0x6C */ dStage_dPnt_c* mPnt2Info;
    /* 0x70 */ dStage_dPath_c* mPath2Info;
    /* 0x74 */ dStage_SoundInfo_c* mSoundInf;
    /* 0x78 */ dStage_SoundInfo_c* mSoundInfCL;
    /* 0x7C */ dStage_FloorInfo_c* mFloorInfo;
    /* 0x80 */ dStage_MemoryConfig_c* mMemoryConfig;
    /* 0x84 */ dStage_MemoryMap_c* mMemoryMap;
    /* 0x88 */ dStage_Multi_c* mMulti;
    /* 0x8C */ dStage_Multi_c* mOldMulti;
    /* 0x90 */ stage_tresure_class* mTresure;
    /* 0x94 */ dStage_DMap_c* mDMap;
    /* 0x98 */ stage_tgsc_class* mDrTg;
    /* 0x9C */ stage_tgsc_class* mDoor;
    /* 0xA0 */ dStage_Elst_c* mElst;
};

class dBgW_Base;

class dStage_roomStatus_c {
public:
    /* 0x000 */ dStage_roomDt_c mRoomDt;
    /* 0x06C */ dKy_tevstr_c mKyTevStr;
    /* 0x3F4 */ u8 mFlag;
    /* 0x3F5 */ bool mDraw;
    /* 0x3F6 */ s8 mZoneCount;
    /* 0x3F7 */ s8 mZoneNo;
    /* 0x3F8 */ s8 mMemBlockID;
    /* 0x3F9 */ u8 mRegionNo;
    /* 0x3FC */ fpc_ProcID mProcID;
    /* 0x400 */ dBgW_Base* mpBgW;

    int getZoneNo() const { return mZoneNo; }
};  // Size: 0x404

STATIC_ASSERT(sizeof(dStage_roomStatus_c) == 0x404);

class dBgp_c;
class dStage_roomControl_c {
public:
    class roomDzs_c {
    public:
        roomDzs_c() { m_num = 0; }
        void create(u8);
        void remove();
        void* add(u8, u8);

        /* 0x00 */ u8 m_num;
        /* 0x04 */ void** m_dzs;
    };

    /**
     * dStage_bankName (made up name)
     * - Represent's Stage resource "name.bin"
     */ 
    struct dStage_bankName {
        /* 0x0 */ u8 m_num;             // number of name entries
        /* 0x1 */ char m_names[1][10];  // variable number of name entries (up to 32 max), each 10 characters long
    };

    /**
     * dStage_bankDataEntry (made up name)
     * - Entry that goes into dStage_bankData
     */ 
    struct dStage_bankDataEntry {
        u8 roomNo;       // required room ID for the bank
        u8 layerNo;      // required layer for the bank
        u8 nameIDs[32];  // indexes into dStage_bankName m_names list. 0xFF used for unused entries
    };

    /**
     * dStage_bankData (made up name)
     * - Represent's Stage resource "bank.bin"
     */ 
    struct dStage_bankData {
        /* 0x0 */ u8 m_num;
        /* 0x1 */ dStage_bankDataEntry m_entries[1];  // variable number of entries
    };

    dStage_roomControl_c() {}
    void init(void);
    void initZone();
    dStage_roomDt_c* getStatusRoomDt(int);
    static JKRExpHeap* getMemoryBlock(int);
    static void setStayNo(int);
    static void setNextStayNo(int);
    BOOL checkRoomDisp(int) const;
    int loadRoom(int, u8*, bool);
    void zoneCountCheck(int) const;
    static JKRExpHeap* createMemoryBlock(int, u32);
    static void destroyMemoryBlock();
    static void setArcBank(int, char const*);
    static char* getArcBank(int);
    static bool resetArchiveBank(int);

    static s8 getRoomReadId() { return mRoomReadId; }
    static void setRoomReadId(s8 id) { mRoomReadId = id; }
    static fpc_ProcID getProcID() { return mProcID; }
    static void setProcID(fpc_ProcID id) { mProcID = id; }
    static int getStayNo() { return mStayNo; }
    static int getNextStayNo() { return mNextStayNo; }
    static BOOL GetTimePass() { return m_time_pass; }
    static void SetTimePass(int i_TimePass) { m_time_pass = i_TimePass; }
    static dStage_bankName* getArcBankName() { return mArcBankName; }
    static dStage_bankData* getArcBankData() { return mArcBankData; }
    static void createRoomDzs(u8 i_num) { m_roomDzs.create(i_num); }
    static void removeRoomDzs() { m_roomDzs.remove(); }
    static void* addRoomDzs(u8 i_num, u8 roomNo) { return m_roomDzs.add(i_num, roomNo); }
    dKy_tevstr_c* getTevStr(int i_roomNo) {
        JUT_ASSERT(2675, 0 <= i_roomNo && i_roomNo < 64);
        return &mStatus[i_roomNo].mKyTevStr;
    }
    void setStatusFlag(int i_roomNo, u8 flag) {
        JUT_ASSERT(2679, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mFlag = flag;
    }
    void onStatusFlag(int i_roomNo, u8 flag) {
        JUT_ASSERT(2691, 0 <= i_roomNo && i_roomNo < 64);
        return cLib_onBit(mStatus[i_roomNo].mFlag, flag);
    }
    void offStatusFlag(int i_roomNo, u8 flag) {
        JUT_ASSERT(2695, 0 <= i_roomNo && i_roomNo < 64);
        return cLib_offBit(mStatus[i_roomNo].mFlag, flag);
    }
    u8 checkStatusFlag(int i_roomNo, u8 flag) const {
        JUT_ASSERT(2699, 0 <= i_roomNo && i_roomNo < 64);
        return cLib_checkBit((u8) mStatus[i_roomNo].mFlag, flag);
    }
    static void setFileList2(int i_roomNo, dStage_FileList2_dt_c* list) {
        JUT_ASSERT(2711, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mRoomDt.setFileList2Info(list);
    }
    static dStage_FileList2_dt_c* getFileList2(int i_roomNo) {
        JUT_ASSERT(2715, 0 <= i_roomNo && i_roomNo < 64);
        return mStatus[i_roomNo].mRoomDt.getFileList2Info();
    }
    static void onStatusDraw(int i_roomNo) {
        JUT_ASSERT(2725, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mDraw = true;
    }
    static void setZoneCount(int i_roomNo, int count) {
        JUT_ASSERT(2737, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mZoneCount = count;
    }
    static void setZoneNo(int i_roomNo, int i_zoneNo) {
        JUT_ASSERT(2745, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mZoneNo = i_zoneNo;
    }
    static int getZoneNo(int i_roomNo) {
        JUT_ASSERT(2749, 0 <= i_roomNo && i_roomNo < 64);
        return mStatus[i_roomNo].mZoneNo;
    }
    static void setMemoryBlockID(int i_roomNo, int i_blockID) {
        JUT_ASSERT(2753, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mMemBlockID = i_blockID;
    }
    static int getMemoryBlockID(int i_roomNo) {
        JUT_ASSERT(2757, 0 <= i_roomNo && i_roomNo < 64);
        return mStatus[i_roomNo].mMemBlockID;
    }
    static void setRegionNo(int i_roomNo, u8 i_regionNo) {
        JUT_ASSERT(2762, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mRegionNo = i_regionNo;
    }
    static u8 getRegionNo(int i_roomNo) {
        JUT_ASSERT(2766, 0 <= i_roomNo && i_roomNo < 64);
        return mStatus[i_roomNo].mRegionNo;
    }
    static void setStatusProcID(int i_roomNo, fpc_ProcID i_id) {
        JUT_ASSERT(2770, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mProcID = i_id;
    }
    static fpc_ProcID getStatusProcID(int i_roomNo) {
        JUT_ASSERT(2774, 0 <= i_roomNo && i_roomNo < 64);
        return mStatus[i_roomNo].mProcID;
    }
    static void setBgW(int i_roomNo, dBgW_Base* i_bgw) {
        JUT_ASSERT(2778, 0 <= i_roomNo && i_roomNo < 64);
        mStatus[i_roomNo].mpBgW = i_bgw;
    }
    static dBgp_c* getBgp(int i_roomNo) {
#if DEBUG
        return (dBgp_c*)mBgp[i_roomNo];
#else
        return NULL;
#endif
    }
    static JKRExpHeap* getMemoryBlockHeap(int i_no) { return mMemoryBlock[i_no]; }
    static char* getDemoArcName() { return mDemoArcName; }
    static void offNoChangeRoom() { mNoChangeRoom = false; }
    static void onNoChangeRoom() { mNoChangeRoom = true; }

    #if DEBUG
    static void setBgp(int i_roomNo, void* i_bgp) {
        mBgp[i_roomNo] = i_bgp;
    }
    #endif

    static const int MEMORY_BLOCK_MAX = 19;

    static JKRExpHeap* mMemoryBlock[MEMORY_BLOCK_MAX];
    static char mArcBank[32][10];
    static dStage_roomStatus_c mStatus[0x40];
    static char mDemoArcName[10];
    static fpc_ProcID mProcID;
    static dStage_bankName* mArcBankName;
    static dStage_bankData* mArcBankData;
    static roomDzs_c m_roomDzs;
    static s8 mStayNo;
    static s8 mOldStayNo;
    static s8 mNextStayNo;
    static u8 m_time_pass;
    static u8 mNoChangeRoom;
    static s8 mRoomReadId;

    #if DEBUG
    static void onNoArcBank() {
        mNoArcBank = true;
    } 

    static void* mBgp[];
    static u8 mNoArcBank;
    #endif

private:
    /* 0x0 */ u8 field_0x0[4];
};

class dStage_startStage_c {
public:
    void set(const char*, s8, s16, s8);
    const char* getName() const { return mName; }
    s16 getPoint() const { return mPoint; }
    s8 getRoomNo() const { return mRoomNo; }
    s8 getLayer() const { return mLayer; }
    void setLayer(s8 layer) { mLayer = layer; }
    s8 getDarkArea() const { return mDarkArea; }
    void setDarkArea(s8 darkArea) { mDarkArea = darkArea; }

private:
    /* 0x0 */ char mName[8];
    /* 0x8 */ s16 mPoint;
    /* 0xA */ s8 mRoomNo;
    /* 0xB */ s8 mLayer;
    /* 0xC */ s8 mDarkArea;
};

class dStage_nextStage_c : public dStage_startStage_c {
public:
    dStage_nextStage_c() {
        enabled = 0;  // TODO: maybe wrong
    }
    void set(const char*, s8, s16, s8, s8, u8);
    void offEnable() { enabled = 0; }
    BOOL isEnable() const { return enabled; }
    s8 getWipe() const { return wipe; }
    u8 getWipeSpeed() const { return wipe_speed; }
    dStage_startStage_c* getStartStage() { return this; }

private:
    s8 enabled;
    s8 wipe;
    u8 wipe_speed;
};

// unknown name
struct dStage_objectNameInf {
    /* 0x00 */ char name[8];
    /* 0x08 */ s16 procname;
    /* 0x0A */ s8 argument;
};  // Size: 0xC

class dStage_KeepDoorInfo {
public:
    /* 0x000 */ int mNum;
    /* 0x004 */ stage_tgsc_data_class mDrTgData[0x40];
};  // Size = 0x904

typedef int (*dStage_Func)(dStage_dt_c*, void*, int, void*);

struct FuncTable {
    char identifier[5];
    dStage_Func function;
};

enum dStage_SaveTbl {
    dStage_SaveTbl_ORDON,
    dStage_SaveTbl_PRISON,
    dStage_SaveTbl_FARON,
    dStage_SaveTbl_ELDIN,
    dStage_SaveTbl_LANAYRU,
    dStage_SaveTbl_FIELD = 6,
    dStage_SaveTbl_GROVE,
    dStage_SaveTbl_SNOWPEAK,
    dStage_SaveTbl_CASTLE_TOWN,
    dStage_SaveTbl_DESERT,
    dStage_SaveTbl_FISHING_POND,

    dStage_SaveTbl_LV1 = 16,
    dStage_SaveTbl_LV2,
    dStage_SaveTbl_LV3,
    dStage_SaveTbl_LV4,
    dStage_SaveTbl_LV5,
    dStage_SaveTbl_LV6,
    dStage_SaveTbl_LV7,
    dStage_SaveTbl_LV8,
    dStage_SaveTbl_LV9,
    dStage_SaveTbl_CAVE1,
    dStage_SaveTbl_CAVE2,
    dStage_SaveTbl_GROTTO,
};

const char* dStage_getName2(s16, s8);
dStage_objectNameInf* dStage_searchName(const char*);
static int dStage_stageKeepTresureInit(dStage_dt_c*, void*, int, void*);
static int dStage_filiInfo2Init(dStage_dt_c*, void*, int, void*);
static int dStage_mapPathInitCommonLayer(dStage_dt_c*, void*, int, void*);
static int dStage_mapPathInit(dStage_dt_c*, void*, int, void*);
static int dStage_memaInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_mecoInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_stagInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_soundInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_lgtvInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_envrInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_pselectInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_paletteInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_vrboxcolInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_roomDrtgInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_tgscInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_actorInit(dStage_dt_c*, void*, int, void*);
static int dStage_layerTresureInit(dStage_dt_c*, void*, int, void*);
static int dStage_elstInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_rppnInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_rpatInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_multInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_playerInit(dStage_dt_c*, void*, int, void*);
static int dStage_cameraInit(dStage_dt_c*, void*, int, void*);
static int dStage_actorInit_always(dStage_dt_c*, void*, int, void*);
static int dStage_roomReadInit(dStage_dt_c*, void*, int, void*);
static int dStage_arrowInit(dStage_dt_c*, void*, int, void*);
static int dStage_vrboxInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_sclsInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_tgscInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_plightInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_ppntInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_pathInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_filiInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_stageDrtgInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_floorInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_dmapInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_stEventInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_soundInfoInitCL(dStage_dt_c*, void*, int, void*);
static int dStage_RoomCameraInit(dStage_dt_c*, void*, int, void*);
static int dStage_lbnkInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_actorCommonLayerInit(dStage_dt_c*, void*, int, void*);
static int dStage_roomTresureInit(dStage_dt_c*, void*, int, void*);
static int dStage_tgscCommonLayerInit(dStage_dt_c*, void*, int, void*);
static int dStage_mapEventInfoInit(dStage_dt_c*, void*, int, void*);
static int dStage_fieldMapTresureInit(dStage_dt_c*, void*, int, void*);
static int dStage_fieldMapFiliInfo2Init(dStage_dt_c*, void*, int, void*);
static int dStage_fieldMapMapPathInit(dStage_dt_c*, void*, int, void*);

s8 dStage_roomRead_dt_c_GetReverbStage(roomRead_class&, int);
int dStage_changeScene(int i_exitId, f32 i_speed, u32 i_mode, s8 i_roomNo, s16 i_angle, int i_layerOverride);
void dStage_infoCreate();
u32 dStage_stagInfo_GetParticleNo(stage_stag_info_class* p_info, int layer);
int dStage_changeSceneExitId(cBgS_PolyInfo& param_0, f32 speed, u32 mode, s8 roomNo, s16 angle);
int dStage_changeScene4Event(int i_exitId, s8 room_no, int i_wipe, bool param_3, f32 speed,
                             u32 mode, s16 angle, int param_7);
void dStage_Create();
void dStage_Delete();
void dStage_restartRoom(u32 roomParam, u32 mode, int param_2);
int dStage_RoomCheck(cBgS_GndChk* gndChk);
void dStage_dt_c_roomReLoader(void* i_data, dStage_dt_c* stageDt, int param_2);
void dStage_dt_c_roomLoader(void* i_data, dStage_dt_c* stageDt, int param_2);
dStage_KeepDoorInfo* dStage_GetKeepDoorInfo();
dStage_KeepDoorInfo* dStage_GetRoomKeepDoorInfo();
void dStage_dt_c_fieldMapLoader(void* i_data, dStage_dt_c* i_stage);

#if DEBUG
void dStage_DebugDisp();
#endif

#define dStage_NAME_LENGTH 8
const char* dStage_getName(s16 procName, s8 argument);

#if VERSION == VERSION_WII_USA_R0
void dStage_escapeRestart();
#endif

inline s32 dStage_roomRead_dt_c_ChkBg(u8 param_0) {
    return param_0 & 0x80;
}

inline s32 dStage_roomRead_dt_c_GetVrboxswitch(roomRead_data_class& data) {
    return data.field_0x2 & 8;
}

inline s32 dStage_roomRead_dt_c_GetTimePass(roomRead_data_class& data) {
    return data.field_0x2 & 3;
}

inline int dStage_roomRead_dt_c_GetLoadRoomIndex(u8 param_0) {
    return param_0 & 0x3f;
}

inline u32 dStage_roomRead_dt_c_GetReverb(roomRead_data_class& room) {
    return room.field_0x1 & 0x7F;
}

inline u32 dStage_stagInfo_GetSTType(stage_stag_info_class* pstag) {
    return (pstag->field_0x0c >> 16) & 7;
}

inline int dStage_stagInfo_GetEscapeWarp(stage_stag_info_class* pstag) {
    return (pstag->field_0x10 >> 24);
}

inline u32 dStage_stagInfo_GetMiniMap(stage_stag_info_class* pstag) {
    return (pstag->field_0x0a >> 0xD) & 7;
}

inline u32 dStage_stagInfo_GetParticleNo(stage_stag_info_class* p_info) {
    return (p_info->field_0x0a >> 0x3) & 0xFF;
}

inline s32 dStage_stagInfo_GetUpButton(stage_stag_info_class* p_info) {
    return p_info->field_0x0a & 7;
}

inline u32 dStage_stagInfo_GetArg0(stage_stag_info_class* p_info) {
    return (p_info->field_0x0c >> 0x14) & 0xFF;
}

inline int dStage_stagInfo_GetMsgGroup(stage_stag_info_class* p_info) {
    return p_info->mMsgGroup;
}

inline s32 dStage_stagInfo_GetSaveTbl(stage_stag_info_class* param_0) {
    return param_0->field_0x09 >> 1 & 0x1f;
}

inline int dStage_stagInfo_GetTimeH(stage_stag_info_class* p_info) {
    s8 time = (p_info->field_0x0c >> 8) & 0xFF;
    return time;
}

inline BOOL dStage_staginfo_GetArchiveHeap(stage_stag_info_class* p_info) {
    return p_info->field_0x0a & 0x1000;
}

inline int dStage_stagInfo_GetGapLevel(stage_stag_info_class* pstag) {
    return pstag->mGapLevel;
}

inline int dStage_stagInfo_GetRangeUp(stage_stag_info_class* pstag) {
    return pstag->mRangeUp;
}

inline int dStage_stagInfo_GetRangeDown(stage_stag_info_class* pstag) {
    return pstag->mRangeDown;
}

inline u32 dStage_stagInfo_ChkKeyDisp(stage_stag_info_class* pstag) {
    return pstag->field_0x09 & 1;
}

inline int dStage_stagInfo_GetWolfDashType(stage_stag_info_class* pstag) {
    return (pstag->field_0x09 >> 6) & 3;
}

inline u16 dStage_stagInfo_GetStageTitleNo(stage_stag_info_class* pstag) {
    return pstag->mStageTitleNo;
}

inline int dStage_stagInfo_DefaultCameraType(stage_stag_info_class* pstag) {
    return pstag->mCameraType;
}

inline u16 dStage_stagInfo_GetCullPoint(stage_stag_info_class* pstag) {
    return pstag->field_0x10 & 0xFFFF;
}

inline u8 dStage_sclsInfo_getSceneLayer(stage_scls_info_class* p_info) {
    return p_info->field_0xb & 0xF;
}

inline s32 dStage_sclsInfo_getWipe(stage_scls_info_class* p_info) {
    return p_info->mWipe;
}

inline s32 dStage_sclsInfo_getWipeTime(stage_scls_info_class* p_info) {
    return (p_info->field_0xb >> 5) & 7;
}

inline int dStage_sclsInfo_getTimeH(stage_scls_info_class* p_info) {
    return ((p_info->field_0xa >> 4) & 0xF) | (p_info->field_0xb & 0x10);
}

inline u32 dStage_FileList_dt_getMiniMap(dStage_FileList_dt_c* p_fList) {
    return p_fList->mParameters >> 3 & 7;
}

inline u32 dStage_FileList_dt_GetEnemyAppear1Flag(dStage_FileList_dt_c* p_fList) {
    return p_fList->mParameters & 0x20000000;
}

inline u8 dStage_FileList_dt_GetBitSw(dStage_FileList_dt_c* p_fList) {
    return p_fList->mBitSw;
}

inline f32 dStage_FileList_dt_SeaLevel(dStage_FileList_dt_c* p_fList) {
    return p_fList->mSeaLevel;
}

inline int dStage_FileList_dt_GlobalWindLevel(dStage_FileList_dt_c* i_fili) {
    return (i_fili->mParameters >> 0x12) & 3;
}

inline int dStage_FileList_dt_GlobalWindDir(dStage_FileList_dt_c* i_fili) {
    return (i_fili->mParameters >> 0xF) & 7;
}

inline u8 dStage_FileList_dt_GetDefaultCamera(dStage_FileList_dt_c* p_fList) {
    return p_fList->mDefaultCamera;
}

inline int dStage_FileList_dt_GRASSLIGHT(dStage_FileList_dt_c* p_fList) {
    return (p_fList->mParameters >> 7) & 0xFF;
}

inline u16 dStage_FileList_dt_GetMsg(dStage_FileList_dt_c* p_fList) {
    return p_fList->mMsg;
}

inline f32 dStage_FileList2_dt_GetLeftRmX(const dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mLeftRmX;
}

inline f32 dStage_FileList2_dt_GetRightRmX(const dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mRightRmX;
}

inline f32 dStage_FileList2_dt_GetInnerRmZ(const dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mInnerRmZ;
}

inline f32 dStage_FileList2_dt_GetFrontRmZ(const dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mFrontRmZ;
}

inline s8 dStage_FileList2_dt_GetMinFloorNo(dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mMinFloorNo;
}

inline s8 dStage_FileList2_dt_GetMaxFloorNo(dStage_FileList2_dt_c* p_fList2) {
    return p_fList2->mMaxFloorNo;
}

inline int dStage_MapEvent_dt_c_getEventSCutSW(dStage_MapEvent_dt_c* event) {
    return event->field_0x8 & 1;
}

inline int dStage_MapEvent_dt_c_getEventSCutType(dStage_MapEvent_dt_c* event) {
    return event->field_0x8 >> 1 & 3;
}

inline int dStage_lbnkWIND(dStage_Lbnk_dt_c* i_data) {
    return (i_data->field_0x2 >> 3) & 7;
}

inline int dStage_lbnkWlevel(dStage_Lbnk_dt_c* i_data) {
    return (i_data->field_0x2 >> 6) & 3;
}

#endif /* D_D_STAGE_H */