]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - host.c
updated MSVC and mingw files to compile filematch.c
[xonotic/darkplaces.git] / host.c
diff --git a/host.c b/host.c
index 0f8987ec641140657e893bcff085491363a40fe0..7ff8874339cd0acf42e1bd8ae8303041447354c0 100644 (file)
--- a/host.c
+++ b/host.c
@@ -8,7 +8,7 @@ of the License, or (at your option) any later version.
 
 This program is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 See the GNU General Public License for more details.
 
@@ -20,6 +20,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 // host.c -- coordinates spawning and killing of local servers
 
 #include "quakedef.h"
+#include <time.h>
 
 /*
 
@@ -142,7 +143,7 @@ void Host_Error (char *error, ...)
        }
        inerror = true;
        
-//     SCR_EndLoadingPlaque ();                // reenable screen updates
+       SCR_EndLoadingPlaque ();                // reenable screen updates
 
        va_start (argptr,error);
        vsprintf (hosterrorstring,error,argptr);
@@ -200,6 +201,11 @@ void       Host_FindMaxClients (void)
                else
                        svs.maxclients = 8;
        }
+
+       // BloodBath doesn't support single player games
+       if (gamemode == GAME_BLOODBATH && svs.maxclients < 4)
+               svs.maxclients = 4;
+
        if (svs.maxclients < 1)
                svs.maxclients = 8;
        else if (svs.maxclients > MAX_SCOREBOARD)
@@ -786,6 +792,9 @@ Host_Init
 */
 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
@@ -868,7 +877,7 @@ void Host_Shutdown(void)
        isdown = true;
 
 // keep Con_Printf from trying to update the screen
-       scr_disabled_for_loading = true;
+//     scr_disabled_for_loading = true;
 
        Host_WriteConfiguration ();