Skip to content

Commit

Permalink
e_pm, e_fs, obj_sm_door, obj_smw_stone (#2244)
Browse files Browse the repository at this point in the history
  • Loading branch information
randomsalience authored Nov 10, 2024
1 parent 7c20cdb commit f4ee3b5
Show file tree
Hide file tree
Showing 13 changed files with 4,036 additions and 3,520 deletions.
4 changes: 2 additions & 2 deletions configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -1985,12 +1985,12 @@ def MatchingFor(*versions):
ActorRel(Matching, "d_a_obj_sekizo"),
ActorRel(NonMatching, "d_a_obj_sekizoa"),
ActorRel(NonMatching, "d_a_obj_shield"),
ActorRel(NonMatching, "d_a_obj_sm_door"),
ActorRel(Equivalent, "d_a_obj_sm_door"),
ActorRel(NonMatching, "d_a_obj_smallkey"),
ActorRel(NonMatching, "d_a_obj_smgdoor"),
ActorRel(Matching, "d_a_obj_smoke"),
ActorRel(NonMatching, "d_a_obj_smtile"),
ActorRel(NonMatching, "d_a_obj_smw_stone"),
ActorRel(Matching, "d_a_obj_smw_stone"),
ActorRel(Matching, "d_a_obj_snowEffTag"),
ActorRel(Matching, "d_a_obj_snow_soup"),
ActorRel(NonMatching, "d_a_obj_so"),
Expand Down
1 change: 1 addition & 0 deletions include/d/actor/d_a_alink.h
Original file line number Diff line number Diff line change
Expand Up @@ -3511,6 +3511,7 @@ class daAlink_c : public daPy_py_c {
u32 getWolfHowlTimer() { return mZ2WolfHowlMgr.getTimer(); }
s8 getOnLineNum() { return mZ2WolfHowlMgr.getOnLineNum(); }
SongNote getCorrectLine(u8 param_0) { return mZ2WolfHowlMgr.getCorrectLine(param_0); }
void startWindStoneSound(s8 id, Vec* pos) { mZ2WolfHowlMgr.startWindStoneSound(id, pos); }
J3DModelData* getItemModelData() { return mpItemModelData; }

cXyz* getIronBallChainPos() const { return mIronBallChainPos; }
Expand Down
61 changes: 57 additions & 4 deletions include/d/actor/d_a_e_fs.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
#ifndef D_A_E_FS_H
#define D_A_E_FS_H

#include "Z2AudioLib/Z2Creature.h"
#include "f_op/f_op_actor_mng.h"
#include "d/d_bg_s_acch.h"
#include "d/d_cc_d.h"
#include "d/d_cc_uty.h"

/**
* @ingroup actors-enemies
Expand All @@ -11,16 +16,64 @@
*
*/
class e_fs_class : public fopEn_enemy_c {
private:
/* 0x5ac */ u8 field_0x5ac[0xb9c - 0x5ac];
public:
/* 0x5AC */ request_of_phase_process_class mPhase;
/* 0x5B4 */ u8 field_0x5b4;
/* 0x5B5 */ u8 field_0x5b5;
/* 0x5B6 */ u8 field_0x5b6;
/* 0x5B7 */ u8 field_0x5b7;
/* 0x5B8 */ cXyz mPlayerPos;
/* 0x5C4 */ s16 mTargetAngleY;
/* 0x5C6 */ s16 mPlayerAngleY;
/* 0x5C8 */ f32 mPlayerDistXZ;
/* 0x5CC */ u8 field_0x5cc[0x5D0 - 0x5CC];
/* 0x5D0 */ mDoExt_McaMorfSO* mpMorf;
/* 0x5D4 */ Z2CreatureEnemy mCreatureSound;
/* 0x678 */ u32 mAnm;
/* 0x67C */ s16 mFrameCounter;
/* 0x67E */ s16 mAction;
/* 0x680 */ s16 mMode;
/* 0x684 */ u32 mShadowKey;
/* 0x688 */ s16 mTimer[4];
/* 0x690 */ s16 mIFrameTimer;
/* 0x692 */ s8 field_0x692;
/* 0x694 */ dBgS_AcchCir mAcchCir;
/* 0x6D4 */ dBgS_ObjAcch mAcch;
/* 0x8AC */ dCcD_Stts mCcStts;
/* 0x8E8 */ dCcD_Cyl mCcCyl;
/* 0xA24 */ dCcD_Sph mAtSph;
/* 0xB5C */ dCcU_AtInfo mAtInfo;
/* 0xB80 */ u32 mSmokeKey1;
/* 0xB84 */ u32 mSmokeKey2;
/* 0xB88 */ u32 mParticleKey[4];
/* 0xB98 */ bool mHIOInit;

enum Action {
/* 0x0 */ ACT_APPEAR,
/* 0x1 */ ACT_WAIT,
/* 0x2 */ ACT_MOVE,
/* 0x3 */ ACT_ATTACK,
/* 0x4 */ ACT_DAMAGE,
/* 0x5 */ ACT_END,
/* 0xA */ ACT_DEMOWAIT = 10,
};
};

STATIC_ASSERT(sizeof(e_fs_class) == 0xb9c);
STATIC_ASSERT(sizeof(e_fs_class) == 0xB9C);

class daE_Fs_HIO_c {
public:
/* 806BBACC */ daE_Fs_HIO_c();
/* 806BDF94 */ ~daE_Fs_HIO_c();
/* 806BDF94 */ virtual ~daE_Fs_HIO_c() {}

/* 0x04 */ s8 field_0x4;
/* 0x08 */ f32 mScale;
/* 0x0C */ f32 mAttackRange;
/* 0x10 */ f32 mAttackDistance;
/* 0x14 */ f32 mMoveSpeedRatio;
/* 0x18 */ f32 mDeleteRange;
};

STATIC_ASSERT(sizeof(daE_Fs_HIO_c) == 0x1C);

#endif /* D_A_E_FS_H */
124 changes: 110 additions & 14 deletions include/d/actor/d_a_e_pm.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
#ifndef D_A_E_PM_H
#define D_A_E_PM_H

#include "f_op/f_op_actor_mng.h"
#include "SSystem/SComponent/c_phase.h"
#include "Z2AudioLib/Z2Creature.h"
#include "f_op/f_op_actor.h"
#include "d/d_bg_s_acch.h"
#include "d/d_cc_d.h"
#include "d/d_cc_uty.h"
#include "d/d_msg_flow.h"

class dPath;

/**
* @ingroup actors-enemies
Expand All @@ -14,20 +22,20 @@
class daE_PM_c : public fopEn_enemy_c {
public:
/* 80741FB4 */ void DemoSkip(int);
/* 80742004 */ void DemoSkipCallBack(void*, int);
/* 80742038 */ void CreateHeap();
/* 80742004 */ static int DemoSkipCallBack(void*, int);
/* 80742038 */ int CreateHeap();
/* 80742448 */ void initCcCylinder();
/* 807424C0 */ void setCcCylinder();
/* 80742508 */ void ctrlJoint(J3DJoint*, J3DModel*);
/* 80742508 */ int ctrlJoint(J3DJoint*, J3DModel*);
/* 80742600 */ void Particle_Set(u16, cXyz);
/* 80742674 */ void SetAnm(int, int, f32, f32);
/* 80742810 */ void Yazirushi();
/* 807428A8 */ void SearchRndP();
/* 80742958 */ void SearchFarP();
/* 80742C94 */ void SearchNearP();
/* 80742E1C */ void SearchNextPos();
/* 80742E1C */ BOOL SearchNextPos();
/* 80742FB4 */ void SetGakkiEffect();
/* 807430C4 */ void CameraSet();
/* 807430C4 */ bool CameraSet();
/* 80743210 */ void SetStopingCam();
/* 80743294 */ void SetStopCam(cXyz, f32, f32, s16);
/* 807433E8 */ void SetMoveCam2(f32, f32);
Expand All @@ -52,7 +60,7 @@ class daE_PM_c : public fopEn_enemy_c {
/* 80747F38 */ void BossWaitAction();
/* 807480A4 */ void BossDeathAction();
/* 80748964 */ void BossAction();
/* 80748B18 */ void Execute();
/* 80748B18 */ int Execute();
/* 80748D74 */ void StartAction();
/* 8074954C */ void GakkiLoopAction(cXyz, f32);
/* 807499C0 */ void DemoCreateAction();
Expand All @@ -63,28 +71,116 @@ class daE_PM_c : public fopEn_enemy_c {
/* 8074A210 */ void At_Check();
/* 8074A3DC */ void ObjHit();
/* 8074A644 */ void EyeMove();
/* 8074A6CC */ void Draw();
/* 8074AAC0 */ void Delete();
/* 8074A6CC */ int Draw();
/* 8074AAC0 */ int Delete();
/* 8074AB28 */ void setBaseMtx();
/* 8074ABA8 */ void setGakkiBaseMtx();
/* 8074AC10 */ void setLampBaseMtx();
/* 8074AEF8 */ void SkipChk();
/* 8074B4DC */ void Create();
/* 8074B4DC */ cPhs__Step Create();

void AppearSet() { mAppear = true; }
u8 ActionChk() { return mPuppetDelete; }
u8 SwitchChk() { return mStage; }
u8 DoorChk() { return mDoorAction; }

private:
/* 0x5AC */ u8 field_0x5ac[0x619 - 0x5AC];
/* 0x5AC */ fpc_ProcID mPuppetID[4];
/* 0x5BC */ u8 field_0x5bc[0x5DC - 0x5BC];
/* 0x5DC */ u8 mDoorAction;
/* 0x5E0 */ dPath* mpPath;
/* 0x5E4 */ cXyz mPoint;
/* 0x5F0 */ u8 mPathIndex;
/* 0x5F4 */ int mPointIndex;
/* 0x5F8 */ u8 mBossHealth;
/* 0x5FC */ f32 field_0x5fc;
/* 0x600 */ u8 mPuppetNum;
/* 0x602 */ s16 mTargetAngleY;
/* 0x604 */ s16 mHeadAngleX;
/* 0x606 */ s16 mHeadAngleZ;
/* 0x608 */ s16 mTargetHeadAngleX;
/* 0x60C */ f32 mTargetSpeed;
/* 0x610 */ u8 mAction;
/* 0x611 */ u8 mMode;
/* 0x612 */ u8 mDemoMode;
/* 0x613 */ u8 field_0x613;
/* 0x614 */ u8 mPuppetDelete;
/* 0x616 */ s16 mIFrameTimer;
/* 0x618 */ u8 field_0x618;
/* 0x619 */ bool mAppear;
/* 0x61A */ u8 field_0x61a[0xb7c - 0x61a];
/* 0x61A */ u8 mStage;
/* 0x61B */ u8 mSwBit;
/* 0x61C */ int mAnm;
/* 0x620 */ s16 mTimer[4];
/* 0x628 */ u32 mParticleKey;
/* 0x62C */ u32 mGakkiParticleKey[3];
/* 0x638 */ u32 mLampParticleKey;
/* 0x63C */ dMsgFlow_c mMsgFlow;
/* 0x688 */ u8 mEyeAnmTimer;
/* 0x689 */ u8 mEyeAnmFrame;
/* 0x68C */ cXyz mCamCenter;
/* 0x698 */ cXyz mCamEye;
/* 0x6A4 */ cXyz mCamCenterTarget;
/* 0x6B0 */ cXyz mCamEyeTarget;
/* 0x6BC */ cXyz mCamCenterTarget2;
/* 0x6C8 */ cXyz mCamEyeTarget2;
/* 0x6D4 */ f32 mCamFovY;
/* 0x6D8 */ bool mSecondEncounter;
/* 0x6DC */ cXyz mOldLampPosition;
/* 0x6E8 */ cXyz mLampPosition;
/* 0x6F4 */ csXyz mLampAngle;
/* 0x6FA */ s16 field_0x6fa;
/* 0x6FC */ s16 field_0x6fc;
/* 0x6FE */ bool mBossLightOn;
/* 0x6FF */ bool field_0x6ff;
/* 0x700 */ mDoExt_btpAnm* mpEyeAnm;
/* 0x704 */ mDoExt_McaMorfSO* mpMorf;
/* 0x708 */ mDoExt_McaMorf* mpTrumpetMorf;
/* 0x70C */ J3DModel* mpLampModel;
/* 0x710 */ mDoExt_McaMorf* mpGlowEffectMorf;
/* 0x714 */ request_of_phase_process_class mPhase;
/* 0x71C */ u32 mShadowKey;
/* 0x720 */ Z2CreatureEnemy mCreatureSound;
/* 0x7C4 */ dBgS_AcchCir mAcchCir;
/* 0x804 */ dBgS_ObjAcch mAcch;
/* 0x9DC */ dCcD_Stts mCcStts;
/* 0xA18 */ dCcD_Cyl mCcCyl;
/* 0xB54 */ dCcU_AtInfo mAtInfo;
/* 0xB78 */ bool mHIOInit;
};

STATIC_ASSERT(sizeof(daE_PM_c) == 0xb7c);
STATIC_ASSERT(sizeof(daE_PM_c) == 0xB7C);

class daE_PM_HIO_c {
public:
/* 80741EEC */ daE_PM_HIO_c();
/* 8074BA68 */ ~daE_PM_HIO_c();
/* 8074BA68 */ virtual ~daE_PM_HIO_c() {}

/* 0x04 */ s8 field_0x4;
/* 0x08 */ f32 mLampParticleScale;
/* 0x0C */ f32 mGlowEffectScale;
/* 0x10 */ f32 mEscapeRange;
/* 0x14 */ s16 mGlowColor1R;
/* 0x16 */ s16 mGlowColor1G;
/* 0x18 */ s16 mGlowColor1B;
/* 0x1A */ s16 mGlowColor2R;
/* 0x1C */ s16 mGlowColor2G;
/* 0x1E */ s16 mGlowColor2B;
/* 0x20 */ s16 mGlowColor1A;
/* 0x22 */ s16 mBossEscapeTimer;
/* 0x24 */ s16 field_0x24;
/* 0x26 */ s16 mAdditionalPuppetNum;
/* 0x28 */ f32 mCreateTimer;
/* 0x2C */ f32 field_0x2c;
/* 0x30 */ f32 field_0x30;
/* 0x34 */ f32 field_0x34;
/* 0x38 */ f32 mBossLightR;
/* 0x3C */ f32 mBossLightG;
/* 0x40 */ f32 mBossLightB;
/* 0x44 */ f32 field_0x44;
/* 0x48 */ f32 field_0x48;
};

STATIC_ASSERT(sizeof(daE_PM_HIO_c) == 0x4C);

#endif /* D_A_E_PM_H */
43 changes: 32 additions & 11 deletions include/d/actor/d_a_obj_sm_door.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
#ifndef D_A_OBJ_SM_DOOR_H
#define D_A_OBJ_SM_DOOR_H

#include "f_op/f_op_actor_mng.h"
#include "SSystem/SComponent/c_phase.h"
#include "d/d_bg_s_acch.h"
#include "d/d_bg_s_movebg_actor.h"
#include "d/d_cc_d.h"
#include "d/d_cc_uty.h"

/**
* @ingroup actors-objects
Expand All @@ -11,24 +15,41 @@
* @details
*
*/
class daObjSM_DOOR_c : public fopAc_ac_c {
class daObjSM_DOOR_c : public dBgS_MoveBgActor {
public:
/* 80CD8784 */ void ChangeModel();
/* 80CD8790 */ void Action();
/* 80CD8A40 */ void SetDzb();
/* 80CD8A90 */ void ReleaceDzb();
/* 80CD8A40 */ int SetDzb();
/* 80CD8A90 */ int ReleaceDzb();
/* 80CD8AF8 */ void DrawChk1();
/* 80CD8BBC */ void DrawChk2();
/* 80CD8C80 */ void setBaseMtx();
/* 80CD8D4C */ void create();
/* 80CD90A4 */ void CreateHeap();
/* 80CD9258 */ void Create();
/* 80CD929C */ void Execute(f32 (**)[3][4]);
/* 80CD930C */ void Draw();
/* 80CD9544 */ void Delete();
/* 80CD8D4C */ cPhs__Step create();
/* 80CD90A4 */ int CreateHeap();
/* 80CD9258 */ int Create();
/* 80CD929C */ int Execute(Mtx**);
/* 80CD930C */ int Draw();
/* 80CD9544 */ int Delete();

private:
/* 0x568 */ u8 field_0x568[0x858 - 0x568];
/* 0x5A0 */ bool mUseAlphaModel;
/* 0x5A1 */ u8 field_0x5a1[0x5AC - 0x5A1];
/* 0x5AC */ s16 mMode;
/* 0x5AE */ u8 field_0x5ae[0x5B8 - 0x5AE];
/* 0x5B8 */ u8 mAlpha;
/* 0x5B9 */ u8 mType;
/* 0x5BA */ u8 mSwType;
/* 0x5BB */ u8 mSwBit;
/* 0x5BC */ bool mActive;
/* 0x5BD */ u8 field_0x5bd[0x5CC - 0x5BD];
/* 0x5CC */ J3DModel* mpModel;
/* 0x5D0 */ J3DModel* mpAlphaModel;
/* 0x5D4 */ request_of_phase_process_class mPhase;
/* 0x5DC */ dBgS_AcchCir mAcchCir;
/* 0x61C */ dBgS_ObjAcch mAcch;
/* 0x7F4 */ dCcD_Stts mCcStts;
/* 0x830 */ dCcU_AtInfo mAtInfo;
/* 0x854 */ u8 field_0x854[0x858 - 0x854];
};

STATIC_ASSERT(sizeof(daObjSM_DOOR_c) == 0x858);
Expand Down
27 changes: 18 additions & 9 deletions include/d/actor/d_a_obj_smw_stone.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,33 @@
* @details
*
*/
class daSmWStone_c : public fopAc_ac_c {
class daSmWStone_c : public fopAc_ac_c, public request_of_phase_process_class {
public:
/* 80CDE538 */ daSmWStone_c();
/* 80CDE588 */ ~daSmWStone_c();
/* 80CDE614 */ void create();
/* 80CDE8D8 */ void execute();
/* 80CDE92C */ void draw();
/* 80CDEA2C */ void Delete();
/* 80CDE588 */ virtual ~daSmWStone_c();
/* 80CDE614 */ cPhs__Step create();
/* 80CDE8D8 */ int execute();
/* 80CDE92C */ int draw();
/* 80CDEA2C */ int Delete();
/* 80CDEAA4 */ void exeModeHowl();
/* 80CDEBA0 */ void setModelMtx();
/* 80CDEC04 */ void createHeap();
/* 80CDEC04 */ int createHeap();
/* 80CDED30 */ void init();
/* 80CDED9C */ void chkWlfInRange();
/* 80CDED9C */ bool chkWlfInRange();

int getTuneId() { return 2; }
u8 getSwBit0() { return fopAcM_GetParamBit(this, 0, 8); }
void deleteStone() { mDelete = true; }

private:
/* 0x568 */ u8 field_0x568[0x5c8 - 0x568];
/* 0x574 */ cBgS_PolyInfo mPolyInfo;
/* 0x584 */ J3DModel* mpModel;
/* 0x588 */ dBgW* mpBgW;
/* 0x58C */ Mtx mBgMtx;
/* 0x5BC */ f32 mGroundH;
/* 0x5C0 */ u32 mShadowKey;
/* 0x5C4 */ u8 mMode;
/* 0x5C5 */ bool mDelete;
};

STATIC_ASSERT(sizeof(daSmWStone_c) == 0x5c8);
Expand Down
2 changes: 1 addition & 1 deletion include/d/d_bg_s.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class cBgS {
public:
cBgS() {}
bool Regist(dBgW_Base*, fpc_ProcID, void*);
int Release(dBgW_Base*);
bool Release(dBgW_Base*);
bool LineCross(cBgS_LinChk*);
f32 GroundCross(cBgS_GndChk*);
static void* ConvDzb(void*);
Expand Down
Loading

0 comments on commit f4ee3b5

Please sign in to comment.