2018-10-07 03:42:33 +00:00
|
|
|
#pragma once
|
2016-04-16 21:49:47 +00:00
|
|
|
|
|
|
|
#include "CGameCamera.hpp"
|
|
|
|
|
|
|
|
namespace urde
|
|
|
|
{
|
|
|
|
|
|
|
|
class CFirstPersonCamera : public CGameCamera
|
|
|
|
{
|
2017-08-19 06:52:13 +00:00
|
|
|
float x188_orbitCameraSpeed;
|
|
|
|
bool x18c_lockCamera = false;
|
2016-09-15 07:26:35 +00:00
|
|
|
zeus::CTransform x190_gunFollowXf;
|
2017-10-07 05:32:11 +00:00
|
|
|
float x1c0_pitch = 0.f;
|
2017-07-17 03:04:14 +00:00
|
|
|
TUniqueId x1c4_pitchId = kInvalidUniqueId;
|
2017-10-07 05:32:11 +00:00
|
|
|
bool x1c6_24_deferBallTransitionProcessing : 1;
|
|
|
|
zeus::CVector3f x1c8_closeInVec;
|
|
|
|
float x1d4_closeInTimer = 0.f;
|
2016-12-19 18:27:58 +00:00
|
|
|
|
2016-04-16 21:49:47 +00:00
|
|
|
public:
|
2017-08-19 06:52:13 +00:00
|
|
|
CFirstPersonCamera(TUniqueId, const zeus::CTransform& xf, TUniqueId, float orbitCameraSpeed,
|
2017-03-24 05:30:16 +00:00
|
|
|
float fov, float nearplane, float farplane, float aspect);
|
2016-08-15 01:19:04 +00:00
|
|
|
|
2017-03-24 05:30:16 +00:00
|
|
|
void Accept(IVisitor& visitor);
|
2017-10-07 05:32:11 +00:00
|
|
|
void PreThink(float dt, CStateManager& mgr);
|
|
|
|
void Think(float dt, CStateManager& mgr);
|
2016-08-15 01:19:04 +00:00
|
|
|
void ProcessInput(const CFinalInput&, CStateManager& mgr);
|
|
|
|
void Reset(const zeus::CTransform&, CStateManager& mgr);
|
2016-09-15 07:26:35 +00:00
|
|
|
|
2017-02-18 02:19:50 +00:00
|
|
|
void SkipCinematic();
|
2017-05-30 03:45:31 +00:00
|
|
|
const zeus::CTransform& GetGunFollowTransform() const { return x190_gunFollowXf; }
|
2017-10-07 05:32:11 +00:00
|
|
|
void UpdateTransform(CStateManager& mgr, float dt);
|
|
|
|
void UpdateElevation(CStateManager& mgr);
|
2016-09-16 22:21:19 +00:00
|
|
|
void CalculateGunFollowOrientationAndTransform(zeus::CTransform&, zeus::CQuaternion&, float, zeus::CVector3f&);
|
2016-12-19 18:27:58 +00:00
|
|
|
void SetScriptPitchId(TUniqueId uid) { x1c4_pitchId = uid; }
|
2017-08-19 06:52:13 +00:00
|
|
|
void SetLockCamera(bool v) { x18c_lockCamera = v; }
|
2017-10-07 05:32:11 +00:00
|
|
|
void DeferBallTransitionProcessing() { x1c6_24_deferBallTransitionProcessing = true; }
|
2016-04-16 21:49:47 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|