mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-25 14:00:58 +00:00
Add cl_anglekick
, when set to 0 angle kicks are ignored.
Angle kicks are used for weapon recoil, damage kicks and the like. Setting the `cl_anglekicks` to `0` ignored them, they're read from the network but not displayed. The cvar is cheat protected, it's reset to `1` on server connect. Rquested by Martin via mail.
This commit is contained in:
parent
fd0c058b2e
commit
1f3f796322
4 changed files with 13 additions and 3 deletions
|
@ -55,6 +55,9 @@ it's `+set busywait 0` (setting the `busywait` cvar) and `-portable`
|
|||
time for the next frame. The later is more CPU friendly but rather
|
||||
inaccurate, especially on Windows. Use with care.
|
||||
|
||||
* **cl_anglekicks**: If set to `0` angle kicks (weapon recoil, damage
|
||||
hits and the like) are ignored. Cheat protected. Defaults to `1`.
|
||||
|
||||
* **cl_async**: If set to `1` (the default) the client is asynchronous.
|
||||
The client framerate is fixed, the renderer framerate is variable.
|
||||
This makes it possible to renderer as many frames as desired without
|
||||
|
|
|
@ -757,11 +757,14 @@ CL_CalcViewValues(void)
|
|||
}
|
||||
}
|
||||
|
||||
if (cl_anglekicks->value)
|
||||
{
|
||||
for (i = 0; i < 3; i++)
|
||||
{
|
||||
cl.refdef.viewangles[i] += LerpAngle(ops->kick_angles[i],
|
||||
ps->kick_angles[i], lerp);
|
||||
}
|
||||
}
|
||||
|
||||
AngleVectors(cl.refdef.viewangles, cl.v_forward, cl.v_right, cl.v_up);
|
||||
|
||||
|
|
|
@ -48,6 +48,7 @@ cvar_t *cl_add_particles;
|
|||
cvar_t *cl_add_lights;
|
||||
cvar_t *cl_add_entities;
|
||||
cvar_t *cl_add_blend;
|
||||
cvar_t *cl_anglekicks;
|
||||
|
||||
cvar_t *cl_shownet;
|
||||
cvar_t *cl_showmiss;
|
||||
|
@ -492,6 +493,7 @@ CL_InitLocal(void)
|
|||
cl_add_lights = Cvar_Get("cl_lights", "1", 0);
|
||||
cl_add_particles = Cvar_Get("cl_particles", "1", 0);
|
||||
cl_add_entities = Cvar_Get("cl_entities", "1", 0);
|
||||
cl_anglekicks = Cvar_Get("cl_anglekicks", "1", 0);
|
||||
cl_gun = Cvar_Get("cl_gun", "2", CVAR_ARCHIVE);
|
||||
cl_footsteps = Cvar_Get("cl_footsteps", "1", 0);
|
||||
cl_noskins = Cvar_Get("cl_noskins", "0", 0);
|
||||
|
@ -659,6 +661,7 @@ cheatvar_t cheatvars[] = {
|
|||
{"sw_draworder", "0"},
|
||||
{"gl_lightmap", "0"},
|
||||
{"gl_saturatelighting", "0"},
|
||||
{"cl_anglekicks", "1"},
|
||||
{NULL, NULL}
|
||||
};
|
||||
|
||||
|
|
|
@ -308,6 +308,7 @@ extern cvar_t *cl_vwep;
|
|||
extern cvar_t *horplus;
|
||||
extern cvar_t *cin_force43;
|
||||
extern cvar_t *vid_fullscreen;
|
||||
extern cvar_t *cl_anglekicks;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue