diff options
| author | Jeff Padgham <jeff.ookami@gmail.com> | 2024-04-26 19:12:56 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-26 19:12:56 -0700 |
| commit | c163dc9ed31c69eb791be1dcdcd7ab8b296e95a1 (patch) | |
| tree | 569d09bb0c51bde94264b8faeb83cee6b4ae1278 /include | |
| parent | 9e80bf0d84c150b07ca14cea53ee6d2f82b073c2 (diff) | |
d_a_arrow work (#2139)
* WIP commit, about halfway done
* More progress, fixed up some issues
* Most functions match, minor issues in draw/create, dtor needs particle work
* Forgot to remove NONMATCHING define
---------
Co-authored-by: GinNoOokami <noreply>
Diffstat (limited to 'include')
| -rw-r--r-- | include/d/a/d_a_alink.h | 5 | ||||
| -rw-r--r-- | include/d/cc/d_cc_d.h | 3 | ||||
| -rw-r--r-- | include/d/d_jnt_col.h | 2 | ||||
| -rw-r--r-- | include/d/particle/d_particle.h | 2 | ||||
| -rw-r--r-- | include/rel/d/a/d_a_arrow/d_a_arrow.h | 80 | ||||
| -rw-r--r-- | include/rel/d/a/d_a_hozelda/d_a_hozelda.h | 2 | ||||
| -rw-r--r-- | include/rel/d/a/e/d_a_e_pz/d_a_e_pz.h | 36 |
7 files changed, 100 insertions, 30 deletions
diff --git a/include/d/a/d_a_alink.h b/include/d/a/d_a_alink.h index 5914b1077d..7c06fa2c6f 100644 --- a/include/d/a/d_a_alink.h +++ b/include/d/a/d_a_alink.h @@ -1762,7 +1762,7 @@ public: /* 800D74A4 */ void setLandDamagePoint(int); /* 800D74F4 */ Vec* getDamageVec(dCcD_GObjInf*); /* 800D76C4 */ void setDashDamage(); - /* 800D7768 */ static bool checkIcePolygonDamage(cBgS_PolyInfo*); + /* 800D7768 */ static BOOL checkIcePolygonDamage(cBgS_PolyInfo*); /* 800D77C8 */ BOOL checkMagicArmorNoDamage(); /* 800D7820 */ void checkPolyDamage(); /* 800D7A98 */ bool checkElecReturnDamage(dCcD_GObjInf&, fopAc_ac_c**); @@ -3237,6 +3237,7 @@ public: BOOL checkReinRide() const { return mRideStatus == 1 || mRideStatus == 2; } int getGrassHowlEventActor() const { return field_0x3198; } MtxP getShieldMtx() const { return mShieldModel->getBaseTRMtx(); } + MtxP getMagneBootsMtx() { return mMagneBootMtx; } bool checkFishingCastMode() const { bool var_r5; @@ -3360,6 +3361,8 @@ public: s8 getOnLineNum() { return mZ2WolfHowlMgr.getOnLineNum(); } SongNote getCorrectLine(u8 param_0) { return mZ2WolfHowlMgr.getCorrectLine(param_0); } + void itemHitSE(u32 param_1, u32 param_2, Z2SoundObjBase* param_3) { mZ2Link.startHitItemSE(param_1, param_2, param_3, -1.0f); } + inline bool checkWindSpeedOnXZ() const; inline void startRestartRoomFromOut(int, u32, int); inline u16 getReadyItem(); diff --git a/include/d/cc/d_cc_d.h b/include/d/cc/d_cc_d.h index 3c7ac0a03d..64ee42a1ef 100644 --- a/include/d/cc/d_cc_d.h +++ b/include/d/cc/d_cc_d.h @@ -236,6 +236,7 @@ public: u8 GetHitMark() { return mHitMark; } void SetRVec(cXyz& vec) { mRVec = vec; } cXyz* GetVecP() { return &mVec; } + cXyz* GetRVecP() { return &mRVec; } void SetHitPos(cXyz& pos) { mHitPos = pos; } cXyz* GetHitPosP() { return &mHitPos; } @@ -362,6 +363,7 @@ public: bool ChkTgWolfSpNoDamage() { return mGObjTg.ChkSPrm(0x800); } bool ChkAtNoHitMark() { return mGObjAt.ChkSPrm(2); } bool ChkTgNoHitMark() { return mGObjTg.ChkSPrm(4); } + bool ChkTgArrowThrough() { return mGObjTg.ChkSPrm(0x20); } bool ChkTgHookShotNoHitMark() { return mGObjTg.ChkSPrm(0x400); } bool ChkTgArrowNoHitMark() { return mGObjTg.ChkSPrm(0x1000); } dCcG_Tg_Spl GetTgSpl() { return (dCcG_Tg_Spl)mGObjTg.GetSpl(); } @@ -389,6 +391,7 @@ public: u32 GetTgHitObjHitSeID(int i_soundID) { return getHitSeID(GetTgHitObjSe(),i_soundID); } cXyz* GetAtHitPosP() { return mGObjAt.GetHitPosP(); } cXyz* GetTgHitPosP() { return mGObjTg.GetHitPosP(); } + cXyz* GetTgRVecP() { return mGObjTg.GetRVecP(); } bool ChkTgHookshotThrough() { return mGObjTg.ChkSPrm(0x80); } static const Z2SoundID m_hitSeID[24]; diff --git a/include/d/d_jnt_col.h b/include/d/d_jnt_col.h index c72b7b4c50..58fae6ffbb 100644 --- a/include/d/d_jnt_col.h +++ b/include/d/d_jnt_col.h @@ -22,7 +22,7 @@ public: /* 80035CA0 */ int init(fopAc_ac_c*, dJntColData_c const*, J3DModel*, int); /* 80035CC8 */ static void setNowLine(cM3dGLin*, cXyz const*, csXyz const*, cXyz*); /* 80035DC8 */ void searchNearPos(cM3dGLin const*, cXyz const*, cXyz*, int) const; - /* 80036AEC */ void getArrowOffsetPosAndAngle(cXyz const*, csXyz const*, cXyz*, cXyz*) const; + /* 80036AEC */ int getArrowOffsetPosAndAngle(cXyz const*, csXyz const*, cXyz*, cXyz*) const; /* 80036C44 */ int getHitmarkPosAndAngle(cXyz const*, csXyz const*, cXyz*, csXyz*, int) const; /* 80036FA8 */ void setArrowPosAndAngle(cXyz const*, cXyz const*, int, cXyz*, csXyz*); diff --git a/include/d/particle/d_particle.h b/include/d/particle/d_particle.h index 731d295690..7a51ed45ab 100644 --- a/include/d/particle/d_particle.h +++ b/include/d/particle/d_particle.h @@ -31,6 +31,8 @@ public: /* 8004F6C4 */ virtual void executeAfter(JPABaseEmitter*); /* 8004FABC */ virtual void setup(JPABaseEmitter*, cXyz const*, csXyz const*, s8); + void setRate(f32 rate) { mRate = rate; } + private: /* 0x04 */ f32 mRate; /* 0x08 */ int mMaxCnt; diff --git a/include/rel/d/a/d_a_arrow/d_a_arrow.h b/include/rel/d/a/d_a_arrow/d_a_arrow.h index 80e1d34523..0119677444 100644 --- a/include/rel/d/a/d_a_arrow/d_a_arrow.h +++ b/include/rel/d/a/d_a_arrow/d_a_arrow.h @@ -8,41 +8,48 @@ class daArrow_c : public fopAc_ac_c { public: - /* 80499C6C */ void createHeap(); + enum ArrowType_e { + ARROW_TYPE_NORMAL = 0, // Needs verification + ARROW_TYPE_BOMB = 1, + ARROW_TYPE_LIGHT = 2, + ARROW_TYPE_SLING = 4, + }; + + /* 80499C6C */ int createHeap(); /* 80499D8C */ void atHitCallBack(dCcD_GObjInf*, fopAc_ac_c*, dCcD_GObjInf*); /* 80499FBC */ void decAlphaBlur(); /* 8049A04C */ void setBlur(); /* 8049A110 */ void setLightArrowHitMark(cXyz const*); /* 8049A1EC */ void setLightChargeEffect(int); - /* 8049A370 */ void setArrowWaterNextPos(cXyz*, cXyz*); + /* 8049A370 */ int setArrowWaterNextPos(cXyz*, cXyz*); /* 8049A76C */ void setArrowAt(f32); /* 8049A9CC */ void arrowShooting(); /* 8049AC84 */ void setBombArrowExplode(cXyz*); /* 8049ACE0 */ void setRoomInfo(); /* 8049AD74 */ void clearNearActorData(); - /* 8049AD94 */ void getVibAngle(); + /* 8049AD94 */ s16 getVibAngle(); /* 8049AE64 */ void setNormalMatrix(); /* 8049AF18 */ void setSmokePos(); /* 8049AFEC */ void setKeepMatrix(); - /* 8049B120 */ void setStopActorMatrix(); + /* 8049B120 */ fopAc_ac_c* setStopActorMatrix(); /* 8049B214 */ void setBombMoveEffect(); - /* 8049B370 */ void checkReget(); - /* 8049B45C */ void procWait(); - /* 8049B764 */ void procMove(); - /* 8049C700 */ void procReturnInit(int); - /* 8049C874 */ void procReturn(); - /* 8049CB70 */ void procBGStop(); - /* 8049CC60 */ void procActorStop(); - /* 8049CCCC */ void procActorControllStop(); - /* 8049CCF0 */ void procSlingHitInit(cXyz*, dCcD_GObjInf*); - /* 8049CE50 */ void procSlingHit(); - /* 8049CEA0 */ void execute(); - /* 8049D0CC */ void draw(); - /* 8049D440 */ void create(); + /* 8049B370 */ bool checkReget(); + /* 8049B45C */ int procWait(); + /* 8049B764 */ int procMove(); + /* 8049C700 */ int procReturnInit(int); + /* 8049C874 */ int procReturn(); + /* 8049CB70 */ int procBGStop(); + /* 8049CC60 */ int procActorStop(); + /* 8049CCCC */ int procActorControllStop(); + /* 8049CCF0 */ int procSlingHitInit(cXyz*, dCcD_GObjInf*); + /* 8049CE50 */ int procSlingHit(); + /* 8049CEA0 */ int execute(); + /* 8049D0CC */ int draw(); + /* 8049D440 */ cPhs__Step create(); /* 8049D98C */ ~daArrow_c(); void setBombArrowExplode() { field_0x950 = 0; } - bool checkBombArrow() const { return mIsBombArrow == true; } + bool checkBombArrow() const { return mArrowType == true; } void setShoot() { fopAcM_SetParam(this, 1); } void setChargeShoot() { fopAcM_SetParam(this, 2); } @@ -71,26 +78,39 @@ public: NULL); } - /* 0x568 */ J3DModel* field_0x568; + /* 0x568 */ J3DModel* mpModel; /* 0x56C */ dBgS_ArrowLinChk field_0x56c; /* 0x5DC */ dBgS_ObjLinChk field_0x5dc; /* 0x64C */ dCcD_Stts field_0x64c; /* 0x688 */ dCcD_Cps field_0x688; /* 0x7CC */ dCcD_Sph field_0x7cc; - /* 0x904 */ Z2SoundObjArrow field_0x904; - /* 0x93C */ bool mIsBombArrow; - /* 0x93D */ u8 field_0x93d[0x948 - 0x93D]; - /* 0x948 */ u8 mReverb; - /* 0x949 */ u8 field_0x949[0x950 - 0x949]; - /* 0x950 */ u16 field_0x950; + /* 0x904 */ Z2SoundObjArrow mSoundObjArrow; + /* 0x93C */ u8 mArrowType; + /* 0x93D */ u8 field_0x93d; + /* 0x93E */ s8 field_0x93e; + /* 0x93F */ u8 field_0x93f; + /* 0x940 */ u8 field_0x940; + /* 0x941 */ u8 field_0x941; + /* 0x942 */ u8 field_0x942; + /* 0x943 */ u8 field_0x943; + /* 0x944 */ u8 field_0x944; + /* 0x945 */ u8 field_0x945; + /* 0x946 */ u8 field_0x946; + /* 0x947 */ u8 field_0x947; + /* 0x948 */ s8 mReverb; + /* 0x949 */ u8 field_0x949[0x94C - 0x949]; + /* 0x94C */ u16 field_0x94c; + /* 0x94E */ s16 field_0x94e; + /* 0x950 */ s16 field_0x950; /* 0x952 */ s16 field_0x952; /* 0x954 */ s16 field_0x954; - /* 0x956 */ u16 field_0x956; + /* 0x956 */ s16 field_0x956; /* 0x958 */ csXyz field_0x958; /* 0x960 */ int field_0x960; /* 0x964 */ u32 field_0x964; /* 0x968 */ u32 field_0x968; - /* 0x96C */ u8 field_0x96c[0x994 - 0x96C]; + /* 0x96C */ u32 field_0x96c[4]; + /* 0x97C */ u32 field_0x97c[6]; /* 0x994 */ u32 mHitAcID; /* 0x998 */ f32 field_0x998; /* 0x99C */ f32 field_0x99c; @@ -106,7 +126,11 @@ public: /* 0x9FC */ cXyz field_0x9fc; /* 0xA08 */ daPy_actorKeep_c field_0xa08; /* 0xA10 */ dPa_hermiteEcallBack_c field_0xa10; - /* 0xA28 */ void (daArrow_c::*mProcFunc)(); + /* 0xA28 */ int (daArrow_c::*mProcFunc)(); + + static s16 m_count; }; +STATIC_ASSERT(sizeof(daArrow_c) == 0xA34); + #endif /* D_A_ARROW_H */ diff --git a/include/rel/d/a/d_a_hozelda/d_a_hozelda.h b/include/rel/d/a/d_a_hozelda/d_a_hozelda.h index 1928bfaf79..7ee052896b 100644 --- a/include/rel/d/a/d_a_hozelda/d_a_hozelda.h +++ b/include/rel/d/a/d_a_hozelda/d_a_hozelda.h @@ -2,6 +2,7 @@ #define D_A_HOZELDA_H #include "f_op/f_op_actor_mng.h" +#include "JSystem/J3DGraphAnimator/J3DMaterialAnm.h" class daHoZelda_matAnm_c : public J3DMaterialAnm { public: @@ -49,6 +50,7 @@ public: /* 808489CC */ void execute(); /* 80848B64 */ void draw(); + MtxP getRightHandMtx() { return mpZeldaModel->getAnmMtx(22); } u8 checkBowMode() const { return field_0x6d8; } void setDamageInit() { field_0x6db = 1; } diff --git a/include/rel/d/a/e/d_a_e_pz/d_a_e_pz.h b/include/rel/d/a/e/d_a_e_pz/d_a_e_pz.h index 7570446059..76862b840e 100644 --- a/include/rel/d/a/e/d_a_e_pz/d_a_e_pz.h +++ b/include/rel/d/a/e/d_a_e_pz/d_a_e_pz.h @@ -3,4 +3,40 @@ #include "dolphin/types.h" +struct daE_PZ_c { + void onBombArrowHit() { field_0x845 = 1; } + + /* 807585BC */ void draw(); + /* 80758800 */ void setBck(int, u8, f32, f32); + /* 807588AC */ void setActionMode(int, int); + /* 807588B8 */ void mEntrySUB(bool); + /* 80758A94 */ void mPzScaleSet(bool); + /* 80758BA0 */ void mEnemyScaleSet(); + /* 80758D44 */ void getCutType(); + /* 80758DA4 */ void mSetFirePos(); + /* 80758E04 */ void damage_check(); + /* 807592F4 */ void executeSearchPoint(); + /* 807593CC */ void executeOpeningDemo(); + /* 8075B7E0 */ void mPointerSet(); + /* 8075B970 */ void executeWait(); + /* 8075C6AC */ void executeAttack(); + /* 8075CB80 */ void executeDamage(); + /* 8075CE68 */ void executeDead(); + /* 8075D94C */ void executeSummonsBullet(); + /* 8075F0BC */ void executeBullet(); + /* 8075F3A8 */ void action(); + /* 8075F510 */ void action_fire(); + /* 8075F578 */ void fire_mtx_set(); + /* 8075F734 */ void mtx_set(); + /* 8075F7E8 */ void cc_set(); + /* 8075F964 */ void execute(); + /* 8075FA88 */ void _delete(); + /* 8075FB4C */ void CreateHeap(); + /* 8076010C */ void create(); + /* 807607EC */ daE_PZ_c(); + + /* 0x000 */ u8 base[0x845]; + /* 0x845 */ u8 field_0x845; +}; + #endif /* D_A_E_PZ_H */ |
