metaforce/Runtime/Camera/CCinematicCamera.cpp

61 lines
1.6 KiB
C++
Raw Normal View History

2016-04-24 04:03:30 +00:00
#include "CCinematicCamera.hpp"
#include "CStateManager.hpp"
#include "Camera/CCameraManager.hpp"
2017-01-15 03:07:01 +00:00
#include "TCastTo.hpp"
2016-04-24 04:03:30 +00:00
namespace urde
{
2017-11-13 06:19:18 +00:00
CCinematicCamera::CCinematicCamera(TUniqueId uid, std::string_view name, const CEntityInfo& info,
const zeus::CTransform& xf, bool active, float shotDuration, float fovy, float znear,
float zfar, float aspect, u32 w1)
: CGameCamera(uid, active, name, info, xf, fovy, znear, zfar, aspect, kInvalidUniqueId, w1 & 0x20, 0), x21c_w1(w1)
2016-04-24 04:03:30 +00:00
{
}
2017-01-15 03:07:01 +00:00
void CCinematicCamera::Accept(IVisitor& visitor)
{
visitor.Visit(this);
}
2016-12-29 21:38:59 +00:00
void CCinematicCamera::ProcessInput(const CFinalInput&, CStateManager& mgr) {}
2016-12-29 21:38:59 +00:00
void CCinematicCamera::Reset(const zeus::CTransform&, CStateManager& mgr) {}
2017-02-18 02:19:50 +00:00
void CCinematicCamera::WasDeactivated(CStateManager& mgr)
{
mgr.GetCameraManager()->RemoveCinemaCamera(GetUniqueId(), mgr);
}
void CCinematicCamera::AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId uid, CStateManager& mgr)
{
CGameCamera::AcceptScriptMsg(msg, uid, mgr);
if (msg == EScriptObjectMessage::Activate)
{
CalculateWaypoints(mgr);
if (x21c_w1 & 1)
{
}
}
else if (msg == EScriptObjectMessage::Deactivate)
{
WasDeactivated(mgr);
}
else if (msg == EScriptObjectMessage::InitializedInArea)
{
}
}
2017-02-18 02:19:50 +00:00
void CCinematicCamera::CalculateWaypoints(CStateManager& mgr)
{
}
void CCinematicCamera::SendArrivedMsg(TUniqueId reciever, CStateManager& mgr)
{
mgr.SendScriptMsgAlways(reciever, GetUniqueId(), EScriptObjectMessage::Arrived);
2017-02-18 02:19:50 +00:00
}
2016-04-24 04:03:30 +00:00
}