2022-10-09 05:13:17 +00:00
|
|
|
#ifndef _CWAVEBEAM
|
|
|
|
#define _CWAVEBEAM
|
|
|
|
|
|
|
|
#include "types.h"
|
2022-10-06 10:38:13 +00:00
|
|
|
|
|
|
|
#include "MetroidPrime/Weapons/CGunWeapon.hpp"
|
|
|
|
|
2022-12-07 22:48:51 +00:00
|
|
|
#include "rstl/single_ptr.hpp"
|
|
|
|
|
|
|
|
class CElectricDescription;
|
|
|
|
class CParticleElectric;
|
|
|
|
|
2022-10-06 10:38:13 +00:00
|
|
|
class CWaveBeam : public CGunWeapon {
|
|
|
|
public:
|
|
|
|
CWaveBeam(CAssetId characterId, EWeaponType type, TUniqueId playerId,
|
2022-10-09 05:13:17 +00:00
|
|
|
EMaterialTypes playerMaterial, const CVector3f& scale);
|
2023-02-06 07:21:28 +00:00
|
|
|
~CWaveBeam();
|
2022-12-07 22:48:51 +00:00
|
|
|
|
2023-02-06 07:21:28 +00:00
|
|
|
void PostRenderGunFx(const CStateManager& mgr, const CTransform4f& xf);
|
2022-12-07 22:48:51 +00:00
|
|
|
void UpdateGunFx(bool shotSmoke, float dt, const CStateManager& mgr,
|
2023-02-06 07:21:28 +00:00
|
|
|
const CTransform4f& xf);
|
2022-12-07 22:48:51 +00:00
|
|
|
void Fire(bool underwater, float dt, CPlayerState::EChargeStage chargeState,
|
|
|
|
const CTransform4f& xf, CStateManager& mgr, TUniqueId homingTarget, float chargeFactor1,
|
2023-02-06 07:21:28 +00:00
|
|
|
float chargeFactor2);
|
|
|
|
void EnableSecondaryFx(ESecondaryFxType type);
|
|
|
|
void Update(float dt, CStateManager& mgr);
|
|
|
|
void Load(CStateManager& mgr, bool subtypeBasePose);
|
|
|
|
void Unload(CStateManager& mgr);
|
|
|
|
bool IsLoaded() const;
|
2022-10-09 05:13:17 +00:00
|
|
|
|
2022-10-06 10:38:13 +00:00
|
|
|
private:
|
2022-12-07 22:48:51 +00:00
|
|
|
TCachedToken< CWeaponDescription > x21c_waveBeam;
|
|
|
|
TCachedToken< CElectricDescription > x228_wave2nd1;
|
|
|
|
TCachedToken< CElectricDescription > x234_wave2nd2;
|
|
|
|
TCachedToken< CGenDescription > x240_wave2nd3;
|
|
|
|
float x24c_effectTimer;
|
|
|
|
rstl::single_ptr< CParticleElectric > x250_chargeElec;
|
|
|
|
rstl::single_ptr< CElementGen > x254_chargeFx;
|
|
|
|
bool x258_24_loaded : 1;
|
|
|
|
bool x258_25_effectTimerActive : 1;
|
|
|
|
|
|
|
|
void ReInitVariables();
|
2022-10-06 10:38:13 +00:00
|
|
|
};
|
|
|
|
CHECK_SIZEOF(CWaveBeam, 0x25c)
|
|
|
|
|
2022-10-09 05:13:17 +00:00
|
|
|
#endif // _CWAVEBEAM
|