diff --git a/common/cl_cam.c b/common/cl_cam.c index 288dd4b..e094c3d 100644 --- a/common/cl_cam.c +++ b/common/cl_cam.c @@ -59,10 +59,10 @@ double cam_lastviewtime; int spec_track = 0; // player# of who we are tracking int autocam = CAM_NONE; -cvar_t cl_chasecam = {"cl_chasecam", "0", true}; -cvar_t cl_chasecam_up = {"cl_chasecam_up", "16", true}; -cvar_t cl_chasecam_back = {"cl_chasecam_back", "100", true}; -cvar_t cl_chasecam_right = {"cl_chasecam_right", "0", true}; +cvar_t cl_chasecam = {"cl_chasecam", "0", CVAR_ARCHIVE}; +cvar_t cl_chasecam_up = {"cl_chasecam_up", "16",CVAR_ARCHIVE}; +cvar_t cl_chasecam_back = {"cl_chasecam_back", "100", CVAR_ARCHIVE}; +cvar_t cl_chasecam_right = {"cl_chasecam_right", "0", CVAR_ARCHIVE}; vec3_t chase_pos; vec3_t chase_angles; diff --git a/common/cl_input.c b/common/cl_input.c index 88a4ced..816462a 100644 --- a/common/cl_input.c +++ b/common/cl_input.c @@ -231,8 +231,8 @@ float CL_KeyState (kbutton_t *key) //========================================================================== cvar_t cl_upspeed = {"cl_upspeed","200"}; -cvar_t cl_forwardspeed = {"cl_forwardspeed","200", true}; -cvar_t cl_backspeed = {"cl_backspeed","200", true}; +cvar_t cl_forwardspeed = {"cl_forwardspeed","200", CVAR_ARCHIVE}; +cvar_t cl_backspeed = {"cl_backspeed","200", CVAR_ARCHIVE}; cvar_t cl_sidespeed = {"cl_sidespeed","350"}; cvar_t cl_movespeedkey = {"cl_movespeedkey","2.0"}; diff --git a/common/cl_main.c b/common/cl_main.c index 17447eb..56c6af0 100644 --- a/common/cl_main.c +++ b/common/cl_main.c @@ -91,31 +91,31 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. qboolean noclip_anglehack; // remnant from old quake -cvar_t rcon_password = {"rcon_password", "", false}; +cvar_t rcon_password = {"rcon_password", "", CVAR_NONE}; cvar_t rcon_address = {"rcon_address", ""}; cvar_t cl_timeout = {"cl_timeout", "60"}; // these two are not intended to be set directly -cvar_t cl_name = {"_cl_name", "player", true}; -cvar_t cl_color = {"_cl_color", "0", true}; +cvar_t cl_name = {"_cl_name", "player", CVAR_ARCHIVE}; +cvar_t cl_color = {"_cl_color", "0", CVAR_ARCHIVE}; cvar_t cl_shownet = {"cl_shownet","0"}; // can be 0, 1, or 2 cvar_t cl_nolerp = {"cl_nolerp","0"}; -cvar_t cl_sbar = {"cl_sbar", "1", true}; -cvar_t cl_hudswap = {"cl_hudswap", "1", true}; -cvar_t cl_maxfps = {"cl_maxfps", "0", true}; +cvar_t cl_sbar = {"cl_sbar", "1", CVAR_ARCHIVE}; +cvar_t cl_hudswap = {"cl_hudswap", "1", CVAR_ARCHIVE}; +cvar_t cl_maxfps = {"cl_maxfps", "0", CVAR_ARCHIVE}; -cvar_t lookspring = {"lookspring","0", true}; -cvar_t lookstrafe = {"lookstrafe","0", true}; -cvar_t sensitivity = {"sensitivity","3", true}; +cvar_t lookspring = {"lookspring","0", CVAR_ARCHIVE}; +cvar_t lookstrafe = {"lookstrafe","0", CVAR_ARCHIVE}; +cvar_t sensitivity = {"sensitivity","3", CVAR_ARCHIVE}; -cvar_t m_pitch = {"m_pitch","0.022", true}; -cvar_t m_yaw = {"m_yaw","0.022", true}; -cvar_t m_forward = {"m_forward","1", true}; -cvar_t m_side = {"m_side","0.8", true}; +cvar_t m_pitch = {"m_pitch","0.022", CVAR_ARCHIVE}; +cvar_t m_yaw = {"m_yaw","0.022", CVAR_ARCHIVE}; +cvar_t m_forward = {"m_forward","1", CVAR_ARCHIVE}; +cvar_t m_side = {"m_side","0.8", CVAR_ARCHIVE}; cvar_t entlatency = {"entlatency", "20"}; cvar_t cl_predict_players = {"cl_predict_players", "1"}; @@ -131,16 +131,16 @@ static qboolean allowremotecmd = true; // // info mirrors // -cvar_t password = {"password", "", false, true}; -cvar_t spectator = {"spectator", "", false, true}; -cvar_t name = {"name","unnamed", true, true}; -cvar_t team = {"team","", true, true}; -cvar_t skin = {"skin","", true, true}; -cvar_t topcolor = {"topcolor","0", true, true}; -cvar_t bottomcolor = {"bottomcolor","0", true, true}; -cvar_t rate = {"rate","2500", true, true}; -cvar_t noaim = {"noaim","0", true, true}; -cvar_t msg = {"msg","1", true, true}; +cvar_t password = {"password", "", CVAR_USERINFO|CVAR_SERVERINFO }; +cvar_t spectator = {"spectator", "",CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t name = {"name","unnamed", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t team = {"team","", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t skin = {"skin","", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t topcolor = {"topcolor","0", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t bottomcolor = {"bottomcolor","0", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t rate = {"rate","2500", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t noaim = {"noaim","0", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t msg = {"msg","1", CVAR_ARCHIVE|CVAR_USERINFO|CVAR_SERVERINFO}; extern cvar_t cl_hightrack; diff --git a/common/cvar.c b/common/cvar.c index e8999cb..070388f 100644 --- a/common/cvar.c +++ b/common/cvar.c @@ -137,16 +137,16 @@ void Cvar_Set (char *var_name, char *value) Con_Printf ("Cvar_Set: variable %s not found\n", var_name); return; } - + if(var->type&CVAR_ROM && !var->first) return; #ifdef SERVERONLY - if (var->info) + if (var->type&CVAR_SERVERINFO) { Info_SetValueForKey (svs.info, var_name, value, MAX_SERVERINFO_STRING); SV_SendServerInfoChange(var_name, value); // SV_BroadcastCommand ("fullserverinfo \"%s\"\n", svs.info); } #else - if (var->info) + if (var->type&CVAR_USERINFO) { Info_SetValueForKey (cls.userinfo, var_name, value, MAX_INFO_STRING); if (cls.state >= ca_connected) @@ -162,6 +162,7 @@ void Cvar_Set (char *var_name, char *value) var->string = Z_Malloc (Q_strlen(value)+1); Q_strcpy (var->string, value); var->value = Q_atof (var->string); + var->first = false; } #elif defined(UQUAKE) void Cvar_Set (char *var_name, char *value) @@ -176,6 +177,9 @@ void Cvar_Set (char *var_name, char *value) return; } + // Don't change if this is a CVAR_ROM + if(var->type&CVAR_ROM && !var->first) return; + changed = Q_strcmp(var->string, value); Z_Free (var->string); // free the old value string @@ -183,11 +187,12 @@ void Cvar_Set (char *var_name, char *value) var->string = Z_Malloc (Q_strlen(value)+1); Q_strcpy (var->string, value); var->value = Q_atof (var->string); - if (var->server && changed) + if (var->type&CVAR_NOTIFY && changed) { if (sv.active) SV_BroadcastPrintf ("\"%s\" changed to \"%s\"\n", var->name, var->string); } + var->first = false; } #endif @@ -239,6 +244,7 @@ void Cvar_RegisterVariable (cvar_t *variable) variable->string = Z_Malloc (1); // set it through the function to be consistant + variable->first = true; Cvar_Set (variable->name, value); } @@ -283,7 +289,7 @@ void Cvar_WriteVariables (QFile *f) cvar_t *var; for (var = cvar_vars ; var ; var = var->next) - if (var->archive) + if (var->type&CVAR_ARCHIVE) Qprintf (f, "%s \"%s\"\n", var->name, var->string); } @@ -308,7 +314,7 @@ void Cvar_Set_f(void) else { var = (cvar_t*)calloc(1,sizeof(cvar_t)); - var->heap = 1; + var->type=CVAR_USER_CREATED|CVAR_HEAP; var->name = strdup (var_name); var->string = value; Cvar_RegisterVariable (var); diff --git a/common/cvar.h b/common/cvar.h index 8aca1f5..58e9f52 100644 --- a/common/cvar.h +++ b/common/cvar.h @@ -63,14 +63,17 @@ typedef struct cvar_s { char *name; char *string; - qboolean archive; // set to true to cause it to be saved to vars.rc - qboolean info; // added to serverinfo or userinfo when changed - qboolean server; // notifies players when changed (UQUAKE) - qboolean heap; // allocated off the heap, safe to free + unsigned int type; + qboolean first; // determine if this is the first write +// qboolean archive; // set to true to cause it to be saved to vars.rc +// qboolean info; // added to serverinfo or userinfo when changed +// qboolean server; // notifies players when changed (UQUAKE) +// qboolean heap; // allocated off the heap, safe to free float value; struct cvar_s *next; } cvar_t; +#define CVAR_NONE 0 #define CVAR_ARCHIVE 1 // set to cause it to be saved to vars.rc // used for system variables, not for player // specific configurations @@ -79,14 +82,11 @@ typedef struct cvar_s #define CVAR_SYSTEMINFO 8 // these cvars will be duplicated on all clients #define CVAR_INIT 16 // don't allow change from console at all, // but can be set from the command line -#define CVAR_LATCH 32 // will only change when C code next does - // a Cvar_Get(), so it can't be changed - // without proper initialization. modified - // will be set, even though the value hasn't - // changed yet +#define CVAR_NOTIFY 32 // Will notify players when changed. + #define CVAR_ROM 64 // display only, cannot be set by user at all #define CVAR_USER_CREATED 128 // created by a set command -#define CVAR_TEMP 256 // can be set even when cheats are disabled, but is not archived +#define CVAR_HEAP 256 // allocated off the heap, safe to free #define CVAR_CHEAT 512 // can not be changed if cheats are disabled #define CVAR_NORESTART 1024 // do not clear when a cvar_restart is issued diff --git a/common/gl_rmain.c b/common/gl_rmain.c index 3d05733..f2e5e91 100644 --- a/common/gl_rmain.c +++ b/common/gl_rmain.c @@ -128,7 +128,7 @@ cvar_t gl_keeptjunctions = {"gl_keeptjunctions","1"}; #else cvar_t gl_keeptjunctions = {"gl_keeptjunctions","0"}; #endif -cvar_t gl_doubleeyes = {"gl_doubleeyes", "1", true}; +cvar_t gl_doubleeyes = {"gl_doubleeyes", "1", CVAR_ARCHIVE}; extern cvar_t gl_ztrick; #ifdef QUAKEWORLD diff --git a/common/gl_vidglx.c b/common/gl_vidglx.c index eec2cc0..fd459ca 100644 --- a/common/gl_vidglx.c +++ b/common/gl_vidglx.c @@ -87,10 +87,10 @@ unsigned short d_8to16table[256]; unsigned d_8to24table[256]; unsigned char d_15to8table[65536]; -cvar_t _windowed_mouse = {"_windowed_mouse", "0", true}; +cvar_t _windowed_mouse = {"_windowed_mouse", "0", CVAR_ARCHIVE}; cvar_t m_filter = {"m_filter", "0"}; -cvar_t vid_mode = {"vid_mode", "0", false}; -cvar_t vid_glx_fullscreen = {"vid_glx_fullscreen", "0", false}; +cvar_t vid_mode = {"vid_mode", "0", CVAR_NONE}; +cvar_t vid_glx_fullscreen = {"vid_glx_fullscreen", "0", CVAR_NONE}; static int fullscreen = 0; @@ -104,7 +104,7 @@ static int nummodes; static XF86VidModeModeInfo **vidmodes; static int hasdgavideo = 0, hasvidmode = 0; static int dgamouse = 0; -static cvar_t vid_dga_mouseaccel = {"vid_dga_mouseaccel", "1", true}; +static cvar_t vid_dga_mouseaccel = {"vid_dga_mouseaccel", "1", CVAR_ARCHIVE}; #endif #ifdef XMESA @@ -139,7 +139,7 @@ int texture_extension_number = 1; float gldepthmin, gldepthmax; -cvar_t gl_ztrick = {"gl_ztrick", "0", true}; +cvar_t gl_ztrick = {"gl_ztrick", "0", CVAR_ARCHIVE}; const char *gl_vendor; const char *gl_renderer; diff --git a/common/gl_vidlinux_3dfx.c b/common/gl_vidlinux_3dfx.c index d2f0e75..16e6f86 100644 --- a/common/gl_vidlinux_3dfx.c +++ b/common/gl_vidlinux_3dfx.c @@ -47,10 +47,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. unsigned d_8to24table[256]; unsigned char d_15to8table[65536]; -static cvar_t vid_mode = {"vid_mode", "5", false}; -static cvar_t vid_redrawfull = {"vid_redrawfull", "0", false}; -static cvar_t vid_waitforrefresh = {"vid_waitforrefresh", "0", true}; -cvar_t gl_ztrick = {"gl_ztrick", "0", true}; +static cvar_t vid_mode = {"vid_mode", "5", CVAR_NONE}; +static cvar_t vid_redrawfull = {"vid_redrawfull", "0", CVAR_NONE}; +static cvar_t vid_waitforrefresh = {"vid_waitforrefresh", "0", CVAR_ARCHIVE}; +cvar_t gl_ztrick = {"gl_ztrick", "0", CVAR_ARCHIVE}; static fxMesaContext fc = NULL; static int scr_width, scr_height; diff --git a/common/gl_vidnt.c b/common/gl_vidnt.c index 5794007..4120234 100644 --- a/common/gl_vidnt.c +++ b/common/gl_vidnt.c @@ -143,20 +143,20 @@ qboolean gl_mtexable = false; //==================================== -cvar_t gl_ztrick = {"gl_ztrick", "1", true}; +cvar_t gl_ztrick = {"gl_ztrick", "1", CVAR_ARCHIVE}; -cvar_t vid_mode = {"vid_mode", "0", false}; +cvar_t vid_mode = {"vid_mode", "0", CVAR_NONE}; // Note that 0 is MODE_WINDOWED -cvar_t _vid_default_mode = {"_vid_default_mode", "0", true}; +cvar_t _vid_default_mode = {"_vid_default_mode", "0", CVAR_ARCHIVE}; // Note that 3 is MODE_FULLSCREEN_DEFAULT -cvar_t _vid_default_mode_win = {"_vid_default_mode_win", "3", true}; +cvar_t _vid_default_mode_win = {"_vid_default_mode_win", "3", CVAR_ARCHIVE}; cvar_t vid_wait = {"vid_wait", "0"}; -cvar_t vid_nopageflip = {"vid_nopageflip", "0", true}; -cvar_t _vid_wait_override = {"_vid_wait_override", "0", true}; -cvar_t vid_config_x = {"vid_config_x", "800", true}; -cvar_t vid_config_y = {"vid_config_y", "600", true}; -cvar_t vid_stretch_by_2 = {"vid_stretch_by_2", "1", true}; -cvar_t _windowed_mouse = {"_windowed_mouse", "1", true}; +cvar_t vid_nopageflip = {"vid_nopageflip", "0", CVAR_ARCHIVE}; +cvar_t _vid_wait_override = {"_vid_wait_override", "0", CVAR_ARCHIVE}; +cvar_t vid_config_x = {"vid_config_x", "800", CVAR_ARCHIVE}; +cvar_t vid_config_y = {"vid_config_y", "600", CVAR_ARCHIVE}; +cvar_t vid_stretch_by_2 = {"vid_stretch_by_2", "1", CVAR_ARCHIVE}; +cvar_t _windowed_mouse = {"_windowed_mouse", "1", CVAR_ARCHIVE}; int window_center_x, window_center_y, window_x, window_y, window_width, window_height; RECT window_rect; diff --git a/common/host.c b/common/host.c index 557d07f..832e545 100644 --- a/common/host.c +++ b/common/host.c @@ -69,16 +69,16 @@ cvar_t sys_ticrate = {"sys_ticrate","0.05"}; cvar_t serverprofile = {"serverprofile", "0"}; cvar_t host_framerate = {"host_framerate", "0"}; // set for slow motion cvar_t samelevel = {"samelevel", "0"}; -cvar_t noexit = {"noexit", "0", false, true}; +cvar_t noexit = {"noexit", "0", CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t pausable = {"pausable", "1"}; cvar_t temp1 = {"temp1", "0"}; cvar_t sv_filter = {"sv_filter", "1"}; // strip \n, \r in names? -cvar_t teamplay = {"teamplay","0",false,true}; +cvar_t teamplay = {"teamplay","0",CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t deathmatch = {"deathmatch","0"}; // 0, 1, or 2 cvar_t coop = {"coop","0"}; // 0 or 1 -cvar_t fraglimit = {"fraglimit","0",false,true}; +cvar_t fraglimit = {"fraglimit","0",CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t skill = {"skill","1"}; // 0 - 3 -cvar_t timelimit = {"timelimit","0",false,true}; +cvar_t timelimit = {"timelimit","0",CVAR_USERINFO|CVAR_SERVERINFO}; #ifdef UQUAKE client_t *host_client; // current client diff --git a/common/in_dos.c b/common/in_dos.c index c3da34c..f211286 100644 --- a/common/in_dos.c +++ b/common/in_dos.c @@ -88,7 +88,7 @@ float old_mouse_x, old_mouse_y; cvar_t in_joystick = {"joystick","1"}; -cvar_t joy_numbuttons = {"joybuttons","4", true}; +cvar_t joy_numbuttons = {"joybuttons","4", CVAR_ARCHIVE}; qboolean joy_avail; int joy_oldbuttonstate; @@ -103,7 +103,7 @@ qboolean extern_avail; int extern_buttons; int extern_oldbuttonstate; int extern_buttonstate; -cvar_t aux_look = {"auxlook","1", true}; +cvar_t aux_look = {"auxlook","1", CVAR_ARCHIVE}; externControl_t *extern_control; void IN_StartupExternal (void); void IN_ExternalMove (usercmd_t *cmd); diff --git a/common/in_sun.c b/common/in_sun.c index 3daeb3c..35c9f01 100644 --- a/common/in_sun.c +++ b/common/in_sun.c @@ -62,7 +62,7 @@ extern int global_dx, global_dy; // globals // -cvar_t _windowed_mouse = {"_windowed_mouse","1", true}; +cvar_t _windowed_mouse = {"_windowed_mouse","1", CVAR_ARCHIVE}; int x_root, y_root; int x_root_old, y_root_old; // diff --git a/common/in_svgalib.c b/common/in_svgalib.c index 6077c9f..34fa60b 100644 --- a/common/in_svgalib.c +++ b/common/in_svgalib.c @@ -57,7 +57,7 @@ static int mx, my; static void IN_init_kb(); static void IN_init_mouse(); -cvar_t _windowed_mouse = {"_windowed_mouse", "1", true}; +cvar_t _windowed_mouse = {"_windowed_mouse", "1", CVAR_ARCHIVE}; cvar_t m_filter = {"m_filter","0"}; static cvar_t mouse_button_commands[3] = diff --git a/common/in_win.c b/common/in_win.c index 1289b8d..c2aa659 100644 --- a/common/in_win.c +++ b/common/in_win.c @@ -86,7 +86,7 @@ PDWORD pdwRawValue[JOY_MAX_AXES]; // each time. this avoids any problems with getting back to a default usage // or when changing from one controller to another. this way at least something // works. -cvar_t in_joystick = {"joystick","0", true}; +cvar_t in_joystick = {"joystick","0", CVAR_ARCHIVE}; cvar_t joy_name = {"joyname", "joystick"}; cvar_t joy_advanced = {"joyadvanced", "0"}; cvar_t joy_advaxisx = {"joyadvaxisx", "0"}; diff --git a/common/in_x11.c b/common/in_x11.c index 21ded30..1c0f49c 100644 --- a/common/in_x11.c +++ b/common/in_x11.c @@ -62,8 +62,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #endif -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; -cvar_t m_filter = {"m_filter","0", true}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; +cvar_t m_filter = {"m_filter","0", CVAR_ARCHIVE}; static qboolean mouse_avail; static float mouse_x, mouse_y; diff --git a/common/pr_edict.c b/common/pr_edict.c index 63fe162..4feae3d 100644 --- a/common/pr_edict.c +++ b/common/pr_edict.c @@ -63,11 +63,11 @@ cvar_t scratch1 = {"scratch1", "0"}; cvar_t scratch2 = {"scratch2", "0"}; cvar_t scratch3 = {"scratch3", "0"}; cvar_t scratch4 = {"scratch4", "0"}; -cvar_t savedgamecfg = {"savedgamecfg", "0", true}; -cvar_t saved1 = {"saved1", "0", true}; -cvar_t saved2 = {"saved2", "0", true}; -cvar_t saved3 = {"saved3", "0", true}; -cvar_t saved4 = {"saved4", "0", true}; +cvar_t savedgamecfg = {"savedgamecfg", "0", CVAR_ARCHIVE}; +cvar_t saved1 = {"saved1", "0", CVAR_ARCHIVE}; +cvar_t saved2 = {"saved2", "0", CVAR_ARCHIVE}; +cvar_t saved3 = {"saved3", "0", CVAR_ARCHIVE}; +cvar_t saved4 = {"saved4", "0", CVAR_ARCHIVE}; #endif #define MAX_FIELD_LEN 64 diff --git a/common/snd_dma.c b/common/snd_dma.c index b998b70..e1c65a4 100644 --- a/common/snd_dma.c +++ b/common/snd_dma.c @@ -82,8 +82,8 @@ int desired_bits = 16; int sound_started=0; -cvar_t bgmvolume = {"bgmvolume", "1", true}; -cvar_t volume = {"volume", "0.7", true}; +cvar_t bgmvolume = {"bgmvolume", "1", CVAR_ARCHIVE}; +cvar_t volume = {"volume", "0.7", CVAR_ARCHIVE}; cvar_t nosound = {"nosound", "0"}; cvar_t precache = {"precache", "1"}; @@ -93,7 +93,7 @@ cvar_t ambient_level = {"ambient_level", "0.3"}; cvar_t ambient_fade = {"ambient_fade", "100"}; cvar_t snd_noextraupdate = {"snd_noextraupdate", "0"}; cvar_t snd_show = {"snd_show", "0"}; -cvar_t _snd_mixahead = {"_snd_mixahead", "0.1", true}; +cvar_t _snd_mixahead = {"_snd_mixahead", "0.1", CVAR_ARCHIVE}; // ==================================================================== diff --git a/common/vid_aa.c b/common/vid_aa.c index 7f638b2..407dbaf 100644 --- a/common/vid_aa.c +++ b/common/vid_aa.c @@ -47,9 +47,9 @@ static byte vid_current_palette[768]; static int UseDisplay = 1; -static cvar_t vid_mode = {"vid_mode","5",false}; -static cvar_t vid_redrawfull = {"vid_redrawfull","0",false}; -static cvar_t vid_waitforrefresh = {"vid_waitforrefresh","0",true}; +static cvar_t vid_mode = {"vid_mode","5",CVAR_NONE}; +static cvar_t vid_redrawfull = {"vid_redrawfull","0",CVAR_NONE}; +static cvar_t vid_waitforrefresh = {"vid_waitforrefresh","0",CVAR_ARCHIVE}; static char *framebuffer_ptr; diff --git a/common/vid_dos.c b/common/vid_dos.c index 71d7979..a84c593 100644 --- a/common/vid_dos.c +++ b/common/vid_dos.c @@ -44,21 +44,21 @@ vmode_t *pcurrentmode = NULL; int vid_testingmode, vid_realmode; double vid_testendtime; -cvar_t vid_mode = {"vid_mode","0", false}; +cvar_t vid_mode = {"vid_mode","0", CVAR_NONE}; cvar_t vid_wait = {"vid_wait","0"}; -cvar_t vid_nopageflip = {"vid_nopageflip","0", true}; -cvar_t _vid_wait_override = {"_vid_wait_override", "0", true}; -cvar_t _vid_default_mode = {"_vid_default_mode","0", true}; -cvar_t _vid_default_mode_win = {"_vid_default_mode_win","1", true}; -cvar_t vid_config_x = {"vid_config_x","800", true}; -cvar_t vid_config_y = {"vid_config_y","600", true}; -cvar_t vid_stretch_by_2 = {"vid_stretch_by_2","1", true}; -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; -cvar_t vid_fullscreen_mode = {"vid_fullscreen_mode","3", true}; -cvar_t vid_windowed_mode = {"vid_windowed_mode","0", true}; -cvar_t block_switch = {"block_switch","0", true}; -cvar_t vid_window_x = {"vid_window_x", "0", true}; -cvar_t vid_window_y = {"vid_window_y", "0", true}; +cvar_t vid_nopageflip = {"vid_nopageflip","0", CVAR_ARCHIVE}; +cvar_t _vid_wait_override = {"_vid_wait_override", "0",CVAR_ARCHIVE}; +cvar_t _vid_default_mode = {"_vid_default_mode","0", CVAR_ARCHIVE}; +cvar_t _vid_default_mode_win = {"_vid_default_mode_win","1", CVAR_ARCHIVE}; +cvar_t vid_config_x = {"vid_config_x","800", CVAR_ARCHIVE}; +cvar_t vid_config_y = {"vid_config_y","600", CVAR_ARCHIVE}; +cvar_t vid_stretch_by_2 = {"vid_stretch_by_2","1", CVAR_ARCHIVE}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; +cvar_t vid_fullscreen_mode = {"vid_fullscreen_mode","3", CVAR_ARCHIVE}; +cvar_t vid_windowed_mode = {"vid_windowed_mode","0", CVAR_ARCHIVE}; +cvar_t block_switch = {"block_switch","0", CVAR_ARCHIVE}; +cvar_t vid_window_x = {"vid_window_x", "0", CVAR_ARCHIVE}; +cvar_t vid_window_y = {"vid_window_y", "0", CVAR_ARCHIVE}; int VID_options_items = 0; diff --git a/common/vid_ggi.c b/common/vid_ggi.c index eef5787..0f98694 100644 --- a/common/vid_ggi.c +++ b/common/vid_ggi.c @@ -44,8 +44,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. viddef_t vid; // global video state unsigned short d_8to16table[256]; -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; -cvar_t m_filter = {"m_filter","0", true}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; +cvar_t m_filter = {"m_filter","0", CVAR_ARCHIVE}; #define NUM_STDBUTTONS 3 #define NUM_BUTTONS 10 diff --git a/common/vid_sdl.c b/common/vid_sdl.c index 406aa6b..3626614 100644 --- a/common/vid_sdl.c +++ b/common/vid_sdl.c @@ -33,7 +33,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #include -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; static float old_windowed_mouse = 0; viddef_t vid; // global video state diff --git a/common/vid_sunx.c b/common/vid_sunx.c index d036957..10ca585 100644 --- a/common/vid_sunx.c +++ b/common/vid_sunx.c @@ -57,8 +57,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #include -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; -cvar_t m_filter = {"m_filter","0", true}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; +cvar_t m_filter = {"m_filter","0", CVAR_ARCHIVE}; static qboolean mouse_avail; static float mouse_x, mouse_y; diff --git a/common/vid_win.c b/common/vid_win.c index d8a5b1d..4705f1e 100644 --- a/common/vid_win.c +++ b/common/vid_win.c @@ -72,23 +72,23 @@ viddef_t vid; // global video state #define MODE_FULLSCREEN_DEFAULT (MODE_WINDOWED + 3) // Note that 0 is MODE_WINDOWED -cvar_t vid_mode = {"vid_mode","0", false}; +cvar_t vid_mode = {"vid_mode","0", CVAR_NONE}; // Note that 0 is MODE_WINDOWED -cvar_t _vid_default_mode = {"_vid_default_mode","0", true}; +cvar_t _vid_default_mode = {"_vid_default_mode","0", CVAR_ARCHIVE}; // Note that 3 is MODE_FULLSCREEN_DEFAULT -cvar_t _vid_default_mode_win = {"_vid_default_mode_win","3", true}; +cvar_t _vid_default_mode_win = {"_vid_default_mode_win","3", CVAR_ARCHIVE}; cvar_t vid_wait = {"vid_wait","0"}; -cvar_t vid_nopageflip = {"vid_nopageflip","0", true}; -cvar_t _vid_wait_override = {"_vid_wait_override", "0", true}; -cvar_t vid_config_x = {"vid_config_x","800", true}; -cvar_t vid_config_y = {"vid_config_y","600", true}; -cvar_t vid_stretch_by_2 = {"vid_stretch_by_2","1", true}; -cvar_t _windowed_mouse = {"_windowed_mouse","0", true}; -cvar_t vid_fullscreen_mode = {"vid_fullscreen_mode","3", true}; -cvar_t vid_windowed_mode = {"vid_windowed_mode","0", true}; -cvar_t block_switch = {"block_switch","0", true}; -cvar_t vid_window_x = {"vid_window_x", "0", true}; -cvar_t vid_window_y = {"vid_window_y", "0", true}; +cvar_t vid_nopageflip = {"vid_nopageflip","0", CVAR_ARCHIVE}; +cvar_t _vid_wait_override = {"_vid_wait_override", "0", CVAR_ARCHIVE}; +cvar_t vid_config_x = {"vid_config_x","800", CVAR_ARCHIVE}; +cvar_t vid_config_y = {"vid_config_y","600", CVAR_ARCHIVE}; +cvar_t vid_stretch_by_2 = {"vid_stretch_by_2","1", CVAR_ARCHIVE}; +cvar_t _windowed_mouse = {"_windowed_mouse","0", CVAR_ARCHIVE}; +cvar_t vid_fullscreen_mode = {"vid_fullscreen_mode","3", CVAR_ARCHIVE}; +cvar_t vid_windowed_mode = {"vid_windowed_mode","0", CVAR_ARCHIVE}; +cvar_t block_switch = {"block_switch","0", CVAR_ARCHIVE}; +cvar_t vid_window_x = {"vid_window_x", "0", CVAR_ARCHIVE}; +cvar_t vid_window_y = {"vid_window_y", "0", CVAR_ARCHIVE}; typedef struct { int width; diff --git a/qw_client/gl_model.c b/qw_client/gl_model.c index 4e16d2d..c18173b 100644 --- a/qw_client/gl_model.c +++ b/qw_client/gl_model.c @@ -52,7 +52,7 @@ byte mod_novis[MAX_MAP_LEAFS/8]; model_t mod_known[MAX_MOD_KNOWN]; int mod_numknown; -cvar_t gl_subdivide_size = {"gl_subdivide_size", "128", true}; +cvar_t gl_subdivide_size = {"gl_subdivide_size", "128", CVAR_ARCHIVE}; /* =============== diff --git a/qw_client/gl_screen.c b/qw_client/gl_screen.c index eb0b919..102535b 100644 --- a/qw_client/gl_screen.c +++ b/qw_client/gl_screen.c @@ -97,7 +97,7 @@ float scr_con_current; float scr_conlines; // lines of console to display float oldscreensize, oldfov; -cvar_t scr_viewsize = {"viewsize","100", true}; +cvar_t scr_viewsize = {"viewsize","100", CVAR_ARCHIVE}; cvar_t scr_fov = {"fov","90"}; // 10 - 170 cvar_t scr_conspeed = {"scr_conspeed","300"}; cvar_t scr_centertime = {"scr_centertime","2"}; @@ -106,7 +106,7 @@ cvar_t scr_showturtle = {"showturtle","0"}; cvar_t scr_showpause = {"showpause","1"}; cvar_t scr_printspeed = {"scr_printspeed","8"}; cvar_t scr_allowsnap = {"scr_allowsnap", "1"}; -cvar_t gl_triplebuffer = {"gl_triplebuffer", "1", true }; +cvar_t gl_triplebuffer = {"gl_triplebuffer", "1", CVAR_ARCHIVE }; extern cvar_t crosshair; qboolean scr_initialized; // ready to draw diff --git a/qw_client/screen.c b/qw_client/screen.c index 4e7550b..0045f30 100644 --- a/qw_client/screen.c +++ b/qw_client/screen.c @@ -94,7 +94,7 @@ float scr_conlines; // lines of console to display float oldscreensize, oldfov; float oldsbar; -cvar_t scr_viewsize = {"viewsize","100", true}; +cvar_t scr_viewsize = {"viewsize","100", CVAR_ARCHIVE}; cvar_t scr_fov = {"fov","90"}; // 10 - 170 cvar_t scr_conspeed = {"scr_conspeed","300"}; cvar_t scr_centertime = {"scr_centertime","2"}; diff --git a/qw_client/view.c b/qw_client/view.c index ea5c830..975c347 100644 --- a/qw_client/view.c +++ b/qw_client/view.c @@ -45,32 +45,32 @@ cvar_t lcd_x = {"lcd_x", "0"}; // FIXME: make this work sometime... cvar_t cl_rollspeed = {"cl_rollspeed", "200"}; cvar_t cl_rollangle = {"cl_rollangle", "2.0"}; -cvar_t cl_bob = {"cl_bob","0.02", false}; -cvar_t cl_bobcycle = {"cl_bobcycle","0.6", false}; -cvar_t cl_bobup = {"cl_bobup","0.5", false}; +cvar_t cl_bob = {"cl_bob","0.02", CVAR_NONE}; +cvar_t cl_bobcycle = {"cl_bobcycle","0.6", CVAR_NONE}; +cvar_t cl_bobup = {"cl_bobup","0.5", CVAR_NONE}; -cvar_t v_kicktime = {"v_kicktime", "0.5", false}; -cvar_t v_kickroll = {"v_kickroll", "0.6", false}; -cvar_t v_kickpitch = {"v_kickpitch", "0.6", false}; +cvar_t v_kicktime = {"v_kicktime", "0.5", CVAR_NONE}; +cvar_t v_kickroll = {"v_kickroll", "0.6", CVAR_NONE}; +cvar_t v_kickpitch = {"v_kickpitch", "0.6", CVAR_NONE}; -cvar_t v_iyaw_cycle = {"v_iyaw_cycle", "2", false}; -cvar_t v_iroll_cycle = {"v_iroll_cycle", "0.5", false}; -cvar_t v_ipitch_cycle = {"v_ipitch_cycle", "1", false}; -cvar_t v_iyaw_level = {"v_iyaw_level", "0.3", false}; -cvar_t v_iroll_level = {"v_iroll_level", "0.1", false}; -cvar_t v_ipitch_level = {"v_ipitch_level", "0.3", false}; +cvar_t v_iyaw_cycle = {"v_iyaw_cycle", "2", CVAR_NONE}; +cvar_t v_iroll_cycle = {"v_iroll_cycle", "0.5", CVAR_NONE}; +cvar_t v_ipitch_cycle = {"v_ipitch_cycle", "1", CVAR_NONE}; +cvar_t v_iyaw_level = {"v_iyaw_level", "0.3", CVAR_NONE}; +cvar_t v_iroll_level = {"v_iroll_level", "0.1", CVAR_NONE}; +cvar_t v_ipitch_level = {"v_ipitch_level", "0.3", CVAR_NONE}; -cvar_t v_idlescale = {"v_idlescale", "0", false}; +cvar_t v_idlescale = {"v_idlescale", "0", CVAR_NONE}; -cvar_t crosshair = {"crosshair", "0", true}; -cvar_t crosshaircolor = {"crosshaircolor", "79", true}; +cvar_t crosshair = {"crosshair", "0", CVAR_ARCHIVE}; +cvar_t crosshaircolor = {"crosshaircolor", "79", CVAR_ARCHIVE}; -cvar_t cl_crossx = {"cl_crossx", "0", true}; -cvar_t cl_crossy = {"cl_crossy", "0", true}; +cvar_t cl_crossx = {"cl_crossx", "0", CVAR_ARCHIVE}; +cvar_t cl_crossy = {"cl_crossy", "0", CVAR_ARCHIVE}; -cvar_t gl_cshiftpercent = {"gl_cshiftpercent", "100", false}; +cvar_t gl_cshiftpercent = {"gl_cshiftpercent", "100", CVAR_NONE}; -cvar_t v_contentblend = {"v_contentblend", "1", false}; +cvar_t v_contentblend = {"v_contentblend", "1", CVAR_NONE}; float v_dmg_time, v_dmg_roll, v_dmg_pitch; @@ -152,7 +152,7 @@ float V_CalcBob (void) //============================================================================= -cvar_t v_centermove = {"v_centermove", "0.15", false}; +cvar_t v_centermove = {"v_centermove", "0.15", CVAR_NONE}; cvar_t v_centerspeed = {"v_centerspeed","500"}; @@ -269,7 +269,7 @@ cshift_t cshift_water = { {130,80,50}, 128 }; cshift_t cshift_slime = { {0,25,5}, 150 }; cshift_t cshift_lava = { {255,80,0}, 150 }; -cvar_t v_gamma = {"gamma", "1", true}; +cvar_t v_gamma = {"gamma", "1", CVAR_ARCHIVE}; byte gammatable[256]; // palette is sent through this diff --git a/qw_server/sv_main.c b/qw_server/sv_main.c index a76ddf1..023748d 100644 --- a/qw_server/sv_main.c +++ b/qw_server/sv_main.c @@ -78,17 +78,17 @@ cvar_t pausable = {"pausable", "1"}; // // game rules mirrored in svs.info // -cvar_t fraglimit = {"fraglimit","0",false,true}; -cvar_t timelimit = {"timelimit","0",false,true}; -cvar_t teamplay = {"teamplay","0",false,true}; -cvar_t samelevel = {"samelevel","0", false, true}; -cvar_t maxclients = {"maxclients","8", false, true}; -cvar_t maxspectators = {"maxspectators","8", false, true}; -cvar_t deathmatch = {"deathmatch","1", false, true}; // 0, 1, or 2 -cvar_t spawn = {"spawn","0", false, true}; -cvar_t watervis = {"watervis", "0", false, true}; +cvar_t fraglimit = {"fraglimit","0",CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t timelimit = {"timelimit","0",CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t teamplay = {"teamplay","0",CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t samelevel = {"samelevel","0", CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t maxclients = {"maxclients","8", CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t maxspectators = {"maxspectators","8", CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t deathmatch = {"deathmatch","1", CVAR_USERINFO|CVAR_SERVERINFO}; // 0, 1, or 2 +cvar_t spawn = {"spawn","0", CVAR_USERINFO|CVAR_SERVERINFO}; +cvar_t watervis = {"watervis", "0", CVAR_USERINFO|CVAR_SERVERINFO}; -cvar_t hostname = {"hostname","unnamed", false, true}; +cvar_t hostname = {"hostname","unnamed", CVAR_USERINFO|CVAR_SERVERINFO}; QFile *sv_logfile; QFile *sv_fraglogfile; diff --git a/uquake/gl_model.c b/uquake/gl_model.c index c0efc38..6d67251 100644 --- a/uquake/gl_model.c +++ b/uquake/gl_model.c @@ -47,7 +47,7 @@ byte mod_novis[MAX_MAP_LEAFS/8]; model_t mod_known[MAX_MOD_KNOWN]; int mod_numknown; -cvar_t gl_subdivide_size = {"gl_subdivide_size", "128", true}; +cvar_t gl_subdivide_size = {"gl_subdivide_size", "128", CVAR_ARCHIVE}; /* =============== diff --git a/uquake/gl_screen.c b/uquake/gl_screen.c index f637612..a049c19 100644 --- a/uquake/gl_screen.c +++ b/uquake/gl_screen.c @@ -98,7 +98,7 @@ float scr_con_current; float scr_conlines; // lines of console to display float oldscreensize, oldfov; -cvar_t scr_viewsize = {"viewsize","100", true}; +cvar_t scr_viewsize = {"viewsize","100", CVAR_ARCHIVE}; cvar_t scr_fov = {"fov","90"}; // 10 - 170 cvar_t scr_conspeed = {"scr_conspeed","300"}; cvar_t scr_centertime = {"scr_centertime","2"}; @@ -106,7 +106,7 @@ cvar_t scr_showram = {"showram","1"}; cvar_t scr_showturtle = {"showturtle","0"}; cvar_t scr_showpause = {"showpause","1"}; cvar_t scr_printspeed = {"scr_printspeed","8"}; -cvar_t gl_triplebuffer = {"gl_triplebuffer", "1", true }; +cvar_t gl_triplebuffer = {"gl_triplebuffer", "1",CVAR_ARCHIVE }; extern cvar_t crosshair; qboolean scr_initialized; // ready to draw diff --git a/uquake/net_dgrm.c b/uquake/net_dgrm.c index a188338..698344c 100644 --- a/uquake/net_dgrm.c +++ b/uquake/net_dgrm.c @@ -958,7 +958,7 @@ static qsocket_t *_Datagram_CheckNewConnections (void) // search for the next server cvar while (var) { - if (var->server) + if (var->type&CVAR_NOTIFY) break; var = var->next; } diff --git a/uquake/net_main.c b/uquake/net_main.c index 7956f59..aebbb80 100644 --- a/uquake/net_main.c +++ b/uquake/net_main.c @@ -76,14 +76,14 @@ cvar_t net_messagetimeout = {"net_messagetimeout","300"}; cvar_t hostname = {"hostname", "UNNAMED"}; qboolean configRestored = false; -cvar_t config_com_port = {"_config_com_port", "0x3f8", true}; -cvar_t config_com_irq = {"_config_com_irq", "4", true}; -cvar_t config_com_baud = {"_config_com_baud", "57600", true}; -cvar_t config_com_modem = {"_config_com_modem", "1", true}; -cvar_t config_modem_dialtype = {"_config_modem_dialtype", "T", true}; -cvar_t config_modem_clear = {"_config_modem_clear", "ATZ", true}; -cvar_t config_modem_init = {"_config_modem_init", "", true}; -cvar_t config_modem_hangup = {"_config_modem_hangup", "AT H", true}; +cvar_t config_com_port = {"_config_com_port", "0x3f8", CVAR_ARCHIVE}; +cvar_t config_com_irq = {"_config_com_irq", "4", CVAR_ARCHIVE}; +cvar_t config_com_baud = {"_config_com_baud", "57600", CVAR_ARCHIVE}; +cvar_t config_com_modem = {"_config_com_modem", "1", CVAR_ARCHIVE}; +cvar_t config_modem_dialtype = {"_config_modem_dialtype", "T", CVAR_ARCHIVE}; +cvar_t config_modem_clear = {"_config_modem_clear", "ATZ", CVAR_ARCHIVE}; +cvar_t config_modem_init = {"_config_modem_init", "", CVAR_ARCHIVE}; +cvar_t config_modem_hangup = {"_config_modem_hangup", "AT H", CVAR_ARCHIVE}; extern int vcrFile; qboolean recording = false; diff --git a/uquake/screen.c b/uquake/screen.c index abf0246..d365628 100644 --- a/uquake/screen.c +++ b/uquake/screen.c @@ -99,7 +99,7 @@ float scr_conlines; // lines of console to display float oldscreensize, oldfov; float oldsbar; -cvar_t scr_viewsize = {"viewsize","100", true}; +cvar_t scr_viewsize = {"viewsize","100", CVAR_ARCHIVE}; cvar_t scr_fov = {"fov","90"}; // 10 - 170 cvar_t scr_conspeed = {"scr_conspeed","300"}; cvar_t scr_centertime = {"scr_centertime","2"}; diff --git a/uquake/sv_phys.c b/uquake/sv_phys.c index cf781b6..039d8f8 100644 --- a/uquake/sv_phys.c +++ b/uquake/sv_phys.c @@ -47,9 +47,9 @@ solid_edge items only clip against bsp models. */ -cvar_t sv_friction = {"sv_friction","4",false,true}; +cvar_t sv_friction = {"sv_friction","4",CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t sv_stopspeed = {"sv_stopspeed","100"}; -cvar_t sv_gravity = {"sv_gravity","800",false,true}; +cvar_t sv_gravity = {"sv_gravity","800",CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t sv_maxvelocity = {"sv_maxvelocity","2000"}; cvar_t sv_nostep = {"sv_nostep","0"}; diff --git a/uquake/sv_user.c b/uquake/sv_user.c index b4d593e..8b3ac39 100644 --- a/uquake/sv_user.c +++ b/uquake/sv_user.c @@ -178,7 +178,7 @@ void SV_UserFriction (void) SV_Accelerate ============== */ -cvar_t sv_maxspeed = {"sv_maxspeed", "320", false, true}; +cvar_t sv_maxspeed = {"sv_maxspeed", "320", CVAR_USERINFO|CVAR_SERVERINFO}; cvar_t sv_accelerate = {"sv_accelerate", "10"}; #if 0 void SV_Accelerate (vec3_t wishvel) diff --git a/uquake/view.c b/uquake/view.c index b8fe6b2..18a23a0 100644 --- a/uquake/view.c +++ b/uquake/view.c @@ -42,37 +42,37 @@ when crossing a water boudnary. cvar_t lcd_x = {"lcd_x", "0"}; // FIXME: make this work sometime... cvar_t lcd_yaw = {"lcd_yaw", "0"}; -cvar_t scr_ofsx = {"scr_ofsx", "0", false}; -cvar_t scr_ofsy = {"scr_ofsy", "0", false}; -cvar_t scr_ofsz = {"scr_ofsz", "0", false}; +cvar_t scr_ofsx = {"scr_ofsx", "0"}; +cvar_t scr_ofsy = {"scr_ofsy", "0"}; +cvar_t scr_ofsz = {"scr_ofsz", "0"}; cvar_t cl_rollspeed = {"cl_rollspeed", "200"}; cvar_t cl_rollangle = {"cl_rollangle", "2.0"}; -cvar_t cl_bob = {"cl_bob","0.02", false}; -cvar_t cl_bobcycle = {"cl_bobcycle","0.6", false}; -cvar_t cl_bobup = {"cl_bobup","0.5", false}; +cvar_t cl_bob = {"cl_bob","0.02"}; +cvar_t cl_bobcycle = {"cl_bobcycle","0.6"}; +cvar_t cl_bobup = {"cl_bobup","0.5"}; -cvar_t v_kicktime = {"v_kicktime", "0.5", false}; -cvar_t v_kickroll = {"v_kickroll", "0.6", false}; -cvar_t v_kickpitch = {"v_kickpitch", "0.6", false}; +cvar_t v_kicktime = {"v_kicktime", "0.5"}; +cvar_t v_kickroll = {"v_kickroll", "0.6"}; +cvar_t v_kickpitch = {"v_kickpitch", "0.6"}; -cvar_t v_iyaw_cycle = {"v_iyaw_cycle", "2", false}; -cvar_t v_iroll_cycle = {"v_iroll_cycle", "0.5", false}; -cvar_t v_ipitch_cycle = {"v_ipitch_cycle", "1", false}; -cvar_t v_iyaw_level = {"v_iyaw_level", "0.3", false}; -cvar_t v_iroll_level = {"v_iroll_level", "0.1", false}; -cvar_t v_ipitch_level = {"v_ipitch_level", "0.3", false}; +cvar_t v_iyaw_cycle = {"v_iyaw_cycle", "2"}; +cvar_t v_iroll_cycle = {"v_iroll_cycle", "0.5"}; +cvar_t v_ipitch_cycle = {"v_ipitch_cycle", "1"}; +cvar_t v_iyaw_level = {"v_iyaw_level", "0.3"}; +cvar_t v_iroll_level = {"v_iroll_level", "0.1"}; +cvar_t v_ipitch_level = {"v_ipitch_level", "0.3"}; -cvar_t v_idlescale = {"v_idlescale", "0", false}; +cvar_t v_idlescale = {"v_idlescale", "0"}; -cvar_t crosshair = {"crosshair", "0", true}; -cvar_t crosshaircolor = {"crosshaircolor", "79", true}; +cvar_t crosshair = {"crosshair", "0", CVAR_ARCHIVE}; +cvar_t crosshaircolor = {"crosshaircolor", "79",CVAR_ARCHIVE}; -cvar_t cl_crossx = {"cl_crossx", "0", true}; -cvar_t cl_crossy = {"cl_crossy", "0", true}; +cvar_t cl_crossx = {"cl_crossx", "0",CVAR_ARCHIVE}; +cvar_t cl_crossy = {"cl_crossy", "0", CVAR_ARCHIVE}; -cvar_t gl_cshiftpercent = {"gl_cshiftpercent", "100", false}; +cvar_t gl_cshiftpercent = {"gl_cshiftpercent", "100"}; float v_dmg_time, v_dmg_roll, v_dmg_pitch; @@ -144,7 +144,7 @@ float V_CalcBob (void) //============================================================================= -cvar_t v_centermove = {"v_centermove", "0.15", false}; +cvar_t v_centermove = {"v_centermove", "0.15"}; cvar_t v_centerspeed = {"v_centerspeed","500"}; @@ -261,7 +261,7 @@ cshift_t cshift_water = { {130,80,50}, 128 }; cshift_t cshift_slime = { {0,25,5}, 150 }; cshift_t cshift_lava = { {255,80,0}, 150 }; -cvar_t v_gamma = {"gamma", "1", true}; +cvar_t v_gamma = {"gamma", "1", CVAR_ARCHIVE}; byte gammatable[256]; // palette is sent through this