r5457 - trunk/data/qcsrc/server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Thu Jan 8 15:14:25 EST 2009


Author: div0
Date: 2009-01-08 15:14:24 -0500 (Thu, 08 Jan 2009)
New Revision: 5457

Modified:
   trunk/data/qcsrc/server/keyhunt.qc
Log:
keyhunt: don't assign keys while waiting for game start


Modified: trunk/data/qcsrc/server/keyhunt.qc
===================================================================
--- trunk/data/qcsrc/server/keyhunt.qc	2009-01-08 19:03:10 UTC (rev 5456)
+++ trunk/data/qcsrc/server/keyhunt.qc	2009-01-08 20:14:24 UTC (rev 5457)
@@ -820,6 +820,13 @@
 void kh_WaitForPlayers()  // delay start of the round until enough players are present
 {
 	string teams_missing;
+
+	if(time < game_starttime)
+	{
+		kh_Controller_SetThink(game_starttime - time + 0.1, "", kh_WaitForPlayers);
+		return;
+	}
+
 	teams_missing = kh_CheckEnoughPlayers();
 	if(teams_missing == "")
 		kh_Controller_SetThink(cvar("g_balance_keyhunt_delay_round"), "Round starts in ", kh_StartRound);
@@ -833,6 +840,12 @@
 	float i, players, teem;
 	entity player;
 
+	if(time < game_starttime)
+	{
+		kh_Controller_SetThink(game_starttime - time + 0.1, "", kh_WaitForPlayers);
+		return;
+	}
+
 	teams_missing = kh_CheckEnoughPlayers();
 	if(teams_missing != "")
 	{




More information about the nexuiz-commits mailing list