]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - host.c
commented out bit-hacking 1/sqrt code
[xonotic/darkplaces.git] / host.c
diff --git a/host.c b/host.c
index 5d570becb6c0d0231bcef2af9ae83a7354405a44..c0741a68b7e001c69f474e6d7e0a954355ba591d 100644 (file)
--- a/host.c
+++ b/host.c
@@ -34,8 +34,6 @@ Memory is cleared / released when a server or client begins, not when they end.
 
 */
 
-quakeparms_t host_parms;
-
 qboolean       host_initialized;               // true if into command execution
 qboolean       host_loopactive = false;        // LordHavoc: used to turn Host_Error into Sys_Error if starting up or shutting down
 qboolean       host_shuttingdown = false;      // LordHavoc: set when quit is executed
@@ -58,6 +56,8 @@ cvar_t        slowmo = {0, "slowmo", "1.0"};                                  // LordHavoc: framerate independent sl
 cvar_t host_minfps = {CVAR_SAVE, "host_minfps", "10"};         // LordHavoc: game logic lower cap on framerate (if framerate is below this is, it pretends it is this, so game logic will run normally)
 cvar_t host_maxfps = {CVAR_SAVE, "host_maxfps", "1000"};               // LordHavoc: framerate upper cap
 
+cvar_t sv_echobprint = {CVAR_SAVE, "sv_echobprint", "1"};      // print broadcast messages in dedicated mode
+
 cvar_t sys_ticrate = {CVAR_SAVE, "sys_ticrate","0.05"};
 cvar_t serverprofile = {0, "serverprofile","0"};
 
@@ -241,6 +241,8 @@ void Host_InitLocal (void)
        Cvar_RegisterVariable (&host_minfps);
        Cvar_RegisterVariable (&host_maxfps);
 
+       Cvar_RegisterVariable (&sv_echobprint);
+
        Cvar_RegisterVariable (&sys_ticrate);
        Cvar_RegisterVariable (&serverprofile);
 
@@ -341,6 +343,9 @@ void SV_BroadcastPrintf (char *fmt, ...)
                        MSG_WriteByte (&svs.clients[i].message, svc_print);
                        MSG_WriteString (&svs.clients[i].message, string);
                }
+
+       if (sv_echobprint.integer && cls.state == ca_dedicated)
+               Sys_Printf ("%s", string);
 }
 
 /*
@@ -807,8 +812,6 @@ void Host_Init (void)
        // LordHavoc: quake never seeded the random number generator before... heh
        srand(time(NULL));
 
-       com_argc = host_parms.argc;
-       com_argv = host_parms.argv;
        // FIXME: this is evil, but possibly temporary
        if (COM_CheckParm("-developer"))
        {