Match & link CScriptPickup

This commit is contained in:
Luke Street 2022-10-08 01:12:48 -04:00
parent 27fedfee46
commit a7cefd7c4b
9 changed files with 25 additions and 19 deletions

View File

@ -156,8 +156,8 @@ lbl_805A6E18:
.balign 8 .balign 8
# CPlayerGun # CPlayerGun
.global lbl_805A8D70 .global skTractorBeamFactor__10CPlayerGun
lbl_805A8D70: skTractorBeamFactor__10CPlayerGun:
.skip 0x4 .skip 0x4
.global lbl_805A8D74 .global lbl_805A8D74
lbl_805A8D74: lbl_805A8D74:
@ -5906,7 +5906,7 @@ lbl_8003F4C0:
/* 8003F4F0 0003C450 98 9E 08 32 */ stb r4, 0x832(r30) /* 8003F4F0 0003C450 98 9E 08 32 */ stb r4, 0x832(r30)
lbl_8003F4F4: lbl_8003F4F4:
/* 8003F4F4 0003C454 C0 3E 03 40 */ lfs f1, 0x340(r30) /* 8003F4F4 0003C454 C0 3E 03 40 */ lfs f1, 0x340(r30)
/* 8003F4F8 0003C458 C0 0D A1 B0 */ lfs f0, lbl_805A8D70@sda21(r13) /* 8003F4F8 0003C458 C0 0D A1 B0 */ lfs f0, skTractorBeamFactor__10CPlayerGun@sda21(r13)
/* 8003F4FC 0003C45C FC 01 00 40 */ fcmpo cr0, f1, f0 /* 8003F4FC 0003C45C FC 01 00 40 */ fcmpo cr0, f1, f0
/* 8003F500 0003C460 40 81 02 2C */ ble lbl_8003F72C /* 8003F500 0003C460 40 81 02 2C */ ble lbl_8003F72C
/* 8003F504 0003C464 7F C3 F3 78 */ mr r3, r30 /* 8003F504 0003C464 7F C3 F3 78 */ mr r3, r30
@ -10826,7 +10826,7 @@ __sinit_CPlayerGun_cpp:
/* 80043BAC 00040B0C 38 61 00 0C */ addi r3, r1, 0xc /* 80043BAC 00040B0C 38 61 00 0C */ addi r3, r1, 0xc
/* 80043BB0 00040B10 C0 42 84 FC */ lfs f2, lbl_805AA21C@sda21(r2) /* 80043BB0 00040B10 C0 42 84 FC */ lfs f2, lbl_805AA21C@sda21(r2)
/* 80043BB4 00040B14 D0 04 00 04 */ stfs f0, 4(r4) /* 80043BB4 00040B14 D0 04 00 04 */ stfs f0, 4(r4)
/* 80043BB8 00040B18 D0 6D A1 B0 */ stfs f3, lbl_805A8D70@sda21(r13) /* 80043BB8 00040B18 D0 6D A1 B0 */ stfs f3, skTractorBeamFactor__10CPlayerGun@sda21(r13)
/* 80043BBC 00040B1C C0 62 84 6C */ lfs f3, lbl_805AA18C@sda21(r2) /* 80043BBC 00040B1C C0 62 84 6C */ lfs f3, lbl_805AA18C@sda21(r2)
/* 80043BC0 00040B20 D0 04 00 08 */ stfs f0, 8(r4) /* 80043BC0 00040B20 D0 04 00 08 */ stfs f0, 8(r4)
/* 80043BC4 00040B24 C0 82 84 7C */ lfs f4, lbl_805AA19C@sda21(r2) /* 80043BC4 00040B24 C0 82 84 7C */ lfs f4, lbl_805AA19C@sda21(r2)

View File

