129{
132
135
136
138 {
141 {
142 Print(
"DayZPlayerCamera1stPerson: main bone not found");
143 }
144
146 }
147
148
149
151 {
152 super.OnActivate(pPrevCamera, pPrevCameraResult);
153
154 if (pPrevCamera)
155 {
156 vector baseAngles = pPrevCamera.GetBaseAngles();
159
160 vector addAngles = pPrevCamera.GetAdditiveAngles();
163 }
164 }
165
166
168 {
172
176
178 pOutResult.m_iDirectBoneMode = 1;
179 pOutResult.m_fUseHeading = 1.0;
180 pOutResult.m_fInsideCamera = 1.0;
181
182 pOutResult.m_fNearPlane = 0.04;
183
185
189 }
190
192 {
196 a[2] = 0;
197 return a;
198 }
199
201 {
205 a[2] = 0;
206 return a;
207 }
208
210 {
211 return "DayZPlayerCamera1stPerson";
212 }
213
216
221}
222
223
224
225
227{
229 {
231 }
232
234 {
235 super.OnUpdate(pDt, pOutResult);
236
238 pOutResult.m_iDirectBoneMode = 4;
239 pOutResult.m_fUseHeading = 0.0;
240
241 vector rot;
242 rot[0] = 0;
243 rot[1] = 90;
244 rot[2] = 0;
245
246 Math3D.YawPitchRollMatrix(rot, pOutResult.m_CameraTM);
247 }
248}
void DayZPlayerCamera1stPerson(DayZPlayer pPlayer, HumanInputController pInput)
int m_iBoneIndex
main bone
float m_fLeftRightAngle
left right angle in rad (in freelook only)
float m_fUpDownAngle
up down angle in rad
static const float CONST_UD_MAX
up limit
float m_fLeftRightAngleAdd
left right angle in rad (in freelook only)
float m_fUpDownAngleAdd
up down angle in rad
static const float CONST_LR_MIN
down limit
override vector GetBaseAngles()
static const float CONST_LR_MAX
up limit
static const float CONST_UD_MIN
down limit
override vector GetAdditiveAngles()
class DayZPlayerCamera1stPerson extends DayZPlayerCameraBase DayZPlayerCamera1stPersonUnconscious(DayZPlayer pPlayer, HumanInputController pInput)
vector m_OffsetLS
position offset
override string GetCameraName()
float UpdateLRAngleUnlocked(out float pAngle, out float pAngleAdd, float pMin, float pMax, float pDt)
float m_CurrentCameraPitch
float UpdateUDAngleUnlocked(out float pAngle, out float pAngleAdd, float pMin, float pMax, float pDt)
void StdFovUpdate(float pDt, out DayZPlayerCameraResult pOutResult)
void InitCameraOnPlayer(bool force=false)
void UpdateCameraNV(PlayerBase player)
void ProcessCameraShake(float delta, out float leftRight, out float upDown)
void DayZPlayerCameraResult()
cannot be instanced from script (always created from C++)
class DayZPlayerCameraResult DayZPlayerCamera(DayZPlayer pPlayer, HumanInputController pInput)
vector GetCurrentOrientation()
proto void Print(void var)
Prints content of variable to console/log.
static proto void YawPitchRollMatrix(vector ang, out vector mat[3])
Creates rotation matrix from angles.