Skip to content

Commit 7bb6063

Browse files
committed
Match and link CGunController
1 parent ac3bd45 commit 7bb6063

21 files changed

Lines changed: 647 additions & 57 deletions

File tree

config/GM8E01_00/symbols.txt

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8947,14 +8947,14 @@ fn_801CFF50 = .text:0x801CFF50; // type:function size:0x1D8
89478947
PreRender__10CFishCloudFR13CStateManagerRC14CFrustumPlanes = .text:0x801D0128; // type:function size:0x80 scope:global
89488948
Think__10CFishCloudFfR13CStateManager = .text:0x801D01A8; // type:function size:0x784 scope:global
89498949
GetTouchBounds__10CFishCloudCFv = .text:0x801D092C; // type:function size:0x70 scope:global
8950-
fn_801D099C = .text:0x801D099C; // type:function size:0xF4
8950+
RemoveRepulsor__10CFishCloudF9TUniqueId = .text:0x801D099C; // type:function size:0xF4
89518951
fn_801D0A90 = .text:0x801D0A90; // type:function size:0x4C
89528952
fn_801D0ADC = .text:0x801D0ADC; // type:function size:0xB4
8953-
fn_801D0B90 = .text:0x801D0B90; // type:function size:0xF4
8954-
fn_801D0C84 = .text:0x801D0C84; // type:function size:0x15C
8953+
RemoveAttractor__10CFishCloudF9TUniqueId = .text:0x801D0B90; // type:function size:0xF4
8954+
AddRepulsor__10CFishCloudF9TUniqueIdbff = .text:0x801D0C84; // type:function size:0x15C
89558955
fn_801D0DE0 = .text:0x801D0DE0; // type:function size:0x8C
89568956
fn_801D0E6C = .text:0x801D0E6C; // type:function size:0x2D8
8957-
fn_801D1144 = .text:0x801D1144; // type:function size:0x15C
8957+
AddAttractor__10CFishCloudF9TUniqueIdbff = .text:0x801D1144; // type:function size:0x15C
89588958
AcceptScriptMsg__10CFishCloudF20EScriptObjectMessage9TUniqueIdR13CStateManager = .text:0x801D12A0; // type:function size:0x320 scope:global
89598959
PlaceBoid__10CFishCloudFR13CStateManagerRQ210CFishCloud5CBoidRC6CAABox = .text:0x801D15C0; // type:function size:0x294 scope:global
89608960
FindClosestPlane__10CFishCloudCFRC6CAABoxRC9CVector3f = .text:0x801D1854; // type:function size:0x46C scope:global
@@ -9089,19 +9089,19 @@ Flinch__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D7EC0; // type:funct
90899089
Attack__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D7F60; // type:function size:0x1AC scope:global
90909090
GetDamageVulnerability__9CJellyZapCFRC9CVector3fRC9CVector3fRC11CDamageInfo = .text:0x801D810C; // type:function size:0x48 scope:global
90919091
GetCollisionResponseType__9CJellyZapCFRC9CVector3fRC9CVector3fRC11CWeaponModei = .text:0x801D8154; // type:function size:0x3C scope:global
9092-
sub801d8190__9CJellyZapFv = .text:0x801D8190; // type:function size:0x18 scope:global
9092+
HitShell__9CJellyZapCFRC9CVector3f = .text:0x801D8190; // type:function size:0x18 scope:global
90939093
Suck__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D81A8; // type:function size:0x318 scope:global
90949094
Active__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D84C0; // type:function size:0x16C scope:global
90959095
InActive__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D862C; // type:function size:0x70 scope:global
90969096
ShouldAttack__9CJellyZapFR13CStateManagerf = .text:0x801D869C; // type:function size:0x18 scope:global
90979097
ShouldSpecialAttack__9CJellyZapFR13CStateManagerf = .text:0x801D86B4; // type:function size:0x20 scope:global
90989098
InAttackPosition__9CJellyZapFR13CStateManagerf = .text:0x801D86D4; // type:function size:0x88 scope:global
90999099
InDetectionRange__9CJellyZapFR13CStateManagerf = .text:0x801D875C; // type:function size:0x38 scope:global
9100-
DoUserAnimEvent__9CJellyZapFR13CStateManagerRC13CInt32POINode14EUserEventType = .text:0x801D8794; // type:function size:0x120 scope:global
9100+
DoUserAnimEvent__9CJellyZapFR13CStateManagerRC13CInt32POINode14EUserEventTypef = .text:0x801D8794; // type:function size:0x120 scope:global
91019101
AcceptScriptMsg__9CJellyZapF20EScriptObjectMessage9TUniqueIdR13CStateManager = .text:0x801D88B4; // type:function size:0xAC scope:global
91029102
Think__9CJellyZapFfR13CStateManager = .text:0x801D8960; // type:function size:0x120 scope:global
91039103
Accept__9CJellyZapFR8IVisitor = .text:0x801D8A80; // type:function size:0x38 scope:global
9104-
__ct__9CJellyZapF9TUniqueIdRCQ24rstl66basic_string<c,Q24rstl14char_traits<c>,Q24rstl17rmemory_allocator>RC11CEntityInfoRC12CTransform4fRC10CModelDataRC11CDamageInfofffffffffffRC14CPatternedInfoRC16CActorParameters = .text:0x801D8AB8; // type:function size:0x23C scope:global
9104+
__ct__9CJellyZapF9TUniqueIdRCQ24rstl66basic_string<c,Q24rstl14char_traits<c>,Q24rstl17rmemory_allocator>RC11CEntityInfoRC12CTransform4fRC10CModelDataRC11CDamageInfobffffffffffffRC14CPatternedInfoRC16CActorParameters = .text:0x801D8AB8; // type:function size:0x23C scope:global
91059105
__dt__23CScriptControllerActionFv = .text:0x801D8CF4; // type:function size:0x60 scope:weak
91069106
GetCommand__23CScriptControllerActionFQ223CScriptControllerAction9ECommands = .text:0x801D8D54; // type:function size:0x4 scope:global
91079107
Think__23CScriptControllerActionFfR13CStateManager = .text:0x801D8D58; // type:function size:0x14C scope:global
@@ -18552,7 +18552,7 @@ __vt__15CScriptVisorGoo = .data:0x803E58C0; // type:object size:0x6C scope:globa
1855218552
lbl_803E5930 = .data:0x803E5930; // type:object size:0xC data:4byte
1855318553
lbl_803E593C = .data:0x803E593C; // type:object size:0xC data:4byte
1855418554
lbl_803E5948 = .data:0x803E5948; // type:object size:0xC data:4byte
18555-
lbl_803E5954 = .data:0x803E5954; // type:object size:0x2CC
18555+
__vt__9CJellyZap = .data:0x803E5954; // type:object size:0x2CC
1855618556
__vt__23CScriptControllerAction = .data:0x803E5C20; // type:object size:0x20 scope:global
1855718557
__vt__13CScriptSwitch = .data:0x803E5C40; // type:object size:0x20 scope:global
1855818558
__vt__8CABSIdle = .data:0x803E5C60; // type:object size:0x20 scope:global
@@ -18562,7 +18562,7 @@ __vt__24CScriptPlayerStateChange = .data:0x803E5CC0; // type:object size:0x20 sc
1856218562
lbl_803E5CE0 = .data:0x803E5CE0; // type:object size:0x2CC
1856318563
jumptable_803E5FAC = .data:0x803E5FAC; // type:object size:0x48 scope:local
1856418564
jumptable_803E5FF4 = .data:0x803E5FF4; // type:object size:0x80 scope:local
18565-
lbl_803E6074 = .data:0x803E6074; // type:object size:0x294
18565+
__vt__16CDestroyableRock = .data:0x803E6074; // type:object size:0x294
1856618566
lbl_803E6308 = .data:0x803E6308; // type:object size:0x6C
1856718567
jumptable_803E6374 = .data:0x803E6374; // type:object size:0x20 scope:local
1856818568
__vt__18CScriptAiJumpPoint = .data:0x803E6398; // type:object size:0x6C scope:global
@@ -25022,9 +25022,9 @@ lbl_805AC87C = .sdata2:0x805AC87C; // type:object size:0x4 align:4 data:float
2502225022
lbl_805AC880 = .sdata2:0x805AC880; // type:object size:0x4 align:4 data:float
2502325023
lbl_805AC884 = .sdata2:0x805AC884; // type:object size:0x4 align:4 data:float
2502425024
lbl_805AC888 = .sdata2:0x805AC888; // type:object size:0x8 align:4 data:float
25025-
lbl_805AC890 = .sdata2:0x805AC890; // type:object size:0x4 align:4 data:float
25026-
lbl_805AC894 = .sdata2:0x805AC894; // type:object size:0x4 align:4 data:float
25027-
lbl_805AC898 = .sdata2:0x805AC898; // type:object size:0x8 align:4 data:float
25025+
@520 = .sdata2:0x805AC890; // type:object size:0x4 align:4 data:float
25026+
@653 = .sdata2:0x805AC894; // type:object size:0x4 align:4 data:float
25027+
@654 = .sdata2:0x805AC898; // type:object size:0x4 align:4 data:float
2502825028
lbl_805AC8A0 = .sdata2:0x805AC8A0; // type:object size:0x4 align:4 data:float
2502925029
lbl_805AC8A4 = .sdata2:0x805AC8A4; // type:object size:0x4 align:4 data:float
2503025030
lbl_805AC8A8 = .sdata2:0x805AC8A8; // type:object size:0x8 align:4 data:float