@ -710,7 +710,7 @@ lbl_800C2DD8:
lbl_800C2E44: lbl_800C2E44:
/* 800C2E44 000BFDA4 C0 22 8D C8 */ lfs f1, lbl_805AAAE8@sda21(r2) /* 800C2E44 000BFDA4 C0 22 8D C8 */ lfs f1, lbl_805AAAE8@sda21(r2)
lbl_800C2E48: lbl_800C2E48:
/* 800C2E48 000BFDA8 C0 0D A1 B0 */ lfs f0, lbl_805A8D70@sda21(r13) /* 800C2E48 000BFDA8 C0 0D A1 B0 */ lfs f0, skTractorBeamFactor__10CPlayerGun@sda21(r13)
/* 800C2E4C 000BFDAC FC 01 00 40 */ fcmpo cr0, f1, f0 /* 800C2E4C 000BFDAC FC 01 00 40 */ fcmpo cr0, f1, f0
/* 800C2E50 000BFDB0 40 80 00 3C */ bge lbl_800C2E8C /* 800C2E50 000BFDB0 40 80 00 3C */ bge lbl_800C2E8C
/* 800C2E54 000BFDB4 88 1E 02 8C */ lbz r0, 0x28c(r30) /* 800C2E54 000BFDB4 88 1E 02 8C */ lbz r0, 0x28c(r30)
@ -745,7 +745,7 @@ lbl_800C2E9C:
lbl_800C2EC0: lbl_800C2EC0:
/* 800C2EC0 000BFE20 C0 22 8D C8 */ lfs f1, lbl_805AAAE8@sda21(r2) /* 800C2EC0 000BFE20 C0 22 8D C8 */ lfs f1, lbl_805AAAE8@sda21(r2)
lbl_800C2EC4: lbl_800C2EC4:
/* 800C2EC4 000BFE24 C0 0D A1 B0 */ lfs f0, lbl_805A8D70@sda21(r13) /* 800C2EC4 000BFE24 C0 0D A1 B0 */ lfs f0, skTractorBeamFactor__10CPlayerGun@sda21(r13)
/* 800C2EC8 000BFE28 FC 01 00 40 */ fcmpo cr0, f1, f0 /* 800C2EC8 000BFE28 FC 01 00 40 */ fcmpo cr0, f1, f0
/* 800C2ECC 000BFE2C 40 81 01 28 */ ble lbl_800C2FF4 /* 800C2ECC 000BFE2C 40 81 01 28 */ ble lbl_800C2FF4
/* 800C2ED0 000BFE30 80 BF 08 70 */ lwz r5, 0x870(r31) /* 800C2ED0 000BFE30 80 BF 08 70 */ lwz r5, 0x870(r31)

View File

