|
Dayz Explorer
1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
|
Go to the documentation of this file.
7 static const float CONST_UD_MAX = 85.0;
9 static const float CONST_LR_MIN = -160.0;
10 static const float CONST_LR_MAX = 160.0;
14 if (pInput.Camera3rdIsRightShoulder())
34 super.OnActivate(pPrevCamera, pPrevCameraResult);
38 vector baseAngles = pPrevCamera.GetBaseAngles();
42 vector addAngles = pPrevCamera.GetAdditiveAngles();
60 if (
m_pInput.Camera3rdIsRightShoulder())
81 pOutResult.m_CameraTM[3] =
"0 0 0";
90 lsOffset[0] = lsOffset[0] + shoulderDist;
94 msOffset[0] = msOffset[0] + shoulderDist;
98 pOutResult.m_CameraTM[3] = pOutResult.m_CameraTM[3] + pOutResult.m_CameraTM[0] * lsOffset[0] + pOutResult.m_CameraTM[1] * lsOffset[1] + pOutResult.m_CameraTM[2] * lsOffset[2] + msOffset;
102 pOutResult.m_fUseHeading = 1.0;
103 pOutResult.m_fInsideCamera = 0.0;
131 return "DayZPlayerCamera3rdPerson";
205 super.OnUpdate(pDt, pOutResult);
209 yDiff =
Math.Clamp(yDiff, 0.0, 2.0);
222 pOutResult.m_CameraTM[3][1] = newY;
268 Print(
"DayZPlayerCamera3rdPersonErcSpr: hips bone not found");
285 float xShift = tm[1][0];
291 super.OnUpdate(pDt, pOutResult);
313 if ( pPlayer.GetCurrentPerItemCameraUD () ==
DayZPlayerCameras.PERITEMUD_EMPTYHANDED )
322 else if ( pPlayer.GetCurrentPerItemCameraUD () ==
DayZPlayerCameras.PERITEMUD_TWOHANDED )
330 else if ( pPlayer.GetCurrentPerItemCameraUD () ==
DayZPlayerCameras.PERITEMUD_ONEHANDED )
397 super.OnUpdate(pDt, pOutResult);
432 protected vector m_BaseOffset
458 super.OnActivate(pPrevCamera, pPrevCameraResult);
466 m_BaseOffset =
"0 0 0";
477 float orientYaw =
m_pPlayer.GetOrientation()[0];
478 float headYaw =
m_pInput.GetHeadingAngle() *
Math.RAD2DEG;
487 if (
m_pInput.Camera3rdIsRightShoulder())
505 m_BaseOffset[0] =
Math.SmoothCD(m_BaseOffset[0], bonePos[0],
m_BaseOffsetVelX, 0.14, 1000, pDt);
506 m_BaseOffset[1] =
Math.SmoothCD(m_BaseOffset[1], bonePos[1],
m_BaseOffsetVelY, 0.14, 1000, pDt);
507 m_BaseOffset[2] =
Math.SmoothCD(m_BaseOffset[2], bonePos[2],
m_BaseOffsetVelZ, 0.14, 1000, pDt);
514 lsOffset[0] = lsOffset[0] + shoulderDist;
517 pOutResult.m_CameraTM[3] = m_BaseOffset + pOutResult.m_CameraTM[0] * lsOffset[0] + pOutResult.m_CameraTM[1] * lsOffset[1] + pOutResult.m_CameraTM[2] * lsOffset[2] + msOffset;
524 pOutResult.m_fUseHeading = 1.0;
525 pOutResult.m_fInsideCamera = 0.0;
526 pOutResult.m_fPositionModelSpace = 1.0;
527 pOutResult.m_bUpdateWhenBlendOut =
false;
543 m_iBoneIndex = pPlayer.GetBoneIndexByName (
"Camera3rd_Helper");
560 m_iBoneIndex = pPlayer.GetBoneIndexByName (
"Camera3rd_Helper");
override void OnUpdate(float pDt, out DayZPlayerCameraResult pOutResult)
protected bool m_bForceFreeLook
float m_fDelayTimer
runtime values
class DayZPlayerCamera3rdPersonJump extends DayZPlayerCamera3rdPersonErc DayZPlayerCamera3rdPersonClimb(DayZPlayer pPlayer, HumanInputController pInput)
protected float m_fLeftRightAngle
left right angle in rad (in freelook only)
float m_fDelay
runtime config
class DayZPlayerCamera1stPersonVehicle extends DayZPlayerCamera1stPerson CONST_UD_MIN
down limit
float m_jumpOffsetVelocity[1]
float UpdateUDAngleUnlocked(out float pAngle, out float pAngleAdd, float pMin, float pMax, float pDt)
void ProcessCameraShake(float delta, out float leftRight, out float upDown)
class DayZPlayerCameraResult DayZPlayerCamera(DayZPlayer pPlayer, HumanInputController pInput)
protected vector m_CameraOffsetLS
local space offset
override string GetCameraName()
protected float m_fCameraHeightVel[1]
protected float m_fCameraLRShoulder
shoulder offsets
proto void Print(void var)
Prints content of variable to console/log.
void DayZPlayerCamera3rdPersonJump(DayZPlayer pPlayer, HumanInputController pInput)
float UpdateLRAngleLookAt(float pMin, float pMax, float pDt)
float UpdateLRAngleUnlocked(out float pAngle, out float pAngleAdd, float pMin, float pMax, float pDt)
void HandleShoulderCameraOverride(HumanInputController pInput)
float Limit(float pV, float pMin, float pMax)
limit function
protected float m_fDistance
distance from start
ref HumanMovementState m_MovementState
movement state
class DayZPlayerCamera3rdPersonErcRaisedMelee extends DayZPlayerCamera3rdPersonErcRaised CONST_CAMERAMOVEMENTHEIGH
protected HumanInputController m_pInput
human input
override vector GetAdditiveAngles()
void DayZPlayerCamera3rdPersonProne(DayZPlayer pPlayer, HumanInputController pInput)
protected float m_fUpDownAngle
runtime values
protected float m_WeaponSwayModifier
protected DayZPlayer m_pPlayer
data
protected float m_CurrentCameraPitch
protected float m_fLRAngleVel[1]
void InitCameraOnPlayer(bool force=false)
protected float m_fCameraLRShoulderVel[1]
void DayZPlayerCamera3rdPersonCrouch(DayZPlayer pPlayer, HumanInputController pInput)
protected float m_fPredictCollisionRadius
collision prediction
class DayZPlayerCamera3rdPerson extends DayZPlayerCameraBase DayZPlayerCamera3rdPersonErc(DayZPlayer pPlayer, HumanInputController pInput)
class DayZPlayerCamera3rdPersonProne extends DayZPlayerCamera3rdPersonProneBase DayZPlayerCamera3rdPersonProneRaised(DayZPlayer pPlayer, HumanInputController pInput)
protected float m_fRoll
camera roll (deprecated)
protected float m_fUpDownAngleAdd
up down angle in rad
class DayZPlayerCamera3rdPersonCrouchRaised extends DayZPlayerCamera3rdPersonCrouch m_BaseOffsetVelZ[1]
protected vector m_CameraOffsetMS
model space offset
void DayZPlayerCamera3rdPerson(DayZPlayer pPlayer, HumanInputController pInput)
this is main camera class
class DayZPlayerCamera3rdPersonCrouchRaised extends DayZPlayerCamera3rdPersonCrouch m_BaseOffsetVelX[1]
protected float m_fCameraHeight
class DayZPlayerCamera3rdPersonErcSpr extends DayZPlayerCamera3rdPersonErc DayZPlayerCamera3rdPersonErcRaised(DayZPlayer pPlayer, HumanInputController pInput)
class DayZPlayerCamera3rdPersonCrouchRaised extends DayZPlayerCamera3rdPersonCrouch m_BaseOffsetVelY[1]
protected int m_iPelvisBone
protected float m_CurrentCameraYaw
protected float m_LookAtLRAngle
void DayZPlayerCamera3rdPersonErcSpr(DayZPlayer pPlayer, HumanInputController pInput)
override void OnActivate(DayZPlayerCamera pPrevCamera, DayZPlayerCameraResult pPrevCameraResult)
float fixAngle_180_180(float pAngle)
protected float m_fShoulderWidth
shoulder camera widths
protected float m_fLeanDistance
shift on leaning
void StdFovUpdate(float pDt, out DayZPlayerCameraResult pOutResult)
protected bool m_bShoulderInLS
true - shoulder is in local space
vector GetCurrentOrientation()
override bool IsCamera3rdRaised()
protected float m_CurrentCameraRoll
protected float m_fLeftRightAngleAdd
left right angle in rad (in freelook only)
override vector GetBaseAngles()
protected int m_iBoneIndex
runtime config
HumanInputControllerOverrideType
void UpdateCameraNV(PlayerBase player)