2018-10-06 20:42:33 -07:00
|
|
|
#pragma once
|
2017-04-13 12:28:31 -07:00
|
|
|
|
2019-09-22 14:52:05 -07:00
|
|
|
#include <memory>
|
|
|
|
#include <string_view>
|
|
|
|
|
|
|
|
#include "Runtime/Particle/CElementGen.hpp"
|
|
|
|
#include "Runtime/Particle/CGenDescription.hpp"
|
|
|
|
#include "Runtime/World/CEffect.hpp"
|
2017-04-13 12:28:31 -07:00
|
|
|
|
2021-04-10 01:42:06 -07:00
|
|
|
namespace metaforce {
|
2017-04-13 12:28:31 -07:00
|
|
|
|
2018-12-07 21:30:43 -08:00
|
|
|
class CExplosion : public CEffect {
|
|
|
|
std::unique_ptr<CParticleGen> xe8_particleGen;
|
|
|
|
TUniqueId xec_explosionLight = kInvalidUniqueId;
|
|
|
|
union {
|
|
|
|
const CGenDescription* xf0_particleDesc;
|
|
|
|
const CElectricDescription* xf0_electricDesc;
|
|
|
|
};
|
|
|
|
bool xf4_24_renderThermalHot : 1;
|
2020-04-19 21:57:50 -07:00
|
|
|
bool xf4_25_ : 1 = true;
|
2018-12-07 21:30:43 -08:00
|
|
|
bool xf4_26_renderXray : 1;
|
|
|
|
float xf8_time = 0.f;
|
2017-04-13 12:28:31 -07:00
|
|
|
|
|
|
|
public:
|
2021-05-26 07:00:57 -07:00
|
|
|
DEFINE_ENTITY
|
2018-12-07 21:30:43 -08:00
|
|
|
CExplosion(const TLockedToken<CGenDescription>& particle, TUniqueId uid, bool active, const CEntityInfo& info,
|
|
|
|
std::string_view name, const zeus::CTransform& xf, u32, const zeus::CVector3f& scale,
|
|
|
|
const zeus::CColor& color);
|
|
|
|
CExplosion(const TLockedToken<CElectricDescription>& electric, TUniqueId uid, bool active, const CEntityInfo& info,
|
|
|
|
std::string_view name, const zeus::CTransform& xf, u32, const zeus::CVector3f& scale,
|
|
|
|
const zeus::CColor& color);
|
2017-09-12 08:27:48 -07:00
|
|
|
|
2019-08-09 05:45:18 -07:00
|
|
|
void Accept(IVisitor&) override;
|
|
|
|
void AcceptScriptMsg(EScriptObjectMessage, TUniqueId, CStateManager&) override;
|
|
|
|
void Think(float, CStateManager&) override;
|
|
|
|
void PreRender(CStateManager&, const zeus::CFrustum&) override;
|
2020-04-05 04:54:02 -07:00
|
|
|
void AddToRenderer(const zeus::CFrustum&, CStateManager&) override;
|
2020-04-09 10:28:20 -07:00
|
|
|
void Render(CStateManager&) override;
|
2019-08-09 05:45:18 -07:00
|
|
|
bool CanRenderUnsorted(const CStateManager&) const override;
|
2017-04-13 12:28:31 -07:00
|
|
|
};
|
|
|
|
|
2021-04-10 01:42:06 -07:00
|
|
|
} // namespace metaforce
|