d_a_e_tk_ball Matching (#2402)

* d_a_e_tk_ball matching

* d_a_e_tk_ball cleanup

* d_a_e_tk_ball comments
This commit is contained in:
Niklas Bauer
2025-04-20 18:05:58 -07:00
committed by GitHub
parent b2d665c911
commit 2e10e625d3
6 changed files with 453 additions and 357 deletions
+1 -1
View File
@@ -1676,7 +1676,7 @@ config.libs = [
ActorRel(MatchingFor("GZ2E01"), "d_a_e_th_ball"), ActorRel(MatchingFor("GZ2E01"), "d_a_e_th_ball"),
ActorRel(MatchingFor("GZ2E01"), "d_a_e_tk"), ActorRel(MatchingFor("GZ2E01"), "d_a_e_tk"),
ActorRel(MatchingFor("GZ2E01"), "d_a_e_tk2"), ActorRel(MatchingFor("GZ2E01"), "d_a_e_tk2"),
ActorRel(NonMatching, "d_a_e_tk_ball"), ActorRel(MatchingFor("GZ2E01"), "d_a_e_tk_ball"),
ActorRel(NonMatching, "d_a_e_tt"), ActorRel(NonMatching, "d_a_e_tt"),
ActorRel(NonMatching, "d_a_e_vt"), ActorRel(NonMatching, "d_a_e_vt"),
ActorRel(NonMatching, "d_a_e_warpappear"), ActorRel(NonMatching, "d_a_e_warpappear"),
+2
View File
@@ -522,6 +522,8 @@ public:
void OnTgSetBit() { mObjTg.OnSPrmBit(1); } void OnTgSetBit() { mObjTg.OnSPrmBit(1); }
void OffTgSetBit() { mObjTg.ClrSet(); } void OffTgSetBit() { mObjTg.ClrSet(); }
void OnCoSetBit() { mObjCo.OnSPrmBit(1); } void OnCoSetBit() { mObjCo.OnSPrmBit(1); }
void OffAtVsEnemyBit() { mObjAt.OffSPrmBit(0x2); }
void OnAtVsEnemyBit() { mObjAt.OnSPrmBit(0x2); }
void OffAtVsPlayerBit() { mObjAt.OffSPrmBit(0xC); } void OffAtVsPlayerBit() { mObjAt.OffSPrmBit(0xC); }
void OnAtVsPlayerBit() { mObjAt.OnSPrmBit(0xC); } void OnAtVsPlayerBit() { mObjAt.OnSPrmBit(0xC); }
void OnCoSPrmBit(u32 flag) { mObjCo.OnSPrmBit(flag); } void OnCoSPrmBit(u32 flag) { mObjCo.OnSPrmBit(flag); }
+31 -7
View File
@@ -1,21 +1,45 @@
#ifndef D_A_E_TK_BALL_H #ifndef D_A_E_TK_BALL_H
#define D_A_E_TK_BALL_H #define D_A_E_TK_BALL_H
#include "f_op/f_op_actor_mng.h"
#include "f_op/f_op_actor.h"
#include "d/d_cc_d.h"
/** /**
* @ingroup actors-enemies * @ingroup actors-enemies
* @class e_tk_ball_class * @class e_tk_ball_class
* @brief Fire/Water Toadpoli Ball * @brief Fire/Water Toadpoli Ball
* *
* @details * @details Projectiles spat by Toadpoli enemies at the player.
* * Two types exist: fire and water. Link can deflect these balls
* with his shield or slice them with his sword. When deflected
* while locked on to the enemy, they will return to the Toadpoli
* that fired them.
*/ */
class e_tk_ball_class : public fopEn_enemy_c { class e_tk_ball_class : public fopEn_enemy_c {
public: public:
/* 0x5ac */ u8 field_0x5ac[0x8cc - 0x5ac]; /* 0x5AC */ request_of_phase_process_class mPhaseReq;
/* 0x5B4 */ u8 mType;
/* 0x5B5 */ u8 mArg1;
/* 0x5B8 */ J3DModel* mpModel;
/* 0x5BC */ Z2SoundObjSimple mSound;
/* 0x5DC */ s16 mLifetime;
/* 0x5DE */ s16 mAction;
/* 0x5E0 */ s16 mMode;
/* 0x5E2 */ s16 mActionTimer[2];
/* 0x5E6 */ s16 mInvincibilityTimer;
/* 0x5E8 */ cXyz mInitalPosition;
/* 0x5F4 */ f32 mInitalDistance;
/* 0x5F8 */ f32 mArcHeight;
/* 0x5FC */ dCcD_Stts mStts;
/* 0x638 */ dCcD_Sph mAtSph;
/* 0x770 */ dCcD_Sph mTgSph;
/* 0x8A8 */ u32 mParticleKey[2];
/* 0x8B0 */ cXyz mParticleDirection;
/* 0x8BC */ cXyz mPreviousPosition;
/* 0x8C8 */ bool mSuspended;
}; };
STATIC_ASSERT(sizeof(e_tk_ball_class) == 0x8cc); STATIC_ASSERT(sizeof(e_tk_ball_class) == 0x8CC);
#endif /* D_A_E_TK_BALL_H */ #endif /* D_A_E_TK_BALL_H */
+1 -1
View File
@@ -630,7 +630,7 @@ static int daE_TK_Execute(e_tk_class* i_this) {
static_cast<e_tk_ball_class*>(fopAcM_SearchByID(i_this->mBallID)); static_cast<e_tk_ball_class*>(fopAcM_SearchByID(i_this->mBallID));
if (ball_actor != NULL) { if (ball_actor != NULL) {
ball_actor->current.pos = i_this->eyePos; ball_actor->current.pos = i_this->eyePos;
ball_actor->field_0x5ac[0x31C] = 0x0; ball_actor->mSuspended = false;
} }
cXyz scale; cXyz scale;
+1 -1
View File
@@ -441,7 +441,7 @@ static int daE_TK2_Execute(e_tk2_class* i_this) {
static_cast<e_tk_ball_class*>(fopAcM_SearchByID(i_this->mBallID)); static_cast<e_tk_ball_class*>(fopAcM_SearchByID(i_this->mBallID));
if (ball_actor != NULL) { if (ball_actor != NULL) {
ball_actor->current.pos = i_this->eyePos; ball_actor->current.pos = i_this->eyePos;
ball_actor->field_0x5ac[0x31C] = 0x0; ball_actor->mSuspended = false;
} }
cXyz scale; cXyz scale;
scale.setall(2.0f); scale.setall(2.0f);
File diff suppressed because it is too large Load Diff