172 if (
STAT(HEALTH) <= 0)
176 LOG_INFO(
"the Weird code path got hit");
330 vector bob_height_check_dest = v;
335 bob_height_check_dest = v;
340 bob_limit *=
min(trace1fraction, trace2fraction);
346 cycle -=
rint(cycle);
355 bob =
bound(0, bob, bob_limit);
356 bob = bob * 0.3 + bob * 0.7 * cycle;
364 cycle -=
rint(cycle);
366 cycle =
cos(
M_PI * cycle / 0.5);
431 float sign = (side < 0) ? -1 : 1;
467 for(offset.x = -16; offset.x <= 16; offset.x += 8)
469 for(offset.y = -16; offset.y <= 16; offset.y += 8)
495 chase_dest.x = v.x + forward.x * cdist;
496 chase_dest.y = v.y + forward.y * cdist;
540 V_CalcRefdef(
this, refdefflags);
585 e.view_ofs =
'0 0 1' * vh;
588 if (vh == pl_viewofs.z) e.flags &=
~FL_DUCKED;
589 else if (vh == pl_viewofs_crouch.z) e.flags |=
FL_DUCKED;
597 e.view_ofs =
'0 0 1' * vh;
618 if (vh == pl_viewofs.z) e.flags &=
~FL_DUCKED;
619 else if(vh == pl_viewofs_crouch.z) e.flags |=
FL_DUCKED;
628#ifdef CSQCMODEL_SERVERSIDE_CROUCH
630 if (vh == pl_viewofs.z) e.flags &=
~FL_DUCKED;
631 else if (vh == pl_viewofs_crouch.z) e.flags |=
FL_DUCKED;
642 setorigin(e, e.origin);
651 view.view_ofs =
'0 0 1' * vh;
685 if (
cvar(
"cl_movement_replay"))
#define BIT(n)
Only ever assign into the first 24 bits in QC (so max is BIT(23)).
#define BITSET(var, mask, flag)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float csqcmodel_teleported
float autocvar_cl_bob_limit
float autocvar_v_idlescale
float autocvar_cl_smoothviewheight
void CSQCPlayer_SetCamera()
Called once per CSQC_UpdateView()
float autocvar_v_ipitch_cycle
float autocvar_cl_movement_errorcompensation
vector csqcplayer_predictionerrorv
vector CSQCPlayer_ApplySmoothing(entity this, vector v)
float csqcplayer_sequence
float stairsmooth_prevtime
vector CSQCPlayer_GetPredictionErrorO()
vector csqcplayer_predictionerroro
float autocvar_cl_bobcycle
float autocvar_cl_stairsmoothspeed
float autocvar_cl_bob2smooth
float autocvar_cl_bob_limit_heightcheck
float autocvar_cl_bob2cycle
void CSQCPlayer_SetPredictionError(vector o, vector v, float onground_diff)
float CSQCPlayer_CalcRoll(entity this)
float autocvar_v_ipitch_level
float autocvar_cl_rollangle
float autocvar_v_deathtiltangle
float autocvar_v_iyaw_level
bool autocvar_cl_movement_intermissionrunning
void CSQCPlayer_Physics(entity this)
float autocvar_cl_bobfall
float stairsmooth_drawtime
vector CSQCModel_ApplyStairSmoothing(entity this, bool isonground, vector v)
void CSQCPlayer_ApplyIdleScaling(entity this)
float autocvar_v_iyaw_cycle
float autocvar_v_iroll_cycle
void CSQCPlayer_CalcRefdef(entity this)
float autocvar_cl_rollspeed
float csqcplayer_moveframe
float autocvar_chase_pitchangle
float autocvar_chase_back
void CSQCPlayer_Unpredict(entity this)
bool CSQCPlayer_PreUpdate(entity this)
vector csqcplayer_velocity
vector CSQCPlayer_ApplyChase(entity this, vector v)
void CSQCPlayer_PredictTo(entity this, float endframe, bool apply_error)
bool autocvar_v_deathtilt
float autocvar_cl_bobfallcycle
void CSQCPlayer_SavePrediction(entity this)
bool CSQCPlayer_PostUpdate(entity this)
bool CSQCPlayer_IsLocalPlayer(entity this)
bool autocvar_chase_overhead
vector CSQCPlayer_ApplyBobbing(entity this, vector v)
float autocvar_cl_bob_velocity_limit
vector CSQCPlayer_GetPredictionErrorV()
void CSQC_ClientMovement_PlayerMove_Frame(entity this)
float csqcplayer_predictionerrorfactor
void CSQCPlayer_SetMinsMaxs(entity this)
void CSQCPlayer_Remove(entity this)
float csqcplayer_predictionerrortime
float autocvar_v_iroll_level
void CSQCPlayer_ApplyDeathTilt(entity this)
float autocvar_cl_bobfallminspeed
const int CSQCPLAYERSTATUS_UNPREDICTED
const int CSQCPLAYERSTATUS_PREDICTED
bool autocvar_cl_movement
const int CSQCPLAYERSTATUS_FROMSERVER
int spectatee_status
the -1 disables HUD panels before CSQC receives necessary data
#define PHYS_PL_CROUCH_VIEWOFS(s)
#define PHYS_INPUT_TIMELENGTH
#define PHYS_WORLD_ANGLES(s)
#define PHYS_PL_VIEWOFS(s)
#define PHYS_PL_CROUCH_MAX(s)
#define PHYS_INVEHICLE(s)
#define PHYS_INPUT_ANGLES(s)
#define PHYS_PL_CROUCH_MIN(s)
#define PHYS_VIEWHEIGHT(s)
float cvar_settemp(string tmp_cvar, string tmp_value)
const float PL_CORPSE_SCALE
const float MOVE_NOMONSTERS
float REFDEFFLAG_INTERMISSION
float REFDEFFLAG_TELEPORTED
vector trace_plane_normal
float ground_networkentity
#define CSQCPLAYER_HOOK_POSTCAMERASETUP()
entity CSQCModel_server2csqc(int i)
void InterpolateOrigin_Do(entity this)
set origin based on iorigin1 (old pos), iorigin2 (desired pos), and time
const int ISPLAYER_PLAYER
void Movetype_Physics_NoMatchTicrate(entity this, float movedt, bool isclient)
#define PHYS_STEPHEIGHT(s)
const int MOVETYPE_NOCLIP
#define vdist(v, cmp, f)
Vector distance comparison, avoids sqrt()
int autocvar_chase_active
bool autocvar_chase_front
int autocvar_cl_eventchase_death