2022-10-09 05:13:17 +00:00
|
|
|
#ifndef _CEXPLOSION
|
|
|
|
#define _CEXPLOSION
|
2022-10-08 04:53:28 +00:00
|
|
|
|
|
|
|
#include "types.h"
|
|
|
|
|
|
|
|
#include "MetroidPrime/CEffect.hpp"
|
|
|
|
|
|
|
|
#include "rstl/single_ptr.hpp"
|
|
|
|
|
|
|
|
class CParticleGen;
|
|
|
|
class CGenDescription;
|
|
|
|
class CElectricDescription;
|
|
|
|
|
|
|
|
class CExplosion : public CEffect {
|
|
|
|
public:
|
|
|
|
CExplosion(const TLockedToken< CGenDescription >& particle, TUniqueId uid, bool active,
|
|
|
|
const CEntityInfo& info, const rstl::string& name, const CTransform4f& xf, uint flags,
|
|
|
|
const CVector3f& scale, const CColor& color);
|
|
|
|
|
2022-11-27 00:26:12 +00:00
|
|
|
CExplosion(const TLockedToken< CElectricDescription >& electric, TUniqueId uid, bool active,
|
|
|
|
const CEntityInfo& info, const rstl::string& name, const CTransform4f& xf, uint flags,
|
|
|
|
const CVector3f& scale, const CColor& color);
|
|
|
|
|
2022-10-08 04:53:28 +00:00
|
|
|
// CEntity
|
2023-02-06 17:01:01 +00:00
|
|
|
~CExplosion() override;
|
|
|
|
void Accept(IVisitor& visitor) override;
|
|
|
|
void Think(float dt, CStateManager& mgr) override;
|
|
|
|
void AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId uid, CStateManager& mgr) override;
|
2022-10-08 04:53:28 +00:00
|
|
|
|
|
|
|
// CActor
|
2023-02-06 17:01:01 +00:00
|
|
|
void PreRender(CStateManager&, const CFrustumPlanes&) override;
|
|
|
|
void AddToRenderer(const CFrustumPlanes&, const CStateManager&) const override;
|
|
|
|
void Render(const CStateManager&) const override;
|
|
|
|
void CalculateRenderBounds() override;
|
2022-10-08 04:53:28 +00:00
|
|
|
|
2023-02-07 05:55:32 +00:00
|
|
|
TUniqueId GetExplosionLightId() const { return xec_explosionLight; }
|
2023-10-13 04:49:09 +00:00
|
|
|
CAssetId GetSourceId() const { return xf0_sourceId; }
|
2023-02-07 05:55:32 +00:00
|
|
|
|
2022-10-08 04:53:28 +00:00
|
|
|
public:
|
|
|
|
rstl::single_ptr< CParticleGen > xe8_particleGen;
|
|
|
|
TUniqueId xec_explosionLight;
|
2023-10-13 04:49:09 +00:00
|
|
|
CAssetId xf0_sourceId;
|
2022-10-08 04:53:28 +00:00
|
|
|
bool xf4_24_renderThermalHot : 1;
|
2023-10-13 04:49:09 +00:00
|
|
|
bool xf4_25_hasRenderBounds : 1;
|
2022-10-08 04:53:28 +00:00
|
|
|
bool xf4_26_renderXray : 1;
|
|
|
|
float xf8_time;
|
|
|
|
};
|
|
|
|
CHECK_SIZEOF(CExplosion, 0x100)
|
|
|
|
|
2022-10-09 05:13:17 +00:00
|
|
|
#endif // _CEXPLOSION
|