MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / CActor

Method CActor

ogsr_engine/xrGame/Actor.cpp:84–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

82static bool updated;
83
84CActor::CActor() : CEntityAlive(), current_ik_cam_shift(0)
85{
86 encyclopedia_registry = xr_new<CEncyclopediaRegistryWrapper>();
87 game_news_registry = xr_new<CGameNewsRegistryWrapper>();
88 // Cameras
89 cameras[eacFirstEye] = xr_new<CCameraFirstEye>(this);
90 cameras[eacFirstEye]->Load("actor_firsteye_cam");
91
92 if constexpr (true /*strstr(Core.Params,"-psp")*/)
93 psActorFlags.set(AF_PSP, TRUE);
94 else
95 psActorFlags.set(AF_PSP, FALSE);
96
97 if (psActorFlags.test(AF_PSP))
98 {
99 cameras[eacLookAt] = xr_new<CCameraLook2>(this);
100 cameras[eacLookAt]->Load("actor_look_cam_psp");
101 }
102 else
103 {
104 cameras[eacLookAt] = xr_new<CCameraLook>(this);
105 cameras[eacLookAt]->Load("actor_look_cam");
106 }
107 cameras[eacFreeLook] = xr_new<CCameraLook>(this);
108 cameras[eacFreeLook]->Load("actor_free_cam");
109
110 cam_active = eacFirstEye;
111 fPrevCamPos = 0.0f;
112 vPrevCamDir.set(0.f, 0.f, 1.f);
113 fCurAVelocity = 0.0f;
114 // эффекторы
115 pCamBobbing = 0;
116 m_pSleepEffector = NULL;
117 m_pSleepEffectorPP = NULL;
118
119 r_torso.yaw = 0;
120 r_torso.pitch = 0;
121 r_torso.roll = 0;
122 r_torso_tgt_roll = 0;
123 r_model_yaw = 0;
124 r_model_yaw_delta = 0;
125 r_model_yaw_dest = 0;
126
127 b_DropActivated = 0;
128 f_DropPower = 0.f;
129
130 m_fRunFactor = 2.f;
131 m_fCrouchFactor = 0.2f;
132 m_fClimbFactor = 1.f;
133 m_fCamHeightFactor = 0.87f;
134
135 m_fFallTime = s_fFallTime;
136 m_bAnimTorsoPlayed = false;
137
138 m_pPhysicsShell = NULL;
139
140 m_holder = NULL;
141 m_holderID = u16(-1);

Callers

nothing calls this directly

Calls 5

SetBeltUsefulMethod · 0.80
LoadMethod · 0.45
setMethod · 0.45
testMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected