diff --git a/config/RSBE01_02/rels/sora_melee/symbols.txt b/config/RSBE01_02/rels/sora_melee/symbols.txt index d74f8df..138fbd2 100644 --- a/config/RSBE01_02/rels/sora_melee/symbols.txt +++ b/config/RSBE01_02/rels/sora_melee/symbols.txt @@ -11082,7 +11082,7 @@ getOwner__9ftManagerFi = .text:0x0010AFD0; // type:function size:0x28 fn_27_10AFF8 = .text:0x0010AFF8; // type:function size:0x2C fn_27_10B024 = .text:0x0010B024; // type:function size:0x2C fn_27_10B050 = .text:0x0010B050; // type:function size:0x2C -fn_27_10B07C = .text:0x0010B07C; // type:function size:0x40 +getSlotNo__9ftManagerFl = .text:0x0010B07C; // type:function size:0x40 getPlayerNo__9ftManagerFi = .text:0x0010B0BC; // type:function size:0x5C fn_27_10B118 = .text:0x0010B118; // type:function size:0x5C fn_27_10B174 = .text:0x0010B174; // type:function size:0x5C @@ -12236,10 +12236,10 @@ fn_27_14523C = .text:0x0014523C; // type:function size:0x78 fn_27_1452B4 = .text:0x001452B4; // type:function size:0x84 fn_27_145338 = .text:0x00145338; // type:function size:0x110 fn_27_145448 = .text:0x00145448; // type:function size:0x30 -fn_27_145478 = .text:0x00145478; // type:function size:0x14 +getData__20ftCommonDataAccesserCF6ftKind = .text:0x00145478; // type:function size:0x14 fn_27_14548C = .text:0x0014548C; // type:function size:0x34 fn_27_1454C0 = .text:0x001454C0; // type:function size:0xC -fn_27_1454CC = .text:0x001454CC; // type:function size:0x48 +getParam__20ftCommonDataAccesserCF6ftKind = .text:0x001454CC; // type:function size:0x48 fn_27_145514 = .text:0x00145514; // type:function size:0x20 fn_27_145534 = .text:0x00145534; // type:function size:0x18 fn_27_14554C = .text:0x0014554C; // type:function size:0x2C @@ -13733,55 +13733,55 @@ fn_27_192AF8 = .text:0x00192AF8; // type:function size:0x164 fn_27_192C5C = .text:0x00192C5C; // type:function size:0x88 fn_27_192CE4 = .text:0x00192CE4; // type:function size:0x40 fn_27_192D24 = .text:0x00192D24; // type:function size:0x28 -fn_27_192D4C = .text:0x00192D4C; // type:function size:0x9C -fn_27_192DE8 = .text:0x00192DE8; // type:function size:0xA0 -fn_27_192E88 = .text:0x00192E88; // type:function size:0x38 -fn_27_192EC0 = .text:0x00192EC0; // type:function size:0xC -fn_27_192ECC = .text:0x00192ECC; // type:function size:0xC -fn_27_192ED8 = .text:0x00192ED8; // type:function size:0x8 -fn_27_192EE0 = .text:0x00192EE0; // type:function size:0x34 -fn_27_192F14 = .text:0x00192F14; // type:function size:0x34 -fn_27_192F48 = .text:0x00192F48; // type:function size:0x34 -fn_27_192F7C = .text:0x00192F7C; // type:function size:0xC -fn_27_192F88 = .text:0x00192F88; // type:function size:0x8 -fn_27_192F90 = .text:0x00192F90; // type:function size:0x8 -fn_27_192F98 = .text:0x00192F98; // type:function size:0x8 -fn_27_192FA0 = .text:0x00192FA0; // type:function size:0x14 -fn_27_192FB4 = .text:0x00192FB4; // type:function size:0x14 -fn_27_192FC8 = .text:0x00192FC8; // type:function size:0x10 -fn_27_192FD8 = .text:0x00192FD8; // type:function size:0x10 -fn_27_192FE8 = .text:0x00192FE8; // type:function size:0x8 -fn_27_192FF0 = .text:0x00192FF0; // type:function size:0x14 -fn_27_193004 = .text:0x00193004; // type:function size:0x10 -fn_27_193014 = .text:0x00193014; // type:function size:0x10 -fn_27_193024 = .text:0x00193024; // type:function size:0xC -fn_27_193030 = .text:0x00193030; // type:function size:0x10 -fn_27_193040 = .text:0x00193040; // type:function size:0x34 -fn_27_193074 = .text:0x00193074; // type:function size:0x34 -fn_27_1930A8 = .text:0x001930A8; // type:function size:0x14 -fn_27_1930BC = .text:0x001930BC; // type:function size:0x20 -fn_27_1930DC = .text:0x001930DC; // type:function size:0x34 -fn_27_193110 = .text:0x00193110; // type:function size:0x110 -fn_27_193220 = .text:0x00193220; // type:function size:0x40 -fn_27_193260 = .text:0x00193260; // type:function size:0x8 -fn_27_193268 = .text:0x00193268; // type:function size:0x8 -fn_27_193270 = .text:0x00193270; // type:function size:0x24 -fn_27_193294 = .text:0x00193294; // type:function size:0x8 -fn_27_19329C = .text:0x0019329C; // type:function size:0x8 -fn_27_1932A4 = .text:0x001932A4; // type:function size:0x8 -fn_27_1932AC = .text:0x001932AC; // type:function size:0x8 -fn_27_1932B4 = .text:0x001932B4; // type:function size:0x8 -fn_27_1932BC = .text:0x001932BC; // type:function size:0x40 -fn_27_1932FC = .text:0x001932FC; // type:function size:0xC -fn_27_193308 = .text:0x00193308; // type:function size:0xC -fn_27_193314 = .text:0x00193314; // type:function size:0x8 -fn_27_19331C = .text:0x0019331C; // type:function size:0x8 -fn_27_193324 = .text:0x00193324; // type:function size:0x8 -fn_27_19332C = .text:0x0019332C; // type:function size:0xC -fn_27_193338 = .text:0x00193338; // type:function size:0x8 -fn_27_193340 = .text:0x00193340; // type:function size:0x8 -fn_27_193348 = .text:0x00193348; // type:function size:0x8 -fn_27_193350 = .text:0x00193350; // type:function size:0x28 +__ct__18ftFighterBuildDataFl6ftKindQ25Heaps8HeapTypeQ25Heaps8HeapTypeQ25Heaps8HeapTypeScP16soModuleAccesserlPvPv = .text:0x00192D4C; // type:function size:0x9C +getAnimCmdData__18ftFighterBuildDataFUll = .text:0x00192DE8; // type:function size:0xA0 +getAnimCmdDisguiseList__18ftFighterBuildDataFbl = .text:0x00192E88; // type:function size:0x38 +getMdlResId__18ftFighterBuildDataFv = .text:0x00192EC0; // type:function size:0xC +getAnimResId__18ftFighterBuildDataFv = .text:0x00192ECC; // type:function size:0xC +getResGroupNo__18ftFighterBuildDataFv = .text:0x00192ED8; // type:function size:0x8 +getMotionData__18ftFighterBuildDataFv = .text:0x00192EE0; // type:function size:0x34 +getStatusData__18ftFighterBuildDataFv = .text:0x00192F14; // type:function size:0x34 +getVisibilityData__18ftFighterBuildDataFv = .text:0x00192F48; // type:function size:0x34 +getParamAccesser__18ftFighterBuildDataFv = .text:0x00192F7C; // type:function size:0xC +getAreaCategory__18ftFighterBuildDataFv = .text:0x00192F88; // type:function size:0x8 +getCameraRangeSet__18ftFighterBuildDataFv = .text:0x00192F90; // type:function size:0x8 +getCameraClipSphereSet__18ftFighterBuildDataFv = .text:0x00192F98; // type:function size:0x8 +getItemNodeData__18ftFighterBuildDataFv = .text:0x00192FA0; // type:function size:0x14 +getModelExtendNodeTable__18ftFighterBuildDataFv = .text:0x00192FB4; // type:function size:0x14 +getIkData__18ftFighterBuildDataFv = .text:0x00192FC8; // type:function size:0x10 +getShakeData__18ftFighterBuildDataFv = .text:0x00192FD8; // type:function size:0x10 +getEffectNodeData__18ftFighterBuildDataFv = .text:0x00192FE8; // type:function size:0x8 +getEffectEmitData__18ftFighterBuildDataFv = .text:0x00192FF0; // type:function size:0x14 +getEffectCommonData__18ftFighterBuildDataFv = .text:0x00193004; // type:function size:0x10 +getEffectScreenData__18ftFighterBuildDataFv = .text:0x00193014; // type:function size:0x10 +getGroundConditionChecker__18ftFighterBuildDataFv = .text:0x00193024; // type:function size:0xC +getJostleData__18ftFighterBuildDataFv = .text:0x00193030; // type:function size:0x10 +getPreCheckAnimCmdData__18ftFighterBuildDataFv = .text:0x00193040; // type:function size:0x34 +getModelScale__18ftFighterBuildDataFv = .text:0x00193074; // type:function size:0x34 +getHeapSlotNo__18ftFighterBuildDataFv = .text:0x001930A8; // type:function size:0x14 +getSoundIdExchanger__18ftFighterBuildDataFv = .text:0x001930BC; // type:function size:0x20 +getSlopeAngleLimit__18ftFighterBuildDataFv = .text:0x001930DC; // type:function size:0x34 +isConditionNoCliffStop__28ftGroundConditionCheckerImplFP16soModuleAccesser = .text:0x00193110; // type:function size:0x110 +__dt__28ftGroundConditionCheckerImplFv = .text:0x00193220; // type:function size:0x40 +getModelLayerType__25soModuleAccesserBuildDataFv = .text:0x00193260; // type:function size:0x8 +getTargetSearchParam__25soModuleAccesserBuildDataFv = .text:0x00193268; // type:function size:0x8 +getTerritoryRect__25soModuleAccesserBuildDataFv = .text:0x00193270; // type:function size:0x24 +getTerritoryParam__25soModuleAccesserBuildDataFv = .text:0x00193294; // type:function size:0x8 +getNWMotionInstanceHeap__18ftFighterBuildDataFv = .text:0x0019329C; // type:function size:0x8 +getNWModelInstanceHeap__18ftFighterBuildDataFv = .text:0x001932A4; // type:function size:0x8 +getInstanceHeap__18ftFighterBuildDataFv = .text:0x001932AC; // type:function size:0x8 +getTeam__18ftFighterBuildDataFv = .text:0x001932B4; // type:function size:0x8 +__dt__18ftFighterBuildDataFv = .text:0x001932BC; // type:function size:0x40 +getSlopeAngleLimit__25soModuleAccesserBuildDataFv = .text:0x001932FC; // type:function size:0xC +getSoundIdExchanger__25soModuleAccesserBuildDataFv = .text:0x00193308; // type:function size:0xC +getHeapSlotNo__25soModuleAccesserBuildDataFv = .text:0x00193314; // type:function size:0x8 +getPreCheckAnimCmdData__25soModuleAccesserBuildDataFv = .text:0x0019331C; // type:function size:0x8 +getModelExtendNodeTable__25soModuleAccesserBuildDataFv = .text:0x00193324; // type:function size:0x8 +getModelScale__25soModuleAccesserBuildDataFv = .text:0x0019332C; // type:function size:0xC +getIkData__25soModuleAccesserBuildDataFv = .text:0x00193338; // type:function size:0x8 +getEffectScreenData__25soModuleAccesserBuildDataFv = .text:0x00193340; // type:function size:0x8 +getEffectNodeData__25soModuleAccesserBuildDataFv = .text:0x00193348; // type:function size:0x8 +__sinit_\ft_fighter_build_data_cpp = .text:0x00193350; // type:function size:0x28 scope:local fn_27_193378 = .text:0x00193378; // type:function size:0x98 fn_27_193410 = .text:0x00193410; // type:function size:0x180 fn_27_193590 = .text:0x00193590; // type:function size:0x24 @@ -29163,7 +29163,7 @@ lbl_27_data_C040 = .data:0x0000C040; // type:object size:0x1D data:string lbl_27_data_C060 = .data:0x0000C060; // type:object size:0x10 lbl_27_data_C070 = .data:0x0000C070; // type:object size:0x8 lbl_27_data_C078 = .data:0x0000C078; // type:object size:0x19 data:string -lbl_27_data_C098 = .data:0x0000C098; // type:object size:0x8 +__RTTI__24soGroundConditionChecker = .data:0x0000C098; // type:object size:0x8 lbl_27_data_C0A0 = .data:0x0000C0A0; // type:object size:0xE0 lbl_27_data_C180 = .data:0x0000C180; // type:object size:0x13 data:string lbl_27_data_C194 = .data:0x0000C194; // type:object size:0xC @@ -32966,16 +32966,16 @@ lbl_27_data_32A48 = .data:0x00032A48; // type:object size:0x34 data:string lbl_27_data_32A7C = .data:0x00032A7C; // type:object size:0x14 lbl_27_data_32A90 = .data:0x00032A90; // type:object size:0x8 jumptable_27_data_32A98 = .data:0x00032A98; // type:object size:0x2C scope:local -lbl_27_data_32AC8 = .data:0x00032AC8; // type:object size:0x10 +__vt__28ftGroundConditionCheckerImpl = .data:0x00032AC8; // type:object size:0x10 lbl_27_data_32AD8 = .data:0x00032AD8; // type:object size:0x1D data:string lbl_27_data_32AF8 = .data:0x00032AF8; // type:object size:0x10 -lbl_27_data_32B08 = .data:0x00032B08; // type:object size:0x8 -lbl_27_data_32B10 = .data:0x00032B10; // type:object size:0x94 +__RTTI__28ftGroundConditionCheckerImpl = .data:0x00032B08; // type:object size:0x8 +__vt__18ftFighterBuildData = .data:0x00032B10; // type:object size:0x94 lbl_27_data_32BA4 = .data:0x00032BA4; // type:object size:0x13 data:string lbl_27_data_32BB8 = .data:0x00032BB8; // type:object size:0x10 -lbl_27_data_32BC8 = .data:0x00032BC8; // type:object size:0x8 +__RTTI__18ftFighterBuildData = .data:0x00032BC8; // type:object size:0x8 lbl_27_data_32BD0 = .data:0x00032BD0; // type:object size:0x1A data:string -lbl_27_data_32BF0 = .data:0x00032BF0; // type:object size:0x8 +__RTTI__25soModuleAccesserBuildData = .data:0x00032BF0; // type:object size:0x8 lbl_27_data_32BF8 = .data:0x00032BF8; // type:object size:0x15 data:string lbl_27_data_32C10 = .data:0x00032C10; // type:object size:0x18 lbl_27_data_32C28 = .data:0x00032C28; // type:object size:0x8 @@ -38741,12 +38741,12 @@ lbl_27_bss_1CC = .bss:0x000001CC; // type:object size:0x24 data:4byte lbl_27_bss_1F0 = .bss:0x000001F0; // type:object size:0x18 lbl_27_bss_208 = .bss:0x00000208; // type:object size:0x18 data:byte lbl_27_bss_220 = .bss:0x00000220; // type:object size:0x14 data:byte -lbl_27_bss_234 = .bss:0x00000234; // type:object size:0x18 data:4byte +g_soParamAccesserNull = .bss:0x00000234; // type:object size:0x18 data:4byte lbl_27_bss_24C = .bss:0x0000024C; // type:object size:0x4C data:4byte lbl_27_bss_298 = .bss:0x00000298; // type:object size:0x14 data:byte lbl_27_bss_2AC = .bss:0x000002AC; // type:object size:0x10 lbl_27_bss_2BC = .bss:0x000002BC; // type:object size:0x1C data:4byte -lbl_27_bss_2D8 = .bss:0x000002D8; // type:object size:0x14 data:byte +g_soSoundIdExchangerNull = .bss:0x000002D8; // type:object size:0x14 data:byte lbl_27_bss_2EC = .bss:0x000002EC; // type:object size:0x18 data:4byte lbl_27_bss_304 = .bss:0x00000304; // type:object size:0x18 data:4byte lbl_27_bss_31C = .bss:0x0000031C; // type:object size:0x14 @@ -39164,9 +39164,9 @@ lbl_27_bss_31E8 = .bss:0x000031E8; // type:object size:0x8 data:4byte lbl_27_bss_31F0 = .bss:0x000031F0; // type:object size:0x8 data:4byte lbl_27_bss_31F8 = .bss:0x000031F8; // type:object size:0x8 data:4byte lbl_27_bss_3200 = .bss:0x00003200; // type:object size:0xC -lbl_27_bss_320C = .bss:0x0000320C; // type:object size:0x4 +g_ftCommonDataAccesser = .bss:0x0000320C; // type:object size:0x4 lbl_27_bss_3210 = .bss:0x00003210; // type:object size:0x298 data:4byte -lbl_27_bss_34A8 = .bss:0x000034A8; // type:object size:0x1088 data:4byte +g_ftCommonData = .bss:0x000034A8; // type:object size:0x1088 data:4byte lbl_27_bss_4530 = .bss:0x00004530; // type:object size:0x38 g_ftExtendParamAccesserTableInit = .bss:0x00004568; // type:object size:0x1 scope:local data:byte g_ftExtendParamAccesserTable = .bss:0x0000456C; // type:object size:0xDC scope:local @@ -39200,8 +39200,9 @@ lbl_27_bss_4810 = .bss:0x00004810; // type:object size:0x18 lbl_27_bss_4828 = .bss:0x00004828; // type:object size:0x18 lbl_27_bss_4840 = .bss:0x00004840; // type:object size:0x8 lbl_27_bss_4848 = .bss:0x00004848; // type:object size:0x10 data:4byte -lbl_27_bss_4858 = .bss:0x00004858; // type:object size:0x18 data:byte -lbl_27_bss_4870 = .bss:0x00004870; // type:object size:0x8 data:byte +g_ftSoundIdExchangerImpl = .bss:0x00004858; // type:object size:0x8 data:byte +lbl_27_bss_4860 = .bss:0x00004860; // type:object size:0xC +g_ftKirbySoundIdExchangerImpl = .bss:0x00004870; // type:object size:0x8 data:byte lbl_27_bss_4878 = .bss:0x00004878; // type:object size:0xC lbl_27_bss_4884 = .bss:0x00004884; // type:object size:0x4 data:4byte lbl_27_bss_4888 = .bss:0x00004888; // type:object size:0xC @@ -39432,7 +39433,7 @@ lbl_27_bss_502C = .bss:0x0000502C; // type:object size:0x4 data:4byte lbl_27_bss_5030 = .bss:0x00005030; // type:object size:0xC lbl_27_bss_503C = .bss:0x0000503C; // type:object size:0x4 data:4byte lbl_27_bss_5040 = .bss:0x00005040; // type:object size:0xC -lbl_27_bss_504C = .bss:0x0000504C; // type:object size:0x4 data:4byte +g_ftGroundConditionCheckerImpl = .bss:0x0000504C; // type:object size:0x4 data:4byte lbl_27_bss_5050 = .bss:0x00005050; // type:object size:0x1 data:byte lbl_27_bss_5054 = .bss:0x00005054; // type:object size:0x14 align:4 data:float lbl_27_bss_5068 = .bss:0x00005068; // type:object size:0x1 data:byte diff --git a/configure.py b/configure.py index 5b04652..0f51a74 100755 --- a/configure.py +++ b/configure.py @@ -818,7 +818,7 @@ def MatchingFor(*versions): Object(Matching, "mo_melee/sora_melee/so/so_common_data_accesser.cpp"), Object(Matching, "mo_melee/sora_melee/ft/ft_class_info.cpp"), Object(Matching, "mo_melee/sora_melee/ft/ft_extend_param_accesser.cpp"), - Object(NonMatching, "mo_melee/sora_melee/ft/ft_fighter_build_data.cpp"), + Object(Matching, "mo_melee/sora_melee/ft/ft_fighter_build_data.cpp"), Object(Matching, "mo_melee/mo_melee.cpp"), ], }, diff --git a/include/lib/BrawlHeaders b/include/lib/BrawlHeaders index f7d45e9..f7c2792 160000 --- a/include/lib/BrawlHeaders +++ b/include/lib/BrawlHeaders @@ -1 +1 @@ -Subproject commit f7d45e96dc4fca29e908f3e8240deac02d8ea2e7 +Subproject commit f7c27926578007110296e38d9a462fb565cc7e59 diff --git a/src/mo_melee/sora_melee/ft/ft_fighter_build_data.cpp b/src/mo_melee/sora_melee/ft/ft_fighter_build_data.cpp index a3f2bcd..520ede5 100644 --- a/src/mo_melee/sora_melee/ft/ft_fighter_build_data.cpp +++ b/src/mo_melee/sora_melee/ft/ft_fighter_build_data.cpp @@ -1,20 +1,197 @@ -#include +#include #include +#include +#include +#include +#include +#include +#include +#include +#include #include +#include #include #include -class soModuleAccesserBuildData { +class ftGroundConditionCheckerImpl : public soGroundConditionChecker { public: - + virtual ~ftGroundConditionCheckerImpl(); + virtual bool isConditionNoCliffStop(soModuleAccesser* moduleAccesser); }; -class ftFighterBuildData : public soModuleAccesserBuildData { -public: - ftFighterBuildData(s32 entryId, ftKind kind, Heaps::HeapType instHeap, - Heaps::HeapType nwModelInstHeap, - Heaps::HeapType nwMotionInstHeap, - s8 resGroupNo, soModuleAccesser* acc, - s32 team, void* cameraRangeSet, - void* cameraClipSphereSet); -}; +static ftGroundConditionCheckerImpl g_ftGroundConditionCheckerImpl; + +ftFighterBuildData::ftFighterBuildData(s32 entryId, ftKind kind, + Heaps::HeapType instHeap, + Heaps::HeapType nwModelInstHeap, + Heaps::HeapType nwMotionInstHeap, + s8 resGroupNo, soModuleAccesser* acc, + s32 team, void* cameraRangeSet, + void* cameraClipSphereSet) : + m_entryId(entryId), + m_kind(kind), + m_ftData(g_ftCommonDataAccesser.getData(kind)), + m_resGroupNo(resGroupNo), + m_team(team), + m_moduleAccsr(acc), + m_cameraRangeSet(cameraRangeSet), + m_cameraClipSphereSet(cameraClipSphereSet), + m_instHeap(instHeap), + m_nwModelInstHeap(nwModelInstHeap), + m_nwMotionInstHeap(nwMotionInstHeap) { } + +void* ftFighterBuildData::getAnimCmdData(u32 eventThread, s32 p2) { + if (p2 == 0) { + switch (eventThread) { + case 0: + return g_ftCommonData.dataCommon->commonActionEntryScripts; + case 1: + case 5: + return m_ftData->unk30; + case 2: + case 6: + return m_ftData->unk34; + case 4: + case 8: + return m_ftData->unk3C; + case 3: + case 7: + return m_ftData->unk38; + case 10: + return g_ftCommonData.dataCommon->flashOverlayScripts; + default: + goto Exit; + } + } + if (p2 == 1 && eventThread == 0) + return g_ftCommonData.dataCommon->commonActionExitScripts; +Exit: + return nullptr; +} + +soAnimCmdDisguiseList* ftFighterBuildData::getAnimCmdDisguiseList(bool p1, s32 actionType) { + if (p1 == false) { + if (actionType == 0) + return m_ftData->unk50; + if (actionType == 1) + return m_ftData->unk54; + } + return nullptr; +} + +u32 ftFighterBuildData::getMdlResId() { + return 0xFFFF; +} + +u32 ftFighterBuildData::getAnimResId() { + return 0xFFFF; +} + +u8 ftFighterBuildData::getResGroupNo() { + return m_resGroupNo; +} + +ftMotionData* ftFighterBuildData::getMotionData() { + return g_ftCommonDataAccesser.getData(m_kind)->motionData; +} + +ftStatusData* ftFighterBuildData::getStatusData() { + return g_ftCommonDataAccesser.getData(m_kind)->statusData; +} + +ftVisibilityData* ftFighterBuildData::getVisibilityData() { + return g_ftCommonDataAccesser.getData(m_kind)->visibilityData; +} + +soParamAccesser* ftFighterBuildData::getParamAccesser() { + return &g_soParamAccesserNull; +} + +s32 ftFighterBuildData::getAreaCategory() { + return 0; +} + +void* ftFighterBuildData::getCameraRangeSet() { + return m_cameraRangeSet; +} + +void* ftFighterBuildData::getCameraClipSphereSet() { + return m_cameraClipSphereSet; +} + +void* ftFighterBuildData::getItemNodeData() { + return soValueAccesser::getConstantIndefinite(m_moduleAccsr, 43015, 0); +} + +void* ftFighterBuildData::getModelExtendNodeTable() { + return soValueAccesser::getConstantIndefinite(m_moduleAccsr, 43014, 0); +} + +ftIkData* ftFighterBuildData::getIkData() { + return g_ftCommonData.dataCommon->ikData; +} + +ftShakeData* ftFighterBuildData::getShakeData() { + return g_ftCommonData.dataCommon->shakeData; +} + +void* ftFighterBuildData::getEffectNodeData() { + return nullptr; +} + +void* ftFighterBuildData::getEffectEmitData() { + return soValueAccesser::getConstantIndefinite(m_moduleAccsr, 43010, 0); +} + +ftEffectCommonData* ftFighterBuildData::getEffectCommonData() { + return g_ftCommonData.dataCommon->effectCommonData; +} + +ftEffectScreenData* ftFighterBuildData::getEffectScreenData() { + return g_ftCommonData.dataCommon->effectScreenData; +} + +soGroundConditionChecker* ftFighterBuildData::getGroundConditionChecker() { + return &g_ftGroundConditionCheckerImpl; +} + +ftJostleData* ftFighterBuildData::getJostleData() { + return g_ftCommonData.dataCommon->jostleData; +} + +ftPreCheckAnimCmdData* ftFighterBuildData::getPreCheckAnimCmdData() { + return g_ftCommonDataAccesser.getData(m_kind)->preCheckAnimCmdData; +} + +float ftFighterBuildData::getModelScale() { + return g_ftCommonDataAccesser.getParam(m_kind)->modelScale; +} + +s32 ftFighterBuildData::getHeapSlotNo() { + return g_ftManager->getSlotNo(m_entryId); +} + +ftSoundIdExchangerImpl* ftFighterBuildData::getSoundIdExchanger() { + if (m_kind == Fighter_Kirby) + return &g_ftKirbySoundIdExchangerImpl; + return &g_ftSoundIdExchangerImpl; +} + +float ftFighterBuildData::getSlopeAngleLimit() { + return g_ftCommonDataAccesser.getParam(m_kind)->slopeAngleLimit; +} + +bool ftGroundConditionCheckerImpl::isConditionNoCliffStop(soModuleAccesser* moduleAccesser) { + soKineticEnergy* energy = moduleAccesser->getKineticModule().getEnergy(4); + if (energy->isEnable() == true) { + float f31 = soValueAccesser::getConstantFloat(moduleAccesser, 3297, 0); + if (energy->getSpeed().lengthSq() > (f31 *= f31)) + return true; + } + if (moduleAccesser->getAreaModule().getEnviromentElementChecker() + ->getOnMovementGroundArea() == true) + return true; + return false; +} + +ftGroundConditionCheckerImpl::~ftGroundConditionCheckerImpl() { } diff --git a/src/mo_melee/sora_melee/so/so_common_data_accesser.cpp b/src/mo_melee/sora_melee/so/so_common_data_accesser.cpp index 1f4f935..0c17b5f 100644 --- a/src/mo_melee/sora_melee/so/so_common_data_accesser.cpp +++ b/src/mo_melee/sora_melee/so/so_common_data_accesser.cpp @@ -1,6 +1,8 @@ #include #include +soCommonDataAccesser g_soCommonDataAccesser; + void soCommonDataAccesser::setupCommonParam(soCommonParam** p1) { for (u32 i = 0; i < 2; i++) { u32 j = 0;