d_a_ppolamp OK (#2535)

* d_a_ppolamp OK

* Remove include

* d_a_tag_Lv6Gate OK
This commit is contained in:
hatal175
2025-07-15 01:28:47 -07:00
committed by GitHub
parent 07403fe796
commit aeeaf91054
10 changed files with 433 additions and 777 deletions
+9 -7
View File
@@ -1,7 +1,7 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x0000002C; // type:function size:0x2C scope:global
_unresolved = .text:0x00000058; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:local
__dt__11daPPolamp_cFv = .text:0x00000098; // type:function size:0xA4 scope:global
create__11daPPolamp_cFv = .text:0x0000013C; // type:function size:0x128 scope:global
execute__11daPPolamp_cFv = .text:0x00000264; // type:function size:0x60 scope:global
@@ -12,11 +12,11 @@ setPclModelMtx__11daPPolamp_cFv = .text:0x000004E8; // type:function size:0xF4 s
createHeap__11daPPolamp_cFv = .text:0x000005DC; // type:function size:0x114 scope:global
moveSwing__11daPPolamp_cFv = .text:0x000006F0; // type:function size:0x15C scope:global
initParam__11daPPolamp_cFv = .text:0x0000084C; // type:function size:0x34 scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:local
__dt__12J3DFrameCtrlFv = .text:0x0000090C; // type:function size:0x48 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:global
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:global
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:local
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:local
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
...rodata.0 = .rodata:0x00000000; // type:label scope:local
@@ -33,8 +33,8 @@ _dtors = .dtors:0x00000000; // type:label scope:global
@3928 = .rodata:0x00000040; // type:object size:0x8 scope:local
@3936 = .rodata:0x00000048; // type:object size:0x4 scope:local align:4 data:float
@stringBase0 = .rodata:0x0000004C; // type:object size:0x8 scope:local data:string_table
l_arcName = .data:0x00000000; // type:object size:0x4 scope:global
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:global
l_arcName = .data:0x00000000; // type:object size:0x4 scope:local
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:local
g_profile_PPolamp = .data:0x00000024; // type:object size:0x30 scope:global
__vt__12J3DFrameCtrl = .data:0x00000054; // type:object size:0xC scope:global
__vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@@ -55,7 +55,9 @@ __vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@1012 = .bss:0x00000034; // type:object size:0x1 scope:local
@1010 = .bss:0x00000038; // type:object size:0x1 scope:local
@1009 = .bss:0x0000003C; // type:object size:0x1 scope:local
init$1515 = .bss:0x0000003D; // type:object size:0x1 scope:local
TEV_COLOR_1$3795 = .bss:0x00000040; // type:object size:0x8 scope:local
init$1520 = .bss:0x00000049; // type:object size:0x1 scope:local
TEV_COLOR_2$3800 = .bss:0x0000004C; // type:object size:0x8 scope:local
sInstance__40JASGlobalInstance<19JASDefaultBankTable> = .bss:0x00000054; // type:object size:0x4 scope:global
sInstance__35JASGlobalInstance<14JASAudioThread> = .bss:0x00000058; // type:object size:0x4 scope:global
+9 -7
View File
@@ -1,7 +1,7 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x0000002C; // type:function size:0x2C scope:global
_unresolved = .text:0x00000058; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:local
__dt__11daPPolamp_cFv = .text:0x00000098; // type:function size:0xA4 scope:global
create__11daPPolamp_cFv = .text:0x0000013C; // type:function size:0x128 scope:global
execute__11daPPolamp_cFv = .text:0x00000264; // type:function size:0x60 scope:global
@@ -12,11 +12,11 @@ setPclModelMtx__11daPPolamp_cFv = .text:0x000004E8; // type:function size:0xF4 s
createHeap__11daPPolamp_cFv = .text:0x000005DC; // type:function size:0x114 scope:global
moveSwing__11daPPolamp_cFv = .text:0x000006F0; // type:function size:0x15C scope:global
initParam__11daPPolamp_cFv = .text:0x0000084C; // type:function size:0x34 scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:local
__dt__12J3DFrameCtrlFv = .text:0x0000090C; // type:function size:0x48 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:global
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:global
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:local
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:local
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
...rodata.0 = .rodata:0x00000000; // type:label scope:local
@@ -33,8 +33,8 @@ _dtors = .dtors:0x00000000; // type:label scope:global
@3928 = .rodata:0x00000040; // type:object size:0x8 scope:local
@3936 = .rodata:0x00000048; // type:object size:0x4 scope:local align:4 data:float
@stringBase0 = .rodata:0x0000004C; // type:object size:0x8 scope:local data:string_table
l_arcName = .data:0x00000000; // type:object size:0x4 scope:global
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:global
l_arcName = .data:0x00000000; // type:object size:0x4 scope:local
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:local
g_profile_PPolamp = .data:0x00000024; // type:object size:0x30 scope:global
__vt__12J3DFrameCtrl = .data:0x00000054; // type:object size:0xC scope:global
__vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@@ -55,7 +55,9 @@ __vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@1012 = .bss:0x00000034; // type:object size:0x1 scope:local
@1010 = .bss:0x00000038; // type:object size:0x1 scope:local
@1009 = .bss:0x0000003C; // type:object size:0x1 scope:local
init$1515 = .bss:0x0000003D; // type:object size:0x1 scope:local
TEV_COLOR_1$3795 = .bss:0x00000040; // type:object size:0x8 scope:local
init$1520 = .bss:0x00000049; // type:object size:0x1 scope:local
TEV_COLOR_2$3800 = .bss:0x0000004C; // type:object size:0x8 scope:local
sInstance__40JASGlobalInstance<19JASDefaultBankTable> = .bss:0x00000054; // type:object size:0x4 scope:global
sInstance__35JASGlobalInstance<14JASAudioThread> = .bss:0x00000058; // type:object size:0x4 scope:global
+9 -7
View File
@@ -1,7 +1,7 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x0000002C; // type:function size:0x2C scope:global
_unresolved = .text:0x00000058; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000078; // type:function size:0x20 scope:local
__dt__11daPPolamp_cFv = .text:0x00000098; // type:function size:0xA4 scope:global
create__11daPPolamp_cFv = .text:0x0000013C; // type:function size:0x128 scope:global
execute__11daPPolamp_cFv = .text:0x00000264; // type:function size:0x60 scope:global
@@ -12,11 +12,11 @@ setPclModelMtx__11daPPolamp_cFv = .text:0x000004E8; // type:function size:0xF4 s
createHeap__11daPPolamp_cFv = .text:0x000005DC; // type:function size:0x114 scope:global
moveSwing__11daPPolamp_cFv = .text:0x000006F0; // type:function size:0x15C scope:global
initParam__11daPPolamp_cFv = .text:0x0000084C; // type:function size:0x34 scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x8C scope:local
__dt__12J3DFrameCtrlFv = .text:0x0000090C; // type:function size:0x48 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:global
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:global
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000954; // type:function size:0x20 scope:local
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000974; // type:function size:0x20 scope:local
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000994; // type:function size:0x20 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
...rodata.0 = .rodata:0x00000000; // type:label scope:local
@@ -33,8 +33,8 @@ _dtors = .dtors:0x00000000; // type:label scope:global
@3928 = .rodata:0x00000040; // type:object size:0x8 scope:local
@3936 = .rodata:0x00000048; // type:object size:0x4 scope:local align:4 data:float
@stringBase0 = .rodata:0x0000004C; // type:object size:0x8 scope:local data:string_table
l_arcName = .data:0x00000000; // type:object size:0x4 scope:global
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:global
l_arcName = .data:0x00000000; // type:object size:0x4 scope:local
daPPolamp_METHODS = .data:0x00000004; // type:object size:0x20 scope:local
g_profile_PPolamp = .data:0x00000024; // type:object size:0x30 scope:global
__vt__12J3DFrameCtrl = .data:0x00000054; // type:object size:0xC scope:global
__vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@@ -55,7 +55,9 @@ __vt__11daPPolamp_c = .data:0x00000060; // type:object size:0xC scope:global
@1012 = .bss:0x00000034; // type:object size:0x1 scope:local
@1010 = .bss:0x00000038; // type:object size:0x1 scope:local
@1009 = .bss:0x0000003C; // type:object size:0x1 scope:local
init$1515 = .bss:0x0000003D; // type:object size:0x1 scope:local
TEV_COLOR_1$3795 = .bss:0x00000040; // type:object size:0x8 scope:local
init$1520 = .bss:0x00000049; // type:object size:0x1 scope:local
TEV_COLOR_2$3800 = .bss:0x0000004C; // type:object size:0x8 scope:local
sInstance__40JASGlobalInstance<19JASDefaultBankTable> = .bss:0x00000054; // type:object size:0x4 scope:global
sInstance__35JASGlobalInstance<14JASAudioThread> = .bss:0x00000058; // type:object size:0x4 scope:global
@@ -1,7 +1,7 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x0000002C; // type:function size:0x2C scope:global
_unresolved = .text:0x00000058; // type:function size:0x4 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x0000005C; // type:function size:0x4 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x0000005C; // type:function size:0x4 scope:local
__dt__11daPPolamp_cFv = .text:0x00000060; // type:function size:0x90 scope:global
create__11daPPolamp_cFv = .text:0x000000F0; // type:function size:0x118 scope:global
execute__11daPPolamp_cFv = .text:0x00000208; // type:function size:0x60 scope:global
@@ -11,10 +11,10 @@ setPclModelMtx__11daPPolamp_cFv = .text:0x00000464; // type:function size:0xDC s
createHeap__11daPPolamp_cFv = .text:0x00000540; // type:function size:0xF8 scope:global
moveSwing__11daPPolamp_cFv = .text:0x00000638; // type:function size:0x154 scope:global
initParam__11daPPolamp_cFv = .text:0x0000078C; // type:function size:0x34 scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x000007C0; // type:function size:0x8C scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x0000084C; // type:function size:0x34 scope:global
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x4 scope:global
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000884; // type:function size:0x4 scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x000007C0; // type:function size:0x8C scope:local
daPPolamp_Delete__FP11daPPolamp_c = .text:0x0000084C; // type:function size:0x34 scope:local
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000880; // type:function size:0x4 scope:local
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000884; // type:function size:0x4 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
...rodata.0 = .rodata:0x00000000; // type:label scope:local
@@ -33,8 +33,8 @@ _dtors = .dtors:0x00000000; // type:label scope:global
UP_VAL$90564 = .rodata:0x0000004C; // type:object size:0x4 scope:local
MAX_ADD$90565 = .rodata:0x00000050; // type:object size:0x4 scope:local
lbl_705_data_0 = .data:0x00000000; // type:object size:0x8 data:string
l_arcName = .data:0x00000008; // type:object size:0x4 scope:global data:4byte
daPPolamp_METHODS = .data:0x0000000C; // type:object size:0x20 scope:global
l_arcName = .data:0x00000008; // type:object size:0x4 scope:local data:4byte
daPPolamp_METHODS = .data:0x0000000C; // type:object size:0x20 scope:local
g_profile_PPolamp = .data:0x0000002C; // type:object size:0x30 scope:global
__vt__11daPPolamp_c = .data:0x0000005C; // type:object size:0xC scope:global
lbl_705_data_68 = .data:0x00000068; // type:object size:0xC data:string
+7 -7
View File
@@ -1,7 +1,7 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x00000030; // type:function size:0x2C scope:global
_unresolved = .text:0x00000060; // type:function size:0x20 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000080; // type:function size:0x28 scope:global
daPPolamp_c_createHeap__FP10fopAc_ac_c = .text:0x00000080; // type:function size:0x28 scope:local
__dt__11daPPolamp_cFv = .text:0x000000B0; // type:function size:0xA0 scope:global
create__11daPPolamp_cFv = .text:0x00000150; // type:function size:0x130 scope:global
execute__11daPPolamp_cFv = .text:0x00000280; // type:function size:0x68 scope:global
@@ -12,11 +12,11 @@ setPclModelMtx__11daPPolamp_cFv = .text:0x00000530; // type:function size:0xDC s
createHeap__11daPPolamp_cFv = .text:0x00000610; // type:function size:0x1A4 scope:global
moveSwing__11daPPolamp_cFv = .text:0x000007C0; // type:function size:0x180 scope:global
initParam__11daPPolamp_cFv = .text:0x00000940; // type:function size:0x3C scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000980; // type:function size:0x7C scope:global
daPPolamp_create__FP11daPPolamp_c = .text:0x00000980; // type:function size:0x7C scope:local
__ct__11daPPolamp_cFv = .text:0x00000A00; // type:function size:0x48 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000A50; // type:function size:0x28 scope:global
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000A80; // type:function size:0x28 scope:global
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000AB0; // type:function size:0x28 scope:global
daPPolamp_Delete__FP11daPPolamp_c = .text:0x00000A50; // type:function size:0x28 scope:local
daPPolamp_execute__FP11daPPolamp_c = .text:0x00000A80; // type:function size:0x28 scope:local
daPPolamp_draw__FP11daPPolamp_c = .text:0x00000AB0; // type:function size:0x28 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
...rodata.0 = .rodata:0x00000000; // type:label scope:local
@@ -38,12 +38,12 @@ cNullVec__6Z2Calc = .rodata:0x0000005C; // type:object size:0xC scope:global
@46916 = .rodata:0x00000068; // type:object size:0x4 scope:local
lbl_696_rodata_6C = .rodata:0x0000006C; // type:object size:0x18
@115603 = .data:0x00000000; // type:object size:0x8 scope:local data:string
l_arcName = .data:0x00000008; // type:object size:0x4 scope:global data:4byte
l_arcName = .data:0x00000008; // type:object size:0x4 scope:local data:4byte
@115767 = .data:0x00000010; // type:object size:0x10 scope:local data:string
@115768 = .data:0x00000020; // type:object size:0x14 scope:local data:string
@115769 = .data:0x00000034; // type:object size:0x5 scope:local data:string
@115770 = .data:0x0000003C; // type:object size:0xD scope:local data:string
daPPolamp_METHODS = .data:0x00000050; // type:object size:0x20 scope:global
daPPolamp_METHODS = .data:0x00000050; // type:object size:0x20 scope:local
g_profile_PPolamp = .data:0x00000070; // type:object size:0x30 scope:global
__vt__11daPPolamp_c = .data:0x000000A0; // type:object size:0xC scope:global
@115842 = .data:0x000000AC; // type:object size:0xC scope:local data:string
+2 -2
View File
@@ -2181,13 +2181,13 @@ config.libs = [
ActorRel(NonMatching, "d_a_obj_zra_rock"),
ActorRel(NonMatching, "d_a_passer_mng"),
ActorRel(Equivalent, "d_a_peru"),
ActorRel(NonMatching, "d_a_ppolamp"),
ActorRel(MatchingFor("GZ2E01"), "d_a_ppolamp"),
ActorRel(MatchingFor("GZ2E01"), "d_a_skip_2D"),
ActorRel(MatchingFor("GZ2E01"), "d_a_startAndGoal", extra_cflags=['-pragma "nosyminline off"']),
ActorRel(MatchingFor("GZ2E01"), "d_a_swBall"),
ActorRel(MatchingFor("GZ2E01"), "d_a_swLBall"),
ActorRel(MatchingFor("GZ2E01"), "d_a_swTime"),
ActorRel(NonMatching, "d_a_tag_Lv6Gate"),
ActorRel(MatchingFor("GZ2E01"), "d_a_tag_Lv6Gate"),
ActorRel(MatchingFor("GZ2E01"), "d_a_tag_Lv7Gate"),
ActorRel(MatchingFor("GZ2E01"), "d_a_tag_Lv8Gate"),
ActorRel(MatchingFor("GZ2E01"), "d_a_tag_TWgate"),
+16 -8
View File
@@ -12,21 +12,29 @@
* @details
*
*/
class daPPolamp_c : public fopAc_ac_c {
class daPPolamp_c : public fopAc_ac_c, public request_of_phase_process_class {
public:
/* 80D4C958 */ ~daPPolamp_c();
/* 80D4C9FC */ void create();
/* 80D4CB24 */ void execute();
/* 80D4CB84 */ void draw();
/* 80D4CCF0 */ void Delete();
/* 80D4C958 */ virtual ~daPPolamp_c();
/* 80D4C9FC */ int create();
/* 80D4CB24 */ int execute();
/* 80D4CB84 */ int draw();
/* 80D4CCF0 */ int Delete();
/* 80D4CD24 */ void setModelMtx();
/* 80D4CDA8 */ void setPclModelMtx();
/* 80D4CE9C */ void createHeap();
/* 80D4CE9C */ int createHeap();
/* 80D4CFB0 */ void moveSwing();
/* 80D4D10C */ void initParam();
private:
/* 0x568 */ u8 field_0x568[0x5ac - 0x568];
/* 0x574 */ J3DModel* mModel1;
/* 0x578 */ J3DModel* mModel2;
/* 0x57C */ mDoExt_bckAnm mBck;
/* 0x598 */ int field_0x598;
/* 0x59C */ s8 field_0x59c;
/* 0x59E */ s16 field_0x59e;
/* 0x5A0 */ u8 mSwingTimer;
/* 0x5A4 */ f32 field_0x5a4;
/* 0x5A8 */ f32 field_0x5a8;
};
STATIC_ASSERT(sizeof(daPPolamp_c) == 0x5ac);
+3 -9
View File
@@ -8,23 +8,17 @@ class daTagLv6Gate_c : public fopAc_ac_c {
public:
/* 80D4F8B8 */ int createHeap();
/* 80D4FBD8 */ int create();
/* 80D4FEDC */ int execute();
/* 80D4FEDC */ inline int execute();
/* 80D506AC */ int draw();
inline ~daTagLv6Gate_c();
inline void seStair();
inline void seGlassOff();
inline void seGlassOn();
inline void initBaseMtx();
inline void setBaseMtx();
inline void create_init();
inline bool checkOpenArea();
inline void cut1();
inline void cut2();
inline void cut4();
void stabMasterSword() { field_0x76a = 1; }
void stabMasterSword() { mIsMasterSwordStabbed = 1; }
u8 getSwitchNo1() { return fopAcM_GetParam(this) & 0xFF; }
u8 getSwitchNo2() { return fopAcM_GetParam(this) >> 0x8 & 0xFF; }
@@ -35,7 +29,7 @@ public:
/* 0x758 */ request_of_phase_process_class mPhase;
/* 0x760 */ f32 field_0x760[2];
/* 0x768 */ s16 mEvtId;
/* 0x76A */ u8 field_0x76a;
/* 0x76A */ bool mIsMasterSwordStabbed;
}; // Size: 0x76C
#endif /* D_A_TAG_LV6GATE_H */
File diff suppressed because it is too large Load Diff
+188 -196
View File
@@ -7,7 +7,6 @@
#include "JSystem/J3DGraphBase/J3DMaterial.h"
#include "d/actor/d_a_player.h"
#include "d/d_procname.h"
#include "dol2asm.h"
/* 80D4F898-80D4F8B8 000078 0020+00 1/1 0/0 0/0 .text createSolidHeap__FP10fopAc_ac_c */
static int createSolidHeap(fopAc_ac_c* i_this) {
@@ -75,21 +74,6 @@ static int daTagLv6Gate_Create(fopAc_ac_c* i_this) {
return static_cast<daTagLv6Gate_c*>(i_this)->create();
}
void daTagLv6Gate_c::seStair() {
Vec se_pos = {0.0f, 1800.0f, -6800.0f};
mDoAud_seStart(Z2SE_OBJ_LV6_GATE_STAIR, &se_pos, 0, 0);
}
void daTagLv6Gate_c::seGlassOff() {
Vec se_pos = {0.0f, 2887.0f, -8330.0f};
mDoAud_seStart(Z2SE_OBJ_LV6_GATE_GLASS_OFF, &se_pos, 0, 0);
}
void daTagLv6Gate_c::seGlassOn() {
Vec se_pos = {0.0f, 2887.0f, -8330.0f};
mDoAud_seStart(Z2SE_OBJ_LV6_GATE_GLASS_ON, &se_pos, 0, 0);
}
void daTagLv6Gate_c::initBaseMtx() {
fopAcM_SetMtx(this, mpModel[0]->getBaseTRMtx());
@@ -106,13 +90,200 @@ void daTagLv6Gate_c::initBaseMtx() {
mBgW[1].Move();
}
inline bool daTagLv6Gate_c::checkOpenArea() {
if (!fopAcM_isSwitch(this, getSwitchNo2())) {
return false;
}
fopAc_ac_c* actor = NULL;
cXyz pos;
mDoMtx_stack_c::copy(mpModel[1]->getBaseTRMtx());
mDoMtx_stack_c::inverse();
for (int i = 0; i < 2; i++) {
actor =
(i == 0) ? daPy_getPlayerActorClass() : fopAcM_SearchByName(PROC_NPC_TKS);
if (actor != NULL) {
mDoMtx_stack_c::push();
mDoMtx_stack_c::multVec(fopAcM_GetPosition_p(actor), &pos);
mDoMtx_stack_c::pop();
if (pos.x >= l_minRelative[0] && pos.x <= l_maxRelative[0] &&
pos.z >= l_minRelative[2] && pos.z <= l_maxRelative[2])
{
return true;
}
}
}
return false;
}
/* 80D4FEDC-80D5068C 0006BC 07B0+00 1/1 0/0 0/0 .text execute__14daTagLv6Gate_cFv */
inline int daTagLv6Gate_c::execute() {
dComIfG_inf_c& game_info = g_dComIfG_gameInfo; // Fake match?
if (game_info.getPlay().getEvent().runCheck() && !eventInfo.checkCommandTalk()) {
dEvent_manager_c& eventManager = dComIfGp_getEventManager();
s32 cut_index = eventManager.getMyStaffId(l_arcName, NULL, 0);
if (cut_index != -1) {
int* cut_name = (int*)eventManager.getMyNowCutName(cut_index);
daPy_getPlayerActorClass()->onShieldBackBone();
if (eventManager.getIsAddvance(cut_index)) {
switch (*cut_name) {
case '0001': {
dComIfGp_getEvent().setSkipZev(this, "LV6_GATE_APPEAR_SKIP");
cXyz pos(0.0f, 0.0f, 78.0f);
mDoMtx_stack_c::transS(current.pos);
mDoMtx_stack_c::YrotM(shape_angle.y);
mDoMtx_stack_c::multVec(&pos, &pos);
daPy_getPlayerActorClass()->setPlayerPosAndAngle(&pos, shape_angle.y + 0x10000 - 0x8000, 0);
break;
}
case '0002': {
cXyz pos(0.0f, 0.0f, 0.0f);
csXyz angle(0, 0, 0);
dComIfGp_particle_set(0x8B89, &pos, &angle, NULL);
break;
}
case '0003':
fopAcM_onSwitch(this, getSwitchNo2());
Vec se_pos = {0.0f, 1800.0f, -6800.0f};
Z2GetAudioMgr()->seStart(Z2SE_OBJ_LV6_GATE_STAIR, &se_pos, 0, 0, 1.0f, 1.0f,
-1.0f, -1.0f, 0);
break;
case '0004': {
cXyz pos(117.8473f, 1677.0f, -5110.8394f);
fopAc_ac_c* actor1;
fopAc_ac_c* actor2;
actor1 = NULL;
fopAcM_SearchByID(parentActorID, &actor1);
if (actor1 == NULL) {
break;
}
fopAcM_GetOldPosition_p(actor1)->set(pos);
fopAcM_GetPosition_p(actor1)->set(pos);
#if VERSION != VERSION_SHIELD_DEBUG
actor2 = NULL;
fopAcM_SearchByName(PROC_NPC_TKC, &actor2);
if (actor2 == NULL) {
break;
}
*fopAcM_GetOldPosition_p(actor2) = pos;
*fopAcM_GetPosition_p(actor2) = pos;
#endif
break;
}
case '0006':
fopAcM_onSwitch(this, getSwitchNo2());
mpBtk[0]->setFrame(mpBtk[0]->getEndFrame());
if (!mBgW[0].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[0], this);
}
fopAcM_delete(parentActorID);
break;
default:
JUT_PANIC(332, "0");
}
}
switch (*cut_name) {
case '0001':
case '0002':
case '0003':
case '0004':
case '0005':
case '0006':
eventManager.cutEnd(cut_index);
break;
default:
JUT_PANIC(345, "0");
}
if (eventInfo.checkCommandDemoAccrpt() && mEvtId != -1 &&
eventManager.endCheck(mEvtId))
{
dComIfGp_event_reset();
mEvtId = -1;
}
}
} else if (mIsMasterSwordStabbed && !fopAcM_isSwitch(this, getSwitchNo1())) {
eventInfo.setArchiveName(l_arcName);
dComIfGp_getEventManager().setObjectArchive(eventInfo.getArchiveName());
mEvtId = dComIfGp_getEventManager().getEventIdx(this, "LV6_GATE_APPEAR", -1);
fopAcM_orderOtherEventId(this, mEvtId, -1, -1, 0, 1);
fopAcM_onSwitch(this, getSwitchNo1());
attention_info.flags = 0;
}
if (fopAcM_isSwitch(this, getSwitchNo2())) {
if (!mBgW[0].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[0], this);
}
mpBtk[0]->play();
mpBtk[1]->play();
}
if (checkOpenArea()) {
if (mBgW[1].ChkUsed()) {
dComIfG_Bgsp().Release(&mBgW[1]);
Vec se_pos = {0.0f, 2887.0f, -8330.0f};
Z2GetAudioMgr()->seStart(Z2SE_OBJ_LV6_GATE_GLASS_OFF, &se_pos, 0, 0, 1.0f, 1.0f, -1.0f,
-1.0f, 0);
}
field_0x760[0] -= 12.75f;
field_0x760[1] -= 5.75f;
if (field_0x760[0] < 0.0f) {
field_0x760[0] = 0.0f;
}
if (field_0x760[1] < 0.0f) {
field_0x760[1] = 0.0f;
}
} else {
if (!mBgW[1].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[1], this);
Vec se_pos = {0.0f, 2887.0f, -8330.0f};
Z2GetAudioMgr()->seStart(Z2SE_OBJ_LV6_GATE_GLASS_ON, &se_pos, 0, 0, 1.0f, 1.0f, -1.0f,
-1.0f, 0);
}
field_0x760[0] += 12.75f;
field_0x760[1] += 5.75f;
if (field_0x760[0] > 255.0f) {
field_0x760[0] = 255.0f;
}
if (field_0x760[1] > 115.0f) {
field_0x760[1] = 115.0f;
}
}
return 1;
}
void daTagLv6Gate_c::create_init() {
fopAcM_setCullSizeBox(this, -50.0f, 0.0f, -50.0f, 50.0f, 100.0f, 50.0f);
attention_info.position = current.pos;
attention_info.flags = (fopAcM_isSwitch(this, getSwitchNo1()) != 0) ? 0 : 0x80;
attention_info.distances[fopAc_attn_ETC_e] = 89;
mEvtId = -1;
field_0x76a = 0;
mIsMasterSwordStabbed = 0;
field_0x760[0] = 255.0f;
field_0x760[1] = 115.0f;
@@ -147,185 +318,6 @@ static int daTagLv6Gate_Execute(daTagLv6Gate_c* i_this) {
return i_this->execute();
}
bool daTagLv6Gate_c::checkOpenArea() {
if (!fopAcM_isSwitch(this, getSwitchNo2())) {
return false;
}
mDoMtx_stack_c::copy(mpModel[1]->getBaseTRMtx());
mDoMtx_stack_c::inverse();
for (int i = 0; i < 2; i++) {
fopAc_ac_c* actor =
(i == 0) ? daPy_getPlayerActorClass() : fopAcM_SearchByName(PROC_NPC_TKS);
if (actor != NULL) {
cXyz pos;
mDoMtx_stack_c::push();
mDoMtx_stack_c::multVec(fopAcM_GetPosition_p(actor), &pos);
mDoMtx_stack_c::pop();
if (pos.x >= l_minRelative[0] && pos.x <= l_maxRelative[0] &&
pos.z >= l_minRelative[2] && pos.z <= l_maxRelative[2])
{
return true;
}
}
}
return false;
}
void daTagLv6Gate_c::cut1() {
dComIfGp_getEvent().setSkipZev(this, "LV6_GATE_APPEAR_SKIP");
cXyz pos(0.0f, 0.0f, 78.0f);
mDoMtx_stack_c::transS(current.pos);
mDoMtx_stack_c::YrotM(shape_angle.y);
mDoMtx_stack_c::multVec(&pos, &pos);
daPy_getPlayerActorClass()->setPlayerPosAndAngle(&pos, shape_angle.y + 0x10000 - 0x8000, 0);
}
void daTagLv6Gate_c::cut2() {
cXyz pos(0.0f, 0.0f, 0.0f);
dComIfGp_particle_set(0x8B89, &pos, &csXyz(0, 0, 0), NULL);
}
void daTagLv6Gate_c::cut4() {
cXyz pos(117.8473f, 1677.0f, -5110.8394f);
fopAc_ac_c* actor2;
fopAc_ac_c* actor1;
actor1 = NULL;
fopAcM_SearchByID(parentActorID, &actor1);
if (actor1 == NULL) {
return;
}
*fopAcM_GetOldPosition_p(actor1) = pos;
*fopAcM_GetPosition_p(actor1) = pos;
actor2 = NULL;
fopAcM_SearchByName(PROC_NPC_TKC, &actor2);
if (actor2 == NULL) {
return;
}
*fopAcM_GetOldPosition_p(actor2) = pos;
*fopAcM_GetPosition_p(actor2) = pos;
}
/* 80D4FEDC-80D5068C 0006BC 07B0+00 1/1 0/0 0/0 .text execute__14daTagLv6Gate_cFv */
// NONMATCHING
int daTagLv6Gate_c::execute() {
dComIfG_inf_c& game_info = g_dComIfG_gameInfo; // Fake match?
if (game_info.getPlay().getEvent().runCheck() && !eventInfo.checkCommandTalk()) {
s32 cut_index = dComIfGp_getEventManager().getMyStaffId(l_arcName, NULL, 0);
if (cut_index != -1) {
int* cut_name = (int*)dComIfGp_getEventManager().getMyNowCutName(cut_index);
daPy_getPlayerActorClass()->onShieldBackBone();
if (dComIfGp_evmng_getIsAddvance(cut_index)) {
switch (*cut_name) {
case '0001':
cut1();
break;
case '0002':
cut2();
break;
case '0003':
fopAcM_onSwitch(this, getSwitchNo2());
seStair();
break;
case '0004':
cut4();
break;
case '0006':
fopAcM_onSwitch(this, getSwitchNo2());
mpBtk[0]->setFrame(mpBtk[0]->getEndFrame());
if (!mBgW[0].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[0], this);
}
fopAcM_delete(parentActorID);
}
}
switch (*cut_name) {
case '0001':
case '0002':
case '0003':
case '0004':
case '0005':
case '0006':
dComIfGp_evmng_cutEnd(cut_index);
}
if (eventInfo.checkCommandDemoAccrpt() && mEvtId != -1 &&
dComIfGp_evmng_endCheck(mEvtId))
{
dComIfGp_event_reset();
mEvtId = -1;
}
}
} else if (field_0x76a && !fopAcM_isSwitch(this, getSwitchNo1())) {
eventInfo.setArchiveName(l_arcName);
dComIfGp_getEventManager().setObjectArchive(eventInfo.getArchiveName());
mEvtId = dComIfGp_getEventManager().getEventIdx(this, "LV6_GATE_APPEAR", -1);
fopAcM_orderOtherEventId(this, mEvtId, -1, -1, 0, 1);
fopAcM_onSwitch(this, getSwitchNo1());
attention_info.flags = 0;
}
if (fopAcM_isSwitch(this, getSwitchNo2())) {
if (!mBgW[0].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[0], this);
}
mpBtk[0]->play();
mpBtk[1]->play();
}
if (checkOpenArea()) {
if (mBgW[1].ChkUsed()) {
dComIfG_Bgsp().Release(&mBgW[1]);
seGlassOff();
}
field_0x760[0] -= 12.75f;
field_0x760[1] -= 5.75f;
if (field_0x760[0] < 0.0f) {
field_0x760[0] = 0.0f;
}
if (field_0x760[1] < 0.0f) {
field_0x760[1] = 0.0f;
}
} else {
if (!mBgW[1].ChkUsed()) {
dComIfG_Bgsp().Regist(&mBgW[1], this);
seGlassOn();
}
field_0x760[0] += 12.75f;
field_0x760[1] += 5.75f;
if (field_0x760[0] > 255.0f) {
field_0x760[0] = 255.0f;
}
if (field_0x760[1] > 115.0f) {
field_0x760[1] = 115.0f;
}
}
return 1;
}
/* 80D5068C-80D506AC 000E6C 0020+00 1/0 0/0 0/0 .text daTagLv6Gate_Draw__FP14daTagLv6Gate_c */
static int daTagLv6Gate_Draw(daTagLv6Gate_c* i_this) {
return i_this->draw();