Add CPlayerGun::GetBeamVelocity

Former-commit-id: e804eb8373
This commit is contained in:
Henrique Gemignani Passos Lima 2022-10-06 19:45:09 +03:00
parent 40ae0acae1
commit f3656746b6
2 changed files with 7 additions and 4 deletions

View File

@ -78,6 +78,7 @@ public:
virtual void Unload(CStateManager& mgr); virtual void Unload(CStateManager& mgr);
virtual bool IsLoaded() const; virtual bool IsLoaded() const;
const CVelocityInfo& GetVelocityInfo() const { return x1d0_velInfo; }
rstl::optional_object< CModelData >& SolidModelData() { return x10_solidModelData; } rstl::optional_object< CModelData >& SolidModelData() { return x10_solidModelData; }
CAABox GetBounds() const; CAABox GetBounds() const;

View File

@ -562,11 +562,13 @@ void CPlayerGun::InitMuzzleData() {
} }
} }
void CPlayerGun::InitCTData() { void CPlayerGun::InitCTData() { x77c_comboXferGen = rstl::auto_ptr< CElementGen >(); }
x77c_comboXferGen = rstl::auto_ptr< CElementGen >();
}
float CPlayerGun::GetBeamVelocity() const { return 0.0f; } float CPlayerGun::GetBeamVelocity() const {
if (x72c_currentBeam->IsLoaded())
return x72c_currentBeam->GetVelocityInfo().GetVelocity(int(x330_chargeState)).GetY();
return 10.f;
}
TUniqueId CPlayerGun::GetTargetId(CStateManager&) { return TUniqueId(0, 0); } TUniqueId CPlayerGun::GetTargetId(CStateManager&) { return TUniqueId(0, 0); }