2018-10-06 20:42:33 -07:00
|
|
|
#pragma once
|
2016-10-01 12:00:16 -07:00
|
|
|
|
2019-09-22 14:52:05 -07:00
|
|
|
#include <string_view>
|
|
|
|
|
|
|
|
#include "Runtime/GCNTypes.hpp"
|
|
|
|
#include "Runtime/World/CActor.hpp"
|
|
|
|
#include "Runtime/Graphics/CLight.hpp"
|
2016-10-01 12:00:16 -07:00
|
|
|
|
2021-04-10 01:42:06 -07:00
|
|
|
namespace metaforce {
|
2018-12-07 21:30:43 -08:00
|
|
|
class CGameLight : public CActor {
|
|
|
|
TUniqueId xe8_parentId;
|
|
|
|
CLight xec_light;
|
|
|
|
u32 x13c_lightId;
|
|
|
|
u32 x140_priority;
|
|
|
|
float x144_lifeTime;
|
2016-10-01 12:00:16 -07:00
|
|
|
|
2020-12-12 23:39:55 -08:00
|
|
|
std::optional<CStaticRes> m_debugRes;
|
|
|
|
std::unique_ptr<CModelData> m_debugModel;
|
2021-06-07 12:29:18 -07:00
|
|
|
|
2016-10-01 12:00:16 -07:00
|
|
|
public:
|
2021-05-26 07:00:57 -07:00
|
|
|
DEFINE_ENTITY
|
2020-04-06 05:46:36 -07:00
|
|
|
CGameLight(TUniqueId uid, TAreaId aid, bool active, std::string_view name, const zeus::CTransform& xf,
|
|
|
|
TUniqueId parentId, const CLight& light, u32 sourceId, u32 priority, float lifeTime);
|
2016-10-01 12:00:16 -07:00
|
|
|
|
2019-08-09 05:45:18 -07:00
|
|
|
void Accept(IVisitor& visitor) override;
|
2020-04-06 05:46:36 -07:00
|
|
|
void Think(float dt, CStateManager& mgr) override;
|
2018-12-07 21:30:43 -08:00
|
|
|
void SetLightPriorityAndId();
|
2020-04-06 05:46:36 -07:00
|
|
|
void SetLight(const CLight& light);
|
2018-12-07 21:30:43 -08:00
|
|
|
CLight GetLight() const;
|
|
|
|
TUniqueId GetParentId() const { return xe8_parentId; }
|
2020-12-12 23:39:55 -08:00
|
|
|
|
|
|
|
void DebugDraw();
|
2016-10-01 12:00:16 -07:00
|
|
|
};
|
2021-04-10 01:42:06 -07:00
|
|
|
} // namespace metaforce
|