From ad8e966dbecae9a9a8bbff4532553bcf1ea9ba2a Mon Sep 17 00:00:00 2001 From: Tal Hayon Date: Tue, 10 Dec 2024 17:17:06 +0200 Subject: [PATCH] d_a_obj_automata OK --- .vscode/settings.json | 1 + .../GZ2E01/rels/d_a_obj_automata/symbols.txt | 26 +- configure.py | 2 +- include/d/actor/d_a_obj_automata.h | 48 +- src/d/actor/d_a_obj_automata.cpp | 776 ++++++------------ 5 files changed, 304 insertions(+), 549 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 8050d3fc72b..0fa734d2b46 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -28,6 +28,7 @@ "build/**/*.o": true, "build/**/*.plf": true, "build/**/*.rel": true, + "orig/**/*.rel": true, "build/**/*.lcf": true, "build/**/*.preplf": true, "build/**/*.d": true, diff --git a/config/GZ2E01/rels/d_a_obj_automata/symbols.txt b/config/GZ2E01/rels/d_a_obj_automata/symbols.txt index 718b463036a..f24c425e952 100644 --- a/config/GZ2E01/rels/d_a_obj_automata/symbols.txt +++ b/config/GZ2E01/rels/d_a_obj_automata/symbols.txt @@ -23,11 +23,11 @@ setEnvTevColor__16daObj_AutoMata_cFv = .text:0x00001034; // type:function size:0 setRoomNo__16daObj_AutoMata_cFv = .text:0x00001090; // type:function size:0x44 scope:global setMtx__16daObj_AutoMata_cFv = .text:0x000010D4; // type:function size:0x78 scope:global setSe__16daObj_AutoMata_cFv = .text:0x0000114C; // type:function size:0x2C4 scope:global -daObj_AutoMata_Create__FPv = .text:0x00001410; // type:function size:0x20 scope:global -daObj_AutoMata_Delete__FPv = .text:0x00001430; // type:function size:0x20 scope:global -daObj_AutoMata_Execute__FPv = .text:0x00001450; // type:function size:0x20 scope:global -daObj_AutoMata_Draw__FPv = .text:0x00001470; // type:function size:0x20 scope:global -daObj_AutoMata_IsDelete__FPv = .text:0x00001490; // type:function size:0x8 scope:global +daObj_AutoMata_Create__FPv = .text:0x00001410; // type:function size:0x20 scope:local +daObj_AutoMata_Delete__FPv = .text:0x00001430; // type:function size:0x20 scope:local +daObj_AutoMata_Execute__FPv = .text:0x00001450; // type:function size:0x20 scope:local +daObj_AutoMata_Draw__FPv = .text:0x00001470; // type:function size:0x20 scope:local +daObj_AutoMata_IsDelete__FPv = .text:0x00001490; // type:function size:0x8 scope:local __dt__10cCcD_GSttsFv = .text:0x00001498; // type:function size:0x48 scope:global __sinit_d_a_obj_automata_cpp = .text:0x000014E0; // type:function size:0xC4 scope:local __dt__22daObj_AutoMata_Param_cFv = .text:0x000015A4; // type:function size:0x48 scope:global @@ -38,7 +38,7 @@ __destroy_global_chain_reference = .dtors:0x00000000; // type:object size:0x4 sc _dtors = .dtors:0x00000000; // type:label scope:global ...rodata.0 = .rodata:0x00000000; // type:label scope:local m__22daObj_AutoMata_Param_c = .rodata:0x00000000; // type:object size:0xC scope:global -l_ccDObjData = .rodata:0x0000000C; // type:object size:0x30 scope:global +l_ccDObjData = .rodata:0x0000000C; // type:object size:0x30 scope:local @3962 = .rodata:0x0000003C; // type:object size:0x4 scope:local @3963 = .rodata:0x00000040; // type:object size:0x4 scope:local @3964 = .rodata:0x00000044; // type:object size:0x4 scope:local @@ -60,13 +60,13 @@ playMode$4222 = .rodata:0x00000078; // type:object size:0x8 scope:local @4352 = .rodata:0x00000090; // type:object size:0x4 scope:local @stringBase0 = .rodata:0x00000094; // type:object size:0xA scope:local data:string_table ...data.0 = .data:0x00000000; // type:label scope:local -cNullVec__6Z2Calc = .data:0x00000000; // type:object size:0xC scope:global +cNullVec__6Z2Calc = .data:0x00000000; // type:object size:0xC scope:local @1787 = .data:0x0000000C; // type:object size:0x4 scope:local -l_bmdData = .data:0x00000020; // type:object size:0x8 scope:global -l_resNameList = .data:0x00000028; // type:object size:0x8 scope:global -l_ccDCyl = .data:0x00000030; // type:object size:0x44 scope:global -l_ccDSph = .data:0x00000074; // type:object size:0x40 scope:global -daObj_AutoMata_MethodTable = .data:0x000000B4; // type:object size:0x20 scope:global +l_bmdData = .data:0x00000020; // type:object size:0x8 scope:local +l_resNameList = .data:0x00000028; // type:object size:0x8 scope:local +l_ccDCyl = .data:0x00000030; // type:object size:0x44 scope:local +l_ccDSph = .data:0x00000074; // type:object size:0x40 scope:local +daObj_AutoMata_MethodTable = .data:0x000000B4; // type:object size:0x20 scope:local g_profile_OBJ_AUTOMATA = .data:0x000000D4; // type:object size:0x30 scope:global __vt__12J3DFrameCtrl = .data:0x00000104; // type:object size:0xC scope:global __vt__12dBgS_ObjAcch = .data:0x00000110; // type:object size:0x24 scope:global @@ -80,4 +80,4 @@ __vt__16daObj_AutoMata_c = .data:0x0000017C; // type:object size:0xC scope:globa __vt__22daObj_AutoMata_Param_c = .data:0x00000188; // type:object size:0xC scope:global __global_destructor_chain = .bss:0x00000000; // type:object size:0x4 scope:global @3801 = .bss:0x00000008; // type:object size:0xC scope:local -l_HIO = .bss:0x00000014; // type:object size:0x4 scope:global data:4byte +l_HIO = .bss:0x00000014; // type:object size:0x4 scope:local data:4byte diff --git a/configure.py b/configure.py index a359d62ed82..81c240e52a4 100644 --- a/configure.py +++ b/configure.py @@ -1764,7 +1764,7 @@ def MatchingFor(*versions): ActorRel(NonMatching, "d_a_obj_Y_taihou"), ActorRel(NonMatching, "d_a_obj_amiShutter"), ActorRel(Matching, "d_a_obj_ari"), - ActorRel(NonMatching, "d_a_obj_automata"), + ActorRel(Matching, "d_a_obj_automata"), ActorRel(Matching, "d_a_obj_avalanche"), ActorRel(Matching, "d_a_obj_balloon"), ActorRel(Matching, "d_a_obj_barDesk"), diff --git a/include/d/actor/d_a_obj_automata.h b/include/d/actor/d_a_obj_automata.h index 3cb2f513f69..46b28b43960 100644 --- a/include/d/actor/d_a_obj_automata.h +++ b/include/d/actor/d_a_obj_automata.h @@ -1,7 +1,9 @@ #ifndef D_A_OBJ_AUTOMATA_H #define D_A_OBJ_AUTOMATA_H -#include "f_op/f_op_actor_mng.h" +#include "d/d_bg_s_acch.h" +#include "d/d_cc_d.h" +#include "f_op/f_op_actor.h" /** * @ingroup actors-objects @@ -12,33 +14,47 @@ * */ class daObj_AutoMata_c : public fopAc_ac_c { +private: + /* 0x568 */ int field_0x568; + /* 0x56C */ mDoExt_McaMorfSO* mpMorf; + /* 0x570 */ Z2Creature mCreature; + /* 0x600 */ mDoExt_btkAnm mBtk; + /* 0x618 */ request_of_phase_process_class mPhase; + /* 0x630 */ dBgS_ObjAcch mAcch; + /* 0x7F8 */ dCcD_Stts mStts; + /* 0x834 */ dBgS_AcchCir field_0x834; + /* 0x874 */ cBgS_GndChk mGndChk; + /* 0x8B0 */ dCcD_Cyl mCyl; + /* 0x9EC */ dCcD_Sph mSph; + /* 0xB24 */ int mShadowId; + /* 0xB28 */ f32 mGroundH; + /* 0xB2C */ f32 mAnmPlaySpeed; + /* 0xB30 */ u8 field_0xb30; + /* 0xB31 */ u8 field_0xb31; + public: - /* 80BA56EC */ ~daObj_AutoMata_c(); - /* 80BA5990 */ void create(); - /* 80BA5F88 */ void CreateHeap(); - /* 80BA60A0 */ void Delete(); - /* 80BA60D4 */ void Execute(); - /* 80BA639C */ void Draw(); - /* 80BA6480 */ void createHeapCallBack(fopAc_ac_c*); - /* 80BA64A0 */ void srchTHouse(fopAc_ac_c*, void*); - /* 80BA6500 */ void setAnm(int, bool); + /* 80BA56EC */ virtual ~daObj_AutoMata_c(); + /* 80BA5990 */ int create(); + /* 80BA5F88 */ int CreateHeap(); + /* 80BA60A0 */ int Delete(); + /* 80BA60D4 */ int Execute(); + /* 80BA639C */ int Draw(); + /* 80BA6480 */ static int createHeapCallBack(fopAc_ac_c*); + /* 80BA64A0 */ static void* srchTHouse(fopAc_ac_c*, void*); + /* 80BA6500 */ int setAnm(int, bool); /* 80BA6634 */ void setEnvTevColor(); /* 80BA6690 */ void setRoomNo(); /* 80BA66D4 */ void setMtx(); /* 80BA674C */ void setSe(); - -private: - /* 0x568 */ u8 field_0x568[0xb38 - 0x568]; }; STATIC_ASSERT(sizeof(daObj_AutoMata_c) == 0xb38); class daObj_AutoMata_Param_c { public: - /* 80BA6BA4 */ ~daObj_AutoMata_Param_c(); + /* 80BA6BA4 */ virtual ~daObj_AutoMata_Param_c() {} - static u8 const m[12]; + static f32 const m[3]; }; - #endif /* D_A_OBJ_AUTOMATA_H */ diff --git a/src/d/actor/d_a_obj_automata.cpp b/src/d/actor/d_a_obj_automata.cpp index 8c73168836f..ec27fb933b9 100644 --- a/src/d/actor/d_a_obj_automata.cpp +++ b/src/d/actor/d_a_obj_automata.cpp @@ -4,156 +4,19 @@ */ #include "d/actor/d_a_obj_automata.h" +#include "SSystem/SComponent/c_counter.h" #include "d/d_cc_d.h" -#include "dol2asm.h" - - - -// -// Forward References: -// - -extern "C" void __dt__16daObj_AutoMata_cFv(); -extern "C" void create__16daObj_AutoMata_cFv(); -extern "C" void __dt__8cM3dGSphFv(); -extern "C" void __dt__8cM3dGCylFv(); -extern "C" void __dt__8cM3dGAabFv(); -extern "C" void __dt__12dBgS_AcchCirFv(); -extern "C" void __dt__10dCcD_GSttsFv(); -extern "C" void __dt__12dBgS_ObjAcchFv(); -extern "C" void __dt__12J3DFrameCtrlFv(); -extern "C" void CreateHeap__16daObj_AutoMata_cFv(); -extern "C" void Delete__16daObj_AutoMata_cFv(); -extern "C" void Execute__16daObj_AutoMata_cFv(); -extern "C" void Draw__16daObj_AutoMata_cFv(); -extern "C" void createHeapCallBack__16daObj_AutoMata_cFP10fopAc_ac_c(); -extern "C" void srchTHouse__16daObj_AutoMata_cFP10fopAc_ac_cPv(); -extern "C" void setAnm__16daObj_AutoMata_cFib(); -extern "C" void setEnvTevColor__16daObj_AutoMata_cFv(); -extern "C" void setRoomNo__16daObj_AutoMata_cFv(); -extern "C" void setMtx__16daObj_AutoMata_cFv(); -extern "C" void setSe__16daObj_AutoMata_cFv(); -extern "C" static void daObj_AutoMata_Create__FPv(); -extern "C" static void daObj_AutoMata_Delete__FPv(); -extern "C" static void daObj_AutoMata_Execute__FPv(); -extern "C" static void daObj_AutoMata_Draw__FPv(); -extern "C" static bool daObj_AutoMata_IsDelete__FPv(); -extern "C" void __dt__10cCcD_GSttsFv(); -extern "C" void __sinit_d_a_obj_automata_cpp(); -extern "C" void __dt__22daObj_AutoMata_Param_cFv(); -extern "C" static void func_80BA6BEC(); -extern "C" static void func_80BA6BF4(); -extern "C" u8 const m__22daObj_AutoMata_Param_c[12]; -extern "C" extern char const* const d_a_obj_automata__stringBase0; - -// -// External References: -// - -extern "C" void scaleM__14mDoMtx_stack_cFRC4cXyz(); -extern "C" void ZXYrotM__14mDoMtx_stack_cFRC5csXyz(); -extern "C" void play__14mDoExt_baseAnmFv(); -extern "C" void init__13mDoExt_btkAnmFP16J3DMaterialTableP19J3DAnmTextureSRTKeyiifss(); -extern "C" void entry__13mDoExt_btkAnmFP16J3DMaterialTablef(); -extern "C" void -__ct__16mDoExt_McaMorfSOFP12J3DModelDataP25mDoExt_McaMorfCallBack1_cP25mDoExt_McaMorfCallBack2_cP15J3DAnmTransformifiiP10Z2CreatureUlUl(); -extern "C" void setAnm__16mDoExt_McaMorfSOFP15J3DAnmTransformiffff(); -extern "C" void play__16mDoExt_McaMorfSOFUlSc(); -extern "C" void entryDL__16mDoExt_McaMorfSOFv(); -extern "C" void modelCalc__16mDoExt_McaMorfSOFv(); -extern "C" void stopZelAnime__16mDoExt_McaMorfSOFv(); -extern "C" void __ct__10fopAc_ac_cFv(); -extern "C" void __dt__10fopAc_ac_cFv(); -extern "C" void fopAcIt_Judge__FPFPvPv_PvPv(); -extern "C" void fopAcM_entrySolidHeap__FP10fopAc_ac_cPFP10fopAc_ac_c_iUl(); -extern "C" void fopAcM_setCullSizeBox__FP10fopAc_ac_cffffff(); -extern "C" void fopAcM_posMoveF__FP10fopAc_ac_cPC4cXyz(); -extern "C" void fpcEx_IsExist__FUi(); -extern "C" void dComIfG_resLoad__FP30request_of_phase_process_classPCc(); -extern "C" void dComIfG_resDelete__FP30request_of_phase_process_classPCc(); -extern "C" void -dComIfGd_setShadow__FUlScP8J3DModelP4cXyzffffR13cBgS_PolyInfoP12dKy_tevstr_csfP9_GXTexObj(); -extern "C" void getRes__14dRes_control_cFPCclP11dRes_info_ci(); -extern "C" void GetPolyColor__4dBgSFRC13cBgS_PolyInfo(); -extern "C" void GetRoomId__4dBgSFRC13cBgS_PolyInfo(); -extern "C" void __ct__12dBgS_AcchCirFv(); -extern "C" void __dt__9dBgS_AcchFv(); -extern "C" void __ct__9dBgS_AcchFv(); -extern "C" void Set__9dBgS_AcchFP4cXyzP4cXyzP10fopAc_ac_ciP12dBgS_AcchCirP4cXyzP5csXyzP5csXyz(); -extern "C" void CrrPos__9dBgS_AcchFR4dBgS(); -extern "C" void SetObj__16dBgS_PolyPassChkFv(); -extern "C" void __ct__10dCcD_GSttsFv(); -extern "C" void Init__9dCcD_SttsFiiP10fopAc_ac_c(); -extern "C" void __ct__12dCcD_GObjInfFv(); -extern "C" void __dt__12dCcD_GObjInfFv(); -extern "C" void Set__8dCcD_CylFRC11dCcD_SrcCyl(); -extern "C" void Set__8dCcD_SphFRC11dCcD_SrcSph(); -extern "C" void settingTevStruct__18dScnKy_env_light_cFiP4cXyzP12dKy_tevstr_c(); -extern "C" void setLightTevColorType_MAJI__18dScnKy_env_light_cFP12J3DModelDataP12dKy_tevstr_c(); -extern "C" void Set__4cCcSFP8cCcD_Obj(); -extern "C" void __ct__11cBgS_GndChkFv(); -extern "C" void __dt__11cBgS_GndChkFv(); -extern "C" void __dt__13cBgS_PolyInfoFv(); -extern "C" void __dt__8cM3dGCirFv(); -extern "C" void SetC__8cM3dGCylFRC4cXyz(); -extern "C" void SetH__8cM3dGCylFf(); -extern "C" void SetR__8cM3dGCylFf(); -extern "C" void SetC__8cM3dGSphFRC4cXyz(); -extern "C" void SetR__8cM3dGSphFf(); -extern "C" void seStart__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc(); -extern "C" void seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc(); -extern "C" void __ct__10Z2CreatureFv(); -extern "C" void __dt__10Z2CreatureFv(); -extern "C" void init__10Z2CreatureFP3VecP3VecUcUc(); -extern "C" void* __nw__FUl(); -extern "C" void __dl__FPv(); -extern "C" void init__12J3DFrameCtrlFs(); -extern "C" void checkPass__12J3DFrameCtrlFf(); -extern "C" void removeTexMtxAnimator__16J3DMaterialTableFP19J3DAnmTextureSRTKey(); -extern "C" void __cvt_fp2unsigned(); -extern "C" void _savegpr_25(); -extern "C" void _savegpr_27(); -extern "C" void _savegpr_28(); -extern "C" void _savegpr_29(); -extern "C" void _restgpr_25(); -extern "C" void _restgpr_27(); -extern "C" void _restgpr_28(); -extern "C" void _restgpr_29(); -extern "C" extern void* __vt__8dCcD_Sph[36]; -extern "C" extern void* __vt__8dCcD_Cyl[36]; -extern "C" extern void* __vt__9dCcD_Stts[11]; -extern "C" extern void* __vt__12cCcD_SphAttr[25]; -extern "C" extern void* __vt__12cCcD_CylAttr[25]; -extern "C" extern void* __vt__14cCcD_ShapeAttr[22]; -extern "C" extern void* __vt__9cCcD_Stts[8]; -extern "C" u8 now__14mDoMtx_stack_c[48]; -extern "C" extern u8 g_dComIfG_gameInfo[122384]; -extern "C" u8 mSimpleTexObj__21dDlst_shadowControl_c[32]; -extern "C" extern u8 mStayNo__20dStage_roomControl_c[4]; -extern "C" u8 mAudioMgrPtr__10Z2AudioMgr[4 + 4 /* padding */]; -extern "C" void __register_global_object(); - -// -// Declarations: -// - -/* ############################################################################################## */ -/* 80BA6CA4-80BA6CA4 000094 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */ -#pragma push -#pragma force_active on -SECTION_DEAD static char const* const stringBase_80BA6CA4 = ""; -SECTION_DEAD static char const* const stringBase_80BA6CA5 = "AutoMata"; -#pragma pop +#include "d/d_com_inf_game.h" /* 80BA6CB0-80BA6CBC 000000 000C+00 1/1 0/0 0/0 .data cNullVec__6Z2Calc */ -SECTION_DATA static u8 cNullVec__6Z2Calc[12] = { +static u8 cNullVec__6Z2Calc[12] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, }; /* 80BA6CBC-80BA6CD0 00000C 0004+10 0/0 0/0 0/0 .data @1787 */ #pragma push #pragma force_active on -SECTION_DATA static u32 lit_1787[1 + 4 /* padding */] = { +static u32 lit_1787[1 + 4 /* padding */] = { 0x02000201, /* padding */ 0x40080000, @@ -164,24 +27,34 @@ SECTION_DATA static u32 lit_1787[1 + 4 /* padding */] = { #pragma pop /* 80BA6CD0-80BA6CD8 000020 0008+00 4/5 0/0 0/0 .data l_bmdData */ -SECTION_DATA static u8 l_bmdData[8] = { - 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x01, +static int l_bmdData[1][2] = { + 9, 1, }; /* 80BA6CD8-80BA6CE0 -00001 0008+00 4/6 0/0 0/0 .data l_resNameList */ -SECTION_DATA static void* l_resNameList[2] = { - (void*)&d_a_obj_automata__stringBase0, - (void*)(((char*)&d_a_obj_automata__stringBase0) + 0x1), +static char* l_resNameList[2] = { + "", + "AutoMata", }; -/* 80BA6CE0-80BA6D24 000030 0044+00 1/2 0/0 0/0 .data l_ccDCyl */ -static dCcD_SrcCyl l_ccDCyl = { - { - {0x0, {{0x0, 0x0, 0x0}, {0x0, 0x0}, 0x0}}, // mObj +/* ############################################################################################## */ +/* 80BA6C10-80BA6C1C 000000 000C+00 5/5 0/0 0/0 .rodata m__22daObj_AutoMata_Param_c */ +f32 const daObj_AutoMata_Param_c::m[3] = { + 220.0f, 80.0f, 40.0f, +}; + +/* 80BA6C1C-80BA6C4C 00000C 0030+00 1/1 0/0 0/0 .rodata l_ccDObjData */ +static dCcD_SrcGObjInf const l_ccDObjData = +{ + {0x0, {{0x0, 0x0, 0}, {0xD8FBFDFF, 0x1F}, 0x79}}, // mObj {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt - {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjTg + {dCcD_SE_STONE, 0x0, 0x0, 0x0, 0x0}, // mGObjTg {0x0}, // mGObjCo - }, // mObjInf + }; + +/* 80BA6CE0-80BA6D24 000030 0044+00 1/2 0/0 0/0 .data l_ccDCyl */ +static dCcD_SrcCyl l_ccDCyl = { + l_ccDObjData, // mObjInf { {0.0f, 0.0f, 0.0f}, // mCenter 0.0f, // mRadius @@ -191,451 +64,316 @@ static dCcD_SrcCyl l_ccDCyl = { /* 80BA6D24-80BA6D64 000074 0040+00 1/2 0/0 0/0 .data l_ccDSph */ static dCcD_SrcSph l_ccDSph = { - { - {0x0, {{0x0, 0x0, 0x0}, {0x0, 0x0}, 0x0}}, // mObj - {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjAt - {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x0}, // mGObjTg - {0x0}, // mGObjCo - }, // mObjInf + l_ccDObjData, // mObjInf { {{0.0f, 0.0f, 0.0f}, 0.0f} // mSph } // mSphAttr }; -/* 80BA6D64-80BA6D84 -00001 0020+00 1/0 0/0 0/0 .data daObj_AutoMata_MethodTable */ -static actor_method_class daObj_AutoMata_MethodTable = { - (process_method_func)daObj_AutoMata_Create__FPv, - (process_method_func)daObj_AutoMata_Delete__FPv, - (process_method_func)daObj_AutoMata_Execute__FPv, - (process_method_func)daObj_AutoMata_IsDelete__FPv, - (process_method_func)daObj_AutoMata_Draw__FPv, -}; - -/* 80BA6D84-80BA6DB4 -00001 0030+00 0/0 0/0 1/0 .data g_profile_OBJ_AUTOMATA */ -extern actor_process_profile_definition g_profile_OBJ_AUTOMATA = { - fpcLy_CURRENT_e, // mLayerID - 8, // mListID - fpcPi_CURRENT_e, // mListPrio - PROC_OBJ_AUTOMATA, // mProcName - &g_fpcLf_Method.base, // sub_method - sizeof(daObj_AutoMata_c), // mSize - 0, // mSizeOther - 0, // mParameters - &g_fopAc_Method.base, // sub_method - 81, // mPriority - &daObj_AutoMata_MethodTable, // sub_method - 0x00044100, // mStatus - fopAc_ACTOR_e, // mActorType - fopAc_CULLBOX_CUSTOM_e, // cullType -}; - -/* 80BA6DB4-80BA6DC0 000104 000C+00 3/3 0/0 0/0 .data __vt__12J3DFrameCtrl */ -SECTION_DATA extern void* __vt__12J3DFrameCtrl[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__12J3DFrameCtrlFv, -}; - -/* 80BA6DC0-80BA6DE4 000110 0024+00 3/3 0/0 0/0 .data __vt__12dBgS_ObjAcch */ -SECTION_DATA extern void* __vt__12dBgS_ObjAcch[9] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__12dBgS_ObjAcchFv, - (void*)NULL, - (void*)NULL, - (void*)func_80BA6BF4, - (void*)NULL, - (void*)NULL, - (void*)func_80BA6BEC, -}; - -/* 80BA6DE4-80BA6DF0 000134 000C+00 3/3 0/0 0/0 .data __vt__10cCcD_GStts */ -SECTION_DATA extern void* __vt__10cCcD_GStts[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__10cCcD_GSttsFv, -}; - -/* 80BA6DF0-80BA6DFC 000140 000C+00 2/2 0/0 0/0 .data __vt__10dCcD_GStts */ -SECTION_DATA extern void* __vt__10dCcD_GStts[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__10dCcD_GSttsFv, -}; - -/* 80BA6DFC-80BA6E08 00014C 000C+00 2/2 0/0 0/0 .data __vt__12dBgS_AcchCir */ -SECTION_DATA extern void* __vt__12dBgS_AcchCir[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__12dBgS_AcchCirFv, -}; - -/* 80BA6E08-80BA6E14 000158 000C+00 3/3 0/0 0/0 .data __vt__8cM3dGCyl */ -SECTION_DATA extern void* __vt__8cM3dGCyl[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__8cM3dGCylFv, -}; - -/* 80BA6E14-80BA6E20 000164 000C+00 3/3 0/0 0/0 .data __vt__8cM3dGAab */ -SECTION_DATA extern void* __vt__8cM3dGAab[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__8cM3dGAabFv, -}; - -/* 80BA6E20-80BA6E2C 000170 000C+00 3/3 0/0 0/0 .data __vt__8cM3dGSph */ -SECTION_DATA extern void* __vt__8cM3dGSph[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__8cM3dGSphFv, -}; - -/* 80BA6E2C-80BA6E38 00017C 000C+00 2/2 0/0 0/0 .data __vt__16daObj_AutoMata_c */ -SECTION_DATA extern void* __vt__16daObj_AutoMata_c[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__16daObj_AutoMata_cFv, -}; - /* 80BA56EC-80BA5990 0000EC 02A4+00 1/0 0/0 0/0 .text __dt__16daObj_AutoMata_cFv */ daObj_AutoMata_c::~daObj_AutoMata_c() { - // NONMATCHING + OS_REPORT("|%06d:%x|daObj_AutoMata_c -> デストラクト\n", g_Counter, this); + if (mpMorf != NULL) { + mpMorf->stopZelAnime(); + } + dComIfG_resDelete(&mPhase, l_resNameList[l_bmdData[field_0xb30][1]]); } -/* ############################################################################################## */ -/* 80BA6C10-80BA6C1C 000000 000C+00 5/5 0/0 0/0 .rodata m__22daObj_AutoMata_Param_c */ -SECTION_RODATA u8 const daObj_AutoMata_Param_c::m[12] = { - 0x43, 0x5C, 0x00, 0x00, 0x42, 0xA0, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00, -}; -COMPILER_STRIP_GATE(0x80BA6C10, &daObj_AutoMata_Param_c::m); - -/* 80BA6C1C-80BA6C4C 00000C 0030+00 1/1 0/0 0/0 .rodata l_ccDObjData */ -SECTION_RODATA static u8 const l_ccDObjData[48] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0xD8, 0xFB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x1F, 0x00, 0x00, 0x00, 0x79, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -}; -COMPILER_STRIP_GATE(0x80BA6C1C, &l_ccDObjData); - -/* 80BA6C4C-80BA6C50 00003C 0004+00 0/1 0/0 0/0 .rodata @3962 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_3962 = -200.0f; -COMPILER_STRIP_GATE(0x80BA6C4C, &lit_3962); -#pragma pop - -/* 80BA6C50-80BA6C54 000040 0004+00 0/1 0/0 0/0 .rodata @3963 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_3963 = -100.0f; -COMPILER_STRIP_GATE(0x80BA6C50, &lit_3963); -#pragma pop - -/* 80BA6C54-80BA6C58 000044 0004+00 0/1 0/0 0/0 .rodata @3964 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_3964 = 200.0f; -COMPILER_STRIP_GATE(0x80BA6C54, &lit_3964); -#pragma pop - -/* 80BA6C58-80BA6C5C 000048 0004+00 0/1 0/0 0/0 .rodata @3965 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_3965 = 300.0f; -COMPILER_STRIP_GATE(0x80BA6C58, &lit_3965); -#pragma pop - -/* 80BA6C5C-80BA6C60 00004C 0004+00 0/3 0/0 0/0 .rodata @3966 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_3966 = -1000000000.0f; -COMPILER_STRIP_GATE(0x80BA6C5C, &lit_3966); -#pragma pop - /* 80BA5990-80BA5D2C 000390 039C+00 1/1 0/0 0/0 .text create__16daObj_AutoMata_cFv */ -void daObj_AutoMata_c::create() { - // NONMATCHING -} - -/* 80BA5D2C-80BA5D74 00072C 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGSphFv */ -// cM3dGSph::~cM3dGSph() { -extern "C" void __dt__8cM3dGSphFv() { - // NONMATCHING -} - -/* 80BA5D74-80BA5DBC 000774 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGCylFv */ -// cM3dGCyl::~cM3dGCyl() { -extern "C" void __dt__8cM3dGCylFv() { - // NONMATCHING -} - -/* 80BA5DBC-80BA5E04 0007BC 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGAabFv */ -// cM3dGAab::~cM3dGAab() { -extern "C" void __dt__8cM3dGAabFv() { - // NONMATCHING -} - -/* 80BA5E04-80BA5E74 000804 0070+00 1/0 0/0 0/0 .text __dt__12dBgS_AcchCirFv */ -// dBgS_AcchCir::~dBgS_AcchCir() { -extern "C" void __dt__12dBgS_AcchCirFv() { - // NONMATCHING -} - -/* 80BA5E74-80BA5ED0 000874 005C+00 1/0 0/0 0/0 .text __dt__10dCcD_GSttsFv */ -// dCcD_GStts::~dCcD_GStts() { -extern "C" void __dt__10dCcD_GSttsFv() { - // NONMATCHING -} - -/* 80BA5ED0-80BA5F40 0008D0 0070+00 3/2 0/0 0/0 .text __dt__12dBgS_ObjAcchFv */ -// dBgS_ObjAcch::~dBgS_ObjAcch() { -extern "C" void __dt__12dBgS_ObjAcchFv() { - // NONMATCHING +int daObj_AutoMata_c::create() { + fopAcM_SetupActor(this, daObj_AutoMata_c); + field_0xb30 = 0; + int rv = dComIfG_resLoad(&mPhase, l_resNameList[l_bmdData[field_0xb30][1]]); + if (rv == cPhs_COMPLEATE_e) { + OS_REPORT("\t(%s:%d) <%08x>\n", fopAcM_getProcNameString(this), field_0xb30, fopAcM_GetParam(this)); + if (fopAcM_entrySolidHeap(this, createHeapCallBack, 0x1370) == 0) { + return cPhs_ERROR_e; + } + mpMorf->getModel()->getModelData(); + fopAcM_SetMtx(this, mpMorf->getModel()->getBaseTRMtx()); + fopAcM_setCullSizeBox(this, -200.0f, -100.0f, -200.0f, 200.0f, 300.0f, 200.0f); + mCreature.init(¤t.pos, &eyePos, 3, 1); + mAcch.Set(fopAcM_GetPosition_p(this), fopAcM_GetOldPosition_p(this), this, 1, &field_0x834, + fopAcM_GetSpeed_p(this), fopAcM_GetAngle_p(this), fopAcM_GetShapeAngle_p(this)); + mStts.Init(0xff, 0, this); + mCyl.Set(l_ccDCyl); + mCyl.SetStts(&mStts); + mSph.Set(l_ccDSph); + mSph.SetStts(&mStts); + mAcch.SetWallNone(); + mAcch.CrrPos(dComIfG_Bgsp()); + mGndChk = mAcch.m_gnd; + mGroundH = mAcch.GetGroundH(); + if (mGroundH != -1e9f) { + setEnvTevColor(); + setRoomNo(); + } + Execute(); + } + return rv; } -/* 80BA5F40-80BA5F88 000940 0048+00 1/0 0/0 0/0 .text __dt__12J3DFrameCtrlFv */ -// J3DFrameCtrl::~J3DFrameCtrl() { -extern "C" void __dt__12J3DFrameCtrlFv() { - // NONMATCHING -} - -/* ############################################################################################## */ -/* 80BA6C60-80BA6C64 000050 0004+00 1/3 0/0 0/0 .rodata @4108 */ -SECTION_RODATA static f32 const lit_4108 = 1.0f; -COMPILER_STRIP_GATE(0x80BA6C60, &lit_4108); - /* 80BA5F88-80BA60A0 000988 0118+00 1/1 0/0 0/0 .text CreateHeap__16daObj_AutoMata_cFv */ -void daObj_AutoMata_c::CreateHeap() { - // NONMATCHING +int daObj_AutoMata_c::CreateHeap() { + J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes( + l_resNameList[l_bmdData[field_0xb30][1]], + l_bmdData[field_0xb30][0]); + if (modelData == NULL) { + return 0; + } + mpMorf = new mDoExt_McaMorfSO(modelData, NULL, NULL, NULL, -1, 1.0f, 0, -1, &mCreature, 0x80000, + 0x11000284); + if (mpMorf == NULL || mpMorf->getModel() == NULL) { + return 0; + } + return setAnm(0, false) ? 1 : 0; } /* 80BA60A0-80BA60D4 000AA0 0034+00 1/1 0/0 0/0 .text Delete__16daObj_AutoMata_cFv */ -void daObj_AutoMata_c::Delete() { - // NONMATCHING +int daObj_AutoMata_c::Delete() { + OS_REPORT("|%06d:%x|daObj_AutoMata_c -> Delete\n", g_Counter, this); + this->~daObj_AutoMata_c(); + return 1; } -/* ############################################################################################## */ -/* 80BA6C64-80BA6C68 000054 0004+00 0/2 0/0 0/0 .rodata @4173 */ -#pragma push -#pragma force_active on -SECTION_RODATA static u8 const lit_4173[4] = { - 0x00, - 0x00, - 0x00, - 0x00, -}; -COMPILER_STRIP_GATE(0x80BA6C64, &lit_4173); -#pragma pop - -/* 80BA6C68-80BA6C6C 000058 0004+00 0/1 0/0 0/0 .rodata @4174 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4174 = -4.0f; -COMPILER_STRIP_GATE(0x80BA6C68, &lit_4174); -#pragma pop - -/* 80BA6C6C-80BA6C70 00005C 0004+00 0/1 0/0 0/0 .rodata @4175 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4175 = 40.0f; -COMPILER_STRIP_GATE(0x80BA6C6C, &lit_4175); -#pragma pop - /* 80BA60D4-80BA639C 000AD4 02C8+00 2/2 0/0 0/0 .text Execute__16daObj_AutoMata_cFv */ -void daObj_AutoMata_c::Execute() { - // NONMATCHING +int daObj_AutoMata_c::Execute() { + if (home.roomNo == dComIfGp_roomControl_getStayNo()) { + cXyz sphCenter; + cXyz cStack_28; + mAcch.SetWallNone(); + gravity = 0.0f; + if (dComIfGp_event_runCheck()) { + gravity = -4.0f; + } + fopAcM_posMoveF(this, mStts.GetCCMoveP()); + mAcch.CrrPos(dComIfG_Bgsp()); + mGndChk = mAcch.m_gnd; + mGroundH = mAcch.GetGroundH(); + if (mGroundH != -1e9f) { + if (fopAcIt_Judge((fopAcIt_JudgeFunc)srchTHouse, ¤t.pos) != NULL) { + current.pos.y = mGroundH; + } + setEnvTevColor(); + setRoomNo(); + } + mpMorf->setPlaySpeed(mAnmPlaySpeed); + mpMorf->play(0, 0); + mBtk.setPlaySpeed(mAnmPlaySpeed); + mBtk.play(); + mAnmPlaySpeed = 0.0f; + setSe(); + setMtx(); + if (field_0xb31 == 0) { + cStack_28.set(0.0f, 40.0f, 0.0f); + mDoMtx_stack_c::copy(mpMorf->getModel()->getAnmMtx(3)); + mDoMtx_stack_c::multVec(&cStack_28, &sphCenter); + mSph.SetC(sphCenter); + mSph.SetR(daObj_AutoMata_Param_c::m[2]); + dComIfG_Ccsp()->Set(&mSph); + mCyl.SetH(daObj_AutoMata_Param_c::m[0]); + mCyl.SetR(daObj_AutoMata_Param_c::m[1]); + mCyl.SetC(current.pos); + dComIfG_Ccsp()->Set(&mCyl); + } + mSph.ClrCoHit(); + mCyl.ClrCoHit(); + attention_info.flags = 0; + eyePos = attention_info.position = current.pos; + field_0xb31 = 0; + return 1; + } + return 0; } -/* ############################################################################################## */ -/* 80BA6C70-80BA6C74 000060 0004+00 0/1 0/0 0/0 .rodata @4197 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4197 = 600.0f; -COMPILER_STRIP_GATE(0x80BA6C70, &lit_4197); -#pragma pop - -/* 80BA6C74-80BA6C78 000064 0004+00 0/1 0/0 0/0 .rodata @4198 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4198 = 20.0f; -COMPILER_STRIP_GATE(0x80BA6C74, &lit_4198); -#pragma pop - /* 80BA639C-80BA6480 000D9C 00E4+00 1/1 0/0 0/0 .text Draw__16daObj_AutoMata_cFv */ -void daObj_AutoMata_c::Draw() { - // NONMATCHING +int daObj_AutoMata_c::Draw() { + J3DModel* morfModel = mpMorf->getModel(); + J3DModelData* modelData = morfModel->getModelData(); + g_env_light.settingTevStruct(0, ¤t.pos, &tevStr); + g_env_light.setLightTevColorType_MAJI(morfModel, &tevStr); + mBtk.entry(modelData); + mpMorf->entryDL(); + mBtk.remove(modelData); + if (mGroundH != -1e+09f) { + mShadowId = dComIfGd_setShadow( + mShadowId, 1, morfModel, ¤t.pos, 600.0f, 20.0f, + current.pos.y, mGroundH, mGndChk, + &tevStr, 0, 1.0f, dDlst_shadowControl_c::getSimpleTex()); + } + return 1; } /* 80BA6480-80BA64A0 000E80 0020+00 1/1 0/0 0/0 .text * createHeapCallBack__16daObj_AutoMata_cFP10fopAc_ac_c */ -void daObj_AutoMata_c::createHeapCallBack(fopAc_ac_c* param_0) { - // NONMATCHING +int daObj_AutoMata_c::createHeapCallBack(fopAc_ac_c* i_this) { + return static_cast(i_this)->CreateHeap(); } /* 80BA64A0-80BA6500 000EA0 0060+00 1/1 0/0 0/0 .text * srchTHouse__16daObj_AutoMata_cFP10fopAc_ac_cPv */ -void daObj_AutoMata_c::srchTHouse(fopAc_ac_c* param_0, void* param_1) { - // NONMATCHING +void* daObj_AutoMata_c::srchTHouse(fopAc_ac_c* actor, void* param_1) { + if (fopAcM_GetName(actor) == PROC_Obj_TobyHouse) { + if (fopAcM_IsExecuting(fopAcM_GetID(actor))) { + return actor; + } + } + return NULL; } /* ############################################################################################## */ /* 80BA6C78-80BA6C80 000068 0008+00 0/1 0/0 0/0 .rodata bckArcIx$4220 */ -#pragma push -#pragma force_active on -SECTION_RODATA static u8 const bckArcIx[8] = { - 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x06, +static int const bckArcIx[2] = { + 5, 6, }; -COMPILER_STRIP_GATE(0x80BA6C78, &bckArcIx); -#pragma pop /* 80BA6C80-80BA6C88 000070 0008+00 0/1 0/0 0/0 .rodata btkArcIx$4221 */ -#pragma push -#pragma force_active on -SECTION_RODATA static u8 const btkArcIx[8] = { - 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x0D, +static int const btkArcIx[2] = { + 12, 13, }; -COMPILER_STRIP_GATE(0x80BA6C80, &btkArcIx); -#pragma pop /* 80BA6C88-80BA6C90 000078 0008+00 0/1 0/0 0/0 .rodata playMode$4222 */ -#pragma push -#pragma force_active on -SECTION_RODATA static u8 const playMode[8] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, +static int const playMode[2] = { + 0, 2, }; -COMPILER_STRIP_GATE(0x80BA6C88, &playMode); -#pragma pop - -/* 80BA6C90-80BA6C94 000080 0004+00 0/2 0/0 0/0 .rodata @4252 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4252 = -1.0f; -COMPILER_STRIP_GATE(0x80BA6C90, &lit_4252); -#pragma pop /* 80BA6500-80BA6634 000F00 0134+00 1/1 0/0 1/1 .text setAnm__16daObj_AutoMata_cFib */ -void daObj_AutoMata_c::setAnm(int param_0, bool param_1) { - // NONMATCHING +int daObj_AutoMata_c::setAnm(int param_1, bool param_2) { + J3DModelData* modelData = mpMorf->getModel()->getModelData(); + const char* resName = l_resNameList[l_bmdData[field_0xb30][1]]; + if (param_1 >= 0 && param_1 < 2) { + J3DAnmTransform* anmTransform = (J3DAnmTransform*)dComIfG_getObjectRes( + resName, + bckArcIx[param_1]); + if (anmTransform == NULL) { + return 0; + } + mpMorf->setAnm(anmTransform, playMode[param_1], 0.0f, 0.0f, 0.0f, -1.0f); + J3DAnmTextureSRTKey* srtKey = + (J3DAnmTextureSRTKey*)dComIfG_getObjectRes(resName, btkArcIx[param_1]); + if (srtKey == NULL) { + return 0; + } + if (mBtk.init(modelData, srtKey, 1, playMode[param_1], 0.0f, 0, -1) == 1) { + return 1; + } + return 0; + } + return 0; } /* 80BA6634-80BA6690 001034 005C+00 2/2 0/0 0/0 .text setEnvTevColor__16daObj_AutoMata_cFv */ void daObj_AutoMata_c::setEnvTevColor() { - // NONMATCHING + tevStr.mEnvrIdxOverride = dComIfG_Bgsp().GetPolyColor(mGndChk); + tevStr.mRoomNo = dComIfG_Bgsp().GetRoomId(mGndChk); } /* 80BA6690-80BA66D4 001090 0044+00 2/2 0/0 0/0 .text setRoomNo__16daObj_AutoMata_cFv */ void daObj_AutoMata_c::setRoomNo() { - // NONMATCHING + s32 roomId = dComIfG_Bgsp().GetRoomId(mGndChk); + fopAcM_SetRoomNo(this, roomId); + mStts.SetRoomId(roomId); } /* 80BA66D4-80BA674C 0010D4 0078+00 1/1 0/0 0/0 .text setMtx__16daObj_AutoMata_cFv */ void daObj_AutoMata_c::setMtx() { - // NONMATCHING + J3DModel* morfModel = mpMorf->getModel(); + mDoMtx_stack_c::transS(current.pos.x, current.pos.y, current.pos.z); + mDoMtx_stack_c::ZXYrotM(shape_angle); + mDoMtx_stack_c::scaleM(scale); + morfModel->setBaseTRMtx(mDoMtx_stack_c::get()); + mpMorf->modelCalc(); } -/* ############################################################################################## */ -/* 80BA6C94-80BA6C98 000084 0004+00 0/1 0/0 0/0 .rodata @4349 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4349 = 17.0f; -COMPILER_STRIP_GATE(0x80BA6C94, &lit_4349); -#pragma pop - -/* 80BA6C98-80BA6C9C 000088 0004+00 0/1 0/0 0/0 .rodata @4350 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4350 = 100.0f; -COMPILER_STRIP_GATE(0x80BA6C98, &lit_4350); -#pragma pop - -/* 80BA6C9C-80BA6CA0 00008C 0004+00 0/1 0/0 0/0 .rodata @4351 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4351 = 7.0f; -COMPILER_STRIP_GATE(0x80BA6C9C, &lit_4351); -#pragma pop - -/* 80BA6CA0-80BA6CA4 000090 0004+00 0/1 0/0 0/0 .rodata @4352 */ -#pragma push -#pragma force_active on -SECTION_RODATA static f32 const lit_4352 = 67.0f; -COMPILER_STRIP_GATE(0x80BA6CA0, &lit_4352); -#pragma pop - /* 80BA674C-80BA6A10 00114C 02C4+00 1/1 0/0 0/0 .text setSe__16daObj_AutoMata_cFv */ void daObj_AutoMata_c::setSe() { - // NONMATCHING + if (cM3d_IsZero(mpMorf->getPlaySpeed()) == false) { + const char* resName = l_resNameList[l_bmdData[field_0xb30][1]]; + J3DAnmTransform* anmTransform = (J3DAnmTransform*)dComIfG_getObjectRes(resName, 5); + J3DAnmTransform* currentAnm = mpMorf->getAnm(); + if (anmTransform == currentAnm) { + if (mpMorf->checkFrame(17.0f)) { + Z2GetAudioMgr()->seStart(Z2SE_OBJ_AMATA_ACTION, ¤t.pos, + mpMorf->getPlaySpeed() * 100.0f, 0, 1.0f, 1.0f, -1.0f, + -1.0f, 0); + } + Z2GetAudioMgr()->seStartLevel(Z2SE_OBJ_AMATA_CRK, ¤t.pos, + mpMorf->getPlaySpeed() * 100.0f, 0, 1.0f, 1.0f, -1.0f, + -1.0f, 0); + } + anmTransform = (J3DAnmTransform*)dComIfG_getObjectRes(resName, 6); + currentAnm = mpMorf->getAnm(); + if (anmTransform == currentAnm) { + if (mpMorf->checkFrame(7.0f)) { + Z2GetAudioMgr()->seStart(Z2SE_OBJ_AMATA_ACTION, ¤t.pos, + mpMorf->getPlaySpeed() * 100.0f, 0, 1.0f, 1.0f, -1.0f, + -1.0, 0); + } + if (mpMorf->checkFrame(67.0f)) { + Z2GetAudioMgr()->seStart(Z2SE_OBJ_AMATA_ACTION, ¤t.pos, + mpMorf->getPlaySpeed() * 100.0f, 0, 1.0f, 1.0f, -1.0f, + -1.0f, 0); + } + Z2GetAudioMgr()->seStartLevel(Z2SE_OBJ_AMATA_CRK, ¤t.pos, + mpMorf->getPlaySpeed() * 100.0f, 0, 1.0f, 1.0f, -1.0f, + -1.0f, 0); + } + } } /* 80BA6A10-80BA6A30 001410 0020+00 1/0 0/0 0/0 .text daObj_AutoMata_Create__FPv */ -static void daObj_AutoMata_Create(void* param_0) { - // NONMATCHING +static int daObj_AutoMata_Create(void* i_this) { + return static_cast(i_this)->create(); } /* 80BA6A30-80BA6A50 001430 0020+00 1/0 0/0 0/0 .text daObj_AutoMata_Delete__FPv */ -static void daObj_AutoMata_Delete(void* param_0) { - // NONMATCHING +static int daObj_AutoMata_Delete(void* i_this) { + return static_cast(i_this)->Delete(); } /* 80BA6A50-80BA6A70 001450 0020+00 1/0 0/0 0/0 .text daObj_AutoMata_Execute__FPv */ -static void daObj_AutoMata_Execute(void* param_0) { - // NONMATCHING +static int daObj_AutoMata_Execute(void* i_this) { + return static_cast(i_this)->Execute(); } /* 80BA6A70-80BA6A90 001470 0020+00 1/0 0/0 0/0 .text daObj_AutoMata_Draw__FPv */ -static void daObj_AutoMata_Draw(void* param_0) { - // NONMATCHING +static int daObj_AutoMata_Draw(void* i_this) { + return static_cast(i_this)->Draw(); } /* 80BA6A90-80BA6A98 001490 0008+00 1/0 0/0 0/0 .text daObj_AutoMata_IsDelete__FPv */ -static bool daObj_AutoMata_IsDelete(void* param_0) { - return true; +static int daObj_AutoMata_IsDelete(void* i_this) { + return 1; } -/* 80BA6A98-80BA6AE0 001498 0048+00 1/0 0/0 0/0 .text __dt__10cCcD_GSttsFv */ -// cCcD_GStts::~cCcD_GStts() { -extern "C" void __dt__10cCcD_GSttsFv() { - // NONMATCHING -} - -/* ############################################################################################## */ -/* 80BA6E38-80BA6E44 000188 000C+00 2/2 0/0 0/0 .data __vt__22daObj_AutoMata_Param_c */ -SECTION_DATA extern void* __vt__22daObj_AutoMata_Param_c[3] = { - (void*)NULL /* RTTI */, - (void*)NULL, - (void*)__dt__22daObj_AutoMata_Param_cFv, -}; - -/* 80BA6E50-80BA6E5C 000008 000C+00 1/1 0/0 0/0 .bss @3801 */ -static u8 lit_3801[12]; - /* 80BA6E5C-80BA6E60 000014 0004+00 1/1 0/0 0/0 .bss l_HIO */ -static u8 l_HIO[4]; - -/* 80BA6AE0-80BA6BA4 0014E0 00C4+00 0/0 1/0 0/0 .text __sinit_d_a_obj_automata_cpp */ -void __sinit_d_a_obj_automata_cpp() { - // NONMATCHING -} - -#pragma push -#pragma force_active on -REGISTER_CTORS(0x80BA6AE0, __sinit_d_a_obj_automata_cpp); -#pragma pop +static daObj_AutoMata_Param_c l_HIO; -/* 80BA6BA4-80BA6BEC 0015A4 0048+00 2/1 0/0 0/0 .text __dt__22daObj_AutoMata_Param_cFv */ -daObj_AutoMata_Param_c::~daObj_AutoMata_Param_c() { - // NONMATCHING -} - -/* 80BA6BEC-80BA6BF4 0015EC 0008+00 1/0 0/0 0/0 .text @36@__dt__12dBgS_ObjAcchFv */ -static void func_80BA6BEC() { - // NONMATCHING -} +/* 80BA6D64-80BA6D84 -00001 0020+00 1/0 0/0 0/0 .data daObj_AutoMata_MethodTable */ +static actor_method_class daObj_AutoMata_MethodTable = { + (process_method_func)daObj_AutoMata_Create, + (process_method_func)daObj_AutoMata_Delete, + (process_method_func)daObj_AutoMata_Execute, + (process_method_func)daObj_AutoMata_IsDelete, + (process_method_func)daObj_AutoMata_Draw, +}; -/* 80BA6BF4-80BA6BFC 0015F4 0008+00 1/0 0/0 0/0 .text @20@__dt__12dBgS_ObjAcchFv */ -static void func_80BA6BF4() { - // NONMATCHING -} +/* 80BA6D84-80BA6DB4 -00001 0030+00 0/0 0/0 1/0 .data g_profile_OBJ_AUTOMATA */ +extern actor_process_profile_definition g_profile_OBJ_AUTOMATA = { + fpcLy_CURRENT_e, // mLayerID + 8, // mListID + fpcPi_CURRENT_e, // mListPrio + PROC_OBJ_AUTOMATA, // mProcName + &g_fpcLf_Method.base, // sub_method + sizeof(daObj_AutoMata_c), // mSize + 0, // mSizeOther + 0, // mParameters + &g_fopAc_Method.base, // sub_method + 81, // mPriority + &daObj_AutoMata_MethodTable, // sub_method + 0x00044100, // mStatus + fopAc_ACTOR_e, // mActorType + fopAc_CULLBOX_CUSTOM_e, // cullType +}; /* 80BA6CA4-80BA6CA4 000094 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */