diff --git a/engine/client/in_generic.c b/engine/client/in_generic.c index 53791945b..6034a9e06 100644 --- a/engine/client/in_generic.c +++ b/engine/client/in_generic.c @@ -304,13 +304,14 @@ void IN_DeviceIDs_f(void) float IN_DetermineMouseRate(void) { - float time = Sys_DoubleTime(); - static float timer; + double time = Sys_DoubleTime(); + static double timer; static float last; - if (fabs(time - timer) > 1) + float interval = time - timer; + if (fabs(interval) >= 1) { timer = time; - last = ptr[0].updates; + last = ptr[0].updates/interval; ptr[0].updates = 0; } return last; diff --git a/engine/client/sound.h b/engine/client/sound.h index b64de1693..150940d10 100644 --- a/engine/client/sound.h +++ b/engine/client/sound.h @@ -117,7 +117,6 @@ typedef struct //#define CF_SV_RESERVED CF_CL_ABSVOLUME #define CF_NOREVERB 32 // disables reverb on this channel, if possible. #define CF_FOLLOW 64 // follows the owning entity (stops moving if we lose track) -//#define CF_RESERVEDN 128 // reserved for things that should be networked. #define CF_NOREPLACE 128 // start sound event is ignored if there's already a sound playing on that entchannel (probably paired with CF_FORCELOOP). #define CF_SV_UNICAST 256 // serverside only. the sound is sent to msg_entity only. diff --git a/engine/common/cvar.c b/engine/common/cvar.c index 06df520a9..f2fca68ee 100644 --- a/engine/common/cvar.c +++ b/engine/common/cvar.c @@ -271,6 +271,7 @@ void Cvar_List_f (void) int listflags = 0, cvarflags = 0; int total = 0; char strtmp[512]; + char *col; static char *cvarlist_help = "cvarlist list all cvars matching given parameters\n" "Syntax: cvarlist [-FLdhlrv] [-f flag] [-g group] [cvar]\n" @@ -467,23 +468,32 @@ showhelp: // print cvar name if (!cmd->defaultstr || !strcmp(cmd->string, cmd->defaultstr)) - Con_Printf(S_COLOR_GREEN "%s", cmd->name); //cvar has default value, woo. + col = S_COLOR_GREEN; //cvar has default value, woo. else if (cmd->flags & CVAR_ARCHIVE) - Con_Printf(S_COLOR_RED "%s", cmd->name); //cvar will persist. oh noes. + col = S_COLOR_RED; //cvar will persist. oh noes. else - Con_Printf(S_COLOR_YELLOW "%s", cmd->name); //cvar is changed, but won't be saved to a config so w/e. + col = S_COLOR_YELLOW; //cvar is changed, but won't be saved to a config so w/e. + if (cmd->flags & CVAR_NOUNSAFEEXPAND) + Con_Printf("^[%s%s\\type\\%s\\tip\\"S_COLOR_YELLOW"%s^]", col, cmd->name, cmd->name, cmd->description?cmd->description:""); //cvar is changed, but won't be saved to a config so w/e. + else + Con_Printf("^[%s%s\\type\\%s %s\\tip\\Default: %s\nCurrent: %s\n\n"S_COLOR_YELLOW"%s^]", col, cmd->name, cmd->name,cmd->string, cmd->defaultstr,cmd->string, cmd->description?cmd->description:""); //cvar is changed, but won't be saved to a config so w/e. total++; // print current value - if (listflags & CLF_VALUES) + if (cmd->flags & CVAR_NOUNSAFEEXPAND) + ; + else { - if (*cmd->string) - Con_Printf(" %s", cmd->string); - } + if (listflags & CLF_VALUES) + { + if (*cmd->string) + Con_Printf(" %s", cmd->string); + } - // print default value - if (cmd->defaultstr && (listflags & CLF_DEFAULT)) - Con_Printf(", default \"%s\"", cmd->defaultstr); + // print default value + if (cmd->defaultstr && (listflags & CLF_DEFAULT)) + Con_Printf(", default \"%s\"", cmd->defaultstr); + } // print alternate name if ((listflags & CLF_ALTNAME) && cmd->name2) @@ -506,7 +516,9 @@ showhelp: // print latched value if (listflags & CLF_LATCHES) { - if (cmd->latched_string) + if (cmd->flags & CVAR_NOUNSAFEEXPAND) + ; + else if (cmd->latched_string) Con_Printf(", latched as \"%s\"", cmd->latched_string); } diff --git a/engine/server/sv_cluster.c b/engine/server/sv_cluster.c index 1d6d3d250..8f7459a89 100644 --- a/engine/server/sv_cluster.c +++ b/engine/server/sv_cluster.c @@ -491,9 +491,11 @@ void MSV_MapCluster_Setup(const char *landingmap, qboolean use_database, qboolea SV_WipeServerState(); //this is the new-player map. - Q_strncpyz(sv.modelname, landingmap, sizeof(sv.modelname)); - if (!*sv.modelname) - Q_strncpyz(sv.modelname, "start", sizeof(sv.modelname)); + Q_strncpyz(svs.name, landingmap, sizeof(svs.name)); + if (!*svs.name) + Q_strncpyz(svs.name, "start", sizeof(svs.name)); + + Q_strncpyz(sv.modelname, svs.name, sizeof(sv.modelname)); if (use_database) {