mirror of
https://git.code.sf.net/p/quake/quakeforge-old
synced 2024-11-24 21:01:17 +00:00
common/cl_input.c:
fix what looks like a bug. if (ms>250) ms=100; ??? common/cl_main.c common/cvars.h qw_client/cl_parse.c: put running autoexec.cfg back in, BUT now controlled by a cvar (cl_autoexec).
This commit is contained in:
parent
71af74200b
commit
a32eb9e1b8
4 changed files with 15 additions and 2 deletions
|
@ -382,7 +382,7 @@ void CL_FinishMove (usercmd_t *cmd)
|
|||
// send milliseconds of time to apply the move
|
||||
ms = host_frametime * 1000;
|
||||
if (ms > 250)
|
||||
ms = 100; // time was unreasonable
|
||||
ms = 250; // time was unreasonable
|
||||
cmd->msec = ms;
|
||||
|
||||
VectorCopy (cl.viewangles, cmd->angles);
|
||||
|
|
|
@ -102,6 +102,8 @@ cvar_t *rcon_password;
|
|||
cvar_t *rcon_address;
|
||||
cvar_t *cl_timeout;
|
||||
|
||||
cvar_t *cl_autoexec;
|
||||
|
||||
// these two are not intended to be set directly
|
||||
cvar_t *cl_name;
|
||||
cvar_t *cl_color;
|
||||
|
@ -1730,6 +1732,7 @@ void CL_InitCvars()
|
|||
sys_nostdout = Cvar_Get ("sys_nostdout","0",0,
|
||||
"Toggles the display of console messages on the stdout stream");
|
||||
|
||||
cl_autoexec = Cvar_Get ("cl_autoexec","0",CVAR_ROM,"exec autoexec.cfg on gamedir change");
|
||||
cl_warncmd = Cvar_Get ("cl_warncmd","0",0,"None");
|
||||
cl_name = Cvar_Get ("_cl_name","player",CVAR_ARCHIVE,
|
||||
"Sets the player name");
|
||||
|
|
|
@ -31,8 +31,9 @@
|
|||
#ifndef _CVARS_H
|
||||
#define _CVARS_H
|
||||
|
||||
extern cvar_t *gl_flashblend;
|
||||
extern cvar_t *cl_autoexec;
|
||||
|
||||
extern cvar_t *gl_flashblend;
|
||||
|
||||
// From r_local.h
|
||||
extern cvar_t *r_draworder;
|
||||
|
|
|
@ -590,6 +590,15 @@ void CL_ParseServerData (void)
|
|||
Cbuf_AddText ("exec frontend.cfg\n");
|
||||
Cbuf_AddText ("cl_warncmd 1\n");
|
||||
}
|
||||
if (cl_autoexec->value) {
|
||||
snprintf(fn, sizeof(fn), "%s/%s", com_gamedir, "autoexec.cfg");
|
||||
if ((f = Qopen(fn, "r")) != NULL) {
|
||||
Qclose(f);
|
||||
Cbuf_AddText ("cl_warncmd 0\n");
|
||||
Cbuf_AddText ("exec autoexec.cfg\n");
|
||||
Cbuf_AddText ("cl_warncmd 1\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// parse player slot, high bit means spectator
|
||||
|
|
Loading…
Reference in a new issue