summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/d/actor/d_a_b_zant.cpp8146
-rw-r--r--src/d/actor/d_a_b_zant_magic.cpp2
2 files changed, 5473 insertions, 2675 deletions
diff --git a/src/d/actor/d_a_b_zant.cpp b/src/d/actor/d_a_b_zant.cpp
index 7566bb6caa..40b3cde428 100644
--- a/src/d/actor/d_a_b_zant.cpp
+++ b/src/d/actor/d_a_b_zant.cpp
@@ -4,3013 +4,5811 @@
*/
#include "d/actor/d_a_b_zant.h"
-#include "dol2asm.h"
-#include "d/d_camera.h"
-
-//
-// Forward References:
-//
-
-extern "C" void __ct__14daB_ZANT_HIO_cFv();
-extern "C" void ctrlJoint__10daB_ZANT_cFP8J3DJointP8J3DModel();
-extern "C" void JointCallBack__10daB_ZANT_cFP8J3DJointi();
-extern "C" void draw__10daB_ZANT_cFv();
-extern "C" void __dt__4cXyzFv();
-extern "C" static void daB_ZANT_Draw__FP10daB_ZANT_c();
-extern "C" void setBck__10daB_ZANT_cFiUcff();
-extern "C" void checkBck__10daB_ZANT_cFi();
-extern "C" void setActionMode__10daB_ZANT_cFii();
-extern "C" void checkBigDamage__10daB_ZANT_cFv();
-extern "C" void checkDamageType__10daB_ZANT_cFv();
-extern "C" void setDamageSe__10daB_ZANT_cFP8dCcD_Sphi();
-extern "C" void damage_check__10daB_ZANT_cFv();
-extern "C" void __as__8dCcD_SphFRC8dCcD_Sph();
-extern "C" void __as__12dCcD_GObjInfFRC12dCcD_GObjInf();
-extern "C" void __dt__8dCcD_SphFv();
-extern "C" void __dt__8cM3dGSphFv();
-extern "C" void __dt__8cM3dGAabFv();
-extern "C" void ice_damage_check__10daB_ZANT_cFv();
-extern "C" void setNextDamageMode__10daB_ZANT_cFi();
-extern "C" static void s_obj_sub__FPvPv();
-extern "C" void checkAvoidWeapon__10daB_ZANT_cFi();
-extern "C" void setTgHitBit__10daB_ZANT_cFi();
-extern "C" void setCoHitBit__10daB_ZANT_cFi();
-extern "C" void setTgShield__10daB_ZANT_cFi();
-extern "C" void setTgType__10daB_ZANT_cFUl();
-extern "C" void setZantMessage__10daB_ZANT_cFi();
-extern "C" void doZantMessage__10daB_ZANT_cFv();
-extern "C" void setIceLandingEffect__10daB_ZANT_cFi();
-extern "C" void setWaterBubble__10daB_ZANT_cFv();
-extern "C" void setMonkeyFallEffect__10daB_ZANT_cFv();
-extern "C" void setLastRollEffect__10daB_ZANT_cFv();
-extern "C" static void s_pillar_sub__FPvPv();
-extern "C" void getMagicSpeed__10daB_ZANT_cFv();
-extern "C" void getMagicWaterSpeed__10daB_ZANT_cFv();
-extern "C" void executeSmallAttack__10daB_ZANT_cFv();
-extern "C" void calcScale__10daB_ZANT_cFi();
-extern "C" void executeWarp__10daB_ZANT_cFv();
-extern "C" void __dt__14dBgS_ObjGndChkFv();
-extern "C" void executeDamage__10daB_ZANT_cFv();
-extern "C" void executeConfuse__10daB_ZANT_cFv();
-extern "C" void executeOpening__10daB_ZANT_cFv();
-extern "C" void executeFly__10daB_ZANT_cFv();
-extern "C" void executeFlyGround__10daB_ZANT_cFv();
-extern "C" void checkSwimLinkNearMouth__10daB_ZANT_cFv();
-extern "C" void checkSwimLinkNear__10daB_ZANT_cFv();
-extern "C" void executeHook__10daB_ZANT_cFv();
-extern "C" void executeWater__10daB_ZANT_cFv();
-extern "C" void executeSwim__10daB_ZANT_cFv();
-extern "C" void executeSimaJump__10daB_ZANT_cFv();
-extern "C" void executeIceDemo__10daB_ZANT_cFv();
-extern "C" void executeIceJump__10daB_ZANT_cFv();
-extern "C" void executeIceStep__10daB_ZANT_cFv();
-extern "C" void executeIceDamage__10daB_ZANT_cFv();
-extern "C" void setFarPillarPos__10daB_ZANT_cFv();
-extern "C" void setNearPillarPos__10daB_ZANT_cFv();
-extern "C" void setNextPillarInfo__10daB_ZANT_cFi();
-extern "C" void setNextPillarPos__10daB_ZANT_cFv();
-extern "C" void checkPillarSwing__10daB_ZANT_cFv();
-extern "C" void executeMonkey__10daB_ZANT_cFv();
-extern "C" void executeMonkeyFall__10daB_ZANT_cFv();
-extern "C" void executeMonkeyDamage__10daB_ZANT_cFv();
-extern "C" void setLastWarp__10daB_ZANT_cFii();
-extern "C" void executeLastStartDemo__10daB_ZANT_cFv();
-extern "C" void executeLastAttack__10daB_ZANT_cFv();
-extern "C" void executeLastTired__10daB_ZANT_cFv();
-extern "C" void executeLastDamage__10daB_ZANT_cFv();
-extern "C" static void s_del_tp__FPvPv();
-extern "C" void executeLastEndDemo__10daB_ZANT_cFv();
-extern "C" void calcMahojinAnime__10daB_ZANT_cFv();
-extern "C" void calcRoomChangeCamera__10daB_ZANT_cFi();
-extern "C" void initNextRoom__10daB_ZANT_cFv();
-extern "C" void executeRoomChange__10daB_ZANT_cFv();
-extern "C" void setBaseActionMode__10daB_ZANT_cFi();
-extern "C" void action__10daB_ZANT_cFv();
-extern "C" void mtx_set__10daB_ZANT_cFv();
-extern "C" void cc_set__10daB_ZANT_cFv();
-extern "C" void cc_ice_set__10daB_ZANT_cFv();
-extern "C" void execute__10daB_ZANT_cFv();
-extern "C" static void daB_ZANT_Execute__FP10daB_ZANT_c();
-extern "C" static bool daB_ZANT_IsDelete__FP10daB_ZANT_c();
-extern "C" void _delete__10daB_ZANT_cFv();
-extern "C" static void daB_ZANT_Delete__FP10daB_ZANT_c();
-extern "C" void CreateHeap__10daB_ZANT_cFv();
-extern "C" void __dt__12J3DFrameCtrlFv();
-extern "C" static void useHeapInit__FP10fopAc_ac_c();
-extern "C" void create__10daB_ZANT_cFv();
-extern "C" void __dt__8cM3dGCylFv();
-extern "C" void __ct__8dCcD_SphFv();
-extern "C" void __dt__10dCcD_GSttsFv();
-extern "C" void __dt__12dBgS_ObjAcchFv();
-extern "C" void __dt__12dBgS_AcchCirFv();
-extern "C" static void daB_ZANT_Create__FP10daB_ZANT_c();
-extern "C" void __dt__10cCcD_GSttsFv();
-extern "C" void __dt__14daB_ZANT_HIO_cFv();
-extern "C" void __sinit_d_a_b_zant_cpp();
-extern "C" static void func_8064EAE0();
-extern "C" static void func_8064EAE8();
-extern "C" static void func_8064EAF0();
-extern "C" static void func_8064EAF8();
-extern "C" static void func_8064EB00();
-extern "C" extern char const* const d_a_b_zant__stringBase0;
-
-//
-// External References:
-//
-
-extern "C" void mDoMtx_ZXYrotM__FPA4_fsss();
-extern "C" void mDoMtx_YrotS__FPA4_fs();
-extern "C" void mDoMtx_YrotM__FPA4_fs();
-extern "C" void mDoMtx_ZrotM__FPA4_fs();
-extern "C" void transS__14mDoMtx_stack_cFRC4cXyz();
-extern "C" void transM__14mDoMtx_stack_cFfff();
-extern "C" void transM__14mDoMtx_stack_cFRC4cXyz();
-extern "C" void scaleM__14mDoMtx_stack_cFfff();
-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 init__13mDoExt_brkAnmFP16J3DMaterialTableP15J3DAnmTevRegKeyiifss();
-extern "C" void entry__13mDoExt_brkAnmFP16J3DMaterialTablef();
-extern "C" void mDoExt_modelUpdateDL__FP8J3DModel();
-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 mDoExt_J3DModel__create__FP12J3DModelDataUlUl();
-extern "C" void __ct__10fopAc_ac_cFv();
-extern "C" void fopAc_IsActor__FPv();
-extern "C" void fopAcM_setStageLayer__FPv();
-extern "C" void fopAcM_SearchByID__FUiPP10fopAc_ac_c();
-extern "C" void fopAcM_delete__FP10fopAc_ac_c();
-extern "C" void fopAcM_create__FsUlPC4cXyziPC5csXyzPC4cXyzSc();
-extern "C" void fopAcM_createChild__FsUiUlPC4cXyziPC5csXyzPC4cXyzScPFPv_i();
-extern "C" void fopAcM_entrySolidHeap__FP10fopAc_ac_cPFP10fopAc_ac_c_iUl();
-extern "C" void fopAcM_SetMin__FP10fopAc_ac_cfff();
-extern "C" void fopAcM_SetMax__FP10fopAc_ac_cfff();
-extern "C" void fopAcM_posMoveF__FP10fopAc_ac_cPC4cXyz();
-extern "C" void fopAcM_searchActorAngleY__FPC10fopAc_ac_cPC10fopAc_ac_c();
-extern "C" void fopAcM_searchActorAngleX__FPC10fopAc_ac_cPC10fopAc_ac_c();
-extern "C" void fopAcM_searchActorDistance__FPC10fopAc_ac_cPC10fopAc_ac_c();
-extern "C" void fopAcM_searchActorDistanceXZ__FPC10fopAc_ac_cPC10fopAc_ac_c();
-extern "C" void fopAcM_orderPotentialEvent__FP10fopAc_ac_cUsUsUs();
-extern "C" void fopAcM_effSmokeSet1__FPUlPUlPC4cXyzPC5csXyzfPC12dKy_tevstr_ci();
-extern "C" void fopMsgM_SearchByID__FUi();
-extern "C" void fopMsgM_messageSet__FUlUl();
-extern "C" void fopMsgM_messageSetDemo__FUl();
-extern "C" void fpcEx_Search__FPFPvPv_PvPv();
-extern "C" void fpcM_IsCreating__FUi();
-extern "C" void dStage_RoomCheck__FP11cBgS_GndChk();
-extern "C" void dComIfG_resLoad__FP30request_of_phase_process_classPCc();
-extern "C" void dComIfG_resDelete__FP30request_of_phase_process_classPCc();
-extern "C" void dComIfGp_getReverb__Fi();
-extern "C" void dComIfGp_setNextStage__FPCcsScSc();
-extern "C" void dComIfGs_onOneZoneSwitch__Fii();
-extern "C" void dComIfGs_offOneZoneSwitch__Fii();
-extern "C" void
-dComIfGd_setShadow__FUlScP8J3DModelP4cXyzffffR13cBgS_PolyInfoP12dKy_tevstr_csfP9_GXTexObj();
-extern "C" void entry__10daMirror_cFP8J3DModel();
-extern "C" void onDungeonItem__12dSv_memBit_cFi();
-extern "C" void onSwitch__12dSv_danBit_cFi();
-extern "C" void offSwitch__12dSv_danBit_cFi();
-extern "C" void setRoom__13dSv_restart_cFRC4cXyzsSc();
-extern "C" void isSwitch__10dSv_info_cCFii();
-extern "C" void getRes__14dRes_control_cFPCclP11dRes_info_ci();
-extern "C" void reset__14dEvt_control_cFv();
-extern "C" void setHitMark__13dPa_control_cFUsP10fopAc_ac_cPC4cXyzPC5csXyzPC4cXyzUl();
-extern "C" void
-set__13dPa_control_cFUcUsPC4cXyzPC12dKy_tevstr_cPC5csXyzPC4cXyzUcP18dPa_levelEcallBackScPC8_GXColorPC8_GXColorPC4cXyzf();
-extern "C" void
-set__13dPa_control_cFUlUcUsPC4cXyzPC12dKy_tevstr_cPC5csXyzPC4cXyzUcP18dPa_levelEcallBackScPC8_GXColorPC8_GXColorPC4cXyzf();
-extern "C" void
-setPoly__13dPa_control_cFUlUsR13cBgS_PolyInfoPC4cXyzPC12dKy_tevstr_cPC5csXyzPC4cXyziP18dPa_levelEcallBackScPC4cXyz();
-extern "C" void addReal__21dDlst_shadowControl_cFUlP8J3DModel();
-extern "C" void StartShock__12dVibration_cFii4cXyz();
-extern "C" void StopQuake__12dVibration_cFi();
-extern "C" void LockonTarget__12dAttention_cFl();
-extern "C" void LockonTruth__12dAttention_cFv();
-extern "C" void GroundCross__4cBgSFP11cBgS_GndChk();
-extern "C" void GetPolyAtt0__4dBgSFRC13cBgS_PolyInfo();
-extern "C" void __ct__12dBgS_AcchCirFv();
-extern "C" void SetWall__12dBgS_AcchCirFff();
-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 __ct__11dBgS_GndChkFv();
-extern "C" void __dt__11dBgS_GndChkFv();
-extern "C" void __dt__18dBgS_ObjGndChk_AllFv();
-extern "C" void SetObj__16dBgS_PolyPassChkFv();
-extern "C" void __ct__10dCcD_GSttsFv();
-extern "C" void Move__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 ChkAtHit__12dCcD_GObjInfFv();
-extern "C" void GetAtHitObj__12dCcD_GObjInfFv();
-extern "C" void ChkTgHit__12dCcD_GObjInfFv();
-extern "C" void GetTgHitObj__12dCcD_GObjInfFv();
-extern "C" void getHitSeID__12dCcD_GObjInfFUci();
-extern "C" void Set__8dCcD_CylFRC11dCcD_SrcCyl();
-extern "C" void Set__8dCcD_SphFRC11dCcD_SrcSph();
-extern "C" void pl_cut_LRC__Fi();
-extern "C" void def_se_set__FP10Z2CreatureP8cCcD_ObjUlP10fopAc_ac_c();
-extern "C" void cc_at_check__FP10fopAc_ac_cP11dCcU_AtInfo();
-extern "C" void checkIronBallThrowMode__9daAlink_cCFv();
-extern "C" void checkIronBallThrowReturnMode__9daAlink_cCFv();
-extern "C" void checkMasterSwordEquip__9daPy_py_cFv();
-extern "C" void getThrowBoomerangActor__9daPy_py_cFv();
-extern "C" void Start__9dCamera_cFv();
-extern "C" void Stop__9dCamera_cFv();
-extern "C" void SetTrimSize__9dCamera_cFl();
-extern "C" void Set__9dCamera_cF4cXyz4cXyzfs();
-extern "C" void Reset__9dCamera_cF4cXyz4cXyz();
-extern "C" void dCam_getBody__Fv();
-extern "C" void Eye__9dCamera_cFv();
-extern "C" void Center__9dCamera_cFv();
-extern "C" void settingTevStruct__18dScnKy_env_light_cFiP4cXyzP12dKy_tevstr_c();
-extern "C" void setLightTevColorType_MAJI__18dScnKy_env_light_cFP12J3DModelDataP12dKy_tevstr_c();
-extern "C" void dKy_custom_colset__FUcUcf();
-extern "C" void GetAc__8cCcD_ObjFv();
-extern "C" void Set__4cCcSFP8cCcD_Obj();
-extern "C" void __mi__4cXyzCFRC3Vec();
-extern "C" void __ml__4cXyzCFf();
-extern "C" void cM_atan2s__Fff();
-extern "C" void cM_rnd__Fv();
-extern "C" void cM_rndF__Ff();
-extern "C" void cM_rndFX__Ff();
-extern "C" void SetPos__11cBgS_GndChkFPC4cXyz();
-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 cLib_addCalc__FPfffff();
-extern "C" void cLib_addCalc2__FPffff();
-extern "C" void cLib_addCalcPos__FP4cXyzRC4cXyzfff();
-extern "C" void cLib_addCalcPosXZ__FP4cXyzRC4cXyzfff();
-extern "C" void cLib_addCalcPos2__FP4cXyzRC4cXyzff();
-extern "C" void cLib_addCalcAngleS__FPsssss();
-extern "C" void cLib_addCalcAngleS2__FPssss();
-extern "C" void cLib_chaseF__FPfff();
-extern "C" void cLib_chasePosXZ__FP4cXyzRC4cXyzf();
-extern "C" void cLib_chaseAngleS__FPsss();
-extern "C" void cLib_targetAngleY__FPC3VecPC3Vec();
-extern "C" void cLib_targetAngleX__FPC4cXyzPC4cXyz();
-extern "C" void cLib_offsetPos__FP4cXyzPC4cXyzsPC4cXyz();
-extern "C" void cLib_distanceAngleS__Fss();
-extern "C" void bgmStart__8Z2SeqMgrFUlUll();
-extern "C" void bgmStop__8Z2SeqMgrFUll();
-extern "C" void changeBgmStatus__8Z2SeqMgrFl();
-extern "C" void setDemoName__11Z2StatusMgrFPc();
-extern "C" void __ct__15Z2CreatureEnemyFv();
-extern "C" void init__15Z2CreatureEnemyFP3VecP3VecUcUc();
-extern "C" void setEnemyName__15Z2CreatureEnemyFPCc();
-extern "C" void* __nw__FUl();
-extern "C" void __dl__FPv();
-extern "C" void init__12J3DFrameCtrlFs();
-extern "C" void checkPass__12J3DFrameCtrlFf();
-extern "C" void __copy();
-extern "C" void __construct_array();
-extern "C" void __cvt_fp2unsigned();
-extern "C" void _savegpr_20();
-extern "C" void _savegpr_21();
-extern "C" void _savegpr_23();
-extern "C" void _savegpr_24();
-extern "C" void _savegpr_25();
-extern "C" void _savegpr_26();
-extern "C" void _savegpr_27();
-extern "C" void _savegpr_28();
-extern "C" void _savegpr_29();
-extern "C" void _restgpr_20();
-extern "C" void _restgpr_21();
-extern "C" void _restgpr_23();
-extern "C" void _restgpr_24();
-extern "C" void _restgpr_25();
-extern "C" void _restgpr_26();
-extern "C" void _restgpr_27();
-extern "C" void _restgpr_28();
-extern "C" void _restgpr_29();
-extern "C" extern void* __vt__18dBgS_ObjGndChk_All[12];
-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" u8 mStatus__20dStage_roomControl_c[65792];
-extern "C" extern u8 g_dComIfG_gameInfo[122384];
-extern "C" u8 mSimpleTexObj__21dDlst_shadowControl_c[32];
-extern "C" u8 mCurrentMtx__6J3DSys[48];
-extern "C" u8 sincosTable___5JMath[65536];
-extern "C" extern u8 pauseTimer__9dScnPly_c[4];
-extern "C" u8 mAudioMgrPtr__10Z2AudioMgr[4 + 4 /* padding */];
-extern "C" void __register_global_object();
-extern "C" void setSnortEffect__11daB_ZANTZ_cFi();
-extern "C" void setMouthMode__11daB_ZANTZ_cFUc();
-extern "C" void setAppearMode__11daB_ZANTZ_cFUc();
-
-//
-// Declarations:
-//
-
-/* ############################################################################################## */
-/* 8064EB1C-8064EB28 000000 000C+00 44/44 0/0 0/0 .rodata @3757 */
-SECTION_RODATA static u8 const lit_3757[12] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EB1C, &lit_3757);
-
-/* 8064EB28-8064EB2C 00000C 0004+00 6/38 0/0 0/0 .rodata @4169 */
-SECTION_RODATA static f32 const lit_4169 = 1.0f;
-COMPILER_STRIP_GATE(0x8064EB28, &lit_4169);
-
-/* 8064EB2C-8064EB30 000010 0004+00 0/13 0/0 0/0 .rodata @4170 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4170 = 10.0f;
-COMPILER_STRIP_GATE(0x8064EB2C, &lit_4170);
-#pragma pop
-
-/* 8064EB30-8064EB34 000014 0004+00 0/4 0/0 0/0 .rodata @4171 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4171 = 15.0f;
-COMPILER_STRIP_GATE(0x8064EB30, &lit_4171);
-#pragma pop
-
-/* 8064EB34-8064EB38 000018 0004+00 0/1 0/0 0/0 .rodata @4172 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4172 = 17.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EB34, &lit_4172);
-#pragma pop
-
-/* 8064EB38-8064EB3C 00001C 0004+00 0/8 0/0 0/0 .rodata @4173 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4173 = 100.0f;
-COMPILER_STRIP_GATE(0x8064EB38, &lit_4173);
-#pragma pop
-
-/* 8064EB3C-8064EB40 000020 0004+00 0/1 0/0 0/0 .rodata @4174 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4174 = 40.0f;
-COMPILER_STRIP_GATE(0x8064EB3C, &lit_4174);
-#pragma pop
-
-/* 8064EB40-8064EB44 000024 0004+00 0/3 0/0 0/0 .rodata @4175 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4175 = 22.0f;
-COMPILER_STRIP_GATE(0x8064EB40, &lit_4175);
-#pragma pop
-
-/* 8064EB44-8064EB48 000028 0004+00 3/43 0/0 0/0 .rodata @4176 */
-SECTION_RODATA static u8 const lit_4176[4] = {
- 0x00,
- 0x00,
- 0x00,
- 0x00,
+#include "d/actor/d_a_b_zant_mobile.h"
+#include "d/actor/d_a_nbomb.h"
+#include "d/actor/d_a_obj_pillar.h"
+#include "d/d_com_inf_game.h"
+#include "d/actor/d_a_alink.h"
+#include "d/actor/d_a_mirror.h"
+#include "d/d_s_play.h"
+#include "f_op/f_op_msg_mng.h"
+#include "SSystem/SComponent/c_math.h"
+#include "Z2AudioLib/Z2Instances.h"
+#include "JSystem/JAudio2/JAUSectionHeap.h"
+#include <cmath.h>
+
+/* ANIMATION IDS */
+#define ANM_DAMAGE_L_A 7
+#define ANM_DAMAGE_R_A 8
+#define ANM_DIE_DEMO 9
+#define ANM_FAINT 10
+#define ANM_FALL 11
+#define ANM_FLOAT_APPEAR 12
+#define ANM_FLOAT_APPEAR_SHORT 13
+#define ANM_FLOAT_APPEAR_WAIT 14
+#define ANM_FLOAT_DAMAGE_L 15
+#define ANM_FLOAT_DAMAGE_R 16
+#define ANM_FLOAT_REACTION 17
+#define ANM_FLOAT_WAIT 18
+#define ANM_FLOAT_WAIT_RETURN 19
+#define ANM_GROUND_REACTION 20
+#define ANM_HOOK_HIT 21
+#define ANM_HOOK_RELEASE 22
+#define ANM_HOOK_WAIT 23
+#define ANM_HUGE 24
+#define ANM_HUGE_LANDING 25
+#define ANM_JUMP_A 26
+#define ANM_JUMP_B 27
+#define ANM_LANDING 28
+#define ANM_LANDING_DAMAGE 29
+#define ANM_LANDING_WAIT 30
+#define ANM_LAST_DEMO 31
+#define ANM_LV1_FATIGUE 32
+#define ANM_LV1_JUMP_A 33
+#define ANM_LB1_JUMP_B 34
+#define ANM_MAGIC_SHOOT_A_A 35
+#define ANM_MAGIC_SHOOT_A_B 36
+#define ANM_MAGIC_SHOOT_A_B_A 37
+#define ANM_MAGIC_SHOOT_A_B_B 38
+#define ANM_MAGIC_SHOOT_A_B_C 39
+#define ANM_MAGIC_SHOOT_A_C 40
+#define ANM_MAGIC_SHOOT_A_D 41
+#define ANM_OP_1 42
+#define ANM_OP_2 43
+#define ANM_OP_3 44
+#define ANM_OP_RISE 45
+#define ANM_SHIND_L 46
+#define ANM_SHIND_R 47
+#define ANM_SPIN 48
+#define ANM_SWAMP_FALL_A 49
+#define ANM_SWAMP_FALL_B 50
+#define ANM_SWAMP_FALL_LOOP 51
+#define ANM_SWAMP_LANDING 52
+#define ANM_SWIM 53
+#define ANM_SW_ATTACK 54
+#define ANM_SW_ATTACK_B 55
+#define ANM_SW_DAMAGE_L 56
+#define ANM_SW_DAMAGE_R 57
+#define ANM_SW_FATIGUE 58
+#define ANM_SW_WAIT 59
+#define ANM_SW_WALK 60
+#define ANM_TRAMPLE_A 61
+#define ANM_TRAMPLE_B 62
+#define ANM_TRAMPLE_C 63
+#define ANM_TRAMPLE_D 64
+#define ANM_WAIT 65
+
+/* JOINT IDS */
+#define JNT_CENTER 0
+#define JNT_BACKBONE 1
+#define JNT_NECK 2
+#define JNT_HEAD 3
+#define JNT_CHIN 4
+#define JNT_HELMET 5
+#define JNT_TONGUE1 6
+#define JNT_TONGUE2 7
+#define JNT_TONGUE3 8
+#define JNT_TONGUE4 9
+#define JNT_TONGUE5 10
+#define JNT_MOUTH 11
+#define JNT_SHOULDER_L 12
+#define JNT_ARM_L1 13
+#define JNT_ARM_L2 14
+#define JNT_ARM_L3 15
+#define JNT_ARM_L4 16
+#define JNT_HIRA_LB1 17
+#define JNT_HIRA_LB2 18
+#define JNT_HIRA_LF1 19
+#define JNT_HIRA_LF2 20
+#define JNT_SPAD_L 21
+#define JNT_SHOULDER_R 22
+#define JNT_ARM_R1 23
+#define JNT_ARM_R2 24
+#define JNT_ARM_R3 25
+#define JNT_ARM_R4 26
+#define JNT_HIRA_RB1 27
+#define JNT_HIRA_RB2 28
+#define JNT_HIRA_RF1 29
+#define JNT_HIRA_RF2 30
+#define JNT_SPAD_R 31
+#define JNT_WAIST 32
+#define JNT_LEG_L1 33
+#define JNT_LEG_L2 34
+#define JNT_FOOT_L 35
+#define JNT_LEG_R1 36
+#define JNT_LEG_R2 37
+#define JNT_FOOT_R 38
+#define JNT_TARE_B1 39
+#define JNT_TARE_B2 40
+#define JNT_TARE_F1 41
+#define JNT_TARE_F2 42
+
+enum OPENING_MODE {
+ MODE_START_DEMO,
+ MODE_START_DEMO_WAIT,
+ MODE_PAN_GROUND,
+
+ MODE_MSG_1 = 4,
+ MODE_MSG_1_WAIT,
+ MODE_WARP_OUT_SE,
+ MODE_START_WARP,
+
+ MODE_WARP_WAIT = 100,
+ MODE_PAN_THRONE,
+ MODE_ZOOM_THRONE,
+ MODE_MSG_2,
+ MODE_FLY_UP,
+ MODE_CLOSE_UP,
+ MODE_SET_BOSS_TITLE,
+
+ MODE_WARP_IN_SE = 20,
+ MODE_WARP_IN_SCALE,
+ MODE_WARP_IN_WAIT,
+ MODE_ZOOM_OUT_ROOM_CHANGE,
+ MODE_START_ROOM_CHANGE,
+ MODE_ROOM_CHANGE,
+ MODE_END_ROOM_CHANGE,
+ MODE_END_DEMO,
};
-COMPILER_STRIP_GATE(0x8064EB44, &lit_4176);
-
-/* 8064EB48-8064EB4C 00002C 0004+00 0/2 0/0 0/0 .rodata @4177 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4177 = 6.0f / 5.0f;
-COMPILER_STRIP_GATE(0x8064EB48, &lit_4177);
-#pragma pop
-
-/* 8064EB4C-8064EB50 000030 0004+00 0/10 0/0 0/0 .rodata @4178 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4178 = 0.5f;
-COMPILER_STRIP_GATE(0x8064EB4C, &lit_4178);
-#pragma pop
-
-/* 8064EB50-8064EB54 000034 0004+00 0/5 0/0 0/0 .rodata @4179 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4179 = 200.0f;
-COMPILER_STRIP_GATE(0x8064EB50, &lit_4179);
-#pragma pop
-
-/* 8064EB54-8064EB58 000038 0004+00 0/4 0/0 0/0 .rodata @4180 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4180 = -100.0f;
-COMPILER_STRIP_GATE(0x8064EB54, &lit_4180);
-#pragma pop
-
-/* 8064EB58-8064EB5C 00003C 0004+00 1/6 0/0 0/0 .rodata @4181 */
-SECTION_RODATA static f32 const lit_4181 = 2.0f;
-COMPILER_STRIP_GATE(0x8064EB58, &lit_4181);
-
-/* 8064EE8C-8064EE98 000000 000C+00 1/1 0/0 0/0 .data cNullVec__6Z2Calc */
-SECTION_DATA static u8 cNullVec__6Z2Calc[12] = {
+
+static u8 const lit_3757[12] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
-/* 8064EE98-8064EEAC 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 */] = {
- 0x02000201,
- /* padding */
- 0x40080000,
- 0x00000000,
- 0x3FE00000,
- 0x00000000,
-};
-#pragma pop
+UNK_REL_DATA
+namespace {
/* 8064EEAC-8064EEEC 000020 0040+00 0/1 0/0 0/0 .data cc_zant_src__24@unnamed@d_a_b_zant_cpp@ */
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EEAC[64] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
- 0xD8, 0xFB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x75, 0x09, 0x00, 0x01, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcSph cc_zant_src = {
+ {
+ {0x0, {{0x400, 0x1, 0x4}, {0xD8FBFDFF, 0x43}, 0x75}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0x1, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
+ } // mSphAttr
};
-#pragma pop
/* 8064EEEC-8064EF2C 000060 0040+00 0/1 0/0 0/0 .data
* cc_zant_sword_src__24@unnamed@d_a_b_zant_cpp@ */
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EEEC[64] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
- 0xD8, 0xFB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcSph cc_zant_sword_src = {
+ {
+ {0x0, {{0x400, 0x1, 0x4}, {0xD8FBFDFF, 0x0}, 0x0}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0x0, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x2}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
+ } // mSphAttr
};
-#pragma pop
/* 8064EF2C-8064EF70 0000A0 0044+00 0/1 0/0 0/0 .data cc_zant_roll_src__24@unnamed@d_a_b_zant_cpp@
*/
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EF2C[68] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x04, 0xD8, 0xFB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x74,
- 0x09, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
- 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcCyl cc_zant_roll_src = {
+ {
+ {0x0, {{0x400, 0x2, 0x4}, {0xD8FBFDFF, 0x42}, 0x74}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0x6, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x2, 0x0, 0x0, 0x303}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {0.0f, 0.0f, 0.0f}, // mCenter
+ 40.0f, // mRadius
+ 40.0f // mHeight
+ } // mCyl
};
-#pragma pop
/* 8064EF70-8064EFB0 0000E4 0040+00 0/1 0/0 0/0 .data cc_zant_foot_src__24@unnamed@d_a_b_zant_cpp@
*/
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EF70[64] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x0A, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcSph cc_zant_foot_src = {
+ {
+ {0x0, {{0x0, 0x0, 0x0}, {0x400000, 0x3}, 0x0}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0xA, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x0, 0x0, 0x0, 0x106}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
+ } // mSphAttr
};
-#pragma pop
/* 8064EFB0-8064EFF0 000124 0040+00 0/1 0/0 0/0 .data
* cc_zant_foot_src2__24@unnamed@d_a_b_zant_cpp@ */
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EFB0[64] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1E,
- 0xD8, 0xBB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x75, 0x09, 0x00, 0x0D, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcSph cc_zant_foot_src2 = {
+ {
+ {0x0, {{0x400, 0x2, 0x1E}, {0xD8BBFDFF, 0x43}, 0x75}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0xD, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x2, 0x0, 0x0, 0x3}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
+ } // mSphAttr
};
-#pragma pop
/* 8064EFF0-8064F030 000164 0040+00 0/1 0/0 0/0 .data
* cc_zant_camera_src__24@unnamed@d_a_b_zant_cpp@ */
-#pragma push
-#pragma force_active on
-SECTION_DATA static u8 data_8064EFF0[64] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1E,
- 0xD8, 0xBB, 0xFD, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x09, 0x00, 0x0D, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+dCcD_SrcSph cc_zant_camera_src = {
+ {
+ {0x0, {{0x400, 0x2, 0x1E}, {0xD8BBFDFF, 0x0}, 0x5}}, // mObj
+ {dCcD_SE_METAL, 0x0, 0xD, 0x0, 0x0}, // mGObjAt
+ {dCcD_SE_NONE, 0x2, 0x0, 0x0, 0x3}, // mGObjTg
+ {0x0}, // mGObjCo
+ }, // mObjInf
+ {
+ {{0.0f, 0.0f, 0.0f}, 40.0f} // mSph
+ } // mSphAttr
};
-#pragma pop
/* 8064F030-8064F038 0001A4 0007+01 4/4 0/0 0/0 .data warp_next_room__24@unnamed@d_a_b_zant_cpp@
*/
-SECTION_DATA static u8 data_8064F030[7 + 1 /* padding */] = {
- 0x32,
- 0x35,
- 0x36,
- 0x37,
- 0x38,
- 0x39,
- 0x3C,
- /* padding */
- 0x00,
-};
-
-/* 8064F038-8064F044 0001AC 000C+00 1/1 0/0 0/0 .data l_landing_effect_id$5199 */
-SECTION_DATA static u8 l_landing_effect_id_5199[12] = {
- 0x86, 0xDC, 0x86, 0xDD, 0x86, 0xDE, 0x86, 0xDF, 0x86, 0xE0, 0x86, 0xE1,
-};
-
-/* 8064F044-8064F04C 0001B8 0006+02 1/1 0/0 0/0 .data l_landing_effect_id$5284 */
-SECTION_DATA static u8 l_landing_effect_id_5284[6 + 2 /* padding */] = {
- 0x89,
- 0x01,
- 0x89,
- 0x02,
- 0x89,
- 0x03,
- /* padding */
- 0x00,
- 0x00,
-};
-
-/* 8064F04C-8064F050 0001C0 0004+00 1/1 0/0 0/0 .data l_roll_effect_id$5301 */
-SECTION_DATA static u8 l_roll_effect_id[4] = {
- 0x89,
- 0x04,
- 0x89,
- 0x05,
-};
-
-/* 8064F050-8064F058 0001C4 0008+00 1/1 0/0 0/0 .data w_eff_id$6078 */
-SECTION_DATA static u8 w_eff_id[8] = {
- 0x01, 0xB8, 0x01, 0xB9, 0x01, 0xBA, 0x01, 0xBB,
-};
-
-/* 8064F058-8064F094 -00001 003C+00 1/1 0/0 0/0 .data @6173 */
-SECTION_DATA static void* lit_6173[15] = {
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0xB4),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x104),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x6B0),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x1E8),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x264),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x264),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x2F4),
- (void*)(((char*)executeFly__10daB_ZANT_cFv) + 0x5A4),
-};
-
-/* 8064F094-8064F110 -00001 007C+00 1/1 0/0 0/0 .data @6631 */
-SECTION_DATA static void* lit_6631[31] = {
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0xB8),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x158),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x1E0),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x49C),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x58C),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x734),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x79C),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x80C),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9C4),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x844),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x94C),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x970),
- (void*)(((char*)executeWater__10daB_ZANT_cFv) + 0x9A8),
-};
-
-/* 8064F110-8064F140 -00001 0030+00 1/1 0/0 0/0 .data @6869 */
-SECTION_DATA static void* lit_6869[12] = {
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x1AC),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x1F0),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x1F0),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x2DC),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x2DC),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x910),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x808),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x88C),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x910),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x910),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0xC8),
- (void*)(((char*)executeSwim__10daB_ZANT_cFv) + 0x130),
-};
-
-/* 8064F140-8064F160 -00001 0020+00 1/1 0/0 0/0 .data @7421 */
-SECTION_DATA static void* lit_7421[8] = {
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x18C),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x1E0),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x214),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x264),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x2B8),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x7C4),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0x7C4),
- (void*)(((char*)executeIceJump__10daB_ZANT_cFv) + 0xAB0),
-};
-
-/* 8064F160-8064F208 -00001 00A8+00 1/1 0/0 0/0 .data @7981 */
-SECTION_DATA static void* lit_7981[42] = {
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0xE4),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0xE4),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x1C4),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x350),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x3C0),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x660),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x6F4),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x774),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x78C),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x7E0),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x868),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x938),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x81C),
- (void*)(((char*)executeIceDamage__10daB_ZANT_cFv) + 0x850),
-};
-
-/* 8064F208-8064F25C -00001 0054+00 1/1 0/0 0/0 .data @8454 */
-SECTION_DATA static void* lit_8454[21] = {
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x44),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0xCC),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0xEC),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x124),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x234),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x2F8),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x338),
- (void*)(((char*)executeMonkeyFall__10daB_ZANT_cFv) + 0x44),
-};
-
-/* 8064F25C-8064F278 -00001 001C+00 1/1 0/0 0/0 .data @8803 */
-SECTION_DATA static void* lit_8803[7] = {
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x68),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x12C),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x1A0),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x24C),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x2AC),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x368),
- (void*)(((char*)executeLastStartDemo__10daB_ZANT_cFv) + 0x3E0),
-};
-
-/* 8064F278-8064F2F8 -00001 0080+00 1/1 0/0 0/0 .data @9169 */
-SECTION_DATA static void* lit_9169[32] = {
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x60),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0xAC),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x1EC),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x318),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x404),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x978),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0xA74),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0xF20),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x1020),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x930),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x10C4),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0x978),
- (void*)(((char*)executeLastAttack__10daB_ZANT_cFv) + 0xA74),
-};
-
-/* 8064F2F8-8064F350 -00001 0058+00 1/1 0/0 0/0 .data @9307 */
-SECTION_DATA static void* lit_9307[22] = {
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x44),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x44),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x44),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x228),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x478),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x4D0),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x580),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x520),
- (void*)(((char*)executeLastDamage__10daB_ZANT_cFv) + 0x558),
-};
-
-/* 8064F350-8064F368 0004C4 0018+00 1/1 0/0 0/0 .data mahojin_se$9642 */
-SECTION_DATA static u8 mahojin_se[24] = {
- 0x00, 0x07, 0x04, 0x13, 0x00, 0x07, 0x04, 0x14, 0x00, 0x07, 0x04, 0x15,
- 0x00, 0x07, 0x04, 0x16, 0x00, 0x07, 0x04, 0x17, 0x00, 0x07, 0x04, 0x18,
-};
-
-/* 8064F368-8064F3AC -00001 0044+00 1/1 0/0 0/0 .data @9790 */
-SECTION_DATA static void* lit_9790[17] = {
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x68),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x1D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x210),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x8D4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x3B4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x4A0),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x520),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x540),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x5C4),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x76C),
- (void*)(((char*)executeRoomChange__10daB_ZANT_cFv) + 0x7E0),
-};
-
-/* 8064F3AC-8064F3C8 -00001 001C+00 1/1 0/0 0/0 .data @9869 */
-SECTION_DATA static void* lit_9869[7] = {
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x3BC),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x44),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x178),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x238),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x320),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x1F0),
- (void*)(((char*)setBaseActionMode__10daB_ZANT_cFi) + 0x370),
-};
-
-/* 8064F3C8-8064F428 -00001 0060+00 1/1 0/0 0/0 .data @9987 */
-SECTION_DATA static void* lit_9987[24] = {
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x5C),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x68),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x74),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x80),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x8C),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x98),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xA4),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xB0),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xBC),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xC8),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xD4),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xE0),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xEC),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0xF8),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x104),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x110),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x11C),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x128),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x134),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x140),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x14C),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x158),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x164),
- (void*)(((char*)action__10daB_ZANT_cFv) + 0x170),
-};
-
-/* 8064F428-8064F4AC 00059C 0084+00 1/1 0/0 0/0 .data ice_sph_jnt$10159 */
-SECTION_DATA static u8 ice_sph_jnt[132] = {
- 0x00, 0x00, 0x00, 0x23, 0x41, 0x20, 0x00, 0x00, 0x41, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x22, 0x41, 0xA0, 0x00, 0x00, 0x41, 0xA0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00,
- 0x00, 0x00, 0x41, 0xC8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x21, 0x41, 0xA0, 0x00, 0x00, 0x41,
- 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x26, 0x41, 0x20, 0x00, 0x00, 0x41, 0x70, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x25, 0x41, 0xA0, 0x00, 0x00, 0x41, 0xA0, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x25, 0x00, 0x00, 0x00, 0x00, 0x41, 0xC8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x41, 0xA0,
- 0x00, 0x00, 0x41, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x42,
- 0x34, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x41, 0xA0, 0x00, 0x00, 0x42, 0x34, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x03, 0x41, 0xA0, 0x00, 0x00, 0x41, 0xC8, 0x00, 0x00,
-};
-
-/* 8064F4AC-8064F4CC -00001 0020+00 1/0 0/0 0/0 .data l_daB_ZANT_Method */
-static actor_method_class l_daB_ZANT_Method = {
- (process_method_func)daB_ZANT_Create__FP10daB_ZANT_c,
- (process_method_func)daB_ZANT_Delete__FP10daB_ZANT_c,
- (process_method_func)daB_ZANT_Execute__FP10daB_ZANT_c,
- (process_method_func)daB_ZANT_IsDelete__FP10daB_ZANT_c,
- (process_method_func)daB_ZANT_Draw__FP10daB_ZANT_c,
-};
-
-/* 8064F4CC-8064F4FC -00001 0030+00 0/0 0/0 1/0 .data g_profile_B_ZANT */
-extern actor_process_profile_definition g_profile_B_ZANT = {
- fpcLy_CURRENT_e, // mLayerID
- 4, // mListID
- fpcPi_CURRENT_e, // mListPrio
- PROC_B_ZANT, // mProcName
- &g_fpcLf_Method.mBase, // sub_method
- sizeof(daB_ZANT_c), // mSize
- 0, // mSizeOther
- 0, // mParameters
- &g_fopAc_Method.base, // sub_method
- 226, // mPriority
- &l_daB_ZANT_Method, // sub_method
- 0x00040000, // mStatus
- fopAc_ENEMY_e, // mActorType
- fopAc_CULLBOX_CUSTOM_e, // cullType
-};
-
-/* 8064F4FC-8064F508 000670 000C+00 1/1 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,
-};
-
-/* 8064F508-8064F514 00067C 000C+00 2/2 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,
-};
-
-/* 8064F514-8064F520 000688 000C+00 1/1 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,
-};
-
-/* 8064F520-8064F52C 000694 000C+00 2/2 0/0 0/0 .data __vt__8cM3dGCyl */
-SECTION_DATA extern void* __vt__8cM3dGCyl[3] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__8cM3dGCylFv,
-};
-
-/* 8064F52C-8064F550 0006A0 0024+00 2/2 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_8064EB00,
- (void*)NULL,
- (void*)NULL,
- (void*)func_8064EAF8,
-};
-
-/* 8064F550-8064F55C 0006C4 000C+00 2/2 0/0 0/0 .data __vt__12J3DFrameCtrl */
-SECTION_DATA extern void* __vt__12J3DFrameCtrl[3] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__12J3DFrameCtrlFv,
-};
-
-/* 8064F55C-8064F58C 0006D0 0030+00 3/3 0/0 0/0 .data __vt__14dBgS_ObjGndChk */
-SECTION_DATA extern void* __vt__14dBgS_ObjGndChk[12] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__14dBgS_ObjGndChkFv,
- (void*)NULL,
- (void*)NULL,
- (void*)func_8064EAE0,
- (void*)NULL,
- (void*)NULL,
- (void*)func_8064EAF0,
- (void*)NULL,
- (void*)NULL,
- (void*)func_8064EAE8,
-};
-
-/* 8064F58C-8064F598 000700 000C+00 4/4 0/0 0/0 .data __vt__8cM3dGSph */
-SECTION_DATA extern void* __vt__8cM3dGSph[3] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__8cM3dGSphFv,
-};
-
-/* 8064F598-8064F5A4 00070C 000C+00 5/5 0/0 0/0 .data __vt__8cM3dGAab */
-SECTION_DATA extern void* __vt__8cM3dGAab[3] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__8cM3dGAabFv,
-};
-
-/* 8064F5A4-8064F5B0 000718 000C+00 2/2 0/0 0/0 .data __vt__14daB_ZANT_HIO_c */
-SECTION_DATA extern void* __vt__14daB_ZANT_HIO_c[3] = {
- (void*)NULL /* RTTI */,
- (void*)NULL,
- (void*)__dt__14daB_ZANT_HIO_cFv,
+static s8 warp_next_room[] = {
+ 50,
+ 53,
+ 54,
+ 55,
+ 56,
+ 57,
+ 60,
};
+}
/* 8063E10C-8063E19C 0000EC 0090+00 1/1 0/0 0/0 .text __ct__14daB_ZANT_HIO_cFv */
daB_ZANT_HIO_c::daB_ZANT_HIO_c() {
- // NONMATCHING
+ field_0x4 = -1;
+ mModelSize = 1.0f;
+ mMahojinWaitTime = 10.0f;
+ mBulletNum = 15.0f;
+ mAttackAnmSpeed = 1.7f;
+ mBulletSpeed = 100.0f;
+ mBulletSpeedUnderwater = 40.0f;
+ mDemoWarpTime = 22.0f;
+ mPlayWarpTime = 0.0f;
+ mSwordAttackSize = 1.2f;
+ mMahojinSize = 0.5f;
+ mMahojinOffsetX = 0.0f;
+ mMahojinOffsetY = 200.0f;
+ mMahojinOffsetZ = -100.0f;
+ mAppearAnmSpeed = 2.0f;
+ mDisappearAnmSpeed = 0.5f;
}
/* 8063E19C-8063E264 00017C 00C8+00 1/1 0/0 0/0 .text ctrlJoint__10daB_ZANT_cFP8J3DJointP8J3DModel
*/
-void daB_ZANT_c::ctrlJoint(J3DJoint* param_0, J3DModel* param_1) {
- // NONMATCHING
+int daB_ZANT_c::ctrlJoint(J3DJoint* i_joint, J3DModel* i_model) {
+ u16 jnt_no = i_joint->getJntNo();
+
+ mDoMtx_stack_c::copy(i_model->getAnmMtx(jnt_no));
+
+ switch (jnt_no) {
+ case JNT_BACKBONE:
+ mDoMtx_stack_c::ZrotM(mBackboneRotZ);
+ break;
+ case JNT_NECK:
+ mDoMtx_stack_c::ZXYrotM(mNeckRotX, 0, mNeckRotZ);
+ break;
+ }
+
+ i_model->setAnmMtx(jnt_no, mDoMtx_stack_c::get());
+ cMtx_copy(mDoMtx_stack_c::get(), J3DSys::mCurrentMtx);
+ return 1;
}
/* 8063E264-8063E2B0 000244 004C+00 1/1 0/0 0/0 .text JointCallBack__10daB_ZANT_cFP8J3DJointi */
-void daB_ZANT_c::JointCallBack(J3DJoint* param_0, int param_1) {
- // NONMATCHING
+int daB_ZANT_c::JointCallBack(J3DJoint* i_joint, int param_1) {
+ if (param_1 == 0) {
+ J3DModel* model = j3dSys.getModel();
+ daB_ZANT_c* actor = (daB_ZANT_c*)model->getUserArea();
+
+ if (actor != NULL) {
+ actor->ctrlJoint(i_joint, model);
+ }
+ }
+
+ return 1;
}
-/* ############################################################################################## */
+namespace {
/* 8064EB5C-8064EB74 000040 0018+00 1/4 0/0 0/0 .rodata iron_tg_cc__24@unnamed@d_a_b_zant_cpp@ */
-SECTION_RODATA static u8 const data_8064EB5C[24] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02,
- 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x06,
+static int const iron_tg_cc[] = {
+ 0,
+ 1,
+ 2,
+ 4,
+ 5,
+ 6,
};
-COMPILER_STRIP_GATE(0x8064EB5C, &data_8064EB5C);
-
-/* 8064EB74-8064EB78 000058 0004+00 0/1 0/0 0/0 .rodata @4333 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4333 = 2000.0f;
-COMPILER_STRIP_GATE(0x8064EB74, &lit_4333);
-#pragma pop
-
-/* 8064EB78-8064EB7C 00005C 0004+00 0/23 0/0 0/0 .rodata @4334 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4334 = 3.0f;
-COMPILER_STRIP_GATE(0x8064EB78, &lit_4334);
-#pragma pop
-
-/* 8064EB7C-8064EB80 000060 0004+00 0/2 0/0 0/0 .rodata @4335 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4335 = 1500.0f;
-COMPILER_STRIP_GATE(0x8064EB7C, &lit_4335);
-#pragma pop
-
-/* 8064EB80-8064EB84 000064 0004+00 0/4 0/0 0/0 .rodata @4336 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4336 = 800.0f;
-COMPILER_STRIP_GATE(0x8064EB80, &lit_4336);
-#pragma pop
-
-/* 8063E2B0-8063E568 000290 02B8+00 1/1 0/0 0/0 .text draw__10daB_ZANT_cFv */
-void daB_ZANT_c::draw() {
- // NONMATCHING
}
-/* 8063E568-8063E5A4 000548 003C+00 1/1 0/0 0/0 .text __dt__4cXyzFv */
-// cXyz::~cXyz() {
-extern "C" void __dt__4cXyzFv() {
- // NONMATCHING
+/* 8063E2B0-8063E568 000290 02B8+00 1/1 0/0 0/0 .text draw__10daB_ZANT_cFv */
+int daB_ZANT_c::draw() {
+ J3DModel* model = mpModelMorf->getModel();
+
+ g_env_light.settingTevStruct(0, &current.pos, &tevStr);
+ g_env_light.setLightTevColorType_MAJI(model, &tevStr);
+
+ mpModelMorf->entryDL();
+ daMirror_c::entry(model);
+
+ cXyz sp38;
+ sp38.set(current.pos.x, current.pos.y + 100.0f, current.pos.z);
+
+ f32 var_f31;
+ if (mFightPhase == PHASE_YO) {
+ var_f31 = 2000.0f - current.pos.y;
+ if (var_f31 < 0.0f) {
+ var_f31 = 0.0f;
+ }
+
+ tevStr.field_0x344 = (var_f31 * 3.0f) / 2000.0f;
+ if (tevStr.field_0x344 >= 1.0f) {
+ tevStr.field_0x344 = 1.0f;
+ }
+
+ mShadowKey = dComIfGd_setShadow(mShadowKey, 0, model, &sp38, 1500.0f, 0.0f, current.pos.y, mAcch.GetGroundH(), mAcch.m_gnd, &tevStr, 0, 1.0f, dDlst_shadowControl_c::getSimpleTex());
+ } else {
+ mShadowKey = dComIfGd_setShadow(mShadowKey, 1, model, &sp38, 800.0f, 0.0f, current.pos.y, mAcch.GetGroundH(), mAcch.m_gnd, &tevStr, 0, 1.0f, dDlst_shadowControl_c::getSimpleTex());
+ }
+
+ if (mDrawSwords) {
+ g_env_light.setLightTevColorType_MAJI(mpSwordLModel, &tevStr);
+ mDoExt_modelUpdateDL(mpSwordLModel);
+ dComIfGd_addRealShadow(mShadowKey, mpSwordLModel);
+
+ g_env_light.setLightTevColorType_MAJI(mpSwordRModel, &tevStr);
+ mDoExt_modelUpdateDL(mpSwordRModel);
+ dComIfGd_addRealShadow(mShadowKey, mpSwordRModel);
+ }
+
+ if (mMahojinAnmMode != 0) {
+ g_env_light.setLightTevColorType_MAJI(mpMahojinModel, &tevStr);
+ mpMahojinBrk->entry(mpMahojinModel->getModelData());
+ mpMahojinBtk->entry(mpMahojinModel->getModelData());
+ mpMahojinStartBtk->entry(mpMahojinModel->getModelData());
+
+ mDoExt_modelUpdateDL(mpMahojinModel);
+
+ if (mMahojin2AnmMode) {
+ g_env_light.setLightTevColorType_MAJI(mpMahojinModel2, &tevStr);
+ mpMahojinBrk2->entry(mpMahojinModel2->getModelData());
+ mpMahojinStartBtk2->entry(mpMahojinModel2->getModelData());
+
+ mDoExt_modelUpdateDL(mpMahojinModel2);
+ }
+ }
+
+ return 1;
}
/* 8063E5A4-8063E5C4 000584 0020+00 1/0 0/0 0/0 .text daB_ZANT_Draw__FP10daB_ZANT_c */
-static void daB_ZANT_Draw(daB_ZANT_c* param_0) {
- // NONMATCHING
+static int daB_ZANT_Draw(daB_ZANT_c* i_this) {
+ return i_this->draw();
}
-/* ############################################################################################## */
-/* 8064EB84-8064EB88 000068 0004+00 1/2 0/0 0/0 .rodata @4348 */
-SECTION_RODATA static f32 const lit_4348 = -1.0f;
-COMPILER_STRIP_GATE(0x8064EB84, &lit_4348);
-
-/* 8064EE60-8064EE60 000344 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */
-#pragma push
-#pragma force_active on
-SECTION_DEAD static char const* const stringBase_8064EE60 = "B_zan";
-#pragma pop
-
/* 8063E5C4-8063E668 0005A4 00A4+00 23/23 0/0 0/0 .text setBck__10daB_ZANT_cFiUcff */
-void daB_ZANT_c::setBck(int param_0, u8 param_1, f32 param_2, f32 param_3) {
- // NONMATCHING
+void daB_ZANT_c::setBck(int i_resID, u8 i_attr, f32 i_morf, f32 i_speed) {
+ mpModelMorf->setAnm((J3DAnmTransform*)dComIfG_getObjectRes("B_zan", i_resID), i_attr, i_morf, i_speed, 0.0f, -1.0f);
}
/* 8063E668-8063E6C4 000648 005C+00 3/3 0/0 0/0 .text checkBck__10daB_ZANT_cFi */
-void daB_ZANT_c::checkBck(int param_0) {
- // NONMATCHING
+bool daB_ZANT_c::checkBck(int i_resID) {
+ return mpModelMorf->getAnm() == (J3DAnmTransform*)dComIfG_getObjectRes("B_zan", i_resID) ? TRUE : FALSE;
}
/* 8063E6C4-8063E6F8 0006A4 0034+00 24/24 0/0 0/0 .text setActionMode__10daB_ZANT_cFii */
-void daB_ZANT_c::setActionMode(int param_0, int param_1) {
- // NONMATCHING
+void daB_ZANT_c::setActionMode(int i_action, int i_mode) {
+ mSwordSize = 1.0f;
+ field_0x701 = 0;
+ field_0x702 = 1;
+ field_0x717 = 0;
+
+ mLastAction = mAction;
+ mAction = i_action;
+ mMode = i_mode;
}
/* 8063E6F8-8063E79C 0006D8 00A4+00 2/2 0/0 0/0 .text checkBigDamage__10daB_ZANT_cFv */
-void daB_ZANT_c::checkBigDamage() {
- // NONMATCHING
+bool daB_ZANT_c::checkBigDamage() {
+ daPy_py_c* player = daPy_getPlayerActorClass();
+ BOOL taken_big_dmg = false;
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_NORMAL_SWORD) && daPy_py_c::checkMasterSwordEquip()) {
+ if (mAtInfo.mpCollider->GetAtAtp() >= 4) {
+ taken_big_dmg = true;
+ } else if (player->getSwordAtUpTime() != 0) {
+ taken_big_dmg = true;
+ } else if (player->getCutCount() >= 4) {
+ taken_big_dmg = true;
+ }
+ }
+
+ return taken_big_dmg;
}
/* 8063E79C-8063E810 00077C 0074+00 2/2 0/0 0/0 .text checkDamageType__10daB_ZANT_cFv */
-void daB_ZANT_c::checkDamageType() {
- // NONMATCHING
+int daB_ZANT_c::checkDamageType() {
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_HOOKSHOT) && mFightPhase == PHASE_OI) {
+ return DMGTYPE_HOOK_OI;
+ }
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_HOOKSHOT) ||
+ mAtInfo.mpCollider->ChkAtType(AT_TYPE_SPINNER) ||
+ mAtInfo.mpCollider->ChkAtType(AT_TYPE_ARROW) ||
+ mAtInfo.mpCollider->ChkAtType(AT_TYPE_SHIELD_ATTACK))
+ {
+ return DMGTYPE_OBJ;
+ }
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_BOOMERANG) || mAtInfo.mpCollider->ChkAtType(AT_TYPE_40)) {
+ return DMGTYPE_BOOMERANG;
+ }
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_MASTER_SWORD)) {
+ return DMGTYPE_SWORD;
+ }
+
+ return DMGTYPE_MISC;
}
/* 8063E810-8063E938 0007F0 0128+00 2/2 0/0 0/0 .text setDamageSe__10daB_ZANT_cFP8dCcD_Sphi */
-void daB_ZANT_c::setDamageSe(dCcD_Sph* param_0, int param_1) {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EB88-8064EB8C 00006C 0004+00 0/4 0/0 0/0 .rodata @4706 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4706 = 19.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EB88, &lit_4706);
-#pragma pop
-
-/* 8064EB8C-8064EB94 000070 0008+00 0/5 0/0 0/0 .rodata @4708 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const lit_4708[8] = {
- 0x43, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EB8C, &lit_4708);
-#pragma pop
-
-/* 8064F5B8-8064F5BC 000008 0001+03 1/1 0/0 0/0 .bss @1109 */
-static u8 lit_1109[1 + 3 /* padding */];
-
-/* 8064F5BC-8064F5C0 00000C 0001+03 0/0 0/0 0/0 .bss @1107 */
-#pragma push
-#pragma force_active on
-static u8 lit_1107[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5C0-8064F5C4 000010 0001+03 0/0 0/0 0/0 .bss @1105 */
-#pragma push
-#pragma force_active on
-static u8 lit_1105[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5C4-8064F5C8 000014 0001+03 0/0 0/0 0/0 .bss @1104 */
-#pragma push
-#pragma force_active on
-static u8 lit_1104[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5C8-8064F5CC 000018 0001+03 0/0 0/0 0/0 .bss @1099 */
-#pragma push
-#pragma force_active on
-static u8 lit_1099[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5CC-8064F5D0 00001C 0001+03 0/0 0/0 0/0 .bss @1097 */
-#pragma push
-#pragma force_active on
-static u8 lit_1097[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5D0-8064F5D4 000020 0001+03 0/0 0/0 0/0 .bss @1095 */
-#pragma push
-#pragma force_active on
-static u8 lit_1095[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5D4-8064F5D8 000024 0001+03 0/0 0/0 0/0 .bss @1094 */
-#pragma push
-#pragma force_active on
-static u8 lit_1094[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5D8-8064F5DC 000028 0001+03 0/0 0/0 0/0 .bss @1057 */
-#pragma push
-#pragma force_active on
-static u8 lit_1057[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5DC-8064F5E0 00002C 0001+03 0/0 0/0 0/0 .bss @1055 */
-#pragma push
-#pragma force_active on
-static u8 lit_1055[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5E0-8064F5E4 000030 0001+03 0/0 0/0 0/0 .bss @1053 */
-#pragma push
-#pragma force_active on
-static u8 lit_1053[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5E4-8064F5E8 000034 0001+03 0/0 0/0 0/0 .bss @1052 */
-#pragma push
-#pragma force_active on
-static u8 lit_1052[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5E8-8064F5EC 000038 0001+03 0/0 0/0 0/0 .bss @1014 */
-#pragma push
-#pragma force_active on
-static u8 lit_1014[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5EC-8064F5F0 00003C 0001+03 0/0 0/0 0/0 .bss @1012 */
-#pragma push
-#pragma force_active on
-static u8 lit_1012[1 + 3 /* padding */];
-#pragma pop
-
-/* 8064F5F0-8064F5F4 000040 0001+03 0/0 0/0 0/0 .bss @1010 */
-#pragma push
-#pragma force_active on
-static u8 lit_1010[1 + 3 /* padding */];
-#pragma pop
+void daB_ZANT_c::setDamageSe(dCcD_Sph* i_hitSph, int i_dmgAmount) {
+ health -= i_dmgAmount;
+ if (health < 0) {
+ health = 0;
+ }
+
+ BOOL var_r29;
+ u8 at_se = ((dCcD_GObjInf*)mAtInfo.mpCollider)->GetAtSe();
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_HOOKSHOT) && !fopAcM_checkStatus(this, 0x280000)) {
+ var_r29 = 1;
+ } else {
+ var_r29 = 0;
+ }
+
+ u32 var_r30 = 30;
+ if (mAtInfo.mHitStatus == 1) {
+ var_r30 = 31;
+ } else if (mAtInfo.mHitStatus == 2) {
+ var_r30 = 32;
+ }
+
+ mSound.startCollisionSE(i_hitSph->getHitSeID(at_se, var_r29), var_r30);
+
+ if (mAtInfo.mHitStatus == 0) {
+ dComIfGp_setHitMark(1, this, i_hitSph->GetTgHitPosP(), NULL, NULL, 0);
+ } else {
+ dComIfGp_setHitMark(3, this, i_hitSph->GetTgHitPosP(), NULL, NULL, 0);
+ }
+}
+
+UNK_BSS(1109)
+UNK_BSS(1107)
+UNK_BSS(1105)
+UNK_BSS(1104)
+UNK_BSS(1099)
+UNK_BSS(1097)
+UNK_BSS(1095)
+UNK_BSS(1094)
+UNK_BSS(1057)
+UNK_BSS(1055)
+UNK_BSS(1053)
+UNK_BSS(1052)
+UNK_BSS(1014)
+UNK_BSS(1012)
+UNK_BSS(1010)
/* 8064F5F4-8064F5F8 -00001 0004+00 2/2 0/0 0/0 .bss None */
/* 8064F5F4 0001+00 data_8064F5F4 @1009 */
-/* 8064F5F5 0003+00 data_8064F5F5 None */
-static u8 struct_8064F5F4[4];
-
-/* 8064F5F8-8064F604 000048 000C+00 0/1 0/0 0/0 .bss @4164 */
-#pragma push
-#pragma force_active on
-static u8 lit_4164[12];
-#pragma pop
+/* 8064F5F5 0003+00 l_initHIO None */
+static u8 data_8064F5F4;
+static u8 l_initHIO;
/* 8064F604-8064F648 000054 0044+00 12/13 0/0 0/0 .bss l_HIO */
-static u8 l_HIO[68];
-
-/* 8064F648-8064F654 000098 000C+00 0/1 0/0 0/0 .bss @4182 */
-#pragma push
-#pragma force_active on
-static u8 lit_4182[12];
-#pragma pop
-
-/* 8064F654-8064F660 0000A4 000C+00 0/1 0/0 0/0 .bss @4183 */
-#pragma push
-#pragma force_active on
-static u8 lit_4183[12];
-#pragma pop
-
-/* 8064F660-8064F66C 0000B0 000C+00 0/1 0/0 0/0 .bss @4184 */
-#pragma push
-#pragma force_active on
-static u8 lit_4184[12];
-#pragma pop
+static daB_ZANT_HIO_c l_HIO;
+namespace {
/* 8064F66C-8064F690 0000BC 0024+00 4/5 0/0 0/0 .bss fly_warp_pos__24@unnamed@d_a_b_zant_cpp@ */
-static u8 data_8064F66C[36];
+static cXyz fly_warp_pos[] = {
+ cXyz(0.0f, 400.0f, 1000.0f),
+ cXyz(1000.0f, 400.0f, 1500.0f),
+ cXyz(-1000.0f, 400.0f, 1500.0f),
+};
+}
/* 8063E938-8063F0F4 000918 07BC+00 1/1 0/0 0/0 .text damage_check__10daB_ZANT_cFv */
void daB_ZANT_c::damage_check() {
- // NONMATCHING
-}
-
-/* 8063F0F4-8063F180 0010D4 008C+00 1/1 0/0 0/0 .text __as__8dCcD_SphFRC8dCcD_Sph */
-// void dCcD_Sph::operator=(dCcD_Sph const& param_0) {
-extern "C" void __as__8dCcD_SphFRC8dCcD_Sph() {
- // NONMATCHING
-}
-
-/* 8063F180-8063F3C8 001160 0248+00 1/1 0/0 0/0 .text __as__12dCcD_GObjInfFRC12dCcD_GObjInf */
-// void dCcD_GObjInf::operator=(dCcD_GObjInf const& param_0) {
-extern "C" void __as__12dCcD_GObjInfFRC12dCcD_GObjInf() {
- // NONMATCHING
-}
-
-/* 8063F3C8-8063F494 0013A8 00CC+00 1/1 0/0 0/0 .text __dt__8dCcD_SphFv */
-// dCcD_Sph::~dCcD_Sph() {
-extern "C" void __dt__8dCcD_SphFv() {
- // NONMATCHING
-}
-
-/* 8063F494-8063F4DC 001474 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGSphFv */
-// cM3dGSph::~cM3dGSph() {
-extern "C" void __dt__8cM3dGSphFv() {
- // NONMATCHING
-}
-
-/* 8063F4DC-8063F524 0014BC 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGAabFv */
-// cM3dGAab::~cM3dGAab() {
-extern "C" void __dt__8cM3dGAabFv() {
- // NONMATCHING
+ field_0x9a4.Move();
+
+ if (mAction != ACT_ROOM_CHANGE) {
+ mAtInfo.mpSound = NULL;
+
+ if (field_0x702 != 0) {
+ mBodySphCc[0].OnTgNoHitMark();
+ mBodySphCc[1].OnTgNoHitMark();
+
+ if (mBodySphCc[0].ChkTgShield()) {
+ mAtInfo.mpSound = &mSound;
+ }
+ }
+
+ mAtInfo.mpCollider = NULL;
+
+ dCcD_Sph tg_hit_sph;
+ if (mBodySphCc[0].ChkTgHit()) {
+ mAtInfo.mpCollider = mBodySphCc[0].GetTgHitObj();
+ tg_hit_sph = mBodySphCc[0];
+ } else if (mBodySphCc[1].ChkTgHit()) {
+ mAtInfo.mpCollider = mBodySphCc[1].GetTgHitObj();
+ tg_hit_sph = mBodySphCc[1];
+ }
+
+ if (mAtInfo.mpCollider != NULL) {
+ daPy_py_c* player = daPy_getPlayerActorClass();
+
+ if (tg_hit_sph.ChkTgShield()) {
+ mAtInfo.field_0x18 = 42;
+ mAtInfo.mpCollider->SetAtAtp(0);
+ } else {
+ mAtInfo.field_0x18 = 0;
+ }
+
+ s16 prev_hp = health;
+ int dmg_amount = 0;
+
+ if (field_0x702 != 0) {
+ health = 280;
+ cc_at_check(this, &mAtInfo);
+ } else {
+ cc_at_check(this, &mAtInfo);
+ dmg_amount = prev_hp - health;
+ }
+
+ health = prev_hp;
+
+ if (!mAtInfo.mpCollider->ChkAtType(AT_TYPE_MASTER_SWORD)) {
+ dScnPly_c::setPauseTimer(0);
+ }
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_WOLF_ATTACK | AT_TYPE_WOLF_CUT_TURN | AT_TYPE_10000000 | AT_TYPE_MIDNA_LOCK)) {
+ field_0x6e4 = 20;
+ } else {
+ field_0x6e4 = 10;
+ }
+
+ if (mAtInfo.mAttackPower <= 1) {
+ field_0x6e4 = 10;
+ }
+
+ mTakenBigDmg = checkBigDamage();
+
+ switch (mFightPhase) {
+ case PHASE_BB:
+ if (field_0x70c == 0) {
+ setActionMode(ACT_FLY, 10);
+ } else {
+ switch (checkDamageType()) {
+ case DMGTYPE_SWORD:
+ setDamageSe(&tg_hit_sph, dmg_amount);
+
+ if (mAction != ACT_DAMAGE) {
+ field_0x6f4 = 100;
+ }
+
+ setActionMode(ACT_DAMAGE, pl_cut_LRC(player->getCutType()));
+ break;
+ case DMGTYPE_MISC:
+ field_0x70c = 0;
+ gravity = 0.0f;
+
+ mFlyWarpPosID = (f32)mFlyWarpPosID + cM_rndF(1.9f) + 1.0f;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID % 3];
+ field_0x711 = 2;
+
+ setActionMode(ACT_WARP, 1);
+ break;
+ case DMGTYPE_BOOMERANG:
+ setActionMode(ACT_CONFUSE, 5);
+ break;
+ case DMGTYPE_OBJ:
+ setActionMode(ACT_CONFUSE, 0);
+ break;
+ }
+ }
+ break;
+ case PHASE_MG:
+ switch (checkDamageType()) {
+ case DMGTYPE_SWORD:
+ setDamageSe(&tg_hit_sph, dmg_amount);
+
+ if (mAction != ACT_DAMAGE) {
+ field_0x6f4 = 100;
+ }
+
+ setActionMode(ACT_DAMAGE, pl_cut_LRC(player->getCutType()));
+ break;
+ case DMGTYPE_MISC:
+ setActionMode(ACT_SIMA_JUMP, 11);
+ break;
+ case DMGTYPE_BOOMERANG:
+ setActionMode(ACT_CONFUSE, 5);
+ break;
+ case DMGTYPE_OBJ:
+ setActionMode(ACT_CONFUSE, 0);
+ break;
+ }
+ break;
+ case PHASE_OI:
+ switch (checkDamageType()) {
+ case DMGTYPE_SWORD:
+ setDamageSe(&tg_hit_sph, dmg_amount);
+
+ if (mAction != ACT_DAMAGE) {
+ field_0x6f4 = 100;
+ }
+
+ setActionMode(ACT_DAMAGE, pl_cut_LRC(player->getCutType()));
+ break;
+ case DMGTYPE_HOOK_OI:
+ setActionMode(ACT_HOOK, 0);
+ break;
+ }
+ break;
+ case PHASE_MK:
+ if (field_0x707 != 0) {
+ if (mAction != ACT_MONKEY_FALL) {
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_BOOMERANG) || mAtInfo.mpCollider->ChkAtType(AT_TYPE_40)) {
+ setActionMode(ACT_MONKEY_FALL, 20);
+ } else {
+ setActionMode(ACT_CONFUSE, 0);
+ }
+ } else {
+ setActionMode(ACT_MONKEY_FALL, 10);
+ }
+ } else {
+ switch (checkDamageType()) {
+ case DMGTYPE_SWORD:
+ setDamageSe(&tg_hit_sph, dmg_amount);
+ setActionMode(ACT_MONKEY_DAMAGE, 0);
+ break;
+ case DMGTYPE_MISC:
+ setNearPillarPos();
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
+ break;
+ case DMGTYPE_BOOMERANG:
+ case DMGTYPE_OBJ:
+ field_0x6f0 = 0;
+ setActionMode(ACT_MONKEY_DAMAGE, 0);
+ break;
+ }
+ }
+ break;
+ case PHASE_LAST:
+ if (!tg_hit_sph.ChkTgShield()) {
+ switch (checkDamageType()) {
+ case DMGTYPE_SWORD:
+ setDamageSe(&tg_hit_sph, dmg_amount);
+
+ if (mAction == ACT_LAST_ATTACK && mMode == 13) {
+ mAction = ACT_LAST_TIRED;
+ }
+
+ setActionMode(ACT_LAST_DAMAGE, pl_cut_LRC(player->getCutType()));
+ break;
+ case DMGTYPE_MISC:
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ setTgHitBit(0);
+ setLastWarp(1, 0);
+ break;
+ case DMGTYPE_BOOMERANG:
+ setActionMode(ACT_LAST_DAMAGE, 20);
+ break;
+ case DMGTYPE_OBJ:
+ setActionMode(ACT_LAST_DAMAGE, 10);
+ break;
+ case DMGTYPE_HOOK_OI:
+ break;
+ }
+ }
+ break;
+ }
+
+ mBodySphCc[0].ClrTgHit();
+ mBodySphCc[1].ClrTgHit();
+ return;
+ }
+ }
}
/* 8063F524-8063F84C 001504 0328+00 1/1 0/0 0/0 .text ice_damage_check__10daB_ZANT_cFv */
void daB_ZANT_c::ice_damage_check() {
- // NONMATCHING
+ field_0xc74.Move();
+
+ if (field_0x6e4 == 0) {
+ s16 prev_hp = health;
+ mAtInfo.mpCollider = NULL;
+
+ for (int i = 0; i < 6; i++) {
+ int tg_idx = iron_tg_cc[i];
+
+ if (mFootCc[tg_idx].ChkTgHit()) {
+ field_0x6e4 = 10;
+ mAtInfo.mpCollider = mFootCc[tg_idx].GetTgHitObj();
+
+ if (!mFootCc[tg_idx].ChkTgShield()) {
+ if (mAction == ACT_ICE_STEP || mAction == ACT_ICE_JUMP) {
+ setDamageSe(&mFootCc[tg_idx], 0);
+
+ if (i < 2) {
+ setActionMode(ACT_ICE_DAMAGE, 0);
+ } else {
+ setActionMode(ACT_ICE_DAMAGE, 1);
+ }
+ } else if (mAction == ACT_ICE_DAMAGE) {
+ setActionMode(ACT_ICE_DAMAGE, 30);
+ mModeTimer = 0;
+ }
+ }
+
+ for (int j = 0; j < 6; j++) {
+ mFootCc[iron_tg_cc[j]].ClrTgHit();
+ }
+
+ return;
+ }
+ }
+
+ for (int i = 0; i < 11; i++) {
+ if (mFoot2Cc[i].ChkTgHit()) {
+ if (field_0x6e4 == 0) {
+ mAtInfo.mpCollider = mFoot2Cc[i].GetTgHitObj();
+
+ if (mFoot2Cc[i].ChkTgShield()) {
+ mAtInfo.field_0x18 = 42;
+ mAtInfo.mpCollider->SetAtAtp(0);
+ } else {
+ mAtInfo.field_0x18 = 0;
+ }
+
+ cc_at_check(this, &mAtInfo);
+
+ int dmg_amount = prev_hp - health;
+ health = prev_hp;
+
+ if (!mAtInfo.mpCollider->ChkAtType(AT_TYPE_MASTER_SWORD)) {
+ dScnPly_c::setPauseTimer(0);
+ }
+
+ if (mAtInfo.mpCollider->ChkAtType(AT_TYPE_WOLF_ATTACK | AT_TYPE_WOLF_CUT_TURN | AT_TYPE_10000000 | AT_TYPE_MIDNA_LOCK)) {
+ field_0x6e4 = 20;
+ } else {
+ field_0x6e4 = 10;
+ }
+
+ if (mAtInfo.mAttackPower <= 1) {
+ field_0x6e4 = 10;
+ }
+
+ mTakenBigDmg = checkBigDamage();
+
+ if (mAction == ACT_ICE_DAMAGE && mAtInfo.field_0x18 != 42) {
+ switch (checkDamageType()) {
+ case DMGTYPE_BOOMERANG:
+ setActionMode(ACT_ICE_DAMAGE, 40);
+ mModeTimer = 0;
+ break;
+ case DMGTYPE_OBJ:
+ setActionMode(ACT_ICE_DAMAGE, 20);
+ mModeTimer = 0;
+ break;
+ case DMGTYPE_MISC:
+ setActionMode(ACT_ICE_DAMAGE, 30);
+ mModeTimer = 0;
+ break;
+ case DMGTYPE_SWORD:
+ setDamageSe(&mFoot2Cc[i], dmg_amount);
+ setActionMode(ACT_ICE_DAMAGE, 10);
+ break;
+ }
+ }
+ }
+
+ mFoot2Cc[i].ClrTgHit();
+ }
+ }
+ }
}
/* 8063F84C-8063F970 00182C 0124+00 3/3 0/0 0/0 .text setNextDamageMode__10daB_ZANT_cFi
*/
-void daB_ZANT_c::setNextDamageMode(int param_0) {
- // NONMATCHING
+bool daB_ZANT_c::setNextDamageMode(BOOL i_checkHealth) {
+ if (i_checkHealth) {
+ if (mFightCycle == 0 && health < 140) {
+ mFightCycle++;
+ setBaseActionMode(2);
+ return true;
+ }
+ } else if (mFightCycle == 0) {
+ if (mTakenBigDmg) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ mFightCycle++;
+ setBaseActionMode(2);
+ return true;
+ }
+ } else if (health <= 0 || mTakenBigDmg) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ mFightCycle = 0;
+ setActionMode(ACT_ROOM_CHANGE, 0);
+ return true;
+ }
+
+ return false;
}
-/* ############################################################################################## */
-/* 8064EB94-8064EB98 000078 0004+00 0/11 0/0 0/0 .rodata @4938 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4938 = 300.0f;
-COMPILER_STRIP_GATE(0x8064EB94, &lit_4938);
-#pragma pop
-
-/* 8064EB98-8064EB9C 00007C 0004+00 0/5 0/0 0/0 .rodata @4939 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_4939 = 700.0f;
-COMPILER_STRIP_GATE(0x8064EB98, &lit_4939);
-#pragma pop
-
/* 8063F970-8063FAB4 001950 0144+00 1/1 0/0 0/0 .text s_obj_sub__FPvPv */
-static void s_obj_sub(void* param_0, void* param_1) {
- // NONMATCHING
+static void* s_obj_sub(void* i_actor, void* i_data) {
+ if (fopAcM_IsActor(i_actor)) {
+ if (!fpcM_IsCreating(fopAcM_GetID(i_actor)) && !fopAcM_checkCarryNow((fopAc_ac_c*)i_actor)) {
+ f32 obj_dist = fopAcM_searchActorDistanceXZ((fopAc_ac_c*)i_actor, (fopAc_ac_c*)i_data);
+ if (obj_dist < 300.0f && fopAcM_GetSpeed((fopAc_ac_c*)i_actor).y) {
+ if (fopAcM_GetName(i_actor) == PROC_Obj_Carry) {
+ return i_actor;
+ }
+
+ if (fopAcM_GetName(i_actor) == PROC_NBOMB) {
+ return i_actor;
+ }
+ }
+
+ if (obj_dist < 300.0f && fopAcM_GetName(i_actor) == PROC_NBOMB && ((daNbomb_c*)i_actor)->getExTime() < 10) {
+ return i_actor;
+ }
+
+ if (obj_dist < 700.0f && fopAcM_GetName(i_actor) == PROC_ARROW && fopAcM_GetSpeedF((fopAc_ac_c*)i_actor)) {
+ s16 actor_angle = ((fopAc_ac_c*)i_actor)->current.angle.y;
+ s16 angle_to_boss = fopAcM_searchActorAngleY((fopAc_ac_c*)i_actor, (fopAc_ac_c*)i_data);
+ if (abs((s16)(actor_angle - angle_to_boss)) < 0x2000) {
+ return i_actor;
+ }
+ }
+ }
+ }
+
+ return NULL;
}
-/* ############################################################################################## */
-/* 8064EB9C-8064EBA4 000080 0008+00 0/9 0/0 0/0 .rodata @5084 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const lit_5084[8] = {
- 0x3F, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EB9C, &lit_5084);
-#pragma pop
-
-/* 8064EBA4-8064EBAC 000088 0008+00 0/9 0/0 0/0 .rodata @5085 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const lit_5085[8] = {
- 0x40, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EBA4, &lit_5085);
-#pragma pop
-
-/* 8064EBAC-8064EBB4 000090 0008+00 0/9 0/0 0/0 .rodata @5086 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const lit_5086[8] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EBAC, &lit_5086);
-#pragma pop
-
/* 8063FAB4-8063FF6C 001A94 04B8+00 3/3 0/0 0/0 .text checkAvoidWeapon__10daB_ZANT_cFi */
-void daB_ZANT_c::checkAvoidWeapon(int param_0) {
- // NONMATCHING
+bool daB_ZANT_c::checkAvoidWeapon(BOOL i_allowBoomerang) {
+ if (i_allowBoomerang == 2) {
+ return FALSE;
+ }
+
+ daPy_py_c* player = daPy_getPlayerActorClass();
+
+ // avoid bomb, arrow, carry obj
+ fopAc_ac_c* obj = (fopAc_ac_c*)fpcM_Search(s_obj_sub, this);
+ if (obj != NULL) {
+ return TRUE;
+ }
+
+ // avoid clawshot
+ if (dComIfGp_checkPlayerStatus0(0, 0x4000)) {
+ cXyz* ppos = player->getHookshotTopPos();
+ if (ppos != NULL && ppos->absXZ(current.pos) < 300.0f) {
+ return TRUE;
+ }
+ }
+
+ // avoid ball and chain
+ cXyz* ppos = player->getIronBallCenterPos();
+ if (ppos != NULL) {
+ daAlink_c* player_alink = daAlink_getAlinkActorClass();
+ if ((player_alink->checkIronBallThrowMode() || player_alink->checkIronBallThrowReturnMode()) && !player->checkIronBallGroundStop()) {
+ if (ppos->absXZ(current.pos) < 300.0f) {
+ return TRUE;
+ }
+ }
+ }
+
+ // avoid boomerang
+ if (!i_allowBoomerang && player->getThrowBoomerangActor() != NULL) {
+ fopAc_ac_c* pboomerang = (fopAc_ac_c*)player->getThrowBoomerangActor();
+ if (pboomerang->current.pos.absXZ(current.pos) < 300.0f) {
+ return TRUE;
+ }
+ }
+
+ return FALSE;
}
/* 8063FF6C-8063FFAC 001F4C 0040+00 18/18 0/0 0/0 .text setTgHitBit__10daB_ZANT_cFi */
-void daB_ZANT_c::setTgHitBit(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setTgHitBit(BOOL i_onBit) {
+ if (i_onBit) {
+ mBodySphCc[0].OnTgSetBit();
+ mBodySphCc[1].OnTgSetBit();
+ } else {
+ mBodySphCc[0].OffTgSetBit();
+ mBodySphCc[1].OffTgSetBit();
+ }
}
/* 8063FFAC-8063FFEC 001F8C 0040+00 2/2 0/0 0/0 .text setCoHitBit__10daB_ZANT_cFi */
-void daB_ZANT_c::setCoHitBit(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setCoHitBit(BOOL i_onBit) {
+ if (i_onBit) {
+ mBodySphCc[0].OnCoSetBit();
+ mBodySphCc[1].OnCoSetBit();
+ } else {
+ mBodySphCc[0].OffCoSetBit();
+ mBodySphCc[1].OffCoSetBit();
+ }
}
/* 8063FFEC-806400BC 001FCC 00D0+00 2/2 0/0 0/0 .text setTgShield__10daB_ZANT_cFi */
-void daB_ZANT_c::setTgShield(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setTgShield(BOOL i_onShield) {
+ if (i_onShield) {
+ mBodySphCc[0].OnTgShield();
+ mBodySphCc[0].OnTgSpinnerReflect();
+ mBodySphCc[0].OnTgIronBallRebound();
+
+ mBodySphCc[1].OnTgShield();
+ mBodySphCc[1].OnTgSpinnerReflect();
+ mBodySphCc[1].OnTgIronBallRebound();
+
+ mBodySphCc[0].OffTgNoHitMark();
+ mBodySphCc[1].OffTgNoHitMark();
+
+ mBodySphCc[0].SetTgHitMark(CcG_Tg_UNK_MARK_2);
+ mBodySphCc[1].SetTgHitMark(CcG_Tg_UNK_MARK_2);
+ } else {
+ mBodySphCc[0].OffTgShield();
+ mBodySphCc[0].OffTgSpinnerReflect();
+ mBodySphCc[0].OffTgIronBallRebound();
+
+ mBodySphCc[1].OffTgShield();
+ mBodySphCc[1].OffTgSpinnerReflect();
+ mBodySphCc[1].OffTgIronBallRebound();
+
+ mBodySphCc[0].SetTgHitMark(CcG_Tg_UNK_MARK_0);
+ mBodySphCc[1].SetTgHitMark(CcG_Tg_UNK_MARK_0);
+ }
}
/* 806400BC-806400C8 00209C 000C+00 3/3 0/0 0/0 .text setTgType__10daB_ZANT_cFUl */
-void daB_ZANT_c::setTgType(u32 param_0) {
- // NONMATCHING
+void daB_ZANT_c::setTgType(u32 i_type) {
+ mBodySphCc[0].SetTgType(i_type);
+ mBodySphCc[1].SetTgType(i_type);
}
/* 806400C8-80640104 0020A8 003C+00 1/1 0/0 0/0 .text setZantMessage__10daB_ZANT_cFi */
-void daB_ZANT_c::setZantMessage(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setZantMessage(int i_msgNo) {
+ mMsgNo = i_msgNo;
+ mMsgID = fopMsgM_messageSet(i_msgNo, 1000);
}
/* 80640104-80640180 0020E4 007C+00 1/1 0/0 0/0 .text doZantMessage__10daB_ZANT_cFv */
-void daB_ZANT_c::doZantMessage() {
- // NONMATCHING
+int daB_ZANT_c::doZantMessage() {
+ if (mpMsg != NULL) {
+ if (mpMsg->mMode == 14) {
+ mpMsg->mMode = 16;
+ } else if (mpMsg->mMode == 18) {
+ mpMsg->mMode = 19;
+ mMsgID = fpcM_ERROR_PROCESS_ID_e;
+ return 1;
+ }
+ } else {
+ mpMsg = fopMsgM_SearchByID(mMsgID);
+ }
+
+ return 0;
}
/* 80640180-80640310 002160 0190+00 2/2 0/0 0/0 .text setIceLandingEffect__10daB_ZANT_cFi
*/
-void daB_ZANT_c::setIceLandingEffect(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setIceLandingEffect(BOOL i_landFootR) {
+ static u16 l_landing_effect_id[] = {
+ 0x86DC, 0x86DD, 0x86DE, 0x86DF, 0x86E0, 0x86E1,
+ };
+
+ cXyz particle_pos;
+ if (!i_landFootR) {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_L));
+ } else {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_R));
+ }
+
+ mDoMtx_stack_c::transM(10.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&particle_pos);
+ particle_pos.y = 2.0f;
+
+ cXyz size(1.0f, 1.0f, 1.0f);
+ for (int i = 0; i < 6; i++) {
+ dComIfGp_particle_set(l_landing_effect_id[i], &particle_pos, &tevStr, &shape_angle, &size);
+ }
+
+ particle_pos.set(0.0f, 0.0f, 0.0f);
+ dComIfGp_particle_set(0x86E2, &particle_pos, &tevStr, &shape_angle, NULL);
}
/* 80640310-806403D4 0022F0 00C4+00 1/1 0/0 0/0 .text setWaterBubble__10daB_ZANT_cFv */
void daB_ZANT_c::setWaterBubble() {
- // NONMATCHING
+ cXyz particle_pos;
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_MOUTH));
+ mDoMtx_stack_c::multVecZero(&particle_pos);
+
+ field_0x389c[0] = dComIfGp_particle_set(field_0x389c[0], 0x1E8, &particle_pos, &tevStr);
}
/* 806403D4-80640478 0023B4 00A4+00 1/1 0/0 0/0 .text setMonkeyFallEffect__10daB_ZANT_cFv
*/
void daB_ZANT_c::setMonkeyFallEffect() {
- // NONMATCHING
+ static u16 l_landing_effect_id[] = {0x8901, 0x8902, 0x8903};
+
+ for (int i = 0; i < 3; i++) {
+ dComIfGp_particle_set(l_landing_effect_id[i], &current.pos, &tevStr, &shape_angle, NULL);
+ }
}
/* 80640478-80640584 002458 010C+00 1/1 0/0 0/0 .text setLastRollEffect__10daB_ZANT_cFv
*/
void daB_ZANT_c::setLastRollEffect() {
- // NONMATCHING
+ static u16 l_roll_effect_id[] = {0x8904, 0x8905};
+
+ mSound.startCreatureSoundLevel(Z2SE_EN_ZAN_CTL_SPIN_ATK, 0, -1);
+
+ for (int i = 0; i < 2; i++) {
+ field_0x38ac[i] = dComIfGp_particle_set(field_0x38ac[i], l_roll_effect_id[i], &current.pos, &tevStr, &shape_angle, NULL, 0xFF, NULL, -1, NULL, NULL, NULL);
+ }
+
+ fopAcM_effSmokeSet2(&field_0x3894, &field_0x3898, &current.pos, NULL, 2.0f, &tevStr);
}
-/* ############################################################################################## */
/* 8064F690-8064F694 0000E0 0004+00 2/2 0/0 0/0 .bss target_info_count */
-static u8 target_info_count[4];
+static int target_info_count;
/* 80640584-80640654 002564 00D0+00 1/1 0/0 0/0 .text s_pillar_sub__FPvPv */
-static void s_pillar_sub(void* param_0, void* param_1) {
- // NONMATCHING
+static void* s_pillar_sub(void* i_actor, void* i_data) {
+ if (fopAcM_IsActor(i_actor)) {
+ if (!fpcM_IsCreating(fopAcM_GetID(i_actor)) && fopAcM_GetName(i_actor) == PROC_Obj_Pillar) {
+ if (((daPillar_c*)i_actor)->getMdlType() != 0) {
+ ((daB_ZANT_c*)i_data)->mPillarIDs[8] = fopAcM_GetID(i_actor);
+ } else {
+ ((daB_ZANT_c*)i_data)->mPillarIDs[target_info_count] = fopAcM_GetID(i_actor);
+ target_info_count++;
+ }
+ }
+ }
+
+ return NULL;
}
/* 80640654-80640664 002634 0010+00 0/0 0/0 1/1 .text getMagicSpeed__10daB_ZANT_cFv */
f32 daB_ZANT_c::getMagicSpeed() {
- // NONMATCHING
+ return l_HIO.mBulletSpeed;
}
/* 80640664-80640674 002644 0010+00 0/0 0/0 1/1 .text getMagicWaterSpeed__10daB_ZANT_cFv
*/
f32 daB_ZANT_c::getMagicWaterSpeed() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EBB4-8064EBB8 000098 0004+00 0/2 0/0 0/0 .rodata @5492 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5492 = 16.0f;
-COMPILER_STRIP_GATE(0x8064EBB4, &lit_5492);
-#pragma pop
-
-/* 8064EBB8-8064EBBC 00009C 0004+00 0/3 0/0 0/0 .rodata @5493 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5493 = 13.0f;
-COMPILER_STRIP_GATE(0x8064EBB8, &lit_5493);
-#pragma pop
-
-/* 8064EBBC-8064EBC0 0000A0 0004+00 0/2 0/0 0/0 .rodata @5494 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5494 = 9.0f;
-COMPILER_STRIP_GATE(0x8064EBBC, &lit_5494);
-#pragma pop
-
-/* 8064EBC0-8064EBC4 0000A4 0004+00 0/4 0/0 0/0 .rodata @5495 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5495 = 19.0f;
-COMPILER_STRIP_GATE(0x8064EBC0, &lit_5495);
-#pragma pop
+ return l_HIO.mBulletSpeedUnderwater;
+}
/* 80640674-80640C20 002654 05AC+00 1/1 0/0 0/0 .text executeSmallAttack__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeSmallAttack() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EBC4-8064EBC8 0000A8 0004+00 0/1 0/0 0/0 .rodata @5510 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5510 = 0.25f;
-COMPILER_STRIP_GATE(0x8064EBC4, &lit_5510);
-#pragma pop
-
-/* 8064EBC8-8064EBCC 0000AC 0004+00 0/7 0/0 0/0 .rodata @5511 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5511 = 1.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EBC8, &lit_5511);
-#pragma pop
-
-/* 8064EBCC-8064EBD0 0000B0 0004+00 0/2 0/0 0/0 .rodata @5512 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5512 = 1.0f / 5.0f;
-COMPILER_STRIP_GATE(0x8064EBCC, &lit_5512);
-#pragma pop
+ cXyz sp44;
+ s16 aim_target_angle = fopAcM_searchPlayerAngleY(this);
+
+ if (mFightPhase == PHASE_OI) {
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+
+ if (pmobile != NULL) {
+ s16 var_r26 = pmobile->shape_angle.y - aim_target_angle;
+ if (abs(var_r26) > 0x1400) {
+ if (var_r26 < 0) {
+ aim_target_angle = pmobile->shape_angle.y + 0x1000;
+ } else {
+ aim_target_angle = pmobile->shape_angle.y - 0x1000;
+ }
+ }
+ }
+ }
+
+ switch (mMode) {
+ case 0:
+ setTgHitBit(TRUE);
+ attention_info.flags = 4;
+ mMode = 2;
+ field_0x6fd = 0;
+
+ if (field_0x711 != 0) {
+ setBck(ANM_MAGIC_SHOOT_A_B, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_MAGIC_SHOOT_A_B_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ field_0x717 = 1;
+ break;
+ case 2:
+ if (field_0x711 != 0) {
+ if (mpModelMorf->checkFrame(15)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_ATK_BALL, -1);
+ }
+ } else {
+ if (mpModelMorf->checkFrame(16)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_ATK_BALL, -1);
+ }
+ }
+
+ cLib_addCalcAngleS(&shape_angle.y, aim_target_angle, 8, 0x400, 0x80);
+ if (mpModelMorf->isStop()) {
+ f32 anm_speed = l_HIO.mAttackAnmSpeed;
+ if (mFightPhase == PHASE_OI) {
+ anm_speed = 1.0f;
+ }
+
+ if (field_0x711 != 0) {
+ setBck(ANM_MAGIC_SHOOT_A_C, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, anm_speed);
+ } else {
+ setBck(ANM_MAGIC_SHOOT_A_B_B, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, anm_speed);
+ }
+
+ mMode = 3;
+ field_0x6fd = 0;
+ }
+ break;
+ case 3:
+ cLib_addCalcAngleS(&shape_angle.y, aim_target_angle, 8, 0x400, 0x80);
+
+ if (mpModelMorf->checkFrame(3) || mpModelMorf->checkFrame(13)) {
+ if (mpModelMorf->checkFrame(13)) {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_ARM_L4));
+ } else {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_ARM_R4));
+ }
+
+ mDoMtx_stack_c::multVecZero(&sp44);
+
+ u32 parameter = field_0x6fd + 1;
+ if (field_0x703 < 10) {
+ parameter += 2;
+ }
+
+ if (parameter > 6) {
+ parameter = 6;
+ }
+
+ fopAcM_createChild(PROC_B_ZANTM, fopAcM_GetID(this), parameter, &sp44, fopAcM_GetRoomNo(this), &shape_angle, NULL, -1, NULL);
+ dComIfGp_particle_set(0x886B, &sp44, &shape_angle, NULL);
+
+ field_0x6fd++;
+ field_0x704++;
+ } else if ((mpModelMorf->checkFrame(9) || mpModelMorf->checkFrame(19)) && field_0x6fd >= field_0x703) {
+ mMode = 4;
+
+ if (field_0x711 != 0) {
+ setBck(ANM_MAGIC_SHOOT_A_D, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_MAGIC_SHOOT_A_B_C, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ field_0x717 = 0;
+ }
+ break;
+ case 4:
+ if (mpModelMorf->isStop()) {
+ attention_info.flags = 4;
+
+ if (mFightPhase == PHASE_BB) {
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 1);
+ } else if (mFightPhase == PHASE_MG) {
+ setActionMode(ACT_SIMA_JUMP, 0);
+ } else if (mFightPhase == PHASE_OI) {
+ setActionMode(ACT_WATER, 0);
+ } else if (mFightPhase == PHASE_MK) {
+ setActionMode(ACT_MONKEY, 0);
+ }
+ }
+ break;
+ }
+
+ if (mFightPhase == PHASE_BB && checkAvoidWeapon(TRUE)) {
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 1);
+ }
+}
/* 80640C20-80640D14 002C00 00F4+00 3/3 0/0 0/0 .text calcScale__10daB_ZANT_cFi */
-void daB_ZANT_c::calcScale(int param_0) {
- // NONMATCHING
+bool daB_ZANT_c::calcScale(BOOL param_0) {
+ if (!param_0) {
+ cLib_addCalc(&mModelScaleXZ, 0.0f, 0.5f, 0.25f, 0.1f);
+ cLib_addCalc(&mModelScaleY, 1.2f, 0.5f, 0.1f, 0.1f);
+
+ if (!mModelScaleXZ) {
+ mModelScaleY = 0.0f;
+ mModelScaleXZ = 0.0f;
+ return true;
+ }
+ } else {
+ cLib_addCalc(&mModelScaleY, 1.0f, 0.5f, 0.2f, 0.1f);
+
+ if (mModelScaleY > 0.5f) {
+ cLib_addCalc(&mModelScaleXZ, 1.0f, 0.5f, 0.2f, 0.1f);
+ }
+
+ if (mModelScaleY == 1.0f && mModelScaleXZ == 1.0f) {
+ return true;
+ }
+ }
+
+ return false;
}
-/* ############################################################################################## */
-/* 8064EBD0-8064EBD4 0000B4 0004+00 0/1 0/0 0/0 .rodata @5606 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5606 = -1000000000.0f;
-COMPILER_STRIP_GATE(0x8064EBD0, &lit_5606);
-#pragma pop
-
/* 80640D14-80641230 002CF4 051C+00 1/1 0/0 0/0 .text executeWarp__10daB_ZANT_cFv */
void daB_ZANT_c::executeWarp() {
- // NONMATCHING
-}
-
-/* 80641230-806412A8 003210 0078+00 4/3 0/0 0/0 .text __dt__14dBgS_ObjGndChkFv */
-// dBgS_ObjGndChk::~dBgS_ObjGndChk() {
-extern "C" void __dt__14dBgS_ObjGndChkFv() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ case 1:
+ attention_info.flags = 0;
+ setTgHitBit(FALSE);
+ setCoHitBit(FALSE);
+
+ if (mFightPhase != PHASE_MK && mFightPhase != PHASE_YO && mFightPhase != PHASE_LAST) {
+ if (field_0x711 & 1) {
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ }
+
+ mMode += 2;
+
+ speed.y = 0.0f;
+ speedF = 0.0f;
+
+ dComIfGp_particle_set(0x88FF, &current.pos, &shape_angle, NULL);
+ dComIfGp_particle_set(0x8900, &current.pos, &shape_angle, NULL);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_OUT, 0, -1);
+ case 2:
+ case 3:
+ if (calcScale(0)) {
+ mMode += 2;
+
+ switch (mFightPhase) {
+ case PHASE_BB:
+ if (field_0x70b == 0) {
+ field_0x70b = 1;
+ mModeTimer = 120;
+ } else if (mFightCycle == 0) {
+ mModeTimer = 40;
+ } else {
+ mModeTimer = 15;
+ }
+ break;
+ case PHASE_MG:
+ mModeTimer = 15;
+ break;
+ case PHASE_OI:
+ mModeTimer = 60;
+ break;
+ case PHASE_MK:
+ if (mLastAction == ACT_MONKEY) {
+ mModeTimer = 15;
+ } else {
+ mModeTimer = 60;
+ }
+ break;
+ case PHASE_YO:
+ mModeTimer = 60;
+ break;
+ case PHASE_LAST:
+ if (mFlyWarpPosID != 0) {
+ mModeTimer = 60;
+ } else {
+ mModeTimer = 15;
+ }
+ break;
+ }
+
+ mModeTimer += (int)l_HIO.mPlayWarpTime;
+ }
+ break;
+ case 4:
+ case 5:
+ if (mModeTimer == 0) {
+ if (mMode == 4) {
+ dBgS_ObjGndChk gndchk;
+ gndchk.SetPos(&mFlyWarpPos);
+
+ f32 gnd_y = dComIfG_Bgsp().GroundCross(&gndchk);
+ if (gnd_y != -1000000000.0f) {
+ mFlyWarpPos.y = gnd_y;
+ }
+
+ shape_angle.y = field_0x6b8;
+ shape_angle.x = 0;
+ current.pos = mFlyWarpPos;
+ } else {
+ current.pos = mFlyWarpPos;
+ shape_angle.x = 0;
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ }
+
+ old.pos = current.pos;
+ mMode = 6;
+
+ if (field_0x711 & 2) {
+ field_0x711 = (field_0x711 & 1) ^ 1;
+ } else {
+ field_0x711 &= 1;
+ }
+
+ if (field_0x711 != 0) {
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+
+ dComIfGp_particle_set(0x88FE, &current.pos, &shape_angle, NULL);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_IN, 0, -1);
+ }
+ break;
+ case 6:
+ if (calcScale(1)) {
+ attention_info.flags = 4;
+ setCoHitBit(TRUE);
+ setBaseActionMode(0);
+ }
+ break;
+ }
}
/* 806412A8-806414E4 003288 023C+00 1/1 0/0 0/0 .text executeDamage__10daB_ZANT_cFv */
void daB_ZANT_c::executeDamage() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ case 1:
+ case 2:
+ attention_info.flags = 4;
+
+ if (setNextDamageMode(FALSE)) {
+ setTgHitBit(FALSE);
+ return;
+ } else if (mFightPhase == PHASE_OI && setNextDamageMode(TRUE)) {
+ setTgHitBit(FALSE);
+ return;
+ }
+
+ field_0x702 = 0;
+ speedF = 0.0f;
+ setTgHitBit(TRUE);
+
+ if (mMode == 0) {
+ if (cM_rnd() < 0.5f) {
+ mMode = 1;
+ } else {
+ mMode = 2;
+ }
+ }
+
+ if (mFightPhase == PHASE_OI) {
+ if (mMode == 1) {
+ setBck(ANM_FLOAT_DAMAGE_L, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_FLOAT_DAMAGE_R, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ } else if (mMode == 1) {
+ setBck(ANM_DAMAGE_L_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_DAMAGE_R_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ mMode = 5;
+ mModeTimer = 40;
+ case 5:
+ if (field_0x6f4 == 0) {
+ setTgHitBit(FALSE);
+ }
+
+ if (mpModelMorf->isStop() && !setNextDamageMode(TRUE)) {
+ setBaseActionMode(0);
+ }
+ break;
+ }
}
/* 806414E4-80641640 0034C4 015C+00 1/1 0/0 0/0 .text executeConfuse__10daB_ZANT_cFv */
void daB_ZANT_c::executeConfuse() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EBD4-8064EBD8 0000B8 0004+00 0/1 0/0 0/0 .rodata @5990 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5990 = 160.0f;
-COMPILER_STRIP_GATE(0x8064EBD4, &lit_5990);
-#pragma pop
-
-/* 8064EBD8-8064EBDC 0000BC 0004+00 0/1 0/0 0/0 .rodata @5991 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5991 = -700.0f;
-COMPILER_STRIP_GATE(0x8064EBD8, &lit_5991);
-#pragma pop
-
-/* 8064EBDC-8064EBE0 0000C0 0004+00 0/1 0/0 0/0 .rodata @5992 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5992 = 220.0f;
-COMPILER_STRIP_GATE(0x8064EBDC, &lit_5992);
-#pragma pop
-
-/* 8064EBE0-8064EBE4 0000C4 0004+00 0/2 0/0 0/0 .rodata @5993 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5993 = 175.0f;
-COMPILER_STRIP_GATE(0x8064EBE0, &lit_5993);
-#pragma pop
-
-/* 8064EBE4-8064EBE8 0000C8 0004+00 0/1 0/0 0/0 .rodata @5994 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5994 = 270.0f;
-COMPILER_STRIP_GATE(0x8064EBE4, &lit_5994);
-#pragma pop
-
-/* 8064EBE8-8064EBEC 0000CC 0004+00 0/1 0/0 0/0 .rodata @5995 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5995 = -194.0f;
-COMPILER_STRIP_GATE(0x8064EBE8, &lit_5995);
-#pragma pop
-
-/* 8064EBEC-8064EBF0 0000D0 0004+00 0/7 0/0 0/0 .rodata @5996 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5996 = 30.0f;
-COMPILER_STRIP_GATE(0x8064EBEC, &lit_5996);
-#pragma pop
-
-/* 8064EBF0-8064EBF4 0000D4 0004+00 0/1 0/0 0/0 .rodata @5997 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5997 = 81.0f;
-COMPILER_STRIP_GATE(0x8064EBF0, &lit_5997);
-#pragma pop
-
-/* 8064EBF4-8064EBF8 0000D8 0004+00 0/1 0/0 0/0 .rodata @5998 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5998 = -187.0f;
-COMPILER_STRIP_GATE(0x8064EBF4, &lit_5998);
-#pragma pop
-
-/* 8064EBF8-8064EBFC 0000DC 0004+00 0/1 0/0 0/0 .rodata @5999 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_5999 = 67.0f;
-COMPILER_STRIP_GATE(0x8064EBF8, &lit_5999);
-#pragma pop
-
-/* 8064EBFC-8064EC00 0000E0 0004+00 0/1 0/0 0/0 .rodata @6000 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6000 = -408.0f;
-COMPILER_STRIP_GATE(0x8064EBFC, &lit_6000);
-#pragma pop
-
-/* 8064EC00-8064EC04 0000E4 0004+00 0/1 0/0 0/0 .rodata @6001 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6001 = 43.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EC00, &lit_6001);
-#pragma pop
-
-/* 8064EC04-8064EC08 0000E8 0004+00 0/3 0/0 0/0 .rodata @6002 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6002 = 6.0f;
-COMPILER_STRIP_GATE(0x8064EC04, &lit_6002);
-#pragma pop
-
-/* 8064EC08-8064EC0C 0000EC 0004+00 0/4 0/0 0/0 .rodata @6003 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6003 = 5.0f;
-COMPILER_STRIP_GATE(0x8064EC08, &lit_6003);
-#pragma pop
-
-/* 8064EC0C-8064EC10 0000F0 0004+00 0/1 0/0 0/0 .rodata @6004 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6004 = 86.0f;
-COMPILER_STRIP_GATE(0x8064EC0C, &lit_6004);
-#pragma pop
-
-/* 8064EC10-8064EC14 0000F4 0004+00 0/1 0/0 0/0 .rodata @6005 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6005 = -9.0f;
-COMPILER_STRIP_GATE(0x8064EC10, &lit_6005);
-#pragma pop
-
-/* 8064EC14-8064EC18 0000F8 0004+00 0/1 0/0 0/0 .rodata @6006 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6006 = -209.0f;
-COMPILER_STRIP_GATE(0x8064EC14, &lit_6006);
-#pragma pop
-
-/* 8064EC18-8064EC1C 0000FC 0004+00 0/2 0/0 0/0 .rodata @6007 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6007 = 26.0f;
-COMPILER_STRIP_GATE(0x8064EC18, &lit_6007);
-#pragma pop
-
-/* 8064EC1C-8064EC20 000100 0004+00 0/1 0/0 0/0 .rodata @6008 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6008 = 225.0f;
-COMPILER_STRIP_GATE(0x8064EC1C, &lit_6008);
-#pragma pop
-
-/* 8064EC20-8064EC24 000104 0004+00 0/1 0/0 0/0 .rodata @6009 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6009 = -1700.0f;
-COMPILER_STRIP_GATE(0x8064EC20, &lit_6009);
-#pragma pop
-
-/* 8064EC24-8064EC28 000108 0004+00 0/1 0/0 0/0 .rodata @6010 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6010 = -500.0f;
-COMPILER_STRIP_GATE(0x8064EC24, &lit_6010);
-#pragma pop
-
-/* 8064EC28-8064EC2C 00010C 0004+00 0/2 0/0 0/0 .rodata @6011 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6011 = 70.0f;
-COMPILER_STRIP_GATE(0x8064EC28, &lit_6011);
-#pragma pop
-
-/* 8064EC2C-8064EC30 000110 0004+00 0/1 0/0 0/0 .rodata @6012 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6012 = -300.0f;
-COMPILER_STRIP_GATE(0x8064EC2C, &lit_6012);
-#pragma pop
-
-/* 8064EC30-8064EC34 000114 0004+00 0/1 0/0 0/0 .rodata @6013 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6013 = 68.0f;
-COMPILER_STRIP_GATE(0x8064EC30, &lit_6013);
-#pragma pop
-
-/* 8064EC34-8064EC38 000118 0004+00 0/2 0/0 0/0 .rodata @6014 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6014 = 32.0f;
-COMPILER_STRIP_GATE(0x8064EC34, &lit_6014);
-#pragma pop
-
-/* 8064EC38-8064EC3C 00011C 0004+00 0/1 0/0 0/0 .rodata @6015 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6015 = 290.0f;
-COMPILER_STRIP_GATE(0x8064EC38, &lit_6015);
-#pragma pop
-
-/* 8064EC3C-8064EC40 000120 0004+00 0/1 0/0 0/0 .rodata @6016 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6016 = -1678.0f;
-COMPILER_STRIP_GATE(0x8064EC3C, &lit_6016);
-#pragma pop
-
-/* 8064EC40-8064EC44 000124 0004+00 0/1 0/0 0/0 .rodata @6017 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6017 = 66.0f;
-COMPILER_STRIP_GATE(0x8064EC40, &lit_6017);
-#pragma pop
-
-/* 8064EC44-8064EC48 000128 0004+00 0/1 0/0 0/0 .rodata @6018 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6018 = 180.0f;
-COMPILER_STRIP_GATE(0x8064EC44, &lit_6018);
-#pragma pop
-
-/* 8064EC48-8064EC4C 00012C 0004+00 0/1 0/0 0/0 .rodata @6019 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6019 = -989.0f;
-COMPILER_STRIP_GATE(0x8064EC48, &lit_6019);
-#pragma pop
-
-/* 8064EC4C-8064EC50 000130 0004+00 0/1 0/0 0/0 .rodata @6020 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6020 = 60.0f;
-COMPILER_STRIP_GATE(0x8064EC4C, &lit_6020);
-#pragma pop
-
-/* 8064EC50-8064EC54 000134 0004+00 0/2 0/0 0/0 .rodata @6021 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6021 = -140.0f;
-COMPILER_STRIP_GATE(0x8064EC50, &lit_6021);
-#pragma pop
-
-/* 8064EC54-8064EC58 000138 0004+00 0/4 0/0 0/0 .rodata @6022 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6022 = 250.0f;
-COMPILER_STRIP_GATE(0x8064EC54, &lit_6022);
-#pragma pop
-
-/* 8064EC58-8064EC5C 00013C 0004+00 0/2 0/0 0/0 .rodata @6023 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6023 = -800.0f;
-COMPILER_STRIP_GATE(0x8064EC58, &lit_6023);
-#pragma pop
-
-/* 8064EC5C-8064EC60 000140 0004+00 0/2 0/0 0/0 .rodata @6024 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6024 = 58.0f;
-COMPILER_STRIP_GATE(0x8064EC5C, &lit_6024);
-#pragma pop
-
-/* 8064EC60-8064EC64 000144 0004+00 0/1 0/0 0/0 .rodata @6025 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6025 = -85.0f;
-COMPILER_STRIP_GATE(0x8064EC60, &lit_6025);
-#pragma pop
-
-/* 8064EC64-8064EC68 000148 0004+00 0/1 0/0 0/0 .rodata @6026 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6026 = 344.0f;
-COMPILER_STRIP_GATE(0x8064EC64, &lit_6026);
-#pragma pop
-
-/* 8064EC68-8064EC6C 00014C 0004+00 0/1 0/0 0/0 .rodata @6027 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6027 = 382.0f;
-COMPILER_STRIP_GATE(0x8064EC68, &lit_6027);
-#pragma pop
-
-/* 8064EC6C-8064EC70 000150 0004+00 0/1 0/0 0/0 .rodata @6028 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6028 = 258.0f;
-COMPILER_STRIP_GATE(0x8064EC6C, &lit_6028);
-#pragma pop
-
-/* 8064EC70-8064EC74 000154 0004+00 0/1 0/0 0/0 .rodata @6029 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6029 = 672.0f;
-COMPILER_STRIP_GATE(0x8064EC70, &lit_6029);
-#pragma pop
-
-/* 8064EC74-8064EC78 000158 0004+00 0/1 0/0 0/0 .rodata @6030 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6030 = 1374.0f;
-COMPILER_STRIP_GATE(0x8064EC74, &lit_6030);
-#pragma pop
-
-/* 8064EC78-8064EC7C 00015C 0004+00 0/2 0/0 0/0 .rodata @6031 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6031 = 550.0f;
-COMPILER_STRIP_GATE(0x8064EC78, &lit_6031);
-#pragma pop
-
-/* 8064EC7C-8064EC80 000160 0004+00 0/1 0/0 0/0 .rodata @6032 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6032 = 9.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EC7C, &lit_6032);
-#pragma pop
-
-/* 8064EC80-8064EC84 000164 0004+00 0/1 0/0 0/0 .rodata @6033 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6033 = 922.0f;
-COMPILER_STRIP_GATE(0x8064EC80, &lit_6033);
-#pragma pop
-
-/* 8064EC84-8064EC88 000168 0004+00 0/3 0/0 0/0 .rodata @6034 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6034 = 3.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EC84, &lit_6034);
-#pragma pop
-
-/* 8064EC88-8064EC8C 00016C 0004+00 0/1 0/0 0/0 .rodata @6035 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u32 const lit_6035 = 0x3BC49BA6;
-COMPILER_STRIP_GATE(0x8064EC88, &lit_6035);
-#pragma pop
-
-/* 8064EC8C-8064EC90 000170 0004+00 0/1 0/0 0/0 .rodata @6036 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6036 = 110.0f;
-COMPILER_STRIP_GATE(0x8064EC8C, &lit_6036);
-#pragma pop
-
-/* 8064EC90-8064EC94 000174 0004+00 0/1 0/0 0/0 .rodata @6037 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6037 = 1.0f / 100.0f;
-COMPILER_STRIP_GATE(0x8064EC90, &lit_6037);
-#pragma pop
-
-/* 8064EC94-8064EC98 000178 0004+00 0/2 0/0 0/0 .rodata @6038 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6038 = 140.0f;
-COMPILER_STRIP_GATE(0x8064EC94, &lit_6038);
-#pragma pop
-
-/* 8064EC98-8064EC9C 00017C 0004+00 0/1 0/0 0/0 .rodata @6039 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6039 = 1.0f / 50.0f;
-COMPILER_STRIP_GATE(0x8064EC98, &lit_6039);
-#pragma pop
-
-/* 8064EC9C-8064ECA4 000180 0008+00 0/4 0/0 0/0 .rodata @6041 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const lit_6041[8] = {
- 0x43, 0x30, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064EC9C, &lit_6041);
-#pragma pop
-
-/* 8064EE60-8064EE60 000344 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */
-#pragma push
-#pragma force_active on
-SECTION_DEAD static char const* const stringBase_8064EE66 = "force_start";
-SECTION_DEAD static char const* const stringBase_8064EE72 = "force_end";
-#pragma pop
+ switch (mMode) {
+ case 0:
+ attention_info.flags = 4;
+ speedF = 0.0f;
+ speed.y = 0.0f;
+ mMode = 1;
+
+ setBck(ANM_GROUND_REACTION, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_NO_DMG, -1);
+ field_0x702 = 0;
+ case 1:
+ if (mpModelMorf->isStop()) {
+ setBaseActionMode(0);
+ }
+ break;
+ case 5:
+ setBck(ANM_FAINT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ speedF = 0.0f;
+ speed.y = 0.0f;
+ field_0x702 = 0;
+ mModeTimer = 20;
+ mMode = 6;
+ case 6:
+ if (mModeTimer == 0) {
+ setBaseActionMode(0);
+ }
+ break;
+ }
+}
/* 80641640-806427EC 003620 11AC+00 2/2 0/0 0/0 .text executeOpening__10daB_ZANT_cFv */
void daB_ZANT_c::executeOpening() {
- // NONMATCHING
+ camera_class* camera = dComIfGp_getCamera(dComIfGp_getPlayerCameraID(0));
+ daPy_py_c* player = daPy_getPlayerActorClass();
+
+ cXyz sp34(0.0f, 0.0f, 0.0f);
+ cXyz sp40;
+ cXyz sp4C;
+
+ switch (mMode) {
+ case MODE_START_DEMO:
+ current.pos.set(0.0f, 0.0f, 160.0f);
+ shape_angle.y = -0x8000;
+
+ if (!eventInfo.i_checkCommandDemoAccrpt()) {
+ fopAcM_orderPotentialEvent(this, 2, 0xFFFF, 4);
+ eventInfo.i_onCondition(2);
+ return;
+ }
+
+ Z2GetAudioMgr()->setDemoName("force_start");
+ fopAcM_OffStatus(this, 0x4000);
+
+ sp34.set(0.0f, 0.0f, -700.0f);
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+
+ setBck(ANM_OP_1, J3DFrameCtrl::LOOP_REPEAT_e, 0.0f, 1.0f);
+ mMode = MODE_START_DEMO_WAIT;
+ mModeTimer = 30;
+
+ camera->mCamera.Stop();
+ camera->mCamera.SetTrimSize(3);
+ field_0x77c = 220.0f;
+ case MODE_START_DEMO_WAIT:
+ sp4C.set(0.0f, 175.0f, 3.0f);
+ sp40.set(0.0f, 270.0f, -194.0f);
+ mDemoCamCenter = sp4C;
+ mDemoCamEye = sp40;
+ mDemoCamBank = 30.0f;
+
+ if (mModeTimer == 0) {
+ mMode = MODE_PAN_GROUND;
+ mModeTimer = 80;
+ }
+ break;
+ case MODE_PAN_GROUND:
+ sp4C.set(0.0f, 81.0f, -187.0f);
+ sp40.set(0.0f, 67.0f, -408.0f);
+ cLib_addCalcPos2(&mDemoCamCenter, sp4C, 0.1f, 4.3f);
+ cLib_addCalcPos2(&mDemoCamEye, sp40, 0.1f, 6.0f);
+
+ if (mModeTimer == 0) {
+ mMode = MODE_MSG_1;
+ setBck(ANM_OP_2, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_OP_V_WAKEUP, -1);
+ }
+ break;
+ case MODE_MSG_1:
+ if (mpModelMorf->getFrame() > 5.0f) {
+ sp4C.set(0.0f, 86.0f, -9.0f);
+ sp40.set(0.0f, 10.0f, -209.0f);
+ cLib_addCalcPos2(&mDemoCamCenter, sp4C, 0.5f, 26.0f);
+ cLib_addCalcPos2(&mDemoCamEye, sp40, 0.5f, 30.0f);
+ }
+
+ if (mpModelMorf->isStop()) {
+ mMode = MODE_MSG_1_WAIT;
+ mModeTimer = 20;
+ setBck(ANM_OP_3, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ setZantMessage(0xE3B); // My god had only one wish...
+ }
+ break;
+ case MODE_MSG_1_WAIT:
+ if (doZantMessage() == true) {
+ mModeTimer = 20;
+ mMode = MODE_WARP_OUT_SE;
+ }
+ break;
+ case MODE_WARP_OUT_SE:
+ if (mModeTimer == 0) {
+ mMode = MODE_START_WARP;
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_OUT, 0, -1);
+ }
+ break;
+ case MODE_START_WARP:
+ if (calcScale(0)) {
+ current.pos.set(0.0f, 225.0f, -1700.0f);
+ sp34.set(0.0f, 0.0f, -500.0f);
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+ player->changeOriginalDemo();
+ player->changeDemoMode(1, 0, 0, 0);
+
+ mMode = MODE_WARP_WAIT;
+ mDemoCamCenter.set(0.0f, 200.0f, -1700.0f);
+ mDemoCamEye.set(0.0f, 70.0f, -300.0f);
+ mDemoCamBank = 68.0f;
+ mModeTimer = 15;
+ }
+ break;
+ case MODE_WARP_WAIT:
+ if (mModeTimer == 0) {
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ player->changeDemoMode(0x48, 0, 0, 0);
+ mMode = MODE_PAN_THRONE;
+ mModeTimer = 105;
+ }
+ break;
+ case MODE_PAN_THRONE:
+ sp4C.set(32.0f, 290.0f, -1678.0f);
+ sp40.set(100.0f, 70.0f, -300.0f);
+ cLib_addCalcPos2(&mDemoCamCenter, sp4C, 0.1f, 1.0f);
+ cLib_addCalcPos2(&mDemoCamEye, sp40, 0.1f, 1.0f);
+
+ if (mModeTimer <= 30) {
+ if (mModeTimer == 30) {
+ current.angle.y = 0;
+ shape_angle.y = 0;
+ dComIfGp_particle_set(0x88FE, &current.pos, &shape_angle, NULL);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_IN, 0, -1);
+ }
+ calcScale(1);
+ }
+
+ if (mModeTimer == 0) {
+ mMode = MODE_ZOOM_THRONE;
+ mModeTimer = 30;
+ }
+ break;
+ case MODE_ZOOM_THRONE:
+ calcScale(1);
+ sp4C.set(32.0f, 290.0f, -1678.0f);
+ sp40.set(66.0f, 180.0f, -989.0f);
+ cLib_addCalcPos2(&mDemoCamCenter, sp4C, 0.5f, 60.0f);
+ cLib_addCalcPos2(&mDemoCamEye, sp40, 0.5f, 60.0f);
+
+ if (mModeTimer == 0) {
+ mMode = MODE_MSG_2;
+ setZantMessage(0xE3C);
+ }
+ break;
+ case MODE_MSG_2:
+ if (doZantMessage() == true) {
+ setBck(ANM_OP_RISE, J3DFrameCtrl::LOOP_REPEAT_e, 10.0f, 1.0f);
+ mMode = MODE_FLY_UP;
+ mModeTimer = 90;
+ mSound.startCreatureSound(Z2SE_EN_ZAN_OP_FLY, 0, -1);
+ }
+ break;
+ case MODE_FLY_UP:
+ current.pos.y += 3.0f;
+ mDemoCamCenter.y += 2.0f;
+
+ if (mModeTimer == 0) {
+ mMode = MODE_CLOSE_UP;
+ }
+ break;
+ case MODE_CLOSE_UP:
+ if (mModeTimer == 0) {
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(0.0f, 300.0f, 700.0f);
+ mDoMtx_stack_c::multVecZero(&current.pos);
+ current.pos.y += 100.0f;
+ current.pos.z -= 800.0f;
+ old.pos = current.pos;
+ speedF = 0.0f;
+ speed.y = 0.0f;
+ gravity = 0.0f;
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ setBck(ANM_OP_RISE, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ sp34.x = -140.0f;
+ sp34.y += 250.0f;
+ sp34.z = -800.0f;
+ player->setPlayerPosAndAngle(&sp34, 0x8000, 0);
+ player->changeOriginalDemo();
+ player->changeDemoPos0(&sp34);
+ player->changeDemoMode(0x17, 1, 4, 0);
+ mDemoCamBank = 58.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(-85.0f, 344.0f, 382.0f);
+ mDoMtx_stack_c::multVecZero(&mDemoCamEye);
+ mDemoCamEye.y += 250.0f;
+ mDemoCamEye.z -= 800.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(258.0f, 672.0f, 1374.0f);
+ mDoMtx_stack_c::multVecZero(&mDemoCamCenter);
+ mDemoCamCenter.y += 200.0f;
+ mDemoCamCenter.z -= 800.0f;
+
+ Z2GetAudioMgr()->bgmStart(Z2BGM_BOSS_ZANT, 0, 0);
+ field_0x77c = 0.0f;
+ field_0x6fc = 1;
+ mMode = MODE_SET_BOSS_TITLE;
+ mModeTimer = 160;
+ }
+ break;
+ case MODE_SET_BOSS_TITLE:
+ if (mModeTimer == 100) {
+ fopMsgM_messageSetDemo(0x486);
+ }
+
+ cLib_addCalc(&current.pos.y, 250.0f + 300.0f, 0.1f, 3.0f, 0.9f);
+ cLib_addCalc(&mDemoCamCenter.y, 250.0f + 672.0f, 0.1f, 1.0f, 0.3f);
+
+ if (mModeTimer == 0) {
+ mMode = MODE_WARP_IN_WAIT;
+ mModeTimer = 20;
+ }
+ break;
+ case MODE_WARP_IN_SE:
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (mModeTimer == 0) {
+ dComIfGp_particle_set(0x88FE, &current.pos, &shape_angle, NULL);
+ mMode = MODE_WARP_IN_SCALE;
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_IN, 0, -1);
+ }
+ break;
+ case MODE_WARP_IN_SCALE:
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (calcScale(1)) {
+ mMode = MODE_WARP_IN_WAIT;
+ mModeTimer = 20;
+ }
+ break;
+ case MODE_WARP_IN_WAIT:
+ if (mModeTimer == 0) {
+ mMode = MODE_ZOOM_OUT_ROOM_CHANGE;
+ mModeTimer = 50;
+ }
+ break;
+ case MODE_ZOOM_OUT_ROOM_CHANGE:
+ calcRoomChangeCamera(0);
+ if (mModeTimer == 0) {
+ mMode = MODE_START_ROOM_CHANGE;
+ setBck(ANM_FLOAT_APPEAR, J3DFrameCtrl::LOOP_ONCE_e, 5.0f, 1.0f);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_MAHOJIN_BB, 0, -1);
+ field_0x714 = 1;
+ mKankyoBlend = 0.0f;
+ }
+ break;
+ case MODE_START_ROOM_CHANGE:
+ cLib_chaseF(&mKankyoBlend, 1.0f, 0.006f);
+ if (mpModelMorf->checkFrame(110)) {
+ mMahojinAnmMode = 1;
+ field_0x715 = 30;
+ }
+
+ if (mpModelMorf->getFrame() > 110.0f) {
+ cLib_chaseF(&mKankyoBlend, 1.0f, 0.01f);
+ }
+
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (mpModelMorf->isStop()) {
+ dComIfGp_getVibration().StopQuake(31);
+ setBck(ANM_FLOAT_APPEAR_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = MODE_ROOM_CHANGE;
+ mModeTimer = l_HIO.mMahojinWaitTime;
+
+ cXyz pos(0.0f, 0.0f, 0.0f);
+ dComIfGs_setRestartRoom(pos, 0, warp_next_room[1]);
+ return;
+ }
+ break;
+ case MODE_ROOM_CHANGE:
+ mFightPhase++;
+ if (mFightPhase >= PHASE_MAX) {
+ mFightPhase = PHASE_OP;
+ }
+
+ current.pos.set(-140.0f, 300.0f, 700.0f);
+
+ sp34.set(0.0f, 0.0f, 0.0f);
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+ player->changeDemoMode(0x17, 1, 4, 0);
+
+ mDemoCamEye.x += 140.0f;
+ mDemoCamEye.y -= 250.0f;
+ mDemoCamEye.z += 800.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(mDemoCamEye);
+ mDoMtx_stack_c::multVecZero(&mDemoCamEye);
+
+ mDemoCamCenter.x += 140.0f;
+ mDemoCamCenter.y -= 250.0f;
+ mDemoCamCenter.z += 800.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(mDemoCamCenter);
+ mDoMtx_stack_c::multVecZero(&mDemoCamCenter);
+
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ initNextRoom();
+ mMode = MODE_END_ROOM_CHANGE;
+ case MODE_END_ROOM_CHANGE:
+ if (mModeTimer == 0 && dComIfGp_roomControl_checkStatusFlag(warp_next_room[mFightPhase], 0x10)) {
+ mMode = MODE_END_DEMO;
+ field_0x714 = 0;
+ mKankyoBlend = 0.0f;
+ setBck(ANM_FLOAT_WAIT_RETURN, J3DFrameCtrl::LOOP_ONCE_e, 5.0f, 1.0f);
+ mMahojinAnmMode = 4;
+ }
+ break;
+ case MODE_END_DEMO:
+ cLib_chaseF(&mKankyoBlend, 1.0f, 0.02f);
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+
+ if (mpModelMorf->isStop()) {
+ camera->mCamera.Reset(mDemoCamCenter, mDemoCamEye);
+ camera->mCamera.Start();
+ camera->mCamera.SetTrimSize(0);
+ dComIfGp_event_reset();
+
+ field_0x6fc = 0;
+ setTgHitBit(TRUE);
+ setBaseActionMode(1);
+ Z2GetAudioMgr()->setDemoName("force_end");
+ return;
+ }
+ break;
+ }
+
+ if (field_0x715 != 0) {
+ calcRoomChangeCamera(1);
+ field_0x715--;
+ }
+
+ camera->mCamera.Set(mDemoCamCenter, mDemoCamEye, mDemoCamBank, 0);
}
/* 806427EC-80642EC8 0047CC 06DC+00 2/1 0/0 0/0 .text executeFly__10daB_ZANT_cFv */
void daB_ZANT_c::executeFly() {
- // NONMATCHING
+ dBgS_ObjGndChk_All gndchk;
+ cXyz sp9C;
+
+ switch (mMode) {
+ case 0:
+ setTgHitBit(TRUE);
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mModeTimer = 0;
+ mMode = 1;
+ gravity = 0.0f;
+ field_0x70c = 0;
+ setTgType(0x10040);
+ case 1:
+ if (mModeTimer == 0) {
+ if (mFightCycle == 0) {
+ field_0x703 = l_HIO.mBulletNum;
+ } else {
+ field_0x703 = 8;
+ }
+
+ mFlyWarpPosID = (f32)mFlyWarpPosID + cM_rndF(1.9f) + 1.0f;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID % 3];
+ field_0x711 = 1;
+ setActionMode(ACT_SMALL_ATTACK, 0);
+ return;
+ }
+ break;
+ case 10:
+ setBck(ANM_SWAMP_FALL_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_BB_V_FALL, -1);
+ mMode = 11;
+
+ speedF = 0.0f;
+ speed.y = 45.0f;
+ current.angle.y = shape_angle.y;
+ gravity = -5.0f;
+ field_0x6f8 = 0x1000;
+ setTgHitBit(FALSE);
+ case 11:
+ case 12:
+ if (mMode == 11) {
+ if (mpModelMorf->isStop()) {
+ setBck(ANM_SWAMP_FALL_LOOP, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 12;
+ }
+ } else if (speed.y < -10.0f) {
+ setBck(ANM_SWAMP_FALL_B, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 13;
+ }
+ case 13:
+ if (speed.y < 5.0f) {
+ gravity = -2.0f;
+ } else {
+ gravity = -5.0f;
+ }
+
+ if (field_0x6f8 != 0) {
+ shape_angle.y += field_0x6f8;
+ cLib_chaseAngleS(&field_0x6f8, 0, 0x40);
+ } else {
+ cLib_addCalcAngleS2(&shape_angle.y, current.angle.y, 4, 0x1000);
+ }
+
+ sp9C = current.pos;
+ sp9C.y += 100.0f;
+ gndchk.SetPos(&sp9C);
+ {
+ f32 gnd_pos = dComIfG_Bgsp().GroundCross(&gndchk);
+ if (gnd_pos != -1000000000.0f && current.pos.y <= gnd_pos) {
+ if (dComIfG_Bgsp().GetPolyAtt0(gndchk) == 11) {
+ speed.y = 50.0f;
+ speedF = 15.0f;
+ current.angle.y = (cM_rndFX(2.9f) * (f32)0x1000) - (f32)0x8000;
+
+ mMode = 11;
+ setBck(ANM_SWAMP_FALL_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_BB_V_JUMP, -1);
+
+ cXyz pos(current.pos.x, gnd_pos, current.pos.z);
+ cXyz size(1.5f, 1.5f, 1.5f);
+ for (int i = 0; i < 4; i++) {
+ static u16 w_eff_id[] = {0x01B8, 0x01B9, 0x01BA, 0x01BB};
+ field_0x389c[i] = dComIfGp_particle_setPolyColor(field_0x389c[i], w_eff_id[i], gndchk, &pos, &tevStr, &shape_angle, &size, 0, NULL, -1, NULL);
+ }
+
+ mSound.startCreatureSound(Z2SE_EN_ZAN_BB_WTR, 0, -1);
+ } else {
+ fopAcM_effSmokeSet1(&field_0x3894, &field_0x3898, &current.pos, NULL, 2.0f, &tevStr, 1);
+ speedF = 0.0f;
+ setBck(ANM_SWAMP_LANDING, J3DFrameCtrl::LOOP_ONCE_e, 0.0f, 1.0f);
+ mMode = 14;
+ setTgHitBit(TRUE);
+ setTgType(0xD8FBFDFF);
+ field_0x702 = 0;
+ field_0x6f0 = 150;
+ field_0x70c = 1;
+ }
+ }
+ }
+ break;
+ case 14:
+ if (mpModelMorf->checkFrame(3)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_BB_LAND, 0, -1);
+ } else if (mpModelMorf->checkFrame(18) || mpModelMorf->checkFrame(23)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_BB_FOOT, 0, -1);
+ }
+
+ if (mpModelMorf->checkFrame(5)) {
+ speedF = 3.0f;
+ }
+
+ if (mpModelMorf->isStop()) {
+ setActionMode(ACT_FLY_GROUND, 0);
+ field_0x702 = 0;
+ }
+ break;
+ }
}
/* 80642EC8-806430E0 004EA8 0218+00 1/1 0/0 0/0 .text executeFlyGround__10daB_ZANT_cFv */
void daB_ZANT_c::executeFlyGround() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064ECA4-8064ECA8 000188 0004+00 0/1 0/0 0/0 .rodata @6162 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6162 = 45.0f;
-COMPILER_STRIP_GATE(0x8064ECA4, &lit_6162);
-#pragma pop
-
-/* 8064ECA8-8064ECAC 00018C 0004+00 0/4 0/0 0/0 .rodata @6163 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6163 = -5.0f;
-COMPILER_STRIP_GATE(0x8064ECA8, &lit_6163);
-#pragma pop
-
-/* 8064ECAC-8064ECB0 000190 0004+00 0/0 0/0 0/0 .rodata @6164 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6164 = -10.0f;
-COMPILER_STRIP_GATE(0x8064ECAC, &lit_6164);
-#pragma pop
-
-/* 8064ECB0-8064ECB4 000194 0004+00 0/0 0/0 0/0 .rodata @6165 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6165 = -2.0f;
-COMPILER_STRIP_GATE(0x8064ECB0, &lit_6165);
-#pragma pop
-
-/* 8064ECB4-8064ECB8 000198 0004+00 0/6 0/0 0/0 .rodata @6166 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6166 = 50.0f;
-COMPILER_STRIP_GATE(0x8064ECB4, &lit_6166);
-#pragma pop
-
-/* 8064ECB8-8064ECBC 00019C 0004+00 0/0 0/0 0/0 .rodata @6167 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6167 = 4096.0f;
-COMPILER_STRIP_GATE(0x8064ECB8, &lit_6167);
-#pragma pop
-
-/* 8064ECBC-8064ECC0 0001A0 0004+00 0/2 0/0 0/0 .rodata @6168 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6168 = 29.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064ECBC, &lit_6168);
-#pragma pop
-
-/* 8064ECC0-8064ECC4 0001A4 0004+00 0/0 0/0 0/0 .rodata @6169 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6169 = 32768.0f;
-COMPILER_STRIP_GATE(0x8064ECC0, &lit_6169);
-#pragma pop
-
-/* 8064ECC4-8064ECC8 0001A8 0004+00 0/0 0/0 0/0 .rodata @6170 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6170 = 1.5f;
-COMPILER_STRIP_GATE(0x8064ECC4, &lit_6170);
-#pragma pop
-
-/* 8064ECC8-8064ECCC 0001AC 0004+00 0/2 0/0 0/0 .rodata @6171 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6171 = 18.0f;
-COMPILER_STRIP_GATE(0x8064ECC8, &lit_6171);
-#pragma pop
-
-/* 8064ECCC-8064ECD0 0001B0 0004+00 0/2 0/0 0/0 .rodata @6172 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6172 = 23.0f;
-COMPILER_STRIP_GATE(0x8064ECCC, &lit_6172);
-#pragma pop
-
-/* 8064ECD0-8064ECD4 0001B4 0004+00 0/1 0/0 0/0 .rodata @6282 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6282 = 900.0f;
-COMPILER_STRIP_GATE(0x8064ECD0, &lit_6282);
-#pragma pop
-
-/* 8064ECD4-8064ECD8 0001B8 0004+00 0/4 0/0 0/0 .rodata @6283 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6283 = 400.0f;
-COMPILER_STRIP_GATE(0x8064ECD4, &lit_6283);
-#pragma pop
+ switch (mMode) {
+ case 0:
+ if (mLastAction == ACT_DAMAGE || mLastAction == ACT_CONFUSE) {
+ field_0x70c = 0;
+ gravity = 0.0f;
+ mFlyWarpPosID = (f32)mFlyWarpPosID + cM_rndF(1.9f) + 1.0f;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID % 3];
+ field_0x711 = 2;
+ setActionMode(ACT_WARP, 1);
+ break;
+ }
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ setBck(ANM_LV1_FATIGUE, J3DFrameCtrl::LOOP_REPEAT_e, 5.0f, 1.0f);
+ mMode = 1;
+ field_0x702 = 0;
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_BB_V_ZEIZEI, -1);
+ case 1:
+ if (field_0x6f0 == 0) {
+ field_0x70c = 0;
+ gravity = 0.0f;
+ mFlyWarpPosID = (f32)mFlyWarpPosID + cM_rndF(1.9f) + 1.0f;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID % 3];
+ field_0x711 = 2;
+ setActionMode(ACT_WARP, 1);
+ }
+ break;
+ }
+}
/* 806430E0-806432F8 0050C0 0218+00 1/1 0/0 0/0 .text checkSwimLinkNearMouth__10daB_ZANT_cFv */
-void daB_ZANT_c::checkSwimLinkNearMouth() {
- // NONMATCHING
+bool daB_ZANT_c::checkSwimLinkNearMouth() {
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+ if (pmobile == NULL) {
+ return false;
+ }
+
+ s16 mobile_angle = pmobile->shape_angle.y;
+ cXyz check_area(cM_ssin(mobile_angle) * 900.0f, 0.0f, cM_scos(mobile_angle) * 900.0f);
+ check_area += pmobile->current.pos;
+
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ if (check_area.absXZ(player_pos) < 400.0f && check_area.y - 300.0f < player_pos.y && check_area.y + 800.0f > player_pos.y) {
+ return true;
+ }
+
+ return false;
}
/* 806432F8-8064350C 0052D8 0214+00 1/1 0/0 0/0 .text checkSwimLinkNear__10daB_ZANT_cFv
*/
-void daB_ZANT_c::checkSwimLinkNear() {
- // NONMATCHING
+bool daB_ZANT_c::checkSwimLinkNear() {
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+ if (pmobile == NULL) {
+ return false;
+ }
+
+ if (checkSwimLinkNearMouth()) {
+ if (field_0x706 != 0 && ((daB_ZANTZ_c*)pmobile)->getMouthMode() == 1) {
+ s16 mobile_angle = pmobile->shape_angle.y;
+ cXyz check_area(cM_ssin(mobile_angle) * 300.0f, 0.0f, cM_scos(mobile_angle) * 300.0f);
+ check_area += pmobile->current.pos;
+
+ if (check_area.abs(current.pos) < 300.0f) {
+ setTgHitBit(FALSE);
+ ((daB_ZANTZ_c*)pmobile)->setMouthMode(2);
+ setActionMode(ACT_WATER, 27);
+ }
+ }
+
+ ((daB_ZANTZ_c*)pmobile)->setSnortEffect(30);
+ return true;
+ }
+
+ return false;
}
/* 8064350C-80643690 0054EC 0184+00 1/1 0/0 0/0 .text executeHook__10daB_ZANT_cFv */
void daB_ZANT_c::executeHook() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ setTgHitBit(FALSE);
+ setCoHitBit(FALSE);
+ gravity = 0.0f;
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ field_0x705 = 0;
+ field_0x706 = 0;
+
+ setBck(ANM_HOOK_HIT, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 2;
+ field_0x6ff++;
+ break;
+ case 2:
+ if (mpModelMorf->checkFrame(2)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_OI_V_CAUGHT, -1);
+ }
+
+ if (mpModelMorf->isStop()) {
+ mMode = 3;
+ setBck(ANM_HOOK_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ case 3:
+ if (!fopAcM_checkStatus(this, 0x100000)) {
+ setTgHitBit(TRUE);
+ setCoHitBit(TRUE);
+ setActionMode(ACT_SWIM, 10);
+ }
+ break;
+ }
}
/* 80643690-80644074 005670 09E4+00 2/1 0/0 0/0 .text executeWater__10daB_ZANT_cFv */
void daB_ZANT_c::executeWater() {
- // NONMATCHING
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+ if (pmobile != NULL) {
+ s16 mobile_angle = pmobile->shape_angle.y;
+ cXyz sp58(cM_ssin(mobile_angle) * 300.0f, 0.0f, cM_scos(mobile_angle) * 300.0f);
+ sp58 += pmobile->current.pos;
+
+ switch (mMode) {
+ case 0:
+ if (mLastAction == ACT_SMALL_ATTACK) {
+ mMode = 0x19;
+ field_0x6f0 = 0x78;
+ field_0x705 = 1;
+ attention_info.flags = 4;
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ } else if (field_0x705 != 0) {
+ if (((daB_ZANTZ_c*)pmobile)->getAppearMode() == 3) {
+ mMode = 15;
+ } else {
+ ((daB_ZANTZ_c*)pmobile)->setMouthMode(2);
+ mMode = 27;
+ }
+
+ attention_info.flags = 0;
+ } else {
+ setActionMode(ACT_SWIM, 0);
+ }
+ break;
+ case 15:
+ {
+ daPy_py_c* player = daPy_getPlayerActorClass();
+ if (player->current.pos.y < 1000.0f) {
+ mMode = 20;
+
+ if (mFightCycle == 0) {
+ ((daB_ZANTZ_c*)pmobile)->setAppearMode(0);
+ } else {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL) {
+ ((daB_ZANTZ_c*)pmobile)->setAppearMode(0);
+ }
+ }
+ }
+
+ field_0x704 = 0;
+ }
+ }
+ break;
+ case 20:
+ old.pos = sp58;
+ current.pos = old.pos;
+ shape_angle.y = mobile_angle;
+
+ if (((daB_ZANTZ_c*)pmobile)->getAppearMode() == 1) {
+ mModeTimer = 30;
+ mMode = 21;
+
+ if (mFightCycle != 0) {
+ // set zant to farthest mobile from player
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ f32 farthest_dist = 0.0f;
+ int correct_no = 0;
+
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL && farthest_dist < pmobile->current.pos.abs(player_pos)) {
+ farthest_dist = pmobile->current.pos.abs(player_pos);
+ correct_no = i;
+ }
+ }
+
+ mCorrectMobileNo = correct_no;
+ }
+ }
+ break;
+ case 21:
+ if (mModeTimer == 0) {
+ field_0x6fd = 1;
+
+ if (mFightCycle == 0) {
+ ((daB_ZANTZ_c*)pmobile)->setAppearMode(4);
+ } else {
+ int sp78 = 0;
+
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL && abs((s16)(fopAcM_searchPlayerAngleY(pmobile) - pmobile->shape_angle.y)) > 0x1000) {
+ sp78++;
+ }
+ }
+
+ if (sp78 != 0) {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL) {
+ ((daB_ZANTZ_c*)pmobile)->setAppearMode(5);
+ }
+ }
+
+ field_0x6fd = 0;
+ }
+ }
+
+ mMode = 22;
+ }
+ break;
+ case 22:
+ if (mFightCycle == 0) {
+ if (((daB_ZANTZ_c*)pmobile)->getAppearMode() == 1) {
+ ((daB_ZANTZ_c*)pmobile)->setSnortEffect(30);
+ mModeTimer = 30;
+ mMode = 23;
+ }
+ } else {
+ int sp84 = 0;
+
+ if (field_0x6fd == 0) {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL && ((daB_ZANTZ_c*)pmobile)->isSearchContinue()) {
+ if (abs((s16)(fopAcM_searchPlayerAngleY(pmobile) - pmobile->shape_angle.y)) < 0xC00) {
+ sp84++;
+ }
+ }
+ }
+
+ if (sp84 == 4) {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL) {
+ ((daB_ZANTZ_c*)pmobile)->offSearchContinue();
+ }
+ }
+ field_0x6fd++;
+ }
+ } else {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL && ((daB_ZANTZ_c*)pmobile)->getAppearMode() == 1) {
+ sp84++;
+ }
+ }
+
+ if (sp84 == 4) {
+ for (int i = 0; i < 4; i++) {
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+ if (pmobile != NULL) {
+ ((daB_ZANTZ_c*)pmobile)->setSnortEffect(30);
+ }
+ }
+ mModeTimer = 30;
+ mMode = 23;
+ }
+ }
+ }
+ break;
+ case 23:
+ if (mModeTimer == 0) {
+ old.pos = sp58;
+ current.pos = old.pos;
+ ((daB_ZANTZ_c*)pmobile)->setMouthMode(0);
+ mMode = 24;
+ setTgHitBit(TRUE);
+ field_0x706 = 1;
+ }
+ break;
+ case 24:
+ cLib_addCalcAngleS(&shape_angle.y, fopAcM_searchPlayerAngleY(this), 8, 0x400, 0x80);
+ if (((daB_ZANTZ_c*)pmobile)->getMouthMode() == 1) {
+ attention_info.flags = 4;
+ field_0x703 = 8;
+ field_0x6ff = 0;
+ field_0x711 = 1;
+ setActionMode(ACT_SMALL_ATTACK, 0);
+ }
+ break;
+ case 25:
+ if (field_0x6f0 == 0) {
+ field_0x706 = 0;
+ setTgHitBit(FALSE);
+ ((daB_ZANTZ_c*)pmobile)->setMouthMode(2);
+ mMode = 27;
+ }
+ break;
+ case 27:
+ if (((daB_ZANTZ_c*)pmobile)->getMouthMode() == 3) {
+ current.pos = sp58;
+ field_0x705 = 1;
+ attention_info.flags = 0;
+
+ if (mFightCycle == 0) {
+ mMode = 30;
+ mModeTimer = cM_rndF(30.0f) + 100.0f;
+ } else if (field_0x712 == 0) {
+ field_0x712++;
+ mMode = 28;
+ mModeTimer = 30;
+ } else {
+ mMode = 30;
+ mModeTimer = cM_rndF(30.0f) + 100.0f;
+ mCorrectMobileNo = (int)((f32)mCorrectMobileNo + cM_rndF(2.9f) + 1.0f) & 3;
+ }
+ }
+ break;
+ case 28:
+ if (mModeTimer == 0) {
+ ((daB_ZANTZ_c*)pmobile)->setAppearMode(2);
+ mMode = 29;
+ }
+ break;
+ case 29:
+ current.pos = sp58;
+ shape_angle.y = mobile_angle;
+
+ if (((daB_ZANTZ_c*)pmobile)->getAppearMode() == 3) {
+ mMode = 15;
+ }
+ break;
+ case 30:
+ if (mModeTimer == 0) {
+ mModeTimer = 30;
+ mMode = 21;
+ }
+ break;
+ }
+ }
}
/* 80644074-80644A3C 006054 09C8+00 2/1 0/0 0/0 .text executeSwim__10daB_ZANT_cFv */
void daB_ZANT_c::executeSwim() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064ECD8-8064ECDC 0001BC 0004+00 0/3 0/0 0/0 .rodata @6630 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6630 = 1000.0f;
-COMPILER_STRIP_GATE(0x8064ECD8, &lit_6630);
-#pragma pop
-
-/* 8064ECDC-8064ECE0 0001C0 0004+00 0/1 0/0 0/0 .rodata @6864 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6864 = 600.0f;
-COMPILER_STRIP_GATE(0x8064ECDC, &lit_6864);
-#pragma pop
-
-/* 8064ECE0-8064ECE4 0001C4 0004+00 0/1 0/0 0/0 .rodata @6865 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6865 = 1200.0f;
-COMPILER_STRIP_GATE(0x8064ECE0, &lit_6865);
-#pragma pop
-
-/* 8064ECE4-8064ECE8 0001C8 0004+00 0/0 0/0 0/0 .rodata @6866 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6866 = 29.0f;
-COMPILER_STRIP_GATE(0x8064ECE4, &lit_6866);
-#pragma pop
-
-/* 8064ECE8-8064ECEC 0001CC 0004+00 0/0 0/0 0/0 .rodata @6867 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6867 = 12.0f;
-COMPILER_STRIP_GATE(0x8064ECE8, &lit_6867);
-#pragma pop
-
-/* 8064ECEC-8064ECF0 0001D0 0004+00 0/1 0/0 0/0 .rodata @6868 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_6868 = 28.0f;
-COMPILER_STRIP_GATE(0x8064ECEC, &lit_6868);
-#pragma pop
-
-/* 8064ECF0-8064ECF4 0001D4 0004+00 0/1 0/0 0/0 .rodata @7002 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7002 = 55.0f;
-COMPILER_STRIP_GATE(0x8064ECF0, &lit_7002);
-#pragma pop
-
-/* 8064ECF4-8064ECF8 0001D8 0004+00 0/2 0/0 0/0 .rodata @7003 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7003 = 7.0f;
-COMPILER_STRIP_GATE(0x8064ECF4, &lit_7003);
-#pragma pop
-
-/* 8064ECF8-8064ECFC 0001DC 0004+00 0/3 0/0 0/0 .rodata @7004 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7004 = 8.0f;
-COMPILER_STRIP_GATE(0x8064ECF8, &lit_7004);
-#pragma pop
-
-/* 8064ECFC-8064ED00 0001E0 0004+00 0/1 0/0 0/0 .rodata @7005 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7005 = 2048.0f;
-COMPILER_STRIP_GATE(0x8064ECFC, &lit_7005);
-#pragma pop
-
-/* 8064ED00-8064ED04 0001E4 0004+00 0/2 0/0 0/0 .rodata @7006 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7006 = 4.0f;
-COMPILER_STRIP_GATE(0x8064ED00, &lit_7006);
-#pragma pop
-
-/* 8064ED04-8064ED08 0001E8 0004+00 0/1 0/0 0/0 .rodata @7007 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7007 = 1100.0f;
-COMPILER_STRIP_GATE(0x8064ED04, &lit_7007);
-#pragma pop
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+
+ if (pmobile != NULL) {
+ s16 mobile_angle = pmobile->shape_angle.y;
+ cXyz sp50(cM_ssin(mobile_angle) * 300.0f, 300.0f, cM_scos(mobile_angle) * 300.0f);
+ sp50 += pmobile->current.pos;
+
+ s16 sp10 = cLib_targetAngleY(&pmobile->current.pos, &current.pos);
+ s16 spE = mobile_angle - sp10;
+
+ switch (mMode) {
+ case 10:
+ if (field_0x6ff > 5) {
+ field_0x6b8 = mobile_angle;
+ mFlyWarpPos = sp50;
+ field_0x705 = 1;
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 0);
+ return;
+ }
+
+ setBck(ANM_HOOK_RELEASE, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 11;
+ case 11:
+ if (current.pos.y < 50.0f) {
+ cLib_addCalc2(&current.pos.y, 50.0f, 0.1f, 10.0f);
+ } else if (current.pos.y > 100.0f) {
+ cLib_addCalc2(&current.pos.y, 100.0f, 0.1f, 10.0f);
+ }
+
+ if (mpModelMorf->isStop()) {
+ mMode = 0;
+ }
+ break;
+ case 0:
+ setBck(ANM_SWIM, J3DFrameCtrl::LOOP_REPEAT_e, 5.0f, 1.0f);
+ mpModelMorf->setFrame(10.0f);
+ field_0x6cc = 0.0f;
+ attention_info.flags = 4;
+ mMode = 1;
+ field_0x702 = 0;
+ case 1:
+ case 2:
+ if (abs(spE) < 0x1000) {
+ if (mMode == 1) {
+ field_0x6ac.set(cM_ssin(mobile_angle) * 600.0f, 300.0f, cM_scos(mobile_angle) * 600.0f);
+ field_0x6ac += pmobile->current.pos;
+ } else {
+ field_0x6ac = sp50;
+ }
+
+ mMode = 4;
+ } else {
+ s16 spC;
+ if (spE < 0) {
+ spC = sp10 - 0x1000;
+ } else {
+ spC = sp10 + 0x1000;
+ }
+
+ field_0x6ac.set(cM_ssin(spC) * 1200.0f, 250.0f, cM_scos(spC) * 1200.0f);
+ field_0x6ac += pmobile->current.pos;
+ mMode = 3;
+ }
+
+ mModeTimer = 60;
+ case 3:
+ case 4:
+ {
+ if (current.pos.y < 50.0f) {
+ cLib_addCalc2(&current.pos.y, 50.0f, 0.1f, 10.0f);
+ }
+
+ f32 player_dist = fopAcM_searchPlayerDistance(this);
+ s16 spA = -cLib_targetAngleX(&current.pos, &field_0x6ac) + 0x4000;
+ s16 sp8 = cLib_targetAngleY(&current.pos, &field_0x6ac);
+ f32 anm_frame = mpModelMorf->getFrame();
+
+ int sp64 = 0;
+ if (anm_frame < 13.0f || anm_frame >= 45.0f) {
+ sp64 = 1;
+ }
+
+ if ((13.0f <= anm_frame && anm_frame <= 19.0f) || (29.0f <= anm_frame && anm_frame <= 45.0f)) {
+ sp64 = 2;
+ }
+
+ if (abs((s16)(sp8 - shape_angle.y)) < 0x2000) {
+ switch (sp64) {
+ case 0:
+ cLib_chaseF(&field_0x6cc, 0.0f, 2.0f);
+ break;
+ case 1:
+ cLib_chaseF(&field_0x6cc, 0.0f, 0.5f);
+ break;
+ case 2:
+ cLib_chaseF(&field_0x6cc, 15.0f, 3.0f);
+ break;
+ }
+ } else {
+ switch (sp64) {
+ case 0:
+ cLib_chaseF(&field_0x6cc, 0.0f, 1.0f);
+ break;
+ case 1:
+ cLib_chaseF(&field_0x6cc, 0.0f, 0.3f);
+ break;
+ case 2:
+ cLib_chaseF(&field_0x6cc, 5.0f, 1.0f);
+ break;
+ }
+ }
+
+ if (sp64 == 2) {
+ cLib_addCalcAngleS2(&shape_angle.y, sp8, 0x10, 0x180);
+ cLib_addCalcAngleS2(&shape_angle.x, spA, 0x10, 0x400);
+ } else {
+ cLib_addCalcAngleS2(&shape_angle.y, sp8, 0x10, 0x80);
+ cLib_addCalcAngleS2(&shape_angle.x, spA, 0x10, 0x200);
+ }
+
+ current.angle.y = shape_angle.y;
+ current.angle.x = cLib_targetAngleX(&current.pos, &field_0x6ac);
+
+ if (mModeTimer != 0) {
+ speed.y = (field_0x6cc / 2) * cM_ssin(current.angle.x);
+ speedF = std::abs((field_0x6cc / 2) * cM_scos(current.angle.x));
+ } else {
+ speed.y = field_0x6cc * cM_ssin(current.angle.x);
+ speedF = std::abs(field_0x6cc * cM_scos(current.angle.x));
+ }
+
+ if (current.pos.absXZ(sp50) < 200.0f) {
+ mMode = 6;
+ attention_info.flags = 0;
+ setTgHitBit(FALSE);
+ ((daB_ZANTZ_c*)pmobile)->setMouthMode(2);
+ mModeTimer = 60;
+ } else if (current.pos.abs(field_0x6ac) < 200.0f) {
+ if (mMode == 3) {
+ mMode = 1;
+ } else {
+ mMode = 2;
+ }
+ }
+ }
+ break;
+ case 6:
+ cLib_chaseF(&speedF, 0.0f, 0.5f);
+ cLib_chaseF(&speed.y, 5.0f, 0.5f);
+ cLib_addCalcAngleS2(&shape_angle.y, mobile_angle, 0x10, 0x200);
+ cLib_addCalcAngleS2(&shape_angle.x, 0, 0x10, 0x200);
+
+ if (!speedF && speed.y == 5.0f) {
+ mMode = 7;
+ gravity = -1.0f;
+ maxFallSpeed = -5.0f;
+ }
+ break;
+ case 7:
+ {
+ field_0x706 = 1;
+ maxFallSpeed = -100.0f;
+
+ cXyz target(sp50.x, current.pos.y, sp50.z);
+ cLib_chasePosXZ(&current.pos, target, 3.0f);
+
+ if (((daB_ZANTZ_c*)pmobile)->getMouthMode() == 3) {
+ field_0x705 = 1;
+ mModeTimer = 30;
+ setActionMode(ACT_WATER, 27);
+
+ shape_angle.x = 0;
+ shape_angle.y = 0;
+ gravity = 0.0f;
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ }
+ }
+ break;
+ }
+
+ if (checkBck(ANM_SWIM)) {
+ if (mpModelMorf->checkFrame(12)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_OI_SWIM1, 0, -1);
+ } else if (mpModelMorf->checkFrame(28)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_OI_SWIM2, 0, -1);
+ }
+ }
+ }
+}
/* 80644A3C-80645014 006A1C 05D8+00 1/1 0/0 0/0 .text executeSimaJump__10daB_ZANT_cFv */
void daB_ZANT_c::executeSimaJump() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ setTgHitBit(TRUE);
+ mBodySphCc[0].OnTgNoHitMark();
+ mBodySphCc[1].OnTgNoHitMark();
+
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ if (mLastAction == ACT_SMALL_ATTACK) {
+ field_0x702 = 0;
+ mMode = 10;
+
+ if (mFightCycle == 0) {
+ field_0x6f0 = 120;
+ } else {
+ field_0x6f0 = 105;
+ }
+
+ attention_info.flags = 4;
+ setBck(ANM_LV1_FATIGUE, J3DFrameCtrl::LOOP_REPEAT_e, 10.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MG_V_ZEIZEI, -1);
+ return;
+ }
+
+ if (mLastAction == ACT_CONFUSE || mLastAction == ACT_DAMAGE) {
+ mMode = 11;
+ return;
+ }
+
+ attention_info.flags = 4;
+ field_0x6ec = 0;
+ mMode = 1;
+ gravity = -5.0f;
+ field_0x6fd = 0;
+
+ if (field_0x70f < 2) {
+ if (field_0x70f == 0) {
+ mModeTimer = 150;
+ }
+
+ field_0x70f++;
+ } else {
+ mModeTimer = cM_rndF(50.0f) + 100.0f;
+
+ if (field_0x70b >= 4) {
+ mModeTimer = 0;
+ } else if (field_0x70b < 2 && mModeTimer < 120) {
+ mModeTimer = 120;
+ }
+
+ if (mModeTimer < 120) {
+ field_0x70b = 0;
+ mModeTimer = 0;
+
+ if (mFightCycle == 0) {
+ field_0x703 = l_HIO.mBulletNum;
+ } else {
+ field_0x703 = 8;
+ }
+
+ field_0x711 = 0;
+ setActionMode(ACT_SMALL_ATTACK, 0);
+ field_0x702 = 0;
+ return;
+ }
+ }
+
+ field_0x70b++;
+ if (mFightCycle != 0) {
+ mModeTimer -= 50;
+ }
+
+ setTgHitBit(FALSE);
+ case 1:
+ case 2:
+ case 3:
+ case 4:
+ case 5:
+ cLib_addCalcAngleS(&shape_angle.y, fopAcM_searchPlayerAngleY(this), 8, 0x800, 0x80);
+
+ if (fopAcM_searchPlayerDistance(this) < 550.0f) {
+ if (mAcch.i_ChkGroundHit()) {
+ mMode = 11;
+ return;
+ }
+ } else {
+ if (checkAvoidWeapon(FALSE)) {
+ mMode = 11;
+ return;
+ }
+ }
+
+ if (mMode == 1) {
+ if (mAcch.i_ChkGroundHit() && field_0x6ec == 0) {
+ setBck(ANM_JUMP_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 2;
+ }
+ } else if (mMode == 2) {
+ if (mpModelMorf->checkFrame(6)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MG_V_JUMP, -1);
+ }
+
+ if (mpModelMorf->checkFrame(10)) {
+ speed.y = 55.0f;
+ mMode = 3;
+ }
+ } else if (mMode == 3) {
+ if (speed.y <= 0.0f) {
+ setBck(ANM_JUMP_B, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 4;
+ }
+ } else if (mMode == 4) {
+ if (mpModelMorf->checkFrame(7)) {
+ mpModelMorf->setPlaySpeed(0.0f);
+ }
+
+ if (mAcch.i_ChkGroundHit()) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_MG_LAND, 0, -1);
+ mpModelMorf->setPlaySpeed(1.0f);
+ mpModelMorf->setFrame(8.0f);
+ mMode = 5;
+ }
+ } else if (mpModelMorf->isStop()) {
+ fopAcM_effSmokeSet1(&field_0x3894, &field_0x3898, &current.pos, NULL, 2.0f, &tevStr, 1);
+ mMode = 1;
+ field_0x6ec = 5;
+ }
+
+ if (mAcch.i_ChkGroundHit() && mModeTimer == 0) {
+ mMode = 11;
+ }
+ break;
+ case 10:
+ if (field_0x6f0 != 0) {
+ return;
+ }
+ case 11:
+ s16 var_r27 = cM_atan2s(daPy_getPlayerActorClass()->current.pos.x, daPy_getPlayerActorClass()->current.pos.z);
+ s16 sp1C = (f32)(var_r27 + 0x8000) + cM_rndFX(4.0f) * (f32)0x800;
+
+ mFlyWarpPos.set(cM_ssin(sp1C) * 1100.0f, 1000.0f, cM_scos(sp1C) * 1100.0f);
+ field_0x6b8 = sp1C + 0x8000;
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 0);
+ break;
+ }
}
-/* ############################################################################################## */
-/* 8064ED08-8064ED0C 0001EC 0004+00 0/1 0/0 0/0 .rodata @7062 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7062 = 115.0f;
-COMPILER_STRIP_GATE(0x8064ED08, &lit_7062);
-#pragma pop
-
/* 80645014-8064524C 006FF4 0238+00 1/1 0/0 0/0 .text executeIceDemo__10daB_ZANT_cFv */
void daB_ZANT_c::executeIceDemo() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ current.pos.set(-140.0f, 300.0f, 700.0f);
+ old.pos = current.pos;
+ case 100:
+ for (int i = 0; i < 11; i++) {
+ mFoot2Cc[i].OnTgSetBit();
+ }
+
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OnTgSetBit();
+ mFootCc[iron_tg_cc[i]].OnTgShield();
+ mFootCc[iron_tg_cc[i]].OnTgIronBallRebound();
+ }
+
+ setBck(ANM_HUGE, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ speedF = 0.0f;
+ gravity = 0.0f;
+ shape_angle.z = 0;
+ shape_angle.x = 0;
+ attention_info.flags = 0;
+ maxFallSpeed = -100.0f;
+
+ mMode = 1;
+ field_0x70e = 0;
+ case 1:
+ if (mpModelMorf->checkFrame(8)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_HUGE, -1);
+ }
+
+ cLib_chaseF(&mModelScaleXZ, 10.0f, 0.1f);
+ cLib_chaseF(&mModelScaleY, 10.0f, 0.1f);
+
+ if (mpModelMorf->checkFrame(115)) {
+ mMode = 2;
+ }
+ break;
+ case 2:
+ cLib_chaseF(&speed.y, 50.0f, 5.0f);
+ if (mpModelMorf->isStop()) {
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ setActionMode(ACT_ICE_JUMP, 3);
+ }
+ break;
+ }
}
-/* ############################################################################################## */
-/* 8064ED0C-8064ED10 0001F0 0004+00 0/1 0/0 0/0 .rodata @7419 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7419 = 130.0f;
-COMPILER_STRIP_GATE(0x8064ED0C, &lit_7419);
-#pragma pop
-
/* 8064524C-80645DA4 00722C 0B58+00 2/1 0/0 0/0 .text executeIceJump__10daB_ZANT_cFv */
void daB_ZANT_c::executeIceJump() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064ED10-8064ED14 0001F4 0004+00 0/3 0/0 0/0 .rodata @7420 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7420 = 20.0f;
-COMPILER_STRIP_GATE(0x8064ED10, &lit_7420);
-#pragma pop
-
-/* 8064ED14-8064ED18 0001F8 0004+00 0/1 0/0 0/0 .rodata @7697 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7697 = 24.0f;
-COMPILER_STRIP_GATE(0x8064ED14, &lit_7697);
-#pragma pop
-
-/* 8064ED18-8064ED1C 0001FC 0004+00 0/3 0/0 0/0 .rodata @7698 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7698 = 14.0f;
-COMPILER_STRIP_GATE(0x8064ED18, &lit_7698);
-#pragma pop
-
-/* 8064ED1C-8064ED20 000200 0004+00 0/1 0/0 0/0 .rodata @7699 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7699 = 27.0f;
-COMPILER_STRIP_GATE(0x8064ED1C, &lit_7699);
-#pragma pop
-
-/* 8064ED20-8064ED24 000204 0004+00 0/2 0/0 0/0 .rodata @7700 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7700 = 17.0f;
-COMPILER_STRIP_GATE(0x8064ED20, &lit_7700);
-#pragma pop
-
-/* 8064ED24-8064ED28 000208 0004+00 0/1 0/0 0/0 .rodata @7701 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7701 = 31.0f;
-COMPILER_STRIP_GATE(0x8064ED24, &lit_7701);
-#pragma pop
-
-/* 8064ED28-8064ED2C 00020C 0004+00 0/1 0/0 0/0 .rodata @7702 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7702 = 21.0f;
-COMPILER_STRIP_GATE(0x8064ED28, &lit_7702);
-#pragma pop
-
-/* 8064ED2C-8064ED30 000210 0004+00 0/1 0/0 0/0 .rodata @7703 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7703 = 11.0f;
-COMPILER_STRIP_GATE(0x8064ED2C, &lit_7703);
-#pragma pop
-
-/* 8064ED30-8064ED34 000214 0004+00 0/1 0/0 0/0 .rodata @7704 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7704 = 35.0f;
-COMPILER_STRIP_GATE(0x8064ED30, &lit_7704);
-#pragma pop
-
-/* 8064ED34-8064ED38 000218 0004+00 0/1 0/0 0/0 .rodata @7705 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7705 = -35.0f;
-COMPILER_STRIP_GATE(0x8064ED34, &lit_7705);
-#pragma pop
-
-/* 8064ED38-8064ED3C 00021C 0004+00 0/1 0/0 0/0 .rodata @7706 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7706 = -30.0f;
-COMPILER_STRIP_GATE(0x8064ED38, &lit_7706);
-#pragma pop
+ cXyz sp44(daPy_getPlayerActorClass()->current.pos);
+ f32 var_f31 = sp44.absXZ(current.pos);
+ cXyz sp50;
+ cXyz sp5C;
+ cXyz sp68;
+
+ switch (mMode) {
+ case 0:
+ setBck(ANM_HUGE_LANDING, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, -1.0f);
+ mMode = 1;
+ attention_info.flags = 0;
+ field_0x70e = 0;
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_JUMP, -1);
+ case 1:
+ if (mpModelMorf->checkFrame(10)) {
+ mMode = 2;
+ speed.y = 130.0f;
+ current.angle.y = shape_angle.y;
+ }
+ break;
+ case 2:
+ if (mpModelMorf->isStop()) {
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 3;
+ }
+ case 3:
+ cLib_chaseF(&speed.y, 15.0f, 5.0f);
+ if (current.pos.y > 1500.0f) {
+ field_0x70e = 3;
+ }
+
+ if (current.pos.y > 2000.0f) {
+ mMode = 4;
+ mModeTimer = 90;
+ current.angle.y = shape_angle.y;
+ }
+ break;
+ case 4:
+ cLib_chaseF(&speed.y, 0.0f, 1.0f);
+ if (var_f31 < 300.0f) {
+ var_f31 -= 50.0f;
+ if (var_f31 < 0.0f) {
+ var_f31 = 0.0f;
+ }
+
+ cLib_chaseF(&speedF, var_f31 / 10.0f, 1.0f);
+ } else {
+ cLib_chaseF(&speedF, 30.0f, 1.0f);
+ cLib_addCalcAngleS(&current.angle.y, fopAcM_searchPlayerAngleY(this), 8, 0x400, 0x80);
+ }
+
+ shape_angle.y = current.angle.y;
+
+ if (mModeTimer == 0 && sp44.absXZ(current.pos) < 550.0f) {
+ mMode = 5;
+ gravity = -5.0f;
+ speed.y = 0.0f;
+ speedF = 0.0f;
+
+ setBck(ANM_HUGE_LANDING, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_LAND, -1);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_L));
+ mDoMtx_stack_c::transM(10.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp50);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_R));
+ mDoMtx_stack_c::transM(10.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp5C);
+
+ if (sp44.absXZ(sp50) < sp44.absXZ(sp5C)) {
+ field_0x70f = 0;
+ } else {
+ field_0x70f = 1;
+ }
+ }
+ break;
+ case 5:
+ case 6:
+ if (field_0x70f == 0) {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_L));
+ } else {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_R));
+ }
+
+ mDoMtx_stack_c::transM(10.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp5C);
+ sp68 = sp5C - sp44;
+ current.pos -= sp68 * (20.0f / sp68.abs());
+
+ if (mMode == 5) {
+ if (mpModelMorf->checkFrame(10)) {
+ mpModelMorf->setPlaySpeed(0.0f);
+ mMode = 6;
+ mFoot2Cc[0].OnAtSetBit();
+ mFoot2Cc[4].OnAtSetBit();
+ mFoot2Cc[0].SetAtAtp(4);
+ mFoot2Cc[4].SetAtAtp(4);
+ }
+ } else {
+ if (mAcch.i_ChkGroundHit()) {
+ field_0x70e = 1;
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_LAND_HUGE, 0, -1);
+ dComIfGp_getVibration().StartShock(8, 31, cXyz(0.0f, 1.0f, 0.0f));
+
+ setIceLandingEffect(0);
+ setIceLandingEffect(1);
+
+ mFoot2Cc[0].OffAtSetBit();
+ mFoot2Cc[4].OffAtSetBit();
+ mFoot2Cc[0].SetAtAtp(2);
+ mFoot2Cc[4].SetAtAtp(2);
+
+ gravity = 0.0f;
+
+ mpModelMorf->setPlaySpeed(1.0f);
+ mMode = 7;
+ attention_info.flags = 4;
+ }
+ }
+ break;
+ case 7:
+ if (mpModelMorf->checkFrame(15)) {
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OffTgShield();
+ }
+ }
+
+ if (mpModelMorf->isStop()) {
+ setActionMode(ACT_ICE_STEP, 0);
+ }
+ break;
+ }
+}
/* 80645DA4-8064687C 007D84 0AD8+00 1/1 0/0 0/0 .text executeIceStep__10daB_ZANT_cFv */
void daB_ZANT_c::executeIceStep() {
- // NONMATCHING
+ s16 var_r29 = shape_angle.y;
+ int var_r28;
+ cXyz sp60;
+
+ switch (mMode) {
+ case 0:
+ mModeTimer = cM_rndFX(50.0f) + 600.0f;
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OffTgShield();
+ }
+ case 1:
+ {
+ f32 var_f30 = cM_rnd();
+ s16 sp8 = shape_angle.y - fopAcM_searchPlayerAngleY(this);
+ f32 var_f29 = fopAcM_searchPlayerDistance(this);
+
+ if (var_f29 < 300.0f) {
+ if (sp8 < 0) {
+ if (var_f30 < 0.5f) {
+ var_r28 = 4;
+ } else {
+ var_r28 = 5;
+ }
+
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) + 0x1000;
+ } else {
+ if (var_f30 < 0.5f) {
+ var_r28 = 2;
+ } else {
+ var_r28 = 3;
+ }
+
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) - 0x1000;
+ }
+ } else if (var_f29 < 400.0f) {
+ if (sp8 > 0) {
+ if (var_f30 < 0.5f) {
+ var_r28 = 2;
+ } else {
+ var_r28 = 3;
+ }
+
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) + 0x4000;
+ } else {
+ if (var_f30 < 0.5f) {
+ var_r28 = 4;
+ } else {
+ var_r28 = 5;
+ }
+
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) - 0x4000;
+ }
+ } else if (abs(sp8) > 0x4000) {
+ if (sp8 < 0) {
+ var_r28 = 4;
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) - 0x1000;
+ } else {
+ var_r28 = 2;
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) + 0x1000;
+ }
+ } else {
+ if (sp8 < 0) {
+ var_r28 = 2;
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) + 0x4000;
+ } else {
+ var_r28 = 4;
+ field_0x6ba = fopAcM_searchPlayerAngleY(this) - 0x4000;
+ }
+ }
+
+ switch (var_r28) {
+ case 2:
+ setBck(ANM_TRAMPLE_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 2;
+ break;
+ case 3:
+ setBck(ANM_TRAMPLE_C, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 3;
+ break;
+ case 4:
+ setBck(ANM_TRAMPLE_B, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 4;
+ break;
+ case 5:
+ setBck(ANM_TRAMPLE_D, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 5;
+ break;
+ }
+ }
+ case 2:
+ case 3:
+ case 4:
+ case 5:
+ f32 anm_frame = mpModelMorf->getFrame();
+ int sp98 = 0;
+
+ if (mMode == 2) {
+ if (8.0f <= anm_frame && anm_frame <= 24.0f) {
+ sp98 = 1;
+ }
+
+ if (mpModelMorf->checkFrame(23)) {
+ mFoot2Cc[4].OnAtSetBit();
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_1, -1);
+ }
+
+ if (mpModelMorf->checkFrame(28)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_FUMI, 0, -1);
+ dComIfGp_getVibration().StartShock(6, 31, cXyz(0.0f, 1.0f, 0.0f));
+ setIceLandingEffect(1);
+ }
+
+ if (mpModelMorf->checkFrame(30)) {
+ mFoot2Cc[4].OffAtSetBit();
+ }
+ } else if (mMode == 3) {
+ if (7.0f <= anm_frame && anm_frame <= 14.0f) {
+ sp98 = 1;
+ }
+
+ if (22.0f <= anm_frame && anm_frame <= 28.0f) {
+ sp98 = 1;
+ }
+
+ if (mpModelMorf->checkFrame(13) || mpModelMorf->checkFrame(27)) {
+ mFoot2Cc[4].OnAtSetBit();
+
+ if (mpModelMorf->checkFrame(13)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_2, -1);
+ } else {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_3, -1);
+ }
+ }
+
+ if (mpModelMorf->checkFrame(17) || mpModelMorf->checkFrame(30)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_FUMI, 0, -1);
+ dComIfGp_getVibration().StartShock(6, 31, cXyz(0.0f, 1.0f, 0.0f));
+ setIceLandingEffect(1);
+ }
+
+ if (mpModelMorf->checkFrame(18) || mpModelMorf->checkFrame(31)) {
+ mFoot2Cc[4].OffAtSetBit();
+ }
+ } else if (mMode == 4) {
+ if (8.0f <= anm_frame && anm_frame <= 23.0f) {
+ sp98 = 1;
+ }
+
+ if (mpModelMorf->checkFrame(22)) {
+ mFoot2Cc[0].OnAtSetBit();
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_1, -1);
+ }
+
+ if (mpModelMorf->checkFrame(28)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_FUMI, 0, -1);
+ dComIfGp_getVibration().StartShock(6, 31, cXyz(0.0f, 1.0f, 0.0f));
+ setIceLandingEffect(0);
+ }
+
+ if (mpModelMorf->checkFrame(30)) {
+ mFoot2Cc[0].OffAtSetBit();
+ }
+ } else {
+ if (7.0f <= anm_frame && anm_frame <= 13.0f) {
+ sp98 = 1;
+ }
+
+ if (21.0f <= anm_frame && anm_frame <= 27.0f) {
+ sp98 = 1;
+ }
+
+ if (mpModelMorf->checkFrame(11) || mpModelMorf->checkFrame(26)) {
+ mFoot2Cc[0].OnAtSetBit();
+
+ if (mpModelMorf->checkFrame(11)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_2, -1);
+ } else {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_FUMI_3, -1);
+ }
+ }
+
+ if (mpModelMorf->checkFrame(16) || mpModelMorf->checkFrame(31)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_FUMI, 0, -1);
+ dComIfGp_getVibration().StartShock(6, 31, cXyz(0.0f, 1.0f, 0.0f));
+ setIceLandingEffect(0);
+ }
+
+ if (mpModelMorf->checkFrame(18) || mpModelMorf->checkFrame(32)) {
+ mFoot2Cc[0].OffAtSetBit();
+ }
+ }
+
+ if (sp98 != 0) {
+ cLib_addCalcAngleS2(&shape_angle.y, field_0x6ba, 0x10, 0x400);
+ }
+
+ if (mMode <= 3) {
+ mDoMtx_stack_c::transS(current.pos);
+ mDoMtx_stack_c::YrotM(var_r29);
+ mDoMtx_stack_c::transM(mModelScaleXZ * 35.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp60);
+ mDoMtx_stack_c::transS(sp60);
+ mDoMtx_stack_c::YrotM(shape_angle.y);
+ mDoMtx_stack_c::transM(mModelScaleXZ * -35.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&current.pos);
+ } else {
+ mDoMtx_stack_c::transS(current.pos);
+ mDoMtx_stack_c::YrotM(var_r29);
+ mDoMtx_stack_c::transM(mModelScaleXZ * -30.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp60);
+ mDoMtx_stack_c::transS(sp60);
+ mDoMtx_stack_c::YrotM(shape_angle.y);
+ mDoMtx_stack_c::transM(mModelScaleXZ * 30.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&current.pos);
+ }
+
+ if (mpModelMorf->isStop()) {
+ if (mModeTimer != 0) {
+ mMode = 1;
+ } else {
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OnTgShield();
+ }
+
+ setActionMode(ACT_ICE_JUMP, 0);
+ }
+ }
+ break;
+ }
}
-/* ############################################################################################## */
-/* 8064ED3C-8064ED68 000220 002C+00 0/1 0/0 0/0 .rodata damage_scale$7711 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const damage_scale[44] = {
- 0x41, 0x20, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x40, 0xF0, 0x00, 0x00, 0x40, 0xC0, 0x00,
- 0x00, 0x40, 0x90, 0x00, 0x00, 0x40, 0x40, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x3F, 0xB3,
- 0x33, 0x33, 0x3F, 0x80, 0x00, 0x00, 0x3F, 0x33, 0x33, 0x33, 0x3F, 0x00, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064ED3C, &damage_scale);
-#pragma pop
-
-/* 8064ED68-8064ED94 00024C 002C+00 0/1 0/0 0/0 .rodata damage_jump_speed$7712 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static u8 const damage_jump_speed[44] = {
- 0x42, 0xC8, 0x00, 0x00, 0x42, 0xBE, 0x00, 0x00, 0x42, 0xB4, 0x00, 0x00, 0x42, 0xAA, 0x00,
- 0x00, 0x42, 0xA0, 0x00, 0x00, 0x42, 0x96, 0x00, 0x00, 0x42, 0x8C, 0x00, 0x00, 0x42, 0x82,
- 0x00, 0x00, 0x42, 0x70, 0x00, 0x00, 0x42, 0x5C, 0x00, 0x00, 0x42, 0x48, 0x00, 0x00,
-};
-COMPILER_STRIP_GATE(0x8064ED68, &damage_jump_speed);
-#pragma pop
-
-/* 8064ED94-8064ED98 000278 0004+00 0/1 0/0 0/0 .rodata @7978 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7978 = 25.0f;
-COMPILER_STRIP_GATE(0x8064ED94, &lit_7978);
-#pragma pop
-
-/* 8064ED98-8064ED9C 00027C 0004+00 0/1 0/0 0/0 .rodata @7979 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7979 = -15.0f;
-COMPILER_STRIP_GATE(0x8064ED98, &lit_7979);
-#pragma pop
-
/* 8064687C-806471CC 00885C 0950+00 2/1 0/0 0/0 .text executeIceDamage__10daB_ZANT_cFv */
void daB_ZANT_c::executeIceDamage() {
- // NONMATCHING
+ static f32 const damage_scale[] = {
+ 10.0f, 8.0f, 7.5f, 6.0f, 4.5f, 3.0f, 2.0f, 1.4f, 1.0f, 0.69999999f, 0.5f,
+ };
+
+ static f32 const damage_jump_speed[] = {
+ 100.0f, 95.0f, 90.0f, 85.0f, 80.0f, 75.0f, 70.0f, 65.0f, 60.0f, 55.0f, 50.0f
+ };
+
+ daPy_py_c* player = daPy_getPlayerActorClass();
+
+ if (mMode >= 10 && mModeTimer == 0) {
+ for (int i = 0; i < 11; i++) {
+ mFoot2Cc[i].OnTgShield();
+ mFoot2Cc[i].OffTgSetBit();
+ mFoot2Cc[i].OffTgNoHitMark();
+ }
+
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OffTgSetBit();
+ mFootCc[iron_tg_cc[i]].OnTgShield();
+ mFootCc[iron_tg_cc[i]].OnTgIronBallRebound();
+ }
+ }
+
+ switch (mMode) {
+ case 0:
+ case 1:
+ field_0x70e = 2;
+
+ if (mMode == 0) {
+ setBck(ANM_SHIND_L, J3DFrameCtrl::LOOP_REPEAT_e, 10.0f, 1.0f);
+ } else {
+ setBck(ANM_SHIND_R, J3DFrameCtrl::LOOP_REPEAT_e, 10.0f, 1.0f);
+ }
+
+ mFoot2Cc[0].OffAtSetBit();
+ mFoot2Cc[4].OffAtSetBit();
+
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OnTgShield();
+ }
+
+ current.angle.y = shape_angle.y;
+ mMode = 2;
+ mModeTimer = 300;
+ field_0x70b = 0;
+ field_0x70b++;
+ field_0x6cc = (mModelScaleXZ - damage_scale[field_0x70b]) / 3.0f;
+ case 2:
+ if (mpModelMorf->checkFrame(6) || mpModelMorf->checkFrame(19)) {
+ if (mpModelMorf->getFrame() < 14) {
+ mpModelMorf->setFrame(6);
+ } else {
+ mpModelMorf->setFrame(19);
+ }
+
+ if (field_0x70b <= 8) {
+ speedF = 25.0f;
+ } else if (field_0x70b == 9) {
+ if (mFightCycle == 0) {
+ speedF = 20.0f;
+ } else {
+ speedF = 23.0f;
+ }
+ } else if (mFightCycle == 0) {
+ speedF = 15.0f;
+ } else {
+ speedF = 22.0f;
+ }
+
+ speed.y = damage_jump_speed[field_0x70b];
+ gravity = -15.0f;
+ mMode = 3;
+
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_YO_V_KENKEN, -1);
+ } else {
+ if (field_0x70b <= 10) {
+ cLib_addCalc2(&mModelScaleXZ, damage_scale[field_0x70b], 0.5f, field_0x6cc);
+ } else {
+ cLib_chaseF(&mModelScaleXZ, 0.5f, 0.1f);
+ }
+
+ mModelScaleY = mModelScaleXZ;
+ cLib_addCalcAngleS2(&shape_angle.y, field_0x6ba, 8, 0x1000);
+ current.angle.y = shape_angle.y;
+ speedF = 0.0f;
+
+ if (mModeTimer == 0) {
+ mMode = 30;
+ }
+ }
+ break;
+ case 3:
+ if (mpModelMorf->checkFrame(12) || mpModelMorf->checkFrame(25)) {
+ if (mpModelMorf->getFrame() < 14) {
+ mpModelMorf->setFrame(12);
+ } else {
+ mpModelMorf->setFrame(25);
+ }
+
+ mpModelMorf->setPlaySpeed(0.0f);
+ mMode = 4;
+ }
+ break;
+ case 4:
+ if (mAcch.i_ChkGroundHit()) {
+ s16 sp8 = fopAcM_searchPlayerAngleY(this) + (4096.0f * cM_rndFX(4.9f)) + 32768.0f;
+
+ if (current.pos.absXZ() > 1200.0f) {
+ sp8 = cM_atan2s(-current.pos.x, -current.pos.z);
+ }
+
+ field_0x6ba = sp8;
+
+ if (field_0x70b < 10) {
+ field_0x70b++;
+ }
+
+ field_0x6cc = (mModelScaleXZ - damage_scale[field_0x70b]) / 3.0f;
+ mpModelMorf->setPlaySpeed((10.0f - mModelScaleXZ) / 10.0f + 1.0f);
+
+ if (field_0x70b == 8) {
+ for (int i = 0; i < 11; i++) {
+ mFoot2Cc[i].OffTgShield();
+ mFoot2Cc[i].OnTgNoHitMark();
+ }
+
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OffTgShield();
+ mFootCc[iron_tg_cc[i]].OffTgIronBallRebound();
+ }
+ }
+
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_LAND, 0, -1);
+ mMode = 2;
+ }
+ break;
+ case 10:
+ if (setNextDamageMode(0)) {
+ return;
+ }
+
+ if (cM_rnd() < 0.5f) {
+ setBck(ANM_DAMAGE_L_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_DAMAGE_R_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ mMode = 11;
+ case 11:
+ cLib_chaseF(&mModelScaleXZ, 0.5f, 0.1f);
+ mModelScaleY = mModelScaleXZ;
+
+ if (mpModelMorf->isStop()) {
+ mMode = 12;
+ if (mModeTimer >= 30) {
+ mModeTimer = 30;
+ }
+
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ break;
+ case 12:
+ if (mModeTimer == 0) {
+ mMode = 30;
+ }
+ break;
+ case 20:
+ setBck(ANM_GROUND_REACTION, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_NO_DMG, -1);
+ mMode = 21;
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ case 21:
+ if (mpModelMorf->isStop()) {
+ mMode = 30;
+ }
+ break;
+ case 40:
+ setBck(ANM_FAINT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 41;
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ mModeTimer = 30;
+ case 41:
+ if (mModeTimer == 0) {
+ mMode = 30;
+ }
+ break;
+ case 30:
+ for (int i = 0; i < 11; i++) {
+ mFoot2Cc[i].OnTgShield();
+ mFoot2Cc[i].OffTgSetBit();
+ mFoot2Cc[i].OffTgNoHitMark();
+ }
+
+ for (int i = 0; i < 6; i++) {
+ mFootCc[iron_tg_cc[i]].OffTgSetBit();
+ mFootCc[iron_tg_cc[i]].OnTgShield();
+ mFootCc[iron_tg_cc[i]].OnTgIronBallRebound();
+ }
+
+ if (!setNextDamageMode(1)) {
+ mFlyWarpPos.set(0.0f, 300.0f, 0.0f);
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 1);
+ gravity = 0.0f;
+ }
+ break;
+ }
}
-/* ############################################################################################## */
-/* 8064ED9C-8064EDA0 000280 0004+00 0/0 0/0 0/0 .rodata @7980 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_7980 = 49.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064ED9C, &lit_7980);
-#pragma pop
-
-/* 8064EDA0-8064EDA4 000284 0004+00 2/4 0/0 0/0 .rodata @8037 */
-SECTION_RODATA static f32 const lit_8037 = 500.0f;
-COMPILER_STRIP_GATE(0x8064EDA0, &lit_8037);
-
/* 806471CC-806473E4 0091AC 0218+00 1/1 0/0 0/0 .text setFarPillarPos__10daB_ZANT_cFv */
void daB_ZANT_c::setFarPillarPos() {
- // NONMATCHING
+ fopAc_ac_c* ppillar;
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ int pillar_no = -1;
+ f32 farthest_dist = 0.0f;
+
+ for (int i = 0; i < 8; i++) {
+ if (i != field_0x70a) {
+ fopAcM_SearchByID(mPillarIDs[i], &ppillar);
+ if (ppillar != NULL) {
+ f32 dist = player_pos.abs(ppillar->current.pos);
+ if (dist > farthest_dist) {
+ pillar_no = i;
+ farthest_dist = dist;
+ }
+ }
+ }
+ }
+
+ if (pillar_no != -1) {
+ fopAcM_SearchByID(mPillarIDs[pillar_no], &ppillar);
+ if (ppillar != NULL) {
+ mFlyWarpPos = ppillar->current.pos;
+ mFlyWarpPos.y += 500.0f;
+ field_0x709 = pillar_no;
+ field_0x708 = pillar_no;
+ field_0x70a = pillar_no;
+ field_0x71b = 1;
+ }
+ }
}
/* 806473E4-80647468 0093C4 0084+00 4/4 0/0 0/0 .text setNearPillarPos__10daB_ZANT_cFv */
void daB_ZANT_c::setNearPillarPos() {
- // NONMATCHING
+ fopAc_ac_c* ppillar;
+ fopAcM_SearchByID(mPillarIDs[8], &ppillar);
+
+ if (ppillar != NULL) {
+ mFlyWarpPos = ppillar->current.pos;
+ mFlyWarpPos.y += 500.0f;
+ field_0x709 = 8;
+ field_0x708 = 8;
+ field_0x70a = 8;
+ field_0x71b = 0;
+ }
}
/* 80647468-806474F4 009448 008C+00 1/1 0/0 0/0 .text setNextPillarInfo__10daB_ZANT_cFi
*/
-void daB_ZANT_c::setNextPillarInfo(int param_0) {
- // NONMATCHING
+void daB_ZANT_c::setNextPillarInfo(int i_pillarNo) {
+ fopAc_ac_c* ppillar;
+ fopAcM_SearchByID(mPillarIDs[i_pillarNo], &ppillar);
+
+ if (ppillar != NULL) {
+ field_0x6ac = ppillar->current.pos;
+ field_0x6ac.y += 500.0f;
+ field_0x708 = field_0x709;
+ field_0x709 = i_pillarNo;
+ }
}
-/* ############################################################################################## */
-/* 8064EDA4-8064EDA8 000288 0004+00 0/1 0/0 0/0 .rodata @8227 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8227 = 10000.0f;
-COMPILER_STRIP_GATE(0x8064EDA4, &lit_8227);
-#pragma pop
-
/* 806474F4-80647A34 0094D4 0540+00 1/1 0/0 0/0 .text setNextPillarPos__10daB_ZANT_cFv */
void daB_ZANT_c::setNextPillarPos() {
- // NONMATCHING
+ fopAc_ac_c* ppillar;
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ int pillar_no = -1;
+ f32 nearest_dist = 10000.0f;
+
+ if (field_0x708 != 8 && field_0x709 != 8 && cM_rnd() < 0.5) {
+ fopAcM_SearchByID(mPillarIDs[8], &ppillar);
+
+ if (ppillar != NULL && player_pos.absXZ(ppillar->current.pos) > 500.0f) {
+ setNextPillarInfo(8);
+ return;
+ }
+ }
+
+ if (field_0x709 == 8) {
+ fopAcM_SearchByID(mPillarIDs[8], &ppillar);
+ if (ppillar != NULL) {
+ cXyz pillar_pos(ppillar->current.pos);
+ s16 sp8 = cLib_targetAngleY(&pillar_pos, &player_pos);
+
+ for (int i = 0; i < 8; i++) {
+ if (i != field_0x708 && i != field_0x709) {
+ fopAcM_SearchByID(mPillarIDs[i], &ppillar);
+ if (ppillar != NULL && abs((s16)(cLib_targetAngleY(&pillar_pos, &ppillar->current.pos) - sp8)) > 0x6000) {
+ setNextPillarInfo(i);
+ return;
+ }
+ }
+ }
+ }
+ }
+
+ for (int i = 0; i < 8; i++) {
+ if (i != field_0x708 && i != field_0x709) {
+ fopAcM_SearchByID(mPillarIDs[i], &ppillar);
+ if (ppillar != NULL && player_pos.absXZ(ppillar->current.pos) > 500.0f) {
+ f32 dist = current.pos.abs(ppillar->current.pos);
+ if (dist < nearest_dist) {
+ pillar_no = i;
+ nearest_dist = dist;
+ }
+ }
+ }
+ }
+
+ if (pillar_no != -1) {
+ setNextPillarInfo(pillar_no);
+ }
}
/* 80647A34-80647AC8 009A14 0094+00 1/1 0/0 0/0 .text checkPillarSwing__10daB_ZANT_cFv */
void daB_ZANT_c::checkPillarSwing() {
- // NONMATCHING
+ if (field_0x707 != 0) {
+ fopAc_ac_c* ppillar;
+ fopAcM_SearchByID(mPillarIDs[field_0x70a], &ppillar);
+
+ if (ppillar != NULL && ((daPillar_c*)ppillar)->checkRollAttack()) {
+ if (mAction != ACT_MONKEY_FALL) {
+ setActionMode(ACT_MONKEY_FALL, 0);
+ } else {
+ setActionMode(ACT_MONKEY_FALL, 10);
+ }
+ }
+ }
}
/* 80647AC8-806481F4 009AA8 072C+00 1/1 0/0 0/0 .text executeMonkey__10daB_ZANT_cFv */
void daB_ZANT_c::executeMonkey() {
- // NONMATCHING
+ fopAc_ac_c* ppillar;
+
+ switch (mMode) {
+ case 0:
+ gravity = -5.0f;
+ field_0x707 = 1;
+ setTgHitBit(FALSE);
+ mBodySphCc[0].OnTgNoHitMark();
+ mBodySphCc[1].OnTgNoHitMark();
+ field_0x708 = field_0x709 = field_0x70a;
+
+ if (mLastAction == ACT_WARP) {
+ if (field_0x71b != 0) {
+ field_0x71b = 0;
+ field_0x703 = l_HIO.mBulletNum;
+ field_0x711 = 0;
+ setActionMode(ACT_SMALL_ATTACK, 0);
+ setNextPillarPos();
+ return;
+ }
+
+ setNextPillarPos();
+ setBck(ANM_LV1_JUMP_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 8;
+ } else if (mLastAction == ACT_SMALL_ATTACK) {
+ mMode = 5;
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mModeTimer = 0;
+ } else {
+ mMode = 5;
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+
+ field_0x70b = cM_rndF(2.9f) + 3.0f;
+ field_0x6fd = 0;
+ field_0x71b = 0;
+ break;
+ case 1:
+ if (mpModelMorf->checkFrame(10) || mpModelMorf->checkFrame(14)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MK_LAND, -1);
+ }
+
+ if (mpModelMorf->isStop()) {
+ field_0x6fd++;
+
+ if (field_0x6fd >= field_0x70b) {
+ if (mFightCycle != 0) {
+ setFarPillarPos();
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
+ } else {
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 2;
+ }
+ } else {
+ mMode = 5;
+ setBck(ANM_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ }
+ break;
+ case 2:
+ cLib_addCalcAngleS(&shape_angle.y, fopAcM_searchPlayerAngleY(this), 8, 0x800, 0x80);
+ if (abs((s16)(shape_angle.y - fopAcM_searchPlayerAngleY(this))) < 0x2000) {
+ field_0x703 = l_HIO.mBulletNum;
+ field_0x711 = 0;
+ setActionMode(ACT_SMALL_ATTACK, 0);
+ }
+ break;
+ case 5:
+ setTgHitBit(FALSE);
+ setNextPillarPos();
+ mMode = 6;
+ case 6:
+ cLib_addCalcAngleS2(&shape_angle.y, cLib_targetAngleY(&current.pos, &field_0x6ac), 8, 0x800);
+
+ if (mModeTimer == 0 && mAcch.i_ChkGroundHit()) {
+ setBck(ANM_LV1_JUMP_A, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 8;
+ }
+ break;
+ case 8:
+ cLib_addCalcAngleS2(&shape_angle.y, cLib_targetAngleY(&current.pos, &field_0x6ac), 8, 0x800);
+
+ if (mpModelMorf->checkFrame(13)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MK_V_JUMP, -1);
+ mModeTimer = 18;
+ speed.y = 45.0f;
+ mMode = 9;
+ field_0x707 = 0;
+
+ fopAcM_SearchByID(mPillarIDs[field_0x70a], &ppillar);
+ if (ppillar != NULL) {
+ ((daPillar_c*)ppillar)->setShake(2);
+ }
+ }
+ break;
+ case 9:
+ if (mModeTimer != 0) {
+ cXyz sp2C(field_0x6ac.x, current.pos.y, field_0x6ac.z);
+ cLib_chasePosXZ(&current.pos, sp2C, field_0x6ac.absXZ(current.pos) / mModeTimer);
+ }
+
+ if (mModeTimer == 8) {
+ setBck(ANM_LB1_JUMP_B, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ if (mAcch.i_ChkGroundHit()) {
+ current.pos = field_0x6ac;
+ field_0x707 = 1;
+ field_0x70a = field_0x709;
+
+ fopAcM_SearchByID(mPillarIDs[field_0x70a], &ppillar);
+ if (ppillar != NULL) {
+ ((daPillar_c*)ppillar)->setShake(2);
+ }
+
+ mMode = 1;
+ field_0x6fd++;
+ }
+ break;
+ case 100:
+ target_info_count = 0;
+ fpcM_Search(s_pillar_sub, this);
+
+ if (target_info_count < 8 || mPillarIDs[8] == fpcM_ERROR_PROCESS_ID_e) {
+ for (int i = 0; i < 9; i++) {
+ mPillarIDs[i] = fpcM_ERROR_PROCESS_ID_e;
+ }
+ } else {
+ setNearPillarPos();
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
+ }
+ break;
+ }
}
/* 806481F4-80648544 00A1D4 0350+00 2/1 0/0 0/0 .text executeMonkeyFall__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeMonkeyFall() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ case 20:
+ setTgHitBit(TRUE);
+ mModeTimer = 90;
+
+ if (mMode == 20) {
+ mModeTimer = 30;
+ }
+
+ setBck(ANM_FAINT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 1;
+
+ mBodySphCc[0].OffTgNoHitMark();
+ mBodySphCc[1].OffTgNoHitMark();
+
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MK_V_OTT, -1);
+ case 1:
+ if (mModeTimer == 0) {
+ setActionMode(ACT_MONKEY, 0);
+ }
+ break;
+ case 10:
+ setBck(ANM_FALL, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mMode = 11;
+ field_0x707 = 0;
+ setTgHitBit(FALSE);
+ speedF = 0.0f;
+ case 11:
+ if (mpModelMorf->checkFrame(5)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MK_V_FALL, -1);
+ }
+
+ if (mpModelMorf->isStop()) {
+ cXyz offset(-30.0f, -170.0f, -175.0f);
+ cLib_offsetPos(&current.pos, &current.pos, shape_angle.y, &offset);
+ old.pos = current.pos;
+ speed.y = -15.0f;
+ speedF = 8.0f;
+ current.angle.y = shape_angle.y + 0x8000;
+
+ setBck(ANM_LANDING, J3DFrameCtrl::LOOP_ONCE_e, 0.0f, 0.0f);
+ mMode = 12;
+
+ mBodySphCc[0].OnAtSetBit();
+ mBodySphCc[1].OnAtSetBit();
+ }
+ break;
+ case 12:
+ if (mAcch.i_ChkGroundHit()) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_MK_UMARU, 0, -1);
+ setMonkeyFallEffect();
+ dComIfGp_getVibration().StartShock(3, 31, cXyz(0.0f, 1.0f, 0.0f));
+
+ mBodySphCc[0].OffAtSetBit();
+ mBodySphCc[1].OffAtSetBit();
+
+ speedF = 0.0f;
+ mpModelMorf->setPlaySpeed(1.0f);
+ mMode = 13;
+ field_0x702 = 0;
+ setTgHitBit(TRUE);
+ field_0x6f0 = 120;
+ }
+ break;
+ case 13:
+ if (mpModelMorf->isStop()) {
+ setActionMode(ACT_MONKEY_DAMAGE, 5);
+ }
+ break;
+ }
}
/* 80648544-80648778 00A524 0234+00 1/1 0/0 0/0 .text executeMonkeyDamage__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeMonkeyDamage() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EDA8-8064EDAC 00028C 0004+00 0/0 0/0 0/0 .rodata @8452 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8452 = -170.0f;
-COMPILER_STRIP_GATE(0x8064EDA8, &lit_8452);
-#pragma pop
-
-/* 8064EDAC-8064EDB0 000290 0004+00 0/0 0/0 0/0 .rodata @8453 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8453 = -175.0f;
-COMPILER_STRIP_GATE(0x8064EDAC, &lit_8453);
-#pragma pop
-
-/* 8064EDB0-8064EDB4 000294 0004+00 0/2 0/0 0/0 .rodata @8683 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8683 = -200.0f;
-COMPILER_STRIP_GATE(0x8064EDB0, &lit_8683);
-#pragma pop
-
-/* 8064EDB4-8064EDB8 000298 0004+00 0/1 0/0 0/0 .rodata @8684 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8684 = 8192.0f;
-COMPILER_STRIP_GATE(0x8064EDB4, &lit_8684);
-#pragma pop
-
-/* 8064EDB8-8064EDBC 00029C 0004+00 0/1 0/0 0/0 .rodata @8685 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8685 = -1400.0f;
-COMPILER_STRIP_GATE(0x8064EDB8, &lit_8685);
-#pragma pop
-
-/* 8064EDBC-8064EDC0 0002A0 0004+00 0/1 0/0 0/0 .rodata @8686 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8686 = 39.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EDBC, &lit_8686);
-#pragma pop
+ switch (mMode) {
+ case 0:
+ if (setNextDamageMode(0)) {
+ setTgHitBit(FALSE);
+ return;
+ }
+
+ setBck(ANM_LANDING_DAMAGE, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ mMode = 1;
+ field_0x702 = 0;
+ case 1:
+ if (field_0x6f0 == 0) {
+ setTgHitBit(FALSE);
+ }
+
+ if (mpModelMorf->isStop()) {
+ setBck(ANM_LANDING_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 10;
+ }
+ break;
+ case 5:
+ case 6:
+ if (mMode == 5) {
+ field_0x6f0 = 100;
+ field_0x6ff = 0;
+ } else if (field_0x6f0 < 30) {
+ field_0x6f0 = 30;
+ }
+
+ setBck(ANM_LANDING_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mMode = 10;
+ field_0x702 = 0;
+ case 10:
+ if (mpModelMorf->checkFrame(1)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_MK_V_MGGG, -1);
+ }
+
+ if (field_0x6f0 == 0) {
+ setTgHitBit(FALSE);
+
+ if (!setNextDamageMode(1)) {
+ setNearPillarPos();
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
+ }
+ }
+ break;
+ }
+}
/* 80648778-80648F64 00A758 07EC+00 5/5 0/0 0/0 .text setLastWarp__10daB_ZANT_cFii */
-void daB_ZANT_c::setLastWarp(int param_0, int param_1) {
- // NONMATCHING
+void daB_ZANT_c::setLastWarp(int param_0, int i_warpID) {
+ mFlyWarpPosID = i_warpID;
+
+ if (mFightCycle == 0) {
+ if (health <= 400) {
+ mFightCycle = 1;
+ }
+ } else if (mFightCycle == 1 && health <= 200) {
+ mFightCycle = 2;
+ }
+
+ if (field_0x713 != mFightCycle) {
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+
+ if (mFightCycle == 2) {
+ field_0x6ec = 450;
+ field_0x71d = 1;
+ field_0x6ff = 0;
+ }
+ }
+
+ field_0x713 = mFightCycle;
+
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ s16 var_r28;
+
+ if (field_0x713 == 2 && param_0) {
+ if (field_0x703 <= 1 || field_0x6ff >= 3) {
+ if (field_0x71d == 1) {
+ param_0 = 3;
+ } else {
+ param_0 = 1;
+ }
+ } else {
+ if (cM_rnd() < 0.5f) {
+ param_0 = 3;
+ } else {
+ param_0 = 1;
+ }
+
+ if (field_0x71d == param_0) {
+ field_0x6ff++;
+ } else {
+ field_0x6ff = 0;
+ }
+ }
+
+ field_0x71d = param_0;
+ }
+
+ switch (param_0) {
+ case 0:
+ mFlyWarpPos.set(0.0f, 0.0f, 1000.0f);
+ field_0x70f = 0;
+ mDrawSwords = true;
+ mSwordSize = 1.0f;
+ break;
+ case 1:
+ if (field_0x713 == 0) {
+ field_0x70f = 0;
+
+ field_0x703++;
+ if (field_0x703 >= 3 && cM_rnd() < (field_0x703 / 10.0f) + 0.3f) {
+ field_0x70f = 10;
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+ }
+
+ field_0x704 = 0;
+
+ var_r28 = cM_atan2s(-player_pos.x, -200.0f - player_pos.z);
+ mFlyWarpPos.set(cM_ssin(var_r28) * 1000.0f, 0.0f, cM_scos(var_r28) * 1000.0f - 200.0f);
+ } else {
+ field_0x70f = 0;
+ field_0x703++;
+
+ if (field_0x713 != 2 && field_0x703 >= 3 && cM_rnd() < (field_0x703 / 10.0f) + 0.3f) {
+ field_0x70f = 10;
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+ }
+
+ field_0x704 = 0;
+ f32 var_f31 = cM_rndF(200.0f) + 300.0f;
+ var_r28 = daPy_getPlayerActorClass()->shape_angle.y + 0x8000;
+
+ if (field_0x70f == 10) {
+ var_f31 += 400.0f;
+ var_r28 = daPy_getPlayerActorClass()->shape_angle.y + cM_rndFX(2.9f) * 8192.0f;
+ } else if (dComIfGp_checkPlayerStatus0(0, 0x400)) {
+ var_f31 += 400.0f;
+ }
+
+ mFlyWarpPos.set(cM_ssin(var_r28) * var_f31, 0.0f, cM_scos(var_r28) * var_f31);
+ mFlyWarpPos += player_pos;
+
+ if (mFlyWarpPos.z > 1000.0f || mFlyWarpPos.z < -1400.0f || std::abs(mFlyWarpPos.x) > 1200.0f) {
+ var_r28 = cM_atan2s(-player_pos.x, -200.0f - player_pos.z);
+ mFlyWarpPos.set(cM_ssin(var_r28) * var_f31, 0.0f, cM_scos(var_r28) * var_f31);
+ mFlyWarpPos += player_pos;
+ }
+ }
+ break;
+ case 2: {
+ f32 var_f29 = player_pos.absXZ(current.pos);
+ s16 spE = cLib_targetAngleY(&player_pos, &current.pos);
+ s16 spC = cM_atan2s(-player_pos.x, -player_pos.z);
+
+ if ((s16)(spE - spC) < 0) {
+ var_r28 = spE + 0x2000;
+ } else {
+ var_r28 = spE - 0x2000;
+ }
+
+ if (var_f29 < 400.0f) {
+ var_f29 = 400.0f;
+ }
+
+ mFlyWarpPos.set(var_f29 * cM_ssin(var_r28), 0.0f, var_f29 * cM_scos(var_r28));
+ mFlyWarpPos += player_pos;
+ field_0x70f = 20;
+ break;
+ }
+ case 3:
+ f32 var_f30 = cM_rndF(200.0f) + 700.0f;
+ if (field_0x713 == 0) {
+ var_f30 += 400.0f;
+ var_r28 = cM_atan2s(-player_pos.x, -200.0f - player_pos.z);
+ } else {
+ var_f30 += 400.0f;
+ var_r28 = daPy_getPlayerActorClass()->shape_angle.y + cM_rndFX(3.9f) * 8192.0f;
+ }
+
+ mFlyWarpPos.set(cM_ssin(var_r28) * var_f30, 0.0f, cM_scos(var_r28) * var_f30);
+ mFlyWarpPos += player_pos;
+
+ if (mFlyWarpPos.z > 1000.0f || mFlyWarpPos.z < -1400.0f || std::abs(mFlyWarpPos.x) > 1200.0f) {
+ var_r28 = cM_atan2s(-player_pos.x, -200.0f - player_pos.z);
+ mFlyWarpPos.set(cM_ssin(var_r28) * var_f30, 0.0f, cM_scos(var_r28) * var_f30);
+ mFlyWarpPos += player_pos;
+ }
+
+ field_0x70f = 10;
+ field_0x704 = 1;
+ break;
+ }
+
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
}
/* 80648F64-806494A8 00AF44 0544+00 2/1 0/0 0/0 .text executeLastStartDemo__10daB_ZANT_cFv */
void daB_ZANT_c::executeLastStartDemo() {
- // NONMATCHING
+ dCamera_c* camera = dCam_getBody();
+ daPy_py_c* player = daPy_getPlayerActorClass();
+ cXyz sp1C;
+ cXyz sp28(0.0f, 0.0f, 0.0f);
+
+ switch (mMode) {
+ case 0:
+ if (!eventInfo.i_checkCommandDemoAccrpt()) {
+ fopAcM_orderPotentialEvent(this, 2, 0xFFFF, 0);
+ eventInfo.i_onCondition(2);
+ } else {
+ camera->Stop();
+ camera->SetTrimSize(3);
+ setBck(ANM_LAST_DEMO, J3DFrameCtrl::LOOP_ONCE_e, 10.0f, 1.0f);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_OP, 0, -1);
+ mpModelMorf->setPlaySpeed(0.0f);
+
+ gravity = -5.0f;
+ mModeTimer = 10;
+ mMode = 1;
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+ }
+ break;
+ case 1:
+ if (mModeTimer == 0) {
+ current.pos.set(0.0f, 480.0f, -1000.0f);
+ shape_angle.y = 0;
+ shape_angle.z = 0;
+ shape_angle.x = 0;
+ current.angle.y = -0x8000;
+ speedF = 0.0f;
+
+ mDemoCamEye.set(0.0f, 50.0f, -600.0f);
+ mDemoCamCenter.set(0.0f, 200.0f, -1000.0f);
+ mDemoCamBank = 60.0f;
+ mMode = 2;
+ return;
+ }
+ break;
+ case 2:
+ player->setPlayerPosAndAngle(&sp28, 0x8000, 0);
+
+ sp1C.set(0.0f, 90.0f, -900.0f);
+ cLib_addCalcPos(&mDemoCamCenter, sp1C, 0.2f, 5.0f, 1.0f);
+
+ if (mAcch.i_ChkGroundHit()) {
+ speed.y = 0.0f;
+ speedF = 0.0f;
+ dComIfGp_getVibration().StartShock(4, 31, cXyz(0.0f, 1.0f, 0.0f));
+ mpModelMorf->setPlaySpeed(1.0f);
+ mMode = 3;
+ }
+ break;
+ case 3:
+ sp1C = eyePos;
+ sp1C.y -= 30.0f;
+
+ cLib_addCalcPos(&mDemoCamCenter, sp1C, 0.5f, 50.0f, 1.0f);
+ if (mpModelMorf->checkFrame(97)) {
+ mMode = 4;
+ }
+ break;
+ case 4:
+ cLib_addCalc2(&mDemoCamBank, 72.0f, 0.3f, 1.0f);
+ sp1C = eyePos;
+ sp1C.y -= 30.0f;
+
+ cLib_addCalc2(&mDemoCamCenter.y, sp1C.y, 0.5f, 50.0f);
+ sp1C.y = mDemoCamCenter.y;
+
+ cLib_addCalcPosXZ(&mDemoCamCenter, sp1C, 0.5f, 3.0f, 1.0f);
+ if (mpModelMorf->checkFrame(103)) {
+ dComIfGp_getVibration().StartShock(2, 31, cXyz(0.0f, 1.0f, 0.0f));
+ mMode = 5;
+ }
+ break;
+ case 5:
+ cLib_addCalc2(&mDemoCamBank, 72.0f, 0.3f, 1.0f);
+ sp1C = eyePos;
+ sp1C.y = mDemoCamCenter.y;
+
+ cLib_addCalcPosXZ(&mDemoCamCenter, sp1C, 0.5f, 3.0f, 1.0f);
+ if (mpModelMorf->checkFrame(134)) {
+ mDrawSwords = true;
+ mMode = 6;
+ }
+ break;
+ case 6:
+ cLib_addCalc2(&mDemoCamCenter.y, 128.0f, 0.3f, 3.0f);
+ cLib_addCalc2(&mDemoCamBank, 55.0f, 0.3f, 3.0f);
+
+ if (mpModelMorf->isStop()) {
+ mFightCycle = 0;
+ field_0x713 = 0;
+ setActionMode(ACT_LAST_ATTACK, 0);
+ field_0x70b = 0;
+ attention_info.flags = 4;
+
+ mDemoCamEye.set(0.0f, 300.0f, 200.0f);
+ camera->Reset(mDemoCamCenter, mDemoCamEye);
+ camera->Start();
+ camera->SetTrimSize(0);
+ dComIfGp_event_reset();
+ return;
+ }
+ break;
+ }
+
+ camera->Set(mDemoCamCenter, mDemoCamEye, mDemoCamBank, 0);
}
/* 806494A8-8064A58C 00B488 10E4+00 2/1 0/0 0/0 .text executeLastAttack__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeLastAttack() {
- // NONMATCHING
+ s16 angle_to_player = fopAcM_searchPlayerAngleY(this);
+
+ switch (mMode) {
+ case 0:
+ gravity = -5.0f;
+
+ if (field_0x713 == 0) {
+ mMode = 1;
+ setBck(ANM_SW_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mModeTimer = 60;
+ } else {
+ mMode = 5;
+ }
+ break;
+ case 1:
+ if (mpModelMorf->checkFrame(2) || mpModelMorf->checkFrame(17)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_SWD_RUB, 0, -1);
+ }
+
+ if (checkAvoidWeapon(0)) {
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ setTgHitBit(FALSE);
+
+ field_0x71c++;
+ if (field_0x71c < 5) {
+ setLastWarp(2, 0);
+ } else {
+ field_0x703 = 7;
+ setLastWarp(1, 0);
+ }
+ } else {
+ cLib_addCalcAngleS2(&shape_angle.y, angle_to_player, 0x10, 0x400);
+ current.angle.y = shape_angle.y;
+
+ if (fopAcM_searchPlayerDistance(this) < 800.0f || mModeTimer == 0) {
+ mMode = 2;
+ setBck(ANM_SW_WALK, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ }
+ break;
+ case 2:
+ if (mpModelMorf->checkFrame(10) || mpModelMorf->checkFrame(26)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_FOOT, 0, -1);
+ }
+
+ if (checkAvoidWeapon(0)) {
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ setTgHitBit(FALSE);
+
+ field_0x71c++;
+ if (field_0x71c < 5) {
+ setLastWarp(2, 0);
+ } else {
+ field_0x703 = 7;
+ setLastWarp(1, 0);
+ }
+ } else {
+ cLib_addCalcAngleS2(&shape_angle.y, angle_to_player, 0x10, 0x400);
+ current.angle.y = shape_angle.y;
+ cLib_chaseF(&speedF, 5.0f, 1.0f);
+
+ if (fopAcM_searchPlayerDistance(this) < 500.0f) {
+ mMode = 5;
+ }
+ }
+ break;
+ case 5:
+ if (field_0x713 == 0) {
+ setBck(ANM_SW_ATTACK, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ mModeTimer = 200;
+ speedF = 5.0f;
+ } else {
+ setBck(ANM_SW_ATTACK_B, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ if (field_0x713 != 2) {
+ mModeTimer = cM_rndF(60.0f) + 60.0f;
+ } else {
+ mModeTimer = cM_rndF(15.0f) + 30.0f;
+ }
+
+ speedF = 10.0f;
+ }
+
+ mMode = 6;
+ field_0x6f8 = 0;
+ current.angle.y = shape_angle.y;
+
+ setTgType(2);
+ setTgHitBit(TRUE);
+ setTgShield(FALSE);
+ field_0x702 = 0;
+ case 6:
+ if (checkAvoidWeapon(FALSE)) {
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ setTgHitBit(FALSE);
+
+ field_0x71c++;
+ if (field_0x71c < 10) {
+ setLastWarp(2, 0);
+ } else {
+ field_0x703 = 7;
+ setLastWarp(1, 0);
+ }
+ } else {
+ cLib_chaseF(&mSwordSize, l_HIO.mSwordAttackSize, 0.1f);
+ cLib_addCalcAngleS2(&current.angle.y, angle_to_player, 8, 0x400);
+ cLib_addCalcAngleS2(&shape_angle.y, angle_to_player, 8, 0x400);
+
+ if (field_0x713 == 0) {
+ if (mpModelMorf->checkFrame(4) || mpModelMorf->checkFrame(24)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_SW_SWING_L, 0, -1);
+ } else if (mpModelMorf->checkFrame(7) || mpModelMorf->checkFrame(28)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_FOOT_L, 0, -1);
+ } else if (mpModelMorf->checkFrame(5)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_CTL_V_SW_ATK_A1, -1);
+ } else if (mpModelMorf->checkFrame(22)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_CTL_V_SW_ATK_A2, -1);
+ }
+
+ if (mpModelMorf->checkFrame(1)) {
+ mSwordCc[1].OnAtSetBit();
+ }
+
+ if (mpModelMorf->checkFrame(12)) {
+ mSwordCc[1].OffAtSetBit();
+ }
+
+ if (mpModelMorf->checkFrame(22)) {
+ mSwordCc[0].OnAtSetBit();
+ }
+
+ if (mpModelMorf->checkFrame(33)) {
+ mSwordCc[0].OffAtSetBit();
+ }
+ } else {
+ if (mpModelMorf->checkFrame(2) || mpModelMorf->checkFrame(20)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_SW_SWING_S1, 0, -1);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_CTL_V_SW_ATK_B1, -1);
+ } else if (mpModelMorf->checkFrame(11) || mpModelMorf->checkFrame(28)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_SW_SWING_S2, 0, -1);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_CTL_V_SW_ATK_B2, -1);
+ } else if (mpModelMorf->checkFrame(0) || mpModelMorf->checkFrame(9) || mpModelMorf->checkFrame(17) || mpModelMorf->checkFrame(26)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_CTL_FOOT, 0, -1);
+ }
+
+ if (mpModelMorf->checkFrame(1) || mpModelMorf->checkFrame(19)) {
+ mSwordCc[1].OnAtSetBit();
+ mSwordCc[0].OffAtSetBit();
+ }
+
+ if (mpModelMorf->checkFrame(9) || mpModelMorf->checkFrame(28)) {
+ mSwordCc[0].OnAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ }
+ }
+
+ if (mModeTimer == 0 && mpModelMorf->checkFrame(1)) {
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+ setTgHitBit(FALSE);
+ setLastWarp(1, 0);
+ }
+ }
+ break;
+ case 20:
+ if (fopAcM_searchPlayerDistance(this) < 500.0f) {
+ mMode = 5;
+ } else {
+ mMode = 2;
+ setBck(ANM_SW_WALK, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+ break;
+ case 10:
+ case 30:
+ dComIfGs_onOneZoneSwitch(1, fopAcM_GetRoomNo(this));
+ setBck(ANM_SPIN, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ if (field_0x704 == 0) {
+ if (field_0x713 != 2) {
+ field_0x6ec = 300;
+ field_0x71d = 1;
+ field_0x6ff = 0;
+ }
+ } else if (field_0x6ec < 30) {
+ field_0x6ec = 30;
+ }
+
+ if (field_0x713 == 0) {
+ mMode = 11;
+ } else {
+ mMode = 31;
+ }
+
+ current.angle.y = angle_to_player;
+
+ mRollCc.OnAtSetBit();
+ mRollCc.OnTgSetBit();
+ mRollCc.OnCoSetBit();
+ setTgType(0xD8FBFDFF);
+ setTgShield(TRUE);
+ setTgHitBit(TRUE);
+ field_0x6f8 = 0x3000;
+ speedF = 30.0f;
+ field_0x6fd = 0;
+ field_0x70b = 0;
+ case 11:
+ case 31: {
+ mSound.startCreatureVoiceLevel(Z2SE_EN_ZAN_CTL_V_SPIN_ATK, -1);
+ setLastRollEffect();
+
+ cLib_chaseF(&mSwordSize, l_HIO.mSwordAttackSize, 0.1f);
+
+ f32 var_f31 = 1.2f;
+ if (field_0x713 != 0) {
+ var_f31 = 1.5f;
+ }
+
+ if (field_0x70b != 0) {
+ if (mAcch.i_ChkGroundHit()) {
+ field_0x70b--;
+
+ if (field_0x70b != 0) {
+ speedF = 0.0f;
+ speed.y = 30.0f;
+ field_0x6ec = 0;
+ }
+ }
+ } else if (mMode == 11) {
+ int sp48 = abs((s16)(angle_to_player - current.angle.y));
+ if (sp48 > 0x4000) {
+ if (sp48 > 0x6800) {
+ cLib_chaseF(&speedF, -30.0f, var_f31 * 0.2f);
+ } else {
+ cLib_chaseF(&speedF, 5.0f, var_f31 * 0.2f);
+ }
+
+ cLib_addCalcAngleS2(&current.angle.y, angle_to_player + 0x8000, 0x10, var_f31 * 512.0f);
+ if (speedF < 0.0f && sp48 > 0x6000) {
+ current.angle.y += 0x8000;
+ speedF = -speedF;
+ }
+ } else {
+ if (sp48 > 0x1800) {
+ cLib_chaseF(&speedF, 10.0f, var_f31);
+ } else {
+ cLib_chaseF(&speedF, var_f31 * 30.0f, var_f31);
+ }
+
+ cLib_addCalcAngleS2(&current.angle.y, angle_to_player, 0x10, var_f31 * 768.0f);
+ }
+ } else {
+ cLib_chaseF(&speedF, var_f31 * 30.0f, var_f31 * 2.0f);
+ }
+
+ int sp3C = 0;
+ int sp40 = 0;
+ int sp44 = 0;
+ cCcD_Obj* sp48 = NULL;
+
+ if (mRollCc.ChkTgHit()) {
+ sp48 = mRollCc.GetTgHitObj();
+
+ if (sp48->ChkAtType(AT_TYPE_IRON_BALL)) {
+ sp40 = 1;
+ } else if (sp48->ChkAtType(AT_TYPE_NORMAL_SWORD)) {
+ daPy_py_c* player = daPy_getPlayerActorClass();
+ if (player->getCutType() == daPy_py_c::CUT_TYPE_TURN_RIGHT || player->getCutType() == daPy_py_c::CUT_TYPE_TURN_LEFT ||
+ player->getCutType() == daPy_py_c::CUT_TYPE_LARGE_TURN_LEFT || player->getCutType() == daPy_py_c::CUT_TYPE_LARGE_TURN_RIGHT)
+ {
+ sp40 = 1;
+ }
+ }
+
+ def_se_set(&mSound, mRollCc.GetTgHitObj(), 0x2A, this);
+ mRollCc.ClrTgHit();
+ } else if (mRollCc.ChkAtHit()) {
+ sp48 = mRollCc.GetAtHitObj();
+ if (!mRollCc.ChkAtShieldHit()) {
+ sp44 = 1;
+ }
+
+ mRollCc.ClrAtHit();
+ }
+
+ if (sp48 != NULL && fopAcM_GetName(dCc_GetAc(sp48->GetAc())) == PROC_ALINK) {
+ sp3C = 1;
+ field_0x6fd++;
+
+ if (sp40 != 0) {
+ speedF = -speedF;
+ field_0x70b = 2;
+ speed.y = 40.0f;
+ } else if (sp44 != 0) {
+ field_0x6fd += 5;
+ speedF = -45.0f;
+ } else {
+ speedF = -2.0f;
+ }
+ } else {
+ if (mAcch.ChkWallHit()) {
+ s16 sp8 = mAcchCir.GetWallAngleY();
+
+ if (speedF > 0.0f) {
+ if ((s16)cLib_distanceAngleS(sp8, current.angle.y) > 0x5800) {
+ current.angle.y = sp8 - 0x8000;
+ speedF *= 0.8f;
+ sp3C = 1;
+ field_0x6fd += 5;
+ }
+ } else {
+ if ((s16)cLib_distanceAngleS(sp8, current.angle.y) < 0x2800) {
+ current.angle.y = sp8 - (s16)(current.angle.y - sp8);
+ speedF *= 0.8f;
+ sp3C = 1;
+ field_0x6fd += 5;
+ }
+ }
+ }
+ }
+
+ if (sp3C != 0) {
+ if (mMode == 31 && field_0x6fd >= 5) {
+ mRollCc.OffAtSetBit();
+ mRollCc.OffTgSetBit();
+ mRollCc.OffCoSetBit();
+ setTgHitBit(FALSE);
+ setLastWarp(3, sp44);
+ return;
+ }
+
+ if (field_0x6ec < 10) {
+ field_0x6ec = 10;
+ mMode = 12;
+ }
+ }
+
+ cLib_chaseAngleS(&field_0x6f8, 0x3000, 0x80);
+ shape_angle.y += field_0x6f8;
+
+ if (field_0x6ec == 0) {
+ mMode = 12;
+ }
+ break;
+ }
+ case 12:
+ mSound.startCreatureVoiceLevel(Z2SE_EN_ZAN_CTL_V_SPIN_ATK, -1);
+ setLastRollEffect();
+
+ cLib_chaseF(&speedF, 0.0f, 1.0f);
+ cLib_chaseAngleS(&field_0x6f8, 0, 0x80);
+ shape_angle.y += field_0x6f8;
+
+ if (field_0x6f8 < 0x1000) {
+ mRollCc.OffAtSetBit();
+ mRollCc.OffTgSetBit();
+ mRollCc.OffCoSetBit();
+
+ setBck(ANM_SW_FATIGUE, J3DFrameCtrl::LOOP_REPEAT_e, 30.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_CTL_V_ZEIZEI, -1);
+ mMode = 13;
+ dComIfGs_offOneZoneSwitch(1, fopAcM_GetRoomNo(this));
+
+ if (field_0x713 == 2) {
+ field_0x6ec = 450;
+ }
+ }
+ break;
+ case 13:
+ if (field_0x6f8 < 0x800) {
+ field_0x702 = 0;
+ setTgShield(FALSE);
+ setTgHitBit(TRUE);
+
+ field_0x6f0 = 60;
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+ }
+
+ cLib_chaseF(&mSwordSize, 1.0f, 0.1f);
+ cLib_chaseF(&speedF, 0.0f, 1.0f);
+ cLib_chaseAngleS(&field_0x6f8, 0, 0x80);
+ shape_angle.y += field_0x6f8;
+
+ if (field_0x6f8 == 0) {
+ setActionMode(ACT_LAST_TIRED, 0);
+ }
+ break;
+ }
}
/* 8064A58C-8064A688 00C56C 00FC+00 1/1 0/0 0/0 .text executeLastTired__10daB_ZANT_cFv */
void daB_ZANT_c::executeLastTired() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EDC0-8064EDC4 0002A4 0004+00 0/0 0/0 0/0 .rodata @8793 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8793 = 480.0f;
-COMPILER_STRIP_GATE(0x8064EDC0, &lit_8793);
-#pragma pop
-
-/* 8064EDC4-8064EDC8 0002A8 0004+00 0/2 0/0 0/0 .rodata @8794 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8794 = -1000.0f;
-COMPILER_STRIP_GATE(0x8064EDC4, &lit_8794);
-#pragma pop
-
-/* 8064EDC8-8064EDCC 0002AC 0004+00 0/0 0/0 0/0 .rodata @8795 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8795 = -600.0f;
-COMPILER_STRIP_GATE(0x8064EDC8, &lit_8795);
-#pragma pop
-
-/* 8064EDCC-8064EDD0 0002B0 0004+00 0/0 0/0 0/0 .rodata @8796 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8796 = 90.0f;
-COMPILER_STRIP_GATE(0x8064EDCC, &lit_8796);
-#pragma pop
-
-/* 8064EDD0-8064EDD4 0002B4 0004+00 0/0 0/0 0/0 .rodata @8797 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8797 = -900.0f;
-COMPILER_STRIP_GATE(0x8064EDD0, &lit_8797);
-#pragma pop
-
-/* 8064EDD4-8064EDD8 0002B8 0004+00 0/0 0/0 0/0 .rodata @8798 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8798 = 97.0f;
-COMPILER_STRIP_GATE(0x8064EDD4, &lit_8798);
-#pragma pop
-
-/* 8064EDD8-8064EDDC 0002BC 0004+00 0/0 0/0 0/0 .rodata @8799 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8799 = 72.0f;
-COMPILER_STRIP_GATE(0x8064EDD8, &lit_8799);
-#pragma pop
-
-/* 8064EDDC-8064EDE0 0002C0 0004+00 0/0 0/0 0/0 .rodata @8800 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8800 = 103.0f;
-COMPILER_STRIP_GATE(0x8064EDDC, &lit_8800);
-#pragma pop
-
-/* 8064EDE0-8064EDE4 0002C4 0004+00 0/0 0/0 0/0 .rodata @8801 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8801 = 134.0f;
-COMPILER_STRIP_GATE(0x8064EDE0, &lit_8801);
-#pragma pop
-
-/* 8064EDE4-8064EDE8 0002C8 0004+00 0/0 0/0 0/0 .rodata @8802 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_8802 = 128.0f;
-COMPILER_STRIP_GATE(0x8064EDE4, &lit_8802);
-#pragma pop
-
-/* 8064EDE8-8064EDEC 0002CC 0004+00 0/0 0/0 0/0 .rodata @9164 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9164 = 33.0f;
-COMPILER_STRIP_GATE(0x8064EDE8, &lit_9164);
-#pragma pop
-
-/* 8064EDEC-8064EDF0 0002D0 0004+00 0/0 0/0 0/0 .rodata @9165 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9165 = 512.0f;
-COMPILER_STRIP_GATE(0x8064EDEC, &lit_9165);
-#pragma pop
-
-/* 8064EDF0-8064EDF4 0002D4 0004+00 0/0 0/0 0/0 .rodata @9166 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9166 = 768.0f;
-COMPILER_STRIP_GATE(0x8064EDF0, &lit_9166);
-#pragma pop
-
-/* 8064EDF4-8064EDF8 0002D8 0004+00 0/0 0/0 0/0 .rodata @9167 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9167 = -45.0f;
-COMPILER_STRIP_GATE(0x8064EDF4, &lit_9167);
-#pragma pop
-
-/* 8064EDF8-8064EDFC 0002DC 0004+00 0/1 0/0 0/0 .rodata @9168 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9168 = 4.0f / 5.0f;
-COMPILER_STRIP_GATE(0x8064EDF8, &lit_9168);
-#pragma pop
-
-/* 8064EDFC-8064EE00 0002E0 0004+00 0/1 0/0 0/0 .rodata @9306 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9306 = 38.0f;
-COMPILER_STRIP_GATE(0x8064EDFC, &lit_9306);
-#pragma pop
+ switch (mMode) {
+ case 0:
+ if (field_0x713 == 0) {
+ mModeTimer = 120;
+ } else if (field_0x713 == 1) {
+ mModeTimer = 90;
+ } else {
+ mModeTimer = 60;
+ }
+
+ field_0x6f0 = mModeTimer;
+ mMode = 5;
+ field_0x702 = 0;
+
+ setTgShield(FALSE);
+ setTgHitBit(TRUE);
+ field_0x71d = 0;
+ field_0x703 = 0;
+ field_0x71c = 0;
+ field_0x712 = 0;
+ case 5:
+ cLib_chaseF(&speedF, 0.0f, 1.0f);
+ if (mModeTimer == 0) {
+ setTgHitBit(FALSE);
+ setLastWarp(1, 0);
+ }
+ }
+}
/* 8064A688-8064AC20 00C668 0598+00 2/1 0/0 0/0 .text executeLastDamage__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeLastDamage() {
- // NONMATCHING
+ switch (mMode) {
+ case 0:
+ case 1:
+ case 2:
+ if (mLastAction == ACT_LAST_ATTACK) {
+ field_0x6f0 = 0;
+ }
+
+ if (field_0x6f0 == 0) {
+ setTgHitBit(FALSE);
+ } else {
+ setTgHitBit(TRUE);
+ }
+
+ mSwordCc[0].OffAtSetBit();
+ mSwordCc[1].OffAtSetBit();
+
+ speedF = 0.0f;
+ attention_info.flags = 4;
+
+ if (mTakenBigDmg) {
+ if (mFightCycle == 0) {
+ if (health < 400) {
+ health = 400;
+ }
+ } else if (mFightCycle == 1 && health < 200) {
+ health = 200;
+ }
+
+ mFightCycle++;
+ setTgHitBit(FALSE);
+ }
+
+ if (health <= 0 || mFightCycle >= 3) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ setActionMode(ACT_LAST_END_DEMO, 0);
+ return;
+ }
+
+ field_0x702 = 0;
+
+ if (mMode == 1) {
+ setBck(ANM_SW_DAMAGE_R, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else if (mMode == 2) {
+ setBck(ANM_SW_DAMAGE_L, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else if (cM_rnd() < 0.5f) {
+ setBck(ANM_SW_DAMAGE_L, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ } else {
+ setBck(ANM_SW_DAMAGE_R, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ }
+
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG, -1);
+ mMode = 5;
+ case 5: {
+ BOOL var_r28 = false;
+ if (checkBck(ANM_SW_DAMAGE_L)) {
+ if (mpModelMorf->checkFrame(17)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG_JITANDA, -1);
+ }
+
+ if (mLastAction == ACT_LAST_ATTACK) {
+ if (mpModelMorf->checkFrame(18)) {
+ var_r28 = true;
+ }
+ } else {
+ if (mpModelMorf->checkFrame(38)) {
+ var_r28 = true;
+ }
+ }
+
+ if (var_r28) {
+ setTgHitBit(FALSE);
+ field_0x71c++;
+ field_0x712++;
+
+ if (field_0x71c >= 5 || field_0x712 >= 3) {
+ field_0x703 = 7;
+ setLastWarp(1, 0);
+ } else if (mLastAction == ACT_LAST_ATTACK) {
+ setLastWarp(2, 0);
+ } else {
+ setLastWarp(1, 0);
+ }
+ }
+ } else {
+ if (mpModelMorf->checkFrame(19)) {
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_DMG_SHINARU, -1);
+ }
+
+ if (mLastAction == ACT_LAST_ATTACK) {
+ if (mpModelMorf->checkFrame(20)) {
+ var_r28 = true;
+ }
+ } else {
+ if (mpModelMorf->checkFrame(30)) {
+ var_r28 = true;
+ }
+ }
+
+ if (var_r28) {
+ setTgHitBit(FALSE);
+ field_0x71c++;
+ field_0x712++;
+
+ if (field_0x71c >= 5 || field_0x712 >= 3) {
+ field_0x703 = 7;
+ setLastWarp(1, 0);
+ } else if (mLastAction == ACT_LAST_ATTACK) {
+ setLastWarp(2, 0);
+ } else {
+ setLastWarp(1, 0);
+ }
+ }
+ }
+ break;
+ }
+ case 10:
+ attention_info.flags = 4;
+ setBck(ANM_GROUND_REACTION, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureVoice(Z2SE_EN_ZAN_V_NO_DMG, -1);
+ mMode = 11;
+ speedF = 0.0f;
+ break;
+ case 11:
+ if (mpModelMorf->isStop()) {
+ setTgHitBit(FALSE);
+ setLastWarp(1, 0);
+ }
+ break;
+ case 20:
+ setBck(ANM_FAINT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ speedF = 0.0f;
+ speed.y = 0.0f;
+ field_0x702 = 0;
+ mModeTimer = 20;
+ mMode = 21;
+ case 21:
+ if (mModeTimer == 0) {
+ setTgHitBit(FALSE);
+ setLastWarp(1, 0);
+ }
+ break;
+ }
}
/* 8064AC20-8064AC8C 00CC00 006C+00 1/1 0/0 0/0 .text s_del_tp__FPvPv */
-static void s_del_tp(void* param_0, void* param_1) {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EE00-8064EE04 0002E4 0004+00 0/2 0/0 0/0 .rodata @9432 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9432 = 120.0f;
-COMPILER_STRIP_GATE(0x8064EE00, &lit_9432);
-#pragma pop
-
-/* 8064EE04-8064EE08 0002E8 0004+00 0/1 0/0 0/0 .rodata @9433 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9433 = -750.0f;
-COMPILER_STRIP_GATE(0x8064EE04, &lit_9433);
-#pragma pop
-
-/* 8064EE08-8064EE0C 0002EC 0004+00 0/1 0/0 0/0 .rodata @9434 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9434 = 80.0f;
-COMPILER_STRIP_GATE(0x8064EE08, &lit_9434);
-#pragma pop
-
-/* 8064EE0C-8064EE10 0002F0 0004+00 0/1 0/0 0/0 .rodata @9435 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9435 = 44.0f;
-COMPILER_STRIP_GATE(0x8064EE0C, &lit_9435);
-#pragma pop
-
-/* 8064EE10-8064EE14 0002F4 0004+00 0/1 0/0 0/0 .rodata @9436 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9436 = 205.0f;
-COMPILER_STRIP_GATE(0x8064EE10, &lit_9436);
-#pragma pop
-
-/* 8064EE14-8064EE18 0002F8 0004+00 0/1 0/0 0/0 .rodata @9437 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9437 = 230.0f;
-COMPILER_STRIP_GATE(0x8064EE14, &lit_9437);
-#pragma pop
-
-/* 8064EE18-8064EE1C 0002FC 0004+00 0/1 0/0 0/0 .rodata @9438 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9438 = 150.0f;
-COMPILER_STRIP_GATE(0x8064EE18, &lit_9438);
-#pragma pop
-
-/* 8064EE1C-8064EE20 000300 0004+00 0/1 0/0 0/0 .rodata @9439 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9439 = 340.0f;
-COMPILER_STRIP_GATE(0x8064EE1C, &lit_9439);
-#pragma pop
-
-/* 8064EE20-8064EE24 000304 0004+00 0/1 0/0 0/0 .rodata @9440 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9440 = 360.0f;
-COMPILER_STRIP_GATE(0x8064EE20, &lit_9440);
-#pragma pop
-
-/* 8064EE24-8064EE28 000308 0004+00 0/1 0/0 0/0 .rodata @9441 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9441 = 375.0f;
-COMPILER_STRIP_GATE(0x8064EE24, &lit_9441);
-#pragma pop
-
-/* 8064EE60-8064EE60 000344 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */
-#pragma push
-#pragma force_active on
-SECTION_DEAD static char const* const stringBase_8064EE7C = "D_MN08A";
-#pragma pop
+static void* s_del_tp(void* i_actor, void* i_data) {
+ if (fopAcM_IsActor(i_actor)) {
+ if (!fpcM_IsCreating(fopAcM_GetID(i_actor)) && fopAcM_GetName(i_actor) == PROC_OBJ_TP) {
+ fopAcM_delete((fopAc_ac_c*)i_actor);
+ }
+ }
+
+ return NULL;
+}
/* 8064AC8C-8064B270 00CC6C 05E4+00 1/1 0/0 0/0 .text executeLastEndDemo__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeLastEndDemo() {
- // NONMATCHING
+ dCamera_c* camera = dCam_getBody();
+ daPy_py_c* player = daPy_getPlayerActorClass();
+ cXyz sp34;
+ cXyz sp40;
+
+ switch (mMode) {
+ case 0:
+ if (!eventInfo.i_checkCommandDemoAccrpt()) {
+ fopAcM_orderPotentialEvent(this, 2, 0xFFFF, 0);
+ eventInfo.i_onCondition(2);
+ return;
+ }
+
+ mDrawSwords = false;
+ camera->Stop();
+ camera->SetTrimSize(3);
+
+ setBck(ANM_DIE_DEMO, J3DFrameCtrl::LOOP_ONCE_e, 3.0f, 1.0f);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_END, 0, -1);
+ Z2GetAudioMgr()->bgmStop(30, 0);
+ fpcM_Search(s_del_tp, this);
+ speedF = 0.0f;
+
+ mDemoCamCenter.set(0.0f, 120.0f, -1000.0f);
+ mDemoCamEye.set(0.0f, 50.0f, -750.0f);
+ mDemoCamBank = 80.0f;
+
+ mMode = 1;
+ field_0x6ba = 0x2F00;
+ field_0x6bc = 0.0f;
+ dComIfGs_onStageBossEnemy();
+ return;
+ case 1:
+ case 2:
+ if (mMode == 1) {
+ cXyz sp4C(0.0f, 0.0f, 0.0f);
+ player->setPlayerPosAndAngle(&sp4C, 0x8000, 0);
+
+ current.pos.set(0.0f, 0.0f, -1000.0f);
+ shape_angle.z = 0;
+ shape_angle.x = 0;
+ shape_angle.y = 0;
+ sp34 = mDemoCamCenter;
+ mMode = 2;
+ } else {
+ sp34 = eyePos;
+ sp34.y -= 44.0f;
+ }
+
+ {
+ f32 var_f31 = mpModelMorf->getFrame();
+ if ((80 <= var_f31 && var_f31 <= 120) || (175 <= var_f31 && var_f31 <= 205)) {
+ cLib_addCalcPos(&mDemoCamCenter, sp34, 0.1f, 3.0f, 1.0f);
+ } else {
+ cLib_addCalcPos(&mDemoCamCenter, sp34, 0.5f, 30.0f, 1.0f);
+ }
+ }
+
+ cLib_addCalcAngleS(&field_0x6ba, 0, 0x10, 0x40, 0x10);
+
+ sp34.set(0.0f, 50.0f, -1000.0f);
+ sp40.set(0.0f, field_0x6bc, 250.0f);
+ cLib_offsetPos(&mDemoCamEye, &sp34, field_0x6ba, &sp40);
+
+ if (mpModelMorf->checkFrame(230)) {
+ dComIfGp_getVibration().StartShock(4, 31, cXyz(0.0f, 1.0f, 0.0f));
+ }
+
+ if (mpModelMorf->checkFrame(250)) {
+ mMode = 3;
+ }
+ break;
+ case 3:
+ cLib_addCalcAngleS(&field_0x6ba, 0, 0x10, 0x40, 0x10);
+ cLib_addCalc2(&field_0x6bc, 250.0f, 0.1f, 3.0f);
+ sp34.set(0.0f, 300.0f, -1000.0f);
+ sp40.set(0.0f, 0.0f, 150.0f);
+
+ {
+ cXyz sp58;
+ cLib_offsetPos(&sp58, &sp34, field_0x6ba, &sp40);
+ cLib_addCalcPos(&mDemoCamEye, sp58, 0.1f, 4.0f, 1.0f);
+ }
+
+ sp34 = eyePos;
+ cLib_addCalcPos(&mDemoCamCenter, sp34, 0.1f, 0.8f, 1.0f);
+
+ if (mpModelMorf->checkFrame(340)) {
+ mpModelMorf->setFrame(300);
+ mMode = 14;
+
+ mDemoCamEye.set(0.0f, 5.0f, -800.0f);
+ field_0x6bc = 30.0f;
+ mDemoCamCenter = eyePos;
+ mDemoCamCenter.y -= field_0x6bc;
+ mDemoCamBank = 80.0f;
+ }
+ break;
+ case 14:
+ mDemoCamCenter = eyePos;
+ mDemoCamCenter.y -= field_0x6bc;
+
+ if (mpModelMorf->checkFrame(360)) {
+ mpModelMorf->setPlaySpeed(0.5f);
+ mMode = 15;
+ }
+ break;
+ case 15:
+ if (mpModelMorf->checkFrame(375)) {
+ dComIfGp_setNextStage("D_MN08A", 25, 10, 9);
+ }
+
+ mDemoCamCenter = eyePos;
+ mDemoCamCenter.y -= field_0x6bc;
+
+ cLib_chaseF(&field_0x6bc, 0.0f, 1.0f);
+ cLib_chaseF(&mDemoCamBank, 80.0f, 0.5f);
+ break;
+ }
+
+ camera->Set(mDemoCamCenter, mDemoCamEye, mDemoCamBank, 0);
}
/* 8064B270-8064B49C 00D250 022C+00 1/1 0/0 0/0 .text calcMahojinAnime__10daB_ZANT_cFv */
void daB_ZANT_c::calcMahojinAnime() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EE28-8064EE2C 00030C 0004+00 0/1 0/0 0/0 .rodata @9560 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9560 = 87.0f;
-COMPILER_STRIP_GATE(0x8064EE28, &lit_9560);
-#pragma pop
-
-/* 8064EE2C-8064EE30 000310 0004+00 0/1 0/0 0/0 .rodata @9561 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9561 = -160.0f;
-COMPILER_STRIP_GATE(0x8064EE2C, &lit_9561);
-#pragma pop
-
-/* 8064EE30-8064EE34 000314 0004+00 0/1 0/0 0/0 .rodata @9562 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9562 = 106.0f;
-COMPILER_STRIP_GATE(0x8064EE30, &lit_9562);
-#pragma pop
-
-/* 8064EE34-8064EE38 000318 0004+00 0/1 0/0 0/0 .rodata @9563 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9563 = 483.0f;
-COMPILER_STRIP_GATE(0x8064EE34, &lit_9563);
-#pragma pop
-
-/* 8064EE38-8064EE3C 00031C 0004+00 0/1 0/0 0/0 .rodata @9564 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9564 = 843.0f;
-COMPILER_STRIP_GATE(0x8064EE38, &lit_9564);
-#pragma pop
-
-/* 8064EE3C-8064EE40 000320 0004+00 0/1 0/0 0/0 .rodata @9565 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9565 = -20.0f;
-COMPILER_STRIP_GATE(0x8064EE3C, &lit_9565);
-#pragma pop
-
-/* 8064EE40-8064EE44 000324 0004+00 0/1 0/0 0/0 .rodata @9566 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9566 = -40.0f;
-COMPILER_STRIP_GATE(0x8064EE40, &lit_9566);
-#pragma pop
-
-/* 8064EE44-8064EE48 000328 0004+00 0/1 0/0 0/0 .rodata @9567 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9567 = 11.0f / 10.0f;
-COMPILER_STRIP_GATE(0x8064EE44, &lit_9567);
-#pragma pop
+ switch (mMahojinAnmMode) {
+ case 1:
+ mpMahojinStartBtk->setPlaySpeed(1.0f);
+ mpMahojinStartBtk->setFrame(0);
+ mpMahojinBrk->setPlaySpeed(0.0f);
+ mpMahojinBrk->setFrame(0);
+ mMahojinAnmMode = 2;
+ case 2:
+ if (mpMahojinStartBtk->checkFrame(9)) {
+ mMahojin2AnmMode = 1;
+ }
+
+ if (mpMahojinStartBtk->isStop()) {
+ mMahojinAnmMode = 3;
+ }
+ break;
+ case 3:
+ break;
+ case 4:
+ mpMahojinBrk->setPlaySpeed(1.0f);
+ mMahojinAnmMode = 5;
+ case 5:
+ if (mpMahojinBrk->isStop()) {
+ mMahojinAnmMode = 0;
+ }
+ break;
+ }
+
+ switch (mMahojin2AnmMode) {
+ case 0:
+ mpMahojinBrk2->setPlaySpeed(0.0f);
+ mpMahojinBrk2->setFrame(30);
+ mpMahojinStartBtk2->setFrame(19);
+ mMahojin2Size = 1.0f;
+ break;
+ case 1:
+ mpMahojinBrk2->setPlaySpeed(0.5f);
+ cLib_chaseF(&mMahojin2Size, 10.0f, 0.1f);
+
+ if (mpMahojinBrk2->isStop()) {
+ mMahojin2AnmMode = 0;
+ mpMahojinBrk2->init(mpMahojinModel2->getModelData(), (J3DAnmTevRegKey*)dComIfG_getObjectRes("B_zan", 0x4F), TRUE, J3DFrameCtrl::LOOP_ONCE_e, 0.0f, 0, -1);
+ }
+ }
+}
/* 8064B49C-8064B69C 00D47C 0200+00 2/2 0/0 0/0 .text calcRoomChangeCamera__10daB_ZANT_cFi */
void daB_ZANT_c::calcRoomChangeCamera(int param_0) {
- // NONMATCHING
+ cXyz eye_target(-100.0f, 87.0f, -160.0f);
+ cXyz center_target(106.0f, 483.0f, 843.0f);
+
+ if (param_0 == 1) {
+ cXyz sp38(-20.0f, -40.0f, -100.0f);
+ eye_target += sp38;
+ center_target += sp38;
+ }
+
+ if (mFightPhase == PHASE_OP) {
+ eye_target.x += 140.0f;
+ center_target.x += 140.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(eye_target);
+ mDoMtx_stack_c::multVecZero(&eye_target);
+
+ eye_target.y += 250.0f;
+ eye_target.z -= 800.0f;
+
+ mDoMtx_stack_c::YrotS(-0x8000);
+ mDoMtx_stack_c::transM(center_target);
+ mDoMtx_stack_c::multVecZero(&center_target);
+
+ center_target.y += 250.0f;
+ center_target.z -= 800.0f;
+ }
+
+ switch (param_0) {
+ case 0:
+ mDemoCamBank = 58.0f;
+ cLib_chaseF(&field_0x77c, 30.0f, 1.0f);
+ cLib_addCalcPos(&mDemoCamEye, eye_target, 0.3f, field_0x77c * 1.1f, 3.0f);
+ cLib_addCalcPos(&mDemoCamCenter, center_target, 0.3f, field_0x77c, 3.0f);
+ break;
+ case 1:
+ cLib_addCalcPos(&mDemoCamEye, eye_target, 0.2f, 15.0f, 3.0f);
+ cLib_addCalcPos(&mDemoCamCenter, center_target, 0.2f, 15.0f, 3.0f);
+ break;
+ }
}
-/* ############################################################################################## */
-/* 8064EE48-8064EE4C 00032C 0004+00 0/1 0/0 0/0 .rodata @9604 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9604 = -3300.0f;
-COMPILER_STRIP_GATE(0x8064EE48, &lit_9604);
-#pragma pop
-
/* 8064B69C-8064B868 00D67C 01CC+00 3/3 0/0 0/0 .text initNextRoom__10daB_ZANT_cFv */
void daB_ZANT_c::initNextRoom() {
- // NONMATCHING
+ field_0x70f = 0;
+ field_0x6f0 = 0;
+ field_0x70e = 0;
+ mDrawSwords = false;
+
+ setTgType(0xD8FBFDFF);
+ mBodySphCc[0].OffTgNoHitMark();
+ mBodySphCc[1].OffTgNoHitMark();
+
+ dComIfGs_offSaveDunSwitch(20);
+ dComIfGs_offSaveDunSwitch(21);
+ dComIfGs_offSaveDunSwitch(22);
+
+ if (mFightPhase != PHASE_LAST) {
+ health = 280;
+ } else {
+ health = field_0x560;
+ }
+
+ mAcchCir.SetWall(100.0f, 100.f);
+
+ if (mFightPhase == PHASE_MG) {
+ attention_info.distances[fopAc_attn_BATTLE_e] = 4;
+ } else {
+ attention_info.distances[fopAc_attn_BATTLE_e] = 24;
+ }
+
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[0], &pmobile);
+
+ if (mFightPhase == PHASE_OI) {
+ fopAcM_OnStatus(this, 0x80000);
+
+ if (pmobile == NULL) {
+ cXyz pos(0.0f, -3300.0f, 0.0f);
+ for (int i = 0; i < 4; i++) {
+ mMobileIDs[i] = fopAcM_create(PROC_B_ZANTZ, i | 0xFFFFFF00, &pos, warp_next_room[mFightPhase], &shape_angle, NULL, -1);
+ }
+
+ mCorrectMobileNo = 0;
+ }
+ } else {
+ fopAcM_OffStatus(this, 0x80000);
+
+ if (pmobile != NULL) {
+ fopAcM_delete(pmobile);
+ mMobileIDs[0] = fpcM_ERROR_PROCESS_ID_e;
+ }
+ }
+
+ tevStr.mRoomNo = warp_next_room[mFightPhase];
}
/* 8064B868-8064C1C0 00D848 0958+00 2/1 0/0 0/0 .text executeRoomChange__10daB_ZANT_cFv
*/
void daB_ZANT_c::executeRoomChange() {
- // NONMATCHING
+ dCamera_c* camera = dCam_getBody();
+ cXyz sp34(0.0f, 0.0f, 0.0f);
+ daPy_py_c* player = daPy_getPlayerActorClass();
+
+ switch (mMode) {
+ case 0:
+ setTgHitBit(FALSE);
+ if (!eventInfo.i_checkCommandDemoAccrpt()) {
+ fopAcM_orderPotentialEvent(this, 2, 0xFFFF, 0);
+ eventInfo.i_onCondition(2);
+ return;
+ }
+
+ camera->Stop();
+ camera->SetTrimSize(3);
+
+ mDemoCamCenter = dCam_getBody()->Center();
+ mDemoCamEye = dCam_getBody()->Eye();
+ mDemoCamBank = dCam_getBody()->Fovy();
+
+ field_0x705 = 0;
+ mMode = 1;
+
+ if (mFightPhase != PHASE_MK) {
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+ }
+
+ dComIfGp_particle_set(0x88FE, &current.pos, &shape_angle, NULL);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_OUT, 0, -1);
+ break;
+ case 1:
+ if (calcScale(0)) {
+ mMode = 4;
+ mModeTimer = l_HIO.mDemoWarpTime;
+ }
+ break;
+ case 4:
+ if (mModeTimer == 0) {
+ mMode = 10;
+ mModeTimer = 15;
+
+ current.pos.set(-140.0f, 300.0f, 700.0f);
+ old.pos = current.pos;
+ speedF = 0.0f;
+ speed.y = 0.0f;
+ gravity = 0.0f;
+
+ shape_angle.x = 0;
+ current.angle.y = 0x8000;
+ shape_angle.y = 0x8000;
+
+ setBck(ANM_FLOAT_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+ player->changeOriginalDemo();
+ player->changeDemoPos0(&sp34);
+ player->changeDemoMode(0x17, 1, 4, 0);
+
+ mDemoCamBank = 65.0f;
+ mDemoCamEye.set(-225.0f, 344.0f, 382.0f);
+ mDemoCamCenter.set(118.0f, 672.0f, 1374.0f);
+
+ Z2GetAudioMgr()->changeBgmStatus(13);
+ field_0x77c = 0.0f;
+
+ calcRoomChangeCamera(0);
+
+ if (mFightPhase == PHASE_OI) {
+ for (int i = 0; i < 4; i++) {
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[i], &pmobile);
+
+ if (pmobile != NULL) {
+ fopAcM_delete(pmobile);
+ mMobileIDs[i] = fpcM_ERROR_PROCESS_ID_e;
+ }
+ }
+ }
+ field_0x6fc = 1;
+ }
+ break;
+ case 10:
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (mModeTimer == 0) {
+ dComIfGp_particle_set(0x88FE, &current.pos, &shape_angle, NULL);
+ mSound.startCreatureSound(Z2SE_EN_ZAN_WARP_IN, 0, -1);
+ mMode = 11;
+ }
+ break;
+ case 11:
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (calcScale(1)) {
+ mMode = 12;
+ mModeTimer = 20;
+ }
+ break;
+ case 12:
+ if (mModeTimer == 0) {
+ mMode = 13;
+ mModeTimer = 50;
+ }
+ break;
+ case 13:
+ calcRoomChangeCamera(0);
+
+ if (mModeTimer == 0) {
+ mMode = 14;
+ setBck(ANM_FLOAT_APPEAR_SHORT, J3DFrameCtrl::LOOP_ONCE_e, 5.0f, 1.0f);
+ field_0x714 = 1;
+ mKankyoBlend = 0.0f;
+
+ static u32 mahojin_se[] = {
+ Z2SE_EN_ZAN_MAHOJIN_BB,
+ Z2SE_EN_ZAN_MAHOJIN_MG,
+ Z2SE_EN_ZAN_MAHOJIN_OI,
+ Z2SE_EN_ZAN_MAHOJIN_MK,
+ Z2SE_EN_ZAN_MAHOJIN_YO,
+ Z2SE_EN_ZAN_MAHOJIN_CTL,
+ };
+
+ mSound.startCreatureSound(mahojin_se[mFightPhase], 0, -1);
+ }
+ break;
+ case 14:
+ cLib_chaseF(&mKankyoBlend, 1.0f, 0.02f);
+
+ if (mpModelMorf->checkFrame(42)) {
+ mMahojinAnmMode = 1;
+ Z2GetAudioMgr()->changeBgmStatus(mFightPhase + PHASE_MAX);
+ }
+
+ if (mpModelMorf->checkFrame(42)) {
+ field_0x715 = 30;
+ }
+
+ shape_angle.y = fopAcM_searchPlayerAngleY(this);
+ shape_angle.x = -fopAcM_searchPlayerAngleX(this) * 0.5f;
+
+ if (mpModelMorf->isStop()) {
+ dComIfGp_getVibration().StopQuake(0x1F);
+ setBck(ANM_FLOAT_APPEAR_WAIT, J3DFrameCtrl::LOOP_REPEAT_e, 3.0f, 1.0f);
+
+ mFightPhase++;
+ if (mFightPhase >= PHASE_MAX) {
+ mFightPhase = PHASE_OP;
+ }
+
+ mMode = 15;
+ mModeTimer = l_HIO.mMahojinWaitTime;
+
+ initNextRoom();
+ cXyz pos(0.0f, 0.0f, 0.0f);
+ dComIfGs_setRestartRoom(pos, 0, warp_next_room[mFightPhase]);
+ }
+ break;
+ case 15:
+ if (mModeTimer == 0 && dComIfGp_roomControl_checkStatusFlag(warp_next_room[mFightPhase], 0x10)) {
+ mMode = 16;
+ field_0x714 = 0;
+ mKankyoBlend = 0.0f;
+
+ setBck(ANM_FLOAT_WAIT_RETURN, J3DFrameCtrl::LOOP_ONCE_e, 5.0f, 1.0f);
+ mMahojinAnmMode = 4;
+ }
+ break;
+ case 16:
+ cLib_chaseF(&mKankyoBlend, 1.0f, 0.02f);
+ player->setPlayerPosAndAngle(&sp34, 0, 0);
+
+ if (mpModelMorf->isStop()) {
+ if (mFightPhase != PHASE_LAST) {
+ camera->Reset(mDemoCamCenter, mDemoCamEye);
+ camera->Start();
+ camera->SetTrimSize(0);
+ dComIfGp_event_reset();
+ }
+
+ field_0x6fc = 0;
+ setTgHitBit(TRUE);
+ setBaseActionMode(1);
+ return;
+ }
+ break;
+ }
+
+ if (field_0x715 != 0) {
+ calcRoomChangeCamera(1);
+ field_0x715--;
+ }
+
+ camera->Set(mDemoCamCenter, mDemoCamEye, mDemoCamBank, 0);
}
/* 8064C1C0-8064C5A8 00E1A0 03E8+00 8/7 0/0 0/0 .text setBaseActionMode__10daB_ZANT_cFi
*/
void daB_ZANT_c::setBaseActionMode(int param_0) {
- // NONMATCHING
+ switch (mFightPhase) {
+ case PHASE_BB:
+ if (param_0 == 0) {
+ if (field_0x70c == 0) {
+ setActionMode(ACT_FLY, 0);
+ } else {
+ setActionMode(ACT_FLY_GROUND, 0);
+ }
+ } else if (param_0 == 1) {
+ field_0x70b = 1;
+ mFlyWarpPosID = 0;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID];
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 1);
+ } else {
+ field_0x70c = 0;
+ gravity = 0.0f;
+ mFlyWarpPosID = (f32)mFlyWarpPosID + cM_rndF(1.9f) + 1.0f;
+ mFlyWarpPos = fly_warp_pos[mFlyWarpPosID % 3];
+ field_0x711 = 2;
+ setActionMode(ACT_WARP, 1);
+ }
+ break;
+ case PHASE_MG:
+ if (param_0 == 0) {
+ setActionMode(ACT_SIMA_JUMP, 0);
+ } else if (param_0 == 1) {
+ gravity = -5.0f;
+ mFlyWarpPosID = 0;
+ mFlyWarpPos.set(0.0f, 1000.0f, 1100.0f);
+ field_0x6b8 = 0x8000;
+ field_0x711 = 3;
+ setActionMode(ACT_WARP, 0);
+ } else {
+ setActionMode(ACT_SIMA_JUMP, 11);
+ }
+ break;
+ case PHASE_YO:
+ if (param_0 == 0) {
+ setActionMode(ACT_ICE_DEMO, 100);
+ } else if (param_0 == 1) {
+ setActionMode(ACT_ICE_DEMO, 0);
+ } else {
+ setActionMode(ACT_ICE_DAMAGE, 30);
+ }
+
+ mModeTimer = 0;
+ break;
+ case PHASE_OI:
+ if (param_0 == 0) {
+ setActionMode(ACT_WATER, 0);
+ } else {
+ fopAc_ac_c* pmobile;
+ fopAcM_SearchByID(mMobileIDs[mCorrectMobileNo], &pmobile);
+
+ s16 var_r27 = shape_angle.y;
+ cXyz sp44(current.pos);
+ sp44.y = -4000.0f;
+
+ if (pmobile != NULL) {
+ var_r27 = pmobile->shape_angle.y;
+ sp44.set(cM_ssin(var_r27) * 300.0f, 300.0f, cM_scos(var_r27) * 300.0f);
+ sp44 += pmobile->current.pos;
+ }
+
+ attention_info.flags = 0;
+ field_0x6b8 = var_r27;
+ mFlyWarpPos = sp44;
+ field_0x705 = 1;
+ field_0x711 = 1;
+ setActionMode(ACT_WARP, 0);
+ }
+ break;
+ case PHASE_MK:
+ if (param_0 == 0) {
+ setActionMode(ACT_MONKEY, 0);
+ } else if (param_0 == 1) {
+ setActionMode(ACT_MONKEY, 100);
+ } else {
+ setNearPillarPos();
+ field_0x711 = 0;
+ setActionMode(ACT_WARP, 1);
+ }
+ break;
+ case PHASE_LAST:
+ if (param_0 == 0) {
+ setActionMode(ACT_LAST_ATTACK, field_0x70f);
+ } else if (param_0 == 1) {
+ if (field_0x718 == 0) {
+ setActionMode(ACT_LAST_START_DEMO, 0);
+ } else {
+ setLastWarp(0, 0);
+ }
+ }
+ break;
+ case PHASE_OP:
+ setActionMode(ACT_OPENING, 0);
+ executeOpening();
+ break;
+ }
}
/* 8064C5A8-8064CB1C 00E588 0574+00 2/1 0/0 0/0 .text action__10daB_ZANT_cFv */
void daB_ZANT_c::action() {
- // NONMATCHING
+ if (mFightPhase == PHASE_YO) {
+ ice_damage_check();
+ } else {
+ damage_check();
+ }
+
+ switch (mAction) {
+ case ACT_SMALL_ATTACK:
+ executeSmallAttack();
+ break;
+ case ACT_WARP:
+ executeWarp();
+ break;
+ case ACT_DAMAGE:
+ executeDamage();
+ break;
+ case ACT_CONFUSE:
+ executeConfuse();
+ break;
+ case ACT_OPENING:
+ executeOpening();
+ break;
+ case ACT_FLY:
+ executeFly();
+ break;
+ case ACT_FLY_GROUND:
+ executeFlyGround();
+ break;
+ case ACT_WATER:
+ executeWater();
+ break;
+ case ACT_HOOK:
+ executeHook();
+ break;
+ case ACT_SWIM:
+ executeSwim();
+ break;
+ case ACT_SIMA_JUMP:
+ executeSimaJump();
+ break;
+ case ACT_ICE_DEMO:
+ executeIceDemo();
+ break;
+ case ACT_ICE_JUMP:
+ executeIceJump();
+ break;
+ case ACT_ICE_STEP:
+ executeIceStep();
+ break;
+ case ACT_ICE_DAMAGE:
+ executeIceDamage();
+ break;
+ case ACT_MONKEY:
+ executeMonkey();
+ break;
+ case ACT_MONKEY_FALL:
+ executeMonkeyFall();
+ break;
+ case ACT_MONKEY_DAMAGE:
+ executeMonkeyDamage();
+ break;
+ case ACT_LAST_START_DEMO:
+ executeLastStartDemo();
+ break;
+ case ACT_LAST_ATTACK:
+ executeLastAttack();
+ break;
+ case ACT_LAST_TIRED:
+ executeLastTired();
+ break;
+ case ACT_LAST_DAMAGE:
+ executeLastDamage();
+ break;
+ case ACT_LAST_END_DEMO:
+ executeLastEndDemo();
+ break;
+ case ACT_ROOM_CHANGE:
+ executeRoomChange();
+ break;
+ }
+
+ if (mAction != ACT_OPENING) {
+ daPy_getPlayerActorClass()->onBossRoomWait();
+ }
+
+ cXyz sp40(0.0f, 0.0f, 0.0f);
+
+ switch (mFightPhase) {
+ case PHASE_BB:
+ if (field_0x70c == 0) {
+ dComIfGs_onOneZoneSwitch(0, fopAcM_GetRoomNo(this));
+ } else {
+ dComIfGs_offOneZoneSwitch(0, fopAcM_GetRoomNo(this));
+ }
+ break;
+ case PHASE_MG:
+ break;
+ case PHASE_YO:
+ if (checkBck(ANM_FLOAT_WAIT) && mpModelMorf->checkFrame(1)) {
+ mSound.startCreatureSound(Z2SE_EN_ZAN_YO_FLOAT_WAIT, 0, -1);
+ }
+
+ {
+ f32 wall_r = mModelScaleXZ * 50.0f;
+ if (wall_r < 100.0f) {
+ wall_r = 100.0f;
+ }
+
+ mAcchCir.SetWall(100.0f, wall_r);
+ }
+
+ dComIfGs_offSaveDunSwitch(20);
+ dComIfGs_offSaveDunSwitch(21);
+ dComIfGs_offSaveDunSwitch(22);
+
+ switch (field_0x70e) {
+ case 1:
+ dComIfGs_onSaveDunSwitch(20);
+ break;
+ case 2:
+ dComIfGs_onSaveDunSwitch(21);
+ break;
+ case 3:
+ dComIfGs_onSaveDunSwitch(22);
+ break;
+ }
+
+ field_0x38b4 = dComIfGp_particle_set(field_0x38b4, 0x87B0, &sp40, &tevStr);
+ break;
+ case PHASE_OI:
+ setWaterBubble();
+ checkSwimLinkNear();
+ dComIfGs_onOneZoneSwitch(0, fopAcM_GetRoomNo(this));
+ break;
+ case PHASE_MK:
+ checkPillarSwing();
+ break;
+ case PHASE_LAST:
+ break;
+ }
+
+ s16 var_r29 = fopAcM_searchPlayerAngleX(this);
+ s16 neck_rot_z = 0;
+ s16 body_rot_x = 0;
+
+ if (field_0x717 != 0) {
+ if (var_r29 > 0x2800) {
+ var_r29 = 0x2800;
+ }
+
+ if (var_r29 < -0x2800) {
+ var_r29 = -0x2800;
+ }
+
+ if (abs(var_r29) < 0x1800) {
+ neck_rot_z = 0;
+ body_rot_x = var_r29;
+ } else if (var_r29 > 0) {
+ body_rot_x = 0x1800;
+ neck_rot_z = (s16)(var_r29 - 0x1800);
+ } else {
+ body_rot_x = -0x1800;
+ neck_rot_z = (s16)(var_r29 + 0x1800);
+ }
+ }
+
+ var_r29 = fopAcM_searchPlayerAngleY(this);
+ s16 neck_rot_x = 0;
+
+ if (field_0x716 != 0) {
+ if (var_r29 > 0x2000) {
+ var_r29 = 0x2000;
+ }
+
+ if (var_r29 < -0x2000) {
+ var_r29 = -0x2000;
+ }
+
+ neck_rot_x = var_r29;
+ }
+
+ cLib_addCalcAngleS(&mNeckRotZ, neck_rot_z, 8, 0x400, 0x80);
+ cLib_addCalcAngleS(&mNeckRotX, neck_rot_x, 8, 0x400, 0x80);
+ cLib_addCalcAngleS(&mBackboneRotZ, body_rot_x, 8, 0x400, 0x80);
+
+ calcMahojinAnime();
+
+ dStage_roomControl_c::onNoChangeRoom();
+ dStage_roomControl_c::setRoomReadId(warp_next_room[mFightPhase]);
+
+ if (field_0x6fc != 0) {
+ dStage_RoomCheck(NULL);
+ }
+
+ fopAcM_posMoveF(this, field_0x9a4.GetCCMoveP());
+
+ if (field_0x705 == 0) {
+ mAcch.CrrPos(dComIfG_Bgsp());
+ }
+
+ u32 sp44 = mModelScaleY * 100.0f;
+ mpModelMorf->play(sp44, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
}
/* 8064CB1C-8064CD0C 00EAFC 01F0+00 2/2 0/0 0/0 .text mtx_set__10daB_ZANT_cFv */
void daB_ZANT_c::mtx_set() {
- // NONMATCHING
+ mDoMtx_stack_c::transS(current.pos);
+ mDoMtx_stack_c::ZXYrotM(shape_angle);
+ mDoMtx_stack_c::scaleM(l_HIO.mModelSize * mModelScaleXZ, l_HIO.mModelSize * mModelScaleY, l_HIO.mModelSize * mModelScaleXZ);
+
+ J3DModel* model = mpModelMorf->getModel();
+ model->setBaseTRMtx(mDoMtx_stack_c::get());
+ mpModelMorf->modelCalc();
+
+ if (mDrawSwords) {
+ mDoMtx_stack_c::copy(model->getAnmMtx(JNT_ARM_L3));
+ mDoMtx_stack_c::scaleM(mSwordSize, mSwordSize, mSwordSize);
+ mpSwordLModel->setBaseTRMtx(mDoMtx_stack_c::get());
+
+ mDoMtx_stack_c::copy(model->getAnmMtx(JNT_ARM_R3));
+ mDoMtx_stack_c::scaleM(mSwordSize, mSwordSize, mSwordSize);
+ mpSwordRModel->setBaseTRMtx(mDoMtx_stack_c::get());
+ }
+
+ if (mMahojinAnmMode != 0) {
+ cXyz offset(l_HIO.mMahojinOffsetX, l_HIO.mMahojinOffsetY, l_HIO.mMahojinOffsetZ);
+ cXyz pos;
+ cLib_offsetPos(&pos, &current.pos, shape_angle.y, &offset);
+
+ mDoMtx_stack_c::transS(pos);
+ mDoMtx_stack_c::ZXYrotM(shape_angle);
+ mDoMtx_stack_c::scaleM(l_HIO.mMahojinSize, l_HIO.mMahojinSize, l_HIO.mMahojinSize);
+ mpMahojinModel->setBaseTRMtx(mDoMtx_stack_c::get());
+
+ mpMahojinBrk->play();
+ mpMahojinBtk->play();
+ mpMahojinStartBtk->play();
+
+ if (mMahojin2AnmMode != 0) {
+ mDoMtx_stack_c::copy(mpMahojinModel->getBaseTRMtx());
+ mDoMtx_stack_c::scaleM(mMahojin2Size, mMahojin2Size, mMahojin2Size);
+ mpMahojinModel2->setBaseTRMtx(mDoMtx_stack_c::get());
+ mpMahojinBrk2->play();
+ mpMahojinStartBtk2->play();
+ }
+ }
}
/* 8064CD0C-8064CFA8 00ECEC 029C+00 1/1 0/0 0/0 .text cc_set__10daB_ZANT_cFv */
void daB_ZANT_c::cc_set() {
- // NONMATCHING
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_NECK));
+ mDoMtx_stack_c::multVecZero(&eyePos);
+ attention_info.position = eyePos;
+ attention_info.position.y += mModelScaleY * 100.0f;
+
+ cXyz center;
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_BACKBONE));
+ mDoMtx_stack_c::transM(30.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&center);
+ mBodySphCc[0].SetC(center);
+ mBodySphCc[0].SetR(70.0f);
+ dComIfG_Ccsp()->Set(&mBodySphCc[0]);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_WAIST));
+ mDoMtx_stack_c::transM(50.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&center);
+ mBodySphCc[1].SetC(center);
+ mBodySphCc[1].SetR(70.0f);
+ dComIfG_Ccsp()->Set(&mBodySphCc[1]);
+
+ if (mFightPhase == PHASE_LAST) {
+ mRollCc.SetC(current.pos);
+ mRollCc.SetR(200.0f);
+ mRollCc.SetH(250.0f);
+ dComIfG_Ccsp()->Set(&mRollCc);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_ARM_L3));
+ mDoMtx_stack_c::transM(100.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&center);
+ mSwordCc[0].SetC(center);
+ mSwordCc[0].SetR(50.0f);
+ dComIfG_Ccsp()->Set(&mSwordCc[0]);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_ARM_R3));
+ mDoMtx_stack_c::transM(-100.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&center);
+ mSwordCc[1].SetC(center);
+ mSwordCc[1].SetR(50.0f);
+ dComIfG_Ccsp()->Set(&mSwordCc[1]);
+ }
}
/* 8064CFA8-8064DA48 00EF88 0AA0+00 1/1 0/0 0/0 .text cc_ice_set__10daB_ZANT_cFv */
void daB_ZANT_c::cc_ice_set() {
- // NONMATCHING
+ class dZantSph_c {
+ public:
+ int joint_no;
+ f32 offset_x;
+ f32 radius;
+ };
+
+ static dZantSph_c ice_sph_jnt[] = {
+ {JNT_FOOT_L, 10.0f, 15.0f},
+ {JNT_LEG_L2, 20.0f, 20.0f},
+ {JNT_LEG_L2, 0.0f, 25.0f},
+ {JNT_LEG_L1, 20.0f, 30.0f},
+ {JNT_FOOT_R, 10.0f, 15.0f},
+ {JNT_LEG_R2, 20.0f, 20.0f},
+ {JNT_LEG_R2, 0.0f, 25.0f},
+ {JNT_LEG_R1, 20.0f, 30.0f},
+ {JNT_WAIST, 0.0f, 45.0f},
+ {JNT_BACKBONE, 20.0f, 45.0f},
+ {JNT_HEAD, 20.0f, 25.0f},
+ };
+
+ cXyz sp34;
+ cXyz sp40;
+
+ if (mAction == ACT_ICE_STEP || mAction == ACT_ICE_JUMP) {
+ if (!dComIfGp_getAttention().LockonTruth() || dComIfGp_getAttention().LockonTarget(0) != this) {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_L));
+ mDoMtx_stack_c::transM(20.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp34);
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_R));
+ mDoMtx_stack_c::transM(20.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp40);
+
+ cXyz player_pos(daPy_getPlayerActorClass()->current.pos);
+ s16 player_angle = daPy_getPlayerActorClass()->shape_angle.y;
+
+ if (sp34.absXZ(player_pos) < 700.0f) {
+ field_0x70d = 0;
+ if (sp40.absXZ(player_pos) < 700.0f && abs((s16)(player_angle - cLib_targetAngleY(&player_pos, &sp40))) < abs((s16)(player_angle - cLib_targetAngleY(&player_pos, &sp34)))) {
+ field_0x70d = 1;
+ }
+ } else if (sp40.absXZ(player_pos) < 700.0f) {
+ field_0x70d = 1;
+ } else if (sp34.absXZ(player_pos) < sp40.absXZ(player_pos)) {
+ field_0x70d = 0;
+ } else {
+ field_0x70d = 1;
+ }
+
+ if (field_0x70d == 0) {
+ eyePos = sp34;
+ } else {
+ eyePos = sp40;
+ }
+ } else {
+ if (field_0x70d == 0) {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_L));
+ } else {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_FOOT_R));
+ }
+
+ mDoMtx_stack_c::transM(20.0f, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&eyePos);
+ }
+
+ attention_info.position = eyePos;
+ attention_info.position.y += 120.0f;
+ } else {
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(JNT_NECK));
+ mDoMtx_stack_c::multVecZero(&eyePos);
+ attention_info.position = eyePos;
+ attention_info.position.y += mModelScaleY * 120.0f;
+ }
+
+ cXyz sp64;
+ dZantSph_c sph;
+
+ for (int i = 0; i < 6; i++) {
+ sph = ice_sph_jnt[i];
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(sph.joint_no));
+ mDoMtx_stack_c::transM(sph.offset_x, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp64);
+
+ mFootCc[i].SetC(sp64);
+ mFootCc[i].SetR(sph.radius * mModelScaleY);
+ dComIfG_Ccsp()->Set(&mFootCc[i]);
+ }
+
+ for (int i = 0; i < 11; i++) {
+ sph = ice_sph_jnt[i];
+
+ mDoMtx_stack_c::copy(mpModelMorf->getModel()->getAnmMtx(sph.joint_no));
+ mDoMtx_stack_c::transM(sph.offset_x, 0.0f, 0.0f);
+ mDoMtx_stack_c::multVecZero(&sp64);
+
+ mFoot2Cc[i].SetC(sp64);
+ mFoot2Cc[i].SetR(sph.radius * mModelScaleY);
+ dComIfG_Ccsp()->Set(&mFoot2Cc[i]);
+
+ mCameraCc[i].SetC(sp64);
+ mCameraCc[i].SetR((sph.radius + 10.0f) * mModelScaleY);
+ dComIfG_Ccsp()->Set(&mCameraCc[i]);
+ }
}
/* 8064DA48-8064DB48 00FA28 0100+00 1/1 0/0 0/0 .text execute__10daB_ZANT_cFv */
-void daB_ZANT_c::execute() {
- // NONMATCHING
+int daB_ZANT_c::execute() {
+ if (mModeTimer != 0) {
+ mModeTimer--;
+ }
+
+ if (field_0x6ec != 0) {
+ field_0x6ec--;
+ }
+
+ if (field_0x6e4 != 0) {
+ field_0x6e4--;
+ }
+
+ if (field_0x6f0 != 0) {
+ field_0x6f0--;
+ }
+
+ if (field_0x6f4 != 0) {
+ field_0x6f4--;
+ }
+
+ switch (field_0x714) {
+ case 0:
+ dKy_custom_colset(10, 0, mKankyoBlend);
+ break;
+ case 1:
+ dKy_custom_colset(0, 10, mKankyoBlend);
+ break;
+ }
+
+ action();
+ mtx_set();
+
+ if (mFightPhase == PHASE_YO) {
+ cc_ice_set();
+ } else {
+ cc_set();
+ }
+
+ return 1;
}
/* 8064DB48-8064DB68 00FB28 0020+00 1/0 0/0 0/0 .text daB_ZANT_Execute__FP10daB_ZANT_c */
-static void daB_ZANT_Execute(daB_ZANT_c* param_0) {
- // NONMATCHING
+static int daB_ZANT_Execute(daB_ZANT_c* i_this) {
+ return i_this->execute();
}
/* 8064DB68-8064DB70 00FB48 0008+00 1/0 0/0 0/0 .text daB_ZANT_IsDelete__FP10daB_ZANT_c
*/
-static bool daB_ZANT_IsDelete(daB_ZANT_c* param_0) {
- return true;
+static int daB_ZANT_IsDelete(daB_ZANT_c* i_this) {
+ return 1;
}
/* 8064DB70-8064DBE4 00FB50 0074+00 1/1 0/0 0/0 .text _delete__10daB_ZANT_cFv */
-void daB_ZANT_c::_delete() {
- // NONMATCHING
+int daB_ZANT_c::_delete() {
+ dComIfG_resDelete(&mPhase, "B_zan");
+
+ if (mInitHIO) {
+ l_initHIO = false;
+ }
+
+ if (heap != NULL) {
+ mSound.deleteObject();
+ }
+
+ return 1;
}
/* 8064DBE4-8064DC04 00FBC4 0020+00 1/0 0/0 0/0 .text daB_ZANT_Delete__FP10daB_ZANT_c */
-static void daB_ZANT_Delete(daB_ZANT_c* param_0) {
- // NONMATCHING
+static int daB_ZANT_Delete(daB_ZANT_c* i_this) {
+ return i_this->_delete();
}
/* 8064DC04-8064E128 00FBE4 0524+00 1/1 0/0 0/0 .text CreateHeap__10daB_ZANT_cFv */
-void daB_ZANT_c::CreateHeap() {
- // NONMATCHING
-}
-
-/* 8064E128-8064E170 010108 0048+00 1/0 0/0 0/0 .text __dt__12J3DFrameCtrlFv */
-// J3DFrameCtrl::~J3DFrameCtrl() {
-extern "C" void __dt__12J3DFrameCtrlFv() {
- // NONMATCHING
+int daB_ZANT_c::CreateHeap() {
+ J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes("B_zan", 0x48);
+ JUT_ASSERT(modelData != 0);
+ mpModelMorf = new mDoExt_McaMorfSO(modelData, NULL, NULL, (J3DAnmTransform*)dComIfG_getObjectRes("B_zan", 0x12), 2, 1.0f, 0, -1, &mSound, 0, 0x11000084);
+ if (mpModelMorf == NULL || mpModelMorf->getModel() == NULL) {
+ return 0;
+ }
+
+ J3DModel* model = mpModelMorf->getModel();
+ model->setUserArea((u32)this);
+ model->getModelData()->getJointNodePointer(1)->setCallBack(JointCallBack);
+ model->getModelData()->getJointNodePointer(2)->setCallBack(JointCallBack);
+
+ mpMahojinModel = mDoExt_J3DModel__create((J3DModelData*)dComIfG_getObjectRes("B_zan", 0x49), 0x80000, 0x11000284);
+ if (mpMahojinModel == NULL) {
+ return 0;
+ }
+
+ mpMahojinBrk = new mDoExt_brkAnm();
+ if (mpMahojinBrk == NULL) {
+ return 0;
+ }
+
+ if (!mpMahojinBrk->init(mpMahojinModel->getModelData(), (J3DAnmTevRegKey*)dComIfG_getObjectRes("B_zan", 0x4F), 1, 0, 1.0f, 0, -1)) {
+ return 0;
+ }
+
+ mpMahojinBtk = new mDoExt_btkAnm();
+ if (mpMahojinBtk == NULL) {
+ return 0;
+ }
+
+ if (!mpMahojinBtk->init(mpMahojinModel->getModelData(), (J3DAnmTextureSRTKey*)dComIfG_getObjectRes("B_zan", 0x53), 1, 2, 1.0f, 0, -1)) {
+ return 0;
+ }
+
+ mpMahojinStartBtk = new mDoExt_btkAnm();
+ if (mpMahojinStartBtk == NULL) {
+ return 0;
+ }
+
+ if (!mpMahojinStartBtk->init(mpMahojinModel->getModelData(), (J3DAnmTextureSRTKey*)dComIfG_getObjectRes("B_zan", 0x54), 1, 0, 1.0f, 0, -1)) {
+ return 0;
+ }
+
+ mpMahojinModel2 = mDoExt_J3DModel__create((J3DModelData*)dComIfG_getObjectRes("B_zan", 0x49), 0x80000, 0x11000284);
+ if (mpMahojinModel2 == NULL) {
+ return 0;
+ }
+
+ mpMahojinBrk2 = new mDoExt_brkAnm();
+ if (mpMahojinBrk2 == NULL) {
+ return 0;
+ }
+
+ if (!mpMahojinBrk2->init(mpMahojinModel2->getModelData(), (J3DAnmTevRegKey*)dComIfG_getObjectRes("B_zan", 0x4F), 1, 0, 0.0f, 0, -1)) {
+ return 0;
+ }
+
+ mpMahojinStartBtk2 = new mDoExt_btkAnm();
+ if (mpMahojinStartBtk2 == NULL) {
+ return 0;
+ }
+
+ if (!mpMahojinStartBtk2->init(mpMahojinModel2->getModelData(), (J3DAnmTextureSRTKey*)dComIfG_getObjectRes("B_zan", 0x54), 1, 0, 1.0f, 0, -1)) {
+ return 0;
+ }
+
+ modelData = (J3DModelData*)dComIfG_getObjectRes("B_zan", 0x4A);
+ JUT_ASSERT(modelData != 0);
+ mpSwordLModel = mDoExt_J3DModel__create(modelData, 0x80000, 0x11000084);
+ if (mpSwordLModel == NULL) {
+ return 0;
+ }
+
+ modelData = (J3DModelData*)dComIfG_getObjectRes("B_zan", 0x4B);
+ JUT_ASSERT(modelData != 0);
+ mpSwordRModel = mDoExt_J3DModel__create(modelData, 0x80000, 0x11000084);
+ if (mpSwordRModel == NULL) {
+ return 0;
+ }
+
+ return 1;
}
/* 8064E170-8064E190 010150 0020+00 1/1 0/0 0/0 .text useHeapInit__FP10fopAc_ac_c */
-static void useHeapInit(fopAc_ac_c* param_0) {
- // NONMATCHING
+static int useHeapInit(fopAc_ac_c* i_this) {
+ return ((daB_ZANT_c*)i_this)->CreateHeap();
}
-/* ############################################################################################## */
-/* 8064EE60-8064EE60 000344 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */
-#pragma push
-#pragma force_active on
-SECTION_DEAD static char const* const stringBase_8064EE84 = "B_zant";
-#pragma pop
-
/* 8064E190-8064E724 010170 0594+00 1/1 0/0 0/0 .text create__10daB_ZANT_cFv */
-void daB_ZANT_c::create() {
- // NONMATCHING
-}
-
-/* 8064E724-8064E76C 010704 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGCylFv */
-// cM3dGCyl::~cM3dGCyl() {
-extern "C" void __dt__8cM3dGCylFv() {
- // NONMATCHING
-}
-
-/* 8064E76C-8064E7F0 01074C 0084+00 1/1 0/0 0/0 .text __ct__8dCcD_SphFv */
-// dCcD_Sph::dCcD_Sph() {
-extern "C" void __ct__8dCcD_SphFv() {
- // NONMATCHING
-}
-
-/* 8064E7F0-8064E84C 0107D0 005C+00 1/0 0/0 0/0 .text __dt__10dCcD_GSttsFv */
-// dCcD_GStts::~dCcD_GStts() {
-extern "C" void __dt__10dCcD_GSttsFv() {
- // NONMATCHING
-}
-
-/* 8064E84C-8064E8BC 01082C 0070+00 3/2 0/0 0/0 .text __dt__12dBgS_ObjAcchFv */
-// dBgS_ObjAcch::~dBgS_ObjAcch() {
-extern "C" void __dt__12dBgS_ObjAcchFv() {
- // NONMATCHING
-}
-
-/* 8064E8BC-8064E92C 01089C 0070+00 1/0 0/0 0/0 .text __dt__12dBgS_AcchCirFv */
-// dBgS_AcchCir::~dBgS_AcchCir() {
-extern "C" void __dt__12dBgS_AcchCirFv() {
- // NONMATCHING
+int daB_ZANT_c::create() {
+ fopAcM_SetupActor(this, daB_ZANT_c);
+ OS_REPORT("B_ZANT PARAM %x\n", fopAcM_GetParam(this));
+
+ mSwbit = fopAcM_GetParam(this);
+ if (mSwbit != 0xFF) {
+ if (dComIfGs_isSwitch(mSwbit, fopAcM_GetRoomNo(this))) {
+ OS_REPORT("B_ZANT やられ後なので再セットしません\n");
+ return cPhs_ERROR_e;
+ }
+ }
+
+ fopAcM_setStageLayer(this);
+
+ int phase_state = dComIfG_resLoad(&mPhase, "B_zan");
+ if (phase_state == cPhs_COMPLEATE_e) {
+ if (!fopAcM_entrySolidHeap(this, useHeapInit, 0x8F80)) {
+ return cPhs_ERROR_e;
+ }
+
+ if (!l_initHIO) {
+ l_initHIO = true;
+ mInitHIO = true;
+ l_HIO.field_0x4 = -1;
+ }
+
+ attention_info.flags = 4;
+ attention_info.distances[fopAc_attn_BATTLE_e] = 24;
+
+ fopAcM_SetMtx(this, mpModelMorf->getModel()->getBaseTRMtx());
+ fopAcM_SetMin(this, -200.0f, -200.0f, -200.0f);
+ fopAcM_SetMax(this, 200.0f, 200.0f, 200.0f);
+
+ mAcch.Set(fopAcM_GetPosition_p(this), fopAcM_GetOldPosition_p(this), this, 1, &mAcchCir, fopAcM_GetSpeed_p(this), NULL, NULL);
+ mAcchCir.SetWall(100.0f, 100.0f);
+
+ health = 600;
+ field_0x560 = 600;
+
+ field_0x9a4.Init(0xFE, 0, this);
+
+ mBodySphCc[0].Set(cc_zant_src);
+ mBodySphCc[0].SetStts(&field_0x9a4);
+
+ mBodySphCc[1].Set(cc_zant_src);
+ mBodySphCc[1].SetStts(&field_0x9a4);
+
+ mRollCc.Set(cc_zant_roll_src);
+ mRollCc.SetStts(&field_0x9a4);
+
+ mSwordCc[0].Set(cc_zant_sword_src);
+ mSwordCc[0].SetStts(&field_0x9a4);
+ mSwordCc[1].Set(cc_zant_sword_src);
+ mSwordCc[1].SetStts(&field_0x9a4);
+
+ field_0xc74.Init(0xFE, 0, this);
+ for (int i = 0; i < 11; i++) {
+ mFoot2Cc[i].Set(cc_zant_foot_src2);
+ mFoot2Cc[i].SetStts(&field_0xc74);
+
+ mFootCc[i].Set(cc_zant_foot_src);
+ mFootCc[i].SetStts(&field_0xc74);
+
+ mCameraCc[i].Set(cc_zant_camera_src);
+ mCameraCc[i].SetStts(&field_0xc74);
+ }
+
+ mSound.init(&current.pos, &eyePos, 3, 1);
+ mSound.setEnemyName("B_zant");
+
+ mAtInfo.mpSound = &mSound;
+ mAtInfo.mPowerType = 0;
+ gravity = 0.0f;
+
+ for (int i = 0; i < 9; i++) {
+ mPillarIDs[i] = fpcM_ERROR_PROCESS_ID_e;
+ }
+
+ for (int i = 0; i < 4; i++) {
+ mMobileIDs[i] = fpcM_ERROR_PROCESS_ID_e;
+ }
+
+ field_0x724 = -1;
+
+ if (dComIfGp_roomControl_getStayNo() == 60) {
+ mFightPhase = PHASE_LAST;
+ field_0x718 = 1;
+ } else if (dComIfGp_roomControl_getStayNo() == 50) {
+ mFightPhase = PHASE_OP;
+ } else {
+ mFightPhase = dComIfGp_roomControl_getStayNo() - 52;
+ if (mFightPhase >= PHASE_MAX) {
+ mFightPhase = PHASE_BB;
+ }
+ }
+
+ if (mFightPhase != PHASE_OP) {
+ Z2GetAudioMgr()->bgmStart(Z2BGM_BOSS_ZANT, 0, 0);
+ Z2GetAudioMgr()->changeBgmStatus(mFightPhase);
+ }
+
+ initNextRoom();
+ mKankyoBlend = 1.0f;
+ setBaseActionMode(1);
+
+ if (mFightPhase == PHASE_BB) {
+ field_0x70b = 0;
+ }
+
+ mModelScaleXZ = 1.0f;
+ mModelScaleY = 1.0f;
+
+ onWolfNoLock();
+ mtx_set();
+ }
+
+ return phase_state;
}
/* 8064E92C-8064E94C 01090C 0020+00 1/0 0/0 0/0 .text daB_ZANT_Create__FP10daB_ZANT_c */
-static void daB_ZANT_Create(daB_ZANT_c* param_0) {
- // NONMATCHING
-}
-
-/* 8064E94C-8064E994 01092C 0048+00 1/0 0/0 0/0 .text __dt__10cCcD_GSttsFv */
-// cCcD_GStts::~cCcD_GStts() {
-extern "C" void __dt__10cCcD_GSttsFv() {
- // NONMATCHING
-}
-
-/* 8064E994-8064E9DC 010974 0048+00 2/1 0/0 0/0 .text __dt__14daB_ZANT_HIO_cFv */
-daB_ZANT_HIO_c::~daB_ZANT_HIO_c() {
- // NONMATCHING
+static int daB_ZANT_Create(daB_ZANT_c* i_this) {
+ return i_this->create();
}
-/* 8064E9DC-8064EAE0 0109BC 0104+00 0/0 1/0 0/0 .text __sinit_d_a_b_zant_cpp */
-void __sinit_d_a_b_zant_cpp() {
- // NONMATCHING
-}
-
-#pragma push
-#pragma force_active on
-REGISTER_CTORS(0x8064E9DC, __sinit_d_a_b_zant_cpp);
-#pragma pop
-
-/* 8064EAE0-8064EAE8 010AC0 0008+00 1/0 0/0 0/0 .text @20@__dt__14dBgS_ObjGndChkFv */
-static void func_8064EAE0() {
- // NONMATCHING
-}
-
-/* 8064EAE8-8064EAF0 010AC8 0008+00 1/0 0/0 0/0 .text @76@__dt__14dBgS_ObjGndChkFv */
-static void func_8064EAE8() {
- // NONMATCHING
-}
-
-/* 8064EAF0-8064EAF8 010AD0 0008+00 1/0 0/0 0/0 .text @60@__dt__14dBgS_ObjGndChkFv */
-static void func_8064EAF0() {
- // NONMATCHING
-}
-
-/* 8064EAF8-8064EB00 010AD8 0008+00 1/0 0/0 0/0 .text @36@__dt__12dBgS_ObjAcchFv */
-static void func_8064EAF8() {
- // NONMATCHING
-}
-
-/* 8064EB00-8064EB08 010AE0 0008+00 1/0 0/0 0/0 .text @20@__dt__12dBgS_ObjAcchFv */
-static void func_8064EB00() {
- // NONMATCHING
-}
-
-/* ############################################################################################## */
-/* 8064EE4C-8064EE50 000330 0004+00 0/0 0/0 0/0 .rodata @9786 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9786 = 65.0f;
-COMPILER_STRIP_GATE(0x8064EE4C, &lit_9786);
-#pragma pop
-
-/* 8064EE50-8064EE54 000334 0004+00 0/0 0/0 0/0 .rodata @9787 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9787 = -225.0f;
-COMPILER_STRIP_GATE(0x8064EE50, &lit_9787);
-#pragma pop
-
-/* 8064EE54-8064EE58 000338 0004+00 0/0 0/0 0/0 .rodata @9788 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9788 = 118.0f;
-COMPILER_STRIP_GATE(0x8064EE54, &lit_9788);
-#pragma pop
-
-/* 8064EE58-8064EE5C 00033C 0004+00 0/0 0/0 0/0 .rodata @9789 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9789 = 42.0f;
-COMPILER_STRIP_GATE(0x8064EE58, &lit_9789);
-#pragma pop
-
-/* 8064EE5C-8064EE60 000340 0004+00 0/0 0/0 0/0 .rodata @9868 */
-#pragma push
-#pragma force_active on
-SECTION_RODATA static f32 const lit_9868 = -4000.0f;
-COMPILER_STRIP_GATE(0x8064EE5C, &lit_9868);
-#pragma pop
-
-/* 8064F694-8064F698 0000E4 0004+00 0/0 0/0 0/0 .bss
- * sInstance__40JASGlobalInstance<19JASDefaultBankTable> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F694[4];
-#pragma pop
-
-/* 8064F698-8064F69C 0000E8 0004+00 0/0 0/0 0/0 .bss
- * sInstance__35JASGlobalInstance<14JASAudioThread> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F698[4];
-#pragma pop
-
-/* 8064F69C-8064F6A0 0000EC 0004+00 0/0 0/0 0/0 .bss sInstance__27JASGlobalInstance<7Z2SeMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F69C[4];
-#pragma pop
-
-/* 8064F6A0-8064F6A4 0000F0 0004+00 0/0 0/0 0/0 .bss sInstance__28JASGlobalInstance<8Z2SeqMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6A0[4];
-#pragma pop
-
-/* 8064F6A4-8064F6A8 0000F4 0004+00 0/0 0/0 0/0 .bss sInstance__31JASGlobalInstance<10Z2SceneMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6A4[4];
-#pragma pop
-
-/* 8064F6A8-8064F6AC 0000F8 0004+00 0/0 0/0 0/0 .bss sInstance__32JASGlobalInstance<11Z2StatusMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6A8[4];
-#pragma pop
-
-/* 8064F6AC-8064F6B0 0000FC 0004+00 0/0 0/0 0/0 .bss sInstance__31JASGlobalInstance<10Z2DebugSys>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6AC[4];
-#pragma pop
-
-/* 8064F6B0-8064F6B4 000100 0004+00 0/0 0/0 0/0 .bss
- * sInstance__36JASGlobalInstance<15JAISoundStarter> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6B0[4];
-#pragma pop
-
-/* 8064F6B4-8064F6B8 000104 0004+00 0/0 0/0 0/0 .bss
- * sInstance__35JASGlobalInstance<14Z2SoundStarter> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6B4[4];
-#pragma pop
-
-/* 8064F6B8-8064F6BC 000108 0004+00 0/0 0/0 0/0 .bss
- * sInstance__33JASGlobalInstance<12Z2SpeechMgr2> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6B8[4];
-#pragma pop
-
-/* 8064F6BC-8064F6C0 00010C 0004+00 0/0 0/0 0/0 .bss sInstance__28JASGlobalInstance<8JAISeMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6BC[4];
-#pragma pop
-
-/* 8064F6C0-8064F6C4 000110 0004+00 0/0 0/0 0/0 .bss sInstance__29JASGlobalInstance<9JAISeqMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6C0[4];
-#pragma pop
-
-/* 8064F6C4-8064F6C8 000114 0004+00 0/0 0/0 0/0 .bss
- * sInstance__33JASGlobalInstance<12JAIStreamMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6C4[4];
-#pragma pop
-
-/* 8064F6C8-8064F6CC 000118 0004+00 0/0 0/0 0/0 .bss sInstance__31JASGlobalInstance<10Z2SoundMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6C8[4];
-#pragma pop
-
-/* 8064F6CC-8064F6D0 00011C 0004+00 0/0 0/0 0/0 .bss
- * sInstance__33JASGlobalInstance<12JAISoundInfo> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6CC[4];
-#pragma pop
-
-/* 8064F6D0-8064F6D4 000120 0004+00 0/0 0/0 0/0 .bss
- * sInstance__34JASGlobalInstance<13JAUSoundTable> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6D0[4];
-#pragma pop
-
-/* 8064F6D4-8064F6D8 000124 0004+00 0/0 0/0 0/0 .bss
- * sInstance__38JASGlobalInstance<17JAUSoundNameTable> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6D4[4];
-#pragma pop
-
-/* 8064F6D8-8064F6DC 000128 0004+00 0/0 0/0 0/0 .bss
- * sInstance__33JASGlobalInstance<12JAUSoundInfo> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6D8[4];
-#pragma pop
-
-/* 8064F6DC-8064F6E0 00012C 0004+00 0/0 0/0 0/0 .bss sInstance__32JASGlobalInstance<11Z2SoundInfo>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6DC[4];
-#pragma pop
-
-/* 8064F6E0-8064F6E4 000130 0004+00 0/0 0/0 0/0 .bss
- * sInstance__34JASGlobalInstance<13Z2SoundObjMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6E0[4];
-#pragma pop
-
-/* 8064F6E4-8064F6E8 000134 0004+00 0/0 0/0 0/0 .bss sInstance__31JASGlobalInstance<10Z2Audience>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6E4[4];
-#pragma pop
-
-/* 8064F6E8-8064F6EC 000138 0004+00 0/0 0/0 0/0 .bss sInstance__32JASGlobalInstance<11Z2FxLineMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6E8[4];
-#pragma pop
+/* 8064F4AC-8064F4CC -00001 0020+00 1/0 0/0 0/0 .data l_daB_ZANT_Method */
+static actor_method_class l_daB_ZANT_Method = {
+ (process_method_func)daB_ZANT_Create,
+ (process_method_func)daB_ZANT_Delete,
+ (process_method_func)daB_ZANT_Execute,
+ (process_method_func)daB_ZANT_IsDelete,
+ (process_method_func)daB_ZANT_Draw,
+};
-/* 8064F6EC-8064F6F0 00013C 0004+00 0/0 0/0 0/0 .bss sInstance__31JASGlobalInstance<10Z2EnvSeMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6EC[4];
-#pragma pop
+/* 8064F4CC-8064F4FC -00001 0030+00 0/0 0/0 1/0 .data g_profile_B_ZANT */
+extern actor_process_profile_definition g_profile_B_ZANT = {
+ fpcLy_CURRENT_e, // mLayerID
+ 4, // mListID
+ fpcPi_CURRENT_e, // mListPrio
+ PROC_B_ZANT, // mProcName
+ &g_fpcLf_Method.mBase, // sub_method
+ sizeof(daB_ZANT_c), // mSize
+ 0, // mSizeOther
+ 0, // mParameters
+ &g_fopAc_Method.base, // sub_method
+ 226, // mPriority
+ &l_daB_ZANT_Method, // sub_method
+ 0x00040000, // mStatus
+ fopAc_ENEMY_e, // mActorType
+ fopAc_CULLBOX_CUSTOM_e, // cullType
+};
-/* 8064F6F0-8064F6F4 000140 0004+00 0/0 0/0 0/0 .bss sInstance__32JASGlobalInstance<11Z2SpeechMgr>
- */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6F0[4];
-#pragma pop
-
-/* 8064F6F4-8064F6F8 000144 0004+00 0/0 0/0 0/0 .bss
- * sInstance__34JASGlobalInstance<13Z2WolfHowlMgr> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6F4[4];
-#pragma pop
-
-/* 8064F6F8-8064F6FC 000148 0004+00 0/0 0/0 0/0 .bss
- * sInstance__35JASGlobalInstance<14JAUSectionHeap> */
-#pragma push
-#pragma force_active on
-static u8 data_8064F6F8[4];
-#pragma pop
-
-/* 8064EE60-8064EE60 000344 0000+00 0/0 0/0 0/0 .rodata @stringBase0 */
+AUDIO_INSTANCES;
+JAUSectionHeap* JASGlobalInstance<JAUSectionHeap>::sInstance;
diff --git a/src/d/actor/d_a_b_zant_magic.cpp b/src/d/actor/d_a_b_zant_magic.cpp
index c82f47b284..656276bec1 100644
--- a/src/d/actor/d_a_b_zant_magic.cpp
+++ b/src/d/actor/d_a_b_zant_magic.cpp
@@ -156,7 +156,7 @@ void daB_ZANTM_c::executeSmall() {
speed.y = magic_speed * cM_ssin(current.angle.x);
Z2GetAudioMgr()->seStart(Z2SE_EN_ZAN_FIRE_OUT, &current.pos, 0, 0, 1.0f, 1.0f, -1.0f, -1.0f, false);
case 1:
- Z2GetAudioMgr()->seStart(Z2SE_EN_ZAN_FIRE, &current.pos, 0, 0, 1.0f, 1.0f, -1.0f, -1.0f, false);
+ Z2GetAudioMgr()->seStartLevel(Z2SE_EN_ZAN_FIRE, &current.pos, 0, 0, 1.0f, 1.0f, -1.0f, -1.0f, false);
cLib_chaseF(&field_0x5e8, 1.0f, 0.1f);
if (mAliveTimer == 0 || mAcch.ChkWallHit() || mAcch.i_ChkGroundHit()) {