2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-05-17 03:11:21 +00:00
metaforce/Runtime/World/CFire.hpp
Lioncash cabbfcc320 CActor: Make AddToRenderer() non-const
This member function alters instance state in a few implementations, so
it shouldn't be made const.

The state manager parameter also shouldn't be const. Retrieved data
from the post constructed instance is further modified in some
implementations. This removes the constness on this parameter in order
to fix more const_cast usages in a follow-up change.
2020-04-06 00:52:10 -04:00

47 lines
1.2 KiB
C++

#pragma once
#include <optional>
#include <memory>
#include "Runtime/World/CActor.hpp"
#include "Runtime/World/CDamageInfo.hpp"
namespace urde {
class CElementGen;
class CFire : public CActor {
std::unique_ptr<CElementGen> xe8_;
TUniqueId xec_ownerId;
CDamageInfo xf0_damageInfo;
CDamageInfo x10c_damageInfo;
std::optional<zeus::CAABox> x128_;
float x144_;
bool x148_24_ : 1;
bool x148_25_ : 1;
bool x148_26_ : 1;
bool x148_27_ : 1;
bool x148_28_ : 1;
bool x148_29_ : 1;
float x14c_;
CAssetId x150_;
float x154_;
float x158_;
float x15c_ = 0.f;
public:
CFire(TToken<CGenDescription>, TUniqueId, TAreaId, bool, TUniqueId, const zeus::CTransform&, const CDamageInfo&,
const zeus::CAABox&, const zeus::CVector3f&, bool, CAssetId, bool, bool, bool, float, float, float, float);
void Accept(IVisitor&) override;
void AcceptScriptMsg(EScriptObjectMessage, TUniqueId, CStateManager&) override;
void Think(float, CStateManager&) override;
std::optional<zeus::CAABox> GetTouchBounds() const override {
if (GetActive())
return x128_;
return {};
}
void Touch(CActor&, CStateManager&) override;
void AddToRenderer(const zeus::CFrustum&, CStateManager&) override;
};
} // namespace urde