config/GM8E01_01/symbols.txt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8947,14 +8947,14 @@ fn_801CFF50 = .text:0x801CFFCC; // type:function size:0x1D8 scope:global
89478947
PreRender__10CFishCloudFR13CStateManagerRC14CFrustumPlanes = .text:0x801D01A4; // type:function size:0x80 scope:global
89488948
Think__10CFishCloudFfR13CStateManager = .text:0x801D0224; // type:function size:0x784 scope:global
89498949
GetTouchBounds__10CFishCloudCFv = .text:0x801D09A8; // type:function size:0x70 scope:global
8950-
fn_801D099C = .text:0x801D0A18; // type:function size:0xF4 scope:global
8950+
RemoveRepulsor__10CFishCloudF9TUniqueId = .text:0x801D0A18; // type:function size:0xF4 scope:global
89518951
fn_801D0A90 = .text:0x801D0B0C; // type:function size:0x4C scope:global
89528952
fn_801D0ADC = .text:0x801D0B58; // type:function size:0xB4 scope:global
8953-
fn_801D0B90 = .text:0x801D0C0C; // type:function size:0xF4 scope:global
8954-
fn_801D0C84 = .text:0x801D0D00; // type:function size:0x15C scope:global
8953+
RemoveAttractor__10CFishCloudF9TUniqueId = .text:0x801D0C0C; // type:function size:0xF4 scope:global
8954+
AddRepulsor__10CFishCloudF9TUniqueIdbff = .text:0x801D0D00; // type:function size:0x15C scope:global
89558955
fn_801D0DE0 = .text:0x801D0E5C; // type:function size:0x8C scope:global
89568956
fn_801D0E6C = .text:0x801D0EE8; // type:function size:0x2D8 scope:global
8957-
fn_801D1144 = .text:0x801D11C0; // type:function size:0x15C scope:global
8957+
AddAttractor__10CFishCloudF9TUniqueIdbff = .text:0x801D11C0; // type:function size:0x15C scope:global
89588958
AcceptScriptMsg__10CFishCloudF20EScriptObjectMessage9TUniqueIdR13CStateManager = .text:0x801D131C; // type:function size:0x320 scope:global
89598959
PlaceBoid__10CFishCloudFR13CStateManagerRQ210CFishCloud5CBoidRC6CAABox = .text:0x801D163C; // type:function size:0x294 scope:global
89608960
FindClosestPlane__10CFishCloudCFRC6CAABoxRC9CVector3f = .text:0x801D18D0; // type:function size:0x46C scope:global
@@ -9089,19 +9089,19 @@ Flinch__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D7F3C; // type:funct
90899089
Attack__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D7FDC; // type:function size:0x1AC scope:global
90909090
GetDamageVulnerability__9CJellyZapCFRC9CVector3fRC9CVector3fRC11CDamageInfo = .text:0x801D8188; // type:function size:0x48 scope:global
90919091
GetCollisionResponseType__9CJellyZapCFRC9CVector3fRC9CVector3fRC11CWeaponModei = .text:0x801D81D0; // type:function size:0x3C scope:global
9092-
sub801d8190__9CJellyZapFv = .text:0x801D820C; // type:function size:0x18 scope:global
9092+
HitShell__9CJellyZapCFRC9CVector3f = .text:0x801D820C; // type:function size:0x18 scope:global
90939093
Suck__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D8224; // type:function size:0x318 scope:global
90949094
Active__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D853C; // type:function size:0x16C scope:global
90959095
InActive__9CJellyZapFR13CStateManager9EStateMsgf = .text:0x801D86A8; // type:function size:0x70 scope:global
90969096
ShouldAttack__9CJellyZapFR13CStateManagerf = .text:0x801D8718; // type:function size:0x18 scope:global
90979097
ShouldSpecialAttack__9CJellyZapFR13CStateManagerf = .text:0x801D8730; // type:function size:0x20 scope:global
90989098
InAttackPosition__9CJellyZapFR13CStateManagerf = .text:0x801D8750; // type:function size:0x88 scope:global
90999099
InDetectionRange__9CJellyZapFR13CStateManagerf = .text:0x801D87D8; // type:function size:0x38 scope:global
9100-
DoUserAnimEvent__9CJellyZapFR13CStateManagerRC13CInt32POINode14EUserEventType = .text:0x801D8810; // type:function size:0x120 scope:global
9100+
DoUserAnimEvent__9CJellyZapFR13CStateManagerRC13CInt32POINode14EUserEventTypef = .text:0x801D8810; // type:function size:0x120 scope:global
91019101
AcceptScriptMsg__9CJellyZapF20EScriptObjectMessage9TUniqueIdR13CStateManager = .text:0x801D8930; // type:function size:0xAC scope:global
91029102
Think__9CJellyZapFfR13CStateManager = .text:0x801D89DC; // type:function size:0x120 scope:global
91039103
Accept__9CJellyZapFR8IVisitor = .text:0x801D8AFC; // type:function size:0x38 scope:global
9104-
__ct__9CJellyZapF9TUniqueIdRCQ24rstl66basic_string<c,Q24rstl14char_traits<c>,Q24rstl17rmemory_allocator>RC11CEntityInfoRC12CTransform4fRC10CModelDataRC11CDamageInfofffffffffffRC14CPatternedInfoRC16CActorParameters = .text:0x801D8B34; // type:function size:0x23C scope:global
9104+
__ct__9CJellyZapF9TUniqueIdRCQ24rstl66basic_string<c,Q24rstl14char_traits<c>,Q24rstl17rmemory_allocator>RC11CEntityInfoRC12CTransform4fRC10CModelDataRC11CDamageInfobffffffffffffRC14CPatternedInfoRC16CActorParameters = .text:0x801D8B34; // type:function size:0x23C scope:global
91059105
__dt__23CScriptControllerActionFv = .text:0x801D8D70; // type:function size:0x60 scope:weak
91069106
GetCommand__23CScriptControllerActionFQ223CScriptControllerAction9ECommands = .text:0x801D8DD0; // type:function size:0x4 scope:global
91079107
Think__23CScriptControllerActionFfR13CStateManager = .text:0x801D8DD4; // type:function size:0x14C scope:global