@ -31,6 +31,7 @@ COMPLETE_OBJECTS = [
"MetroidPrime/CMemoryDrawEnum", "MetroidPrime/CMemoryDrawEnum",
"MetroidPrime/HUD/CHUDMemoParms", "MetroidPrime/HUD/CHUDMemoParms",
"MetroidPrime/ScriptObjects/CScriptDebugCameraWaypoint", "MetroidPrime/ScriptObjects/CScriptDebugCameraWaypoint",
"MetroidPrime/ScriptObjects/CScriptPickup",
"Weapons/IWeaponRenderer", "Weapons/IWeaponRenderer",
"Collision/CMaterialList", "Collision/CMaterialList",
"Collision/CMaterialFilter", "Collision/CMaterialFilter",

View File

@ -43,9 +43,9 @@ public:
f32 Get21() const { return m2.GetY(); } f32 Get21() const { return m2.GetY(); }
f32 Get22() const { return m2.GetZ(); } f32 Get22() const { return m2.GetZ(); }
f32 Get23() const { return posZ; } f32 Get23() const { return posZ; }
CVector3f GetColumn(EDimX dim) const { return CVector3f(m0.GetX(), m1.GetX(), m2.GetX()); } CVector3f GetColumn(EDimX dim) const { return CVector3f(m0[dim], m1[dim], m2[dim]); }
CVector3f GetColumn(EDimY dim) const { return CVector3f(m0.GetY(), m1.GetY(), m2.GetY()); } CVector3f GetColumn(EDimY dim) const { return CVector3f(m0[dim], m1[dim], m2[dim]); }
CVector3f GetColumn(EDimZ dim) const { return CVector3f(m0.GetZ(), m1.GetZ(), m2.GetZ()); } CVector3f GetColumn(EDimZ dim) const { return CVector3f(m0[dim], m1[dim], m2[dim]); }
// GetColumn__12CTransform4fCFi // GetColumn__12CTransform4fCFi
// GetCStyleMatrix__12CTransform4fCFv // GetCStyleMatrix__12CTransform4fCFv
CTransform4f GetInverse() const; CTransform4f GetInverse() const;

View File

@ -53,9 +53,9 @@ public:
f32& operator[](EDimX dim) { return mX; } f32& operator[](EDimX dim) { return mX; }
f32& operator[](EDimY dim) { return mY; } f32& operator[](EDimY dim) { return mY; }
f32& operator[](EDimZ dim) { return mZ; } f32& operator[](EDimZ dim) { return mZ; }
f32 operator[](EDimX) const { return mX; } const f32& operator[](EDimX) const { return mX; }
f32 operator[](EDimY) const { return mY; } const f32& operator[](EDimY) const { return mY; }
f32 operator[](EDimZ) const { return mZ; } const f32& operator[](EDimZ) const { return mZ; }
f32& operator[](int i) { return (&mX)[i]; } f32& operator[](int i) { return (&mX)[i]; }
f32 operator[](int i) const { return (&mX)[i]; } f32 operator[](int i) const { return (&mX)[i]; }

View File

@ -69,7 +69,8 @@ public:
// CPhysicsActor // CPhysicsActor
virtual const CCollisionPrimitive* GetCollisionPrimitive() const; virtual const CCollisionPrimitive* GetCollisionPrimitive() const;
virtual CTransform4f GetPrimitiveTransform() const; virtual CTransform4f GetPrimitiveTransform() const;
virtual void CollidedWith(TUniqueId id, const CCollisionInfoList& list, CStateManager& mgr); virtual void CollidedWith(const TUniqueId& id, const CCollisionInfoList& list,
CStateManager& mgr);
virtual f32 GetStepDownHeight() const; virtual f32 GetStepDownHeight() const;
virtual f32 GetStepUpHeight() const; virtual f32 GetStepUpHeight() const;
virtual f32 GetWeight() const; virtual f32 GetWeight() const;
@ -101,7 +102,9 @@ public:
const CVector3f& GetConstantForceWR() const { return xfc_constantForce; } const CVector3f& GetConstantForceWR() const { return xfc_constantForce; }
void SetConstantForceWR(const CVector3f& force) { xfc_constantForce = force; } void SetConstantForceWR(const CVector3f& force) { xfc_constantForce = force; }
const CAxisAngle& GetAngularMomentumWR() const { return x108_angularMomentum; } const CAxisAngle& GetAngularMomentumWR() const { return x108_angularMomentum; }
void SetAngularMomentumWR(const CAxisAngle& angularMomentum) { x108_angularMomentum = angularMomentum; } void SetAngularMomentumWR(const CAxisAngle& angularMomentum) {
x108_angularMomentum = angularMomentum;
}
const CVector3f& GetMomentumWR() const { return x150_momentum; } const CVector3f& GetMomentumWR() const { return x150_momentum; }
void SetMomentumWR(const CVector3f& momentum) { x150_momentum = momentum; } void SetMomentumWR(const CVector3f& momentum) { x150_momentum = momentum; }
const CVector3f& GetForceWR() const { return x15c_force; } const CVector3f& GetForceWR() const { return x15c_force; }
@ -111,7 +114,9 @@ public:
const CAxisAngle& GetTorqueWR() const { return x174_torque; } const CAxisAngle& GetTorqueWR() const { return x174_torque; }
void SetTorqueWR(const CAxisAngle& torque) { x174_torque = torque; } void SetTorqueWR(const CAxisAngle& torque) { x174_torque = torque; }
const CAxisAngle& GetAngularImpulseWR() const { return x180_angularImpulse; } const CAxisAngle& GetAngularImpulseWR() const { return x180_angularImpulse; }
void SetAngularImpulseWR(const CAxisAngle& angularImpulse) { x180_angularImpulse = angularImpulse; } void SetAngularImpulseWR(const CAxisAngle& angularImpulse) {
x180_angularImpulse = angularImpulse;
}
CPhysicsState GetPhysicsState() const; CPhysicsState GetPhysicsState() const;
void SetPhysicsState(const CPhysicsState& state); void SetPhysicsState(const CPhysicsState& state);

View File

@ -140,7 +140,8 @@ public:
// CPhysicsActor // CPhysicsActor
const CCollisionPrimitive* GetCollisionPrimitive() const override; const CCollisionPrimitive* GetCollisionPrimitive() const override;
CTransform4f GetPrimitiveTransform() const override; CTransform4f GetPrimitiveTransform() const override;
void CollidedWith(TUniqueId id, const CCollisionInfoList& list, CStateManager& mgr) override; void CollidedWith(const TUniqueId& id, const CCollisionInfoList& list,
CStateManager& mgr) override;
f32 GetStepDownHeight() const override; f32 GetStepDownHeight() const override;
f32 GetStepUpHeight() const override; f32 GetStepUpHeight() const override;
f32 GetWeight() const override; f32 GetWeight() const override;

View File

@ -172,7 +172,6 @@ public:
void DropPowerBomb(CStateManager&) const; void DropPowerBomb(CStateManager&) const;
void SetPhazonBeamFeedback(bool); void SetPhazonBeamFeedback(bool);
bool IsCharging() const { return x834_24_charging; }
float GetChargeBeamFactor() const { return x834_24_charging ? x340_chargeBeamFactor : 0.f; } float GetChargeBeamFactor() const { return x834_24_charging ? x340_chargeBeamFactor : 0.f; }
static float GetTractorBeamFactor() { return skTractorBeamFactor; } static float GetTractorBeamFactor() { return skTractorBeamFactor; }

View File

@ -187,7 +187,7 @@ void CScriptPickup::Touch(CActor& act, CStateManager& mgr) {
if (opts.GetShowPowerBombAmmoMessage()) { if (opts.GetShowPowerBombAmmoMessage()) {
opts.IncrementPowerBombAmmoCount(); opts.IncrementPowerBombAmmoCount();
CSamusHud::DisplayHudMemo(rstl::wstring_l(gpStringTable->GetString(109)), CSamusHud::DisplayHudMemo(rstl::wstring_l(gpStringTable->GetString(109)),
CHUDMemoParms(0.5f, true, false, false)); CHUDMemoParms(5.f, true, false, false));
} }
} }
} }