2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-16 08:17:03 +00:00

RuntimeCommon: Use const on member functions where applicable

Adds missing const qualifiers on class member functions that don't
modify instance state.
This commit is contained in:
Lioncash
2019-08-14 06:04:11 -04:00
parent cf294db9eb
commit d3d629d405
91 changed files with 269 additions and 248 deletions

View File

@@ -50,7 +50,7 @@ public:
const CDamageInfo& GetFireBreathDamage() const { return x4c_fireBreathDamage; }
const CDamageVulnerability& GetShellDamageVulnerability() const { return xd0_shellVulnerabilities; }
float GetShellHitPoints() const { return x140_shellHitPoints; }
s16 GetShellCrackSfx() { return x144_shellCrackSfx; }
s16 GetShellCrackSfx() const { return x144_shellCrackSfx; }
};
class CBabygoth final : public CPatterned {
@@ -130,9 +130,9 @@ private:
void ApplySeparationBehavior(CStateManager&);
bool IsMouthCollisionActor(TUniqueId uid) { return x9f6_mouthCollisionActor == uid; }
bool IsMouthCollisionActor(TUniqueId uid) const { return x9f6_mouthCollisionActor == uid; }
bool IsShell(TUniqueId uid) {
bool IsShell(TUniqueId uid) const {
for (TUniqueId shellId : x9f8_shellIds) {
if (shellId == uid)
return true;
@@ -172,7 +172,7 @@ private:
void UpdateHealth(CStateManager&);
float CalculateShellCrackHP(EShellState state);
float CalculateShellCrackHP(EShellState state) const;
void UpdateAttackTimeLeft(CStateManager& mgr);