configure.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -948,7 +948,7 @@ def MatchingFor(*versions):
948948
Object(NonMatching, "MetroidPrime/PathFinding/CPathFindRegion.cpp"),
949949
Object(NonMatching, "MetroidPrime/PathFinding/CPathFindArea.cpp"),
950950
Object(
951-
NonMatching, "MetroidPrime/Weapons/GunController/CGunController.cpp"
951+
MatchingFor("GM8E01_00", "GM8E01_01"), "MetroidPrime/Weapons/GunController/CGunController.cpp"
952952
),
953953
Object(NonMatching, "MetroidPrime/Weapons/GunController/CGSFreeLook.cpp"),
954954
Object(

include/MetroidPrime/CActor.hpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,8 @@ class CActor : public CEntity {
157157

158158
TUniqueId InFluidId() const { return xc4_fluidId; }
159159

160+
void SetDamageMag(const float d) { xd0_damageMag = d; }
161+
160162
bool GetTransformDirty() const { return xe4_27_notInSortedLists; }
161163
bool GetTransformDirtySpare() const { return xe4_28_transformDirty; }
162164
bool GetPreRenderHasMoved() const { return xe4_29_actorLightsDirty; }
@@ -182,6 +184,7 @@ class CActor : public CEntity {
182184
void SetMuted(bool b);
183185
void SetThermalFlags(EThermalFlags flags) { xe6_27_thermalVisorFlags = flags; }
184186
void SetRenderParticleDatabaseInside(bool b) { xe6_29_renderParticleDBInside = b; }
187+
void SetDoTargetDistanceTest(const bool b) { xe7_30_doTargetDistanceTest = b; }
185188
void SetTargetable(bool b) { xe7_31_targetable = b; }
186189

187190
void RemoveMaterial(EMaterialTypes, EMaterialTypes, EMaterialTypes, EMaterialTypes,

include/MetroidPrime/CAnimData.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ class CAnimData {
5252

5353
void SetIsAnimating(bool v) { x220_24_animating = v; }
5454
void SetParticleEffectState(const rstl::string& name, const bool active, CStateManager& mgr) {
55-
x120_particleDB.SetParticleEffectState(name, active, mgr);
56-
}
55+
x120_particleDB.SetParticleEffectState(name, active, mgr);
56+
}
5757

5858
int GetCharacterIndex() const { return x204_charIdx; }
5959
float GetAverageVelocity(int idx) const;
@@ -94,7 +94,7 @@ class CAnimData {
9494
// AdvanceIgnoreParticles__9CAnimDataFfR9CRandom16b
9595
// Advance__9CAnimDataFfRC9CVector3fR13CStateManagerb
9696
// DoAdvance__9CAnimDataFfRbR9CRandom16b
97-
void SetAnimation(const CAnimPlaybackParms& parms, bool noTrans);
97+
void SetAnimation(const CAnimPlaybackParms& parms, const bool noTrans);
9898
void GetAnimationPrimitives(const CAnimPlaybackParms& parms,
9999
rstl::set< CPrimitive >& primsOut) const;
100100
// PrimitiveSetToTokenVector__9CAnimDataFRCQ24rstl72set<10CPrimitive,Q24rstl18less<10CPrimitive>,Q24rstl17rmemory_allocator>RQ24rstl42vector<6CToken,Q24rstl17rmemory_allocator>b

include/MetroidPrime/CAnimPlaybackParms.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ class CAnimPlaybackParms {
2121
const CVector3f* x24_objectScale;
2222

2323
public:
24-
CAnimPlaybackParms(int animA, int animB, float blendWeight, bool animating)
24+
CAnimPlaybackParms(const int animA, const int animB, const float blendWeight,
25+
const bool animating)
2526
: x0_animA(animA)
2627
, x4_animB(animB)
2728
, x8_blendWeight(blendWeight)

include/MetroidPrime/CModelData.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ class CModelData {
7070
CModelData();
7171
CModelData(const CAnimRes&);
7272
CModelData(const CStaticRes&);
73+
//CModelData(const CModelData&);
7374
~CModelData();
7475

7576
CAdvancementDeltas AdvanceAnimation(float dt, CStateManager& mgr, TAreaId aid, bool advTree);

include/MetroidPrime/Enemies/CJellyZap.hpp

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,60 @@
44
#include "MetroidPrime/Enemies/CPatterned.hpp"
55

66
class CJellyZap : public CPatterned {
7+
public:
8+
CJellyZap(TUniqueId uid, const rstl::string& name, const CEntityInfo& info,
9+
const CTransform4f& xf, const CModelData& mData, const CDamageInfo& attackDamage,
10+
bool b1, float attackRadius, float f2, float f3, float f4, float attackDelay, float f6,
11+
float f7, float f8, float priority, float repulseRadius, float attractRadius, float f12,
12+
const CPatternedInfo& pInfo, const CActorParameters& actParms);
713

14+
void Accept(IVisitor& visitor) override;
15+
void Think(float dt, CStateManager& mgr) override;
16+
void AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId uid, CStateManager& mgr) override;
17+
void DoUserAnimEvent(CStateManager& mgr, const CInt32POINode& node, EUserEventType type,
18+
float dt) override;
19+
20+
bool InDetectionRange(CStateManager& mgr, float arg) override;
21+
bool InAttackPosition(CStateManager& mgr, float arg) override;
22+
bool ShouldSpecialAttack(CStateManager& mgr, float arg) override;
23+
bool ShouldAttack(CStateManager& mgr, float arg) override;
24+
void InActive(CStateManager& mgr, EStateMsg msg, float arg) override;
25+
void Active(CStateManager& mgr, EStateMsg msg, float arg) override;
26+
void Suck(CStateManager& mgr, EStateMsg msg, float arg) override;
27+
EWeaponCollisionResponseTypes GetCollisionResponseType(const CVector3f&, const CVector3f&,
28+
const CWeaponMode&, int) const override;
29+
const CDamageVulnerability* GetDamageVulnerability(const CVector3f& pos, const CVector3f& dir,
30+
const CDamageInfo& info) const override;
31+
void Attack(CStateManager& mgr, EStateMsg msg, float arg) override;
32+
void Flinch(CStateManager& mgr, EStateMsg msg, float arg) override;
33+
void KnockBack(const CVector3f&, CStateManager&, const CDamageInfo& info, EKnockBackType type,
34+
bool inDeferred, float magnitude) override;
35+
36+
private:
37+
void AddAttractor(CStateManager& mgr);
38+
void RemoveAllAttractors(CStateManager& mgr);
39+
void AddRepulsor(CStateManager& mgr);
40+
void AddSelfToFishCloud(CStateManager& mgr, float radius, float priority, bool repulsor);
41+
void RemoveSelfFromFishCloud(CStateManager& mgr);
42+
bool ClosestToPlayer(CStateManager& mgr) const;
43+
bool HitShell(const CVector3f&) const;
44+
uint x568_;
45+
CDamageInfo x56c_attackDamage;
46+
float x588_attackRadius;
47+
float x58c_;
48+
float x590_;
49+
float x594_;
50+
float x598_;
51+
float x59c_priority;
52+
float x5a0_repulseRadius;
53+
float x5a4_attractRadius;
54+
float x5a8_attackDelay;
55+
float x5ac_;
56+
float x5b0_;
57+
float x5b4_;
58+
bool x5b8_24_ : 1;
59+
bool x5b8_25_ : 1;
60+
bool x5b8_26_ : 1;
861
};
962

1063
#endif // _CJELLYZAP

include/MetroidPrime/Enemies/CPatterned.hpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,11 +274,16 @@ class CPatterned : public CAi {
274274
const CVector3f& GetMoveVector() const { return x310_moveVec; }
275275
void SetMoveVector(const CVector3f& vec) { x310_moveVec = vec; }
276276

277+
float GetFreezeDuration() const { return x4fc_freezeDur; }
278+
279+
void SetBaseDamageMag(const float mag) { x50c_baseDamageMag = mag; }
280+
277281
bool ApplyBoneTracking() const;
278282

279283
template < class T >
280284
static T* CastTo(const TPatternedCast< T >& ent);
281285

286+
void TryKnockBack(CStateManager& mgr, int arg);
282287
void TryLoopReaction(CStateManager& mgr, int arg);
283288
void TryCommand(CStateManager& mgr, int state, FTryCommandCallback cb, int arg);
284289

@@ -289,6 +294,8 @@ class CPatterned : public CAi {
289294

290295
float GetAnimationDistance(const CPASAnimParmData& data) const;
291296

297+
void UpdateThermalFrozenState(const bool thawed);
298+
292299
protected:
293300
EPatrolState x2d8_patrolState;
294301
TUniqueId x2dc_destObj;

include/MetroidPrime/Enemies/CThardus.hpp

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,34 @@
11
#ifndef _CTHARDUS
22
#define _CTHARDUS
3+
#include "MetroidPrime/Enemies/CPatterned.hpp"
4+
5+
class CDestroyableRock : public CAi {
6+
public:
7+
CDestroyableRock(TUniqueId id, bool active, const rstl::string& name, const CEntityInfo& info,
8+
const CTransform4f& xf, const CModelData& modelData, float mass,
9+
const CHealthInfo& health, const CDamageVulnerability& vulnerability,
10+
const CMaterialList& matList, CAssetId fsm, const CActorParameters& actParams,
11+
const CModelData& phazonModel, int w1);
12+
13+
void PreThink(float dt, CStateManager& mgr) override;
14+
void Think(float dt, CStateManager& mgr) override;
15+
16+
private:
17+
CModelData x2d8_phazonModel;
18+
float x324_;
19+
float x328_;
20+
float x32c_thermalMag;
21+
CColor x330_;
22+
bool x334_isCold;
23+
bool x335_usePhazonModel;
24+
CHealthInfo x338_healthInfo;
25+
bool x340_;
26+
bool x341_;
27+
};
328

429
class CThardus : public CPatterned {
530
public:
31+
void RenderThermalSpot(float dt) const;
632
void ShakeScreen(CStateManager& mgr, const CVector3f& position, const float, const float,
733
const float);
834
void StartTimedThermalFlash(CStateManager& mgr, float, CActor& actor);

0 commit comments

Comments
 (0)