[nexuiz-commits] r8328 - trunk/data/qcsrc/server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Sat Nov 28 05:41:07 EST 2009


Author: fruitiex
Date: 2009-11-28 05:41:07 -0500 (Sat, 28 Nov 2009)
New Revision: 8328

Modified:
   trunk/data/qcsrc/server/arena.qc
   trunk/data/qcsrc/server/cl_player.qc
   trunk/data/qcsrc/server/cl_weapons.qc
   trunk/data/qcsrc/server/clientcommands.qc
   trunk/data/qcsrc/server/miscfunctions.qc
Log:
add warmup support to clan arena


Modified: trunk/data/qcsrc/server/arena.qc
===================================================================
--- trunk/data/qcsrc/server/arena.qc	2009-11-28 10:26:56 UTC (rev 8327)
+++ trunk/data/qcsrc/server/arena.qc	2009-11-28 10:41:07 UTC (rev 8328)
@@ -198,11 +198,11 @@
 
 	allowed_to_spawn = 0;
 
-	if(g_ca && player_cnt < 2)
+	if(g_ca && (player_cnt < 2 || inWarmupStage))
 		allowed_to_spawn = 1;
 
 	msg = NEWLINES;
-	if(time < warmup)
+	if(time < warmup && !inWarmupStage)
 	{
 		if (g_ca)
 			allowed_to_spawn = 1;
@@ -261,7 +261,7 @@
  */
 void Spawnqueue_Check()
 {
-	if(time < warmup + 1)
+	if(time < warmup + 1 || inWarmupStage)
 		return;
 
 	if(g_ca) {

Modified: trunk/data/qcsrc/server/cl_player.qc
===================================================================
--- trunk/data/qcsrc/server/cl_player.qc	2009-11-28 10:26:56 UTC (rev 8327)
+++ trunk/data/qcsrc/server/cl_player.qc	2009-11-28 10:41:07 UTC (rev 8328)
@@ -475,7 +475,7 @@
 	else
 		Violence_GibSplash_At(hitloc, force, 2, bound(0, damage, 200) / 16, self, attacker);
 
-	if((g_arena && numspawned < 2) || (g_ca && player_cnt < 2))
+	if((g_arena && numspawned < 2) || (g_ca && player_cnt < 2) && !inWarmupStage)
 		return;
 
 	if (!g_minstagib)

Modified: trunk/data/qcsrc/server/cl_weapons.qc
===================================================================
--- trunk/data/qcsrc/server/cl_weapons.qc	2009-11-28 10:26:56 UTC (rev 8327)
+++ trunk/data/qcsrc/server/cl_weapons.qc	2009-11-28 10:41:07 UTC (rev 8328)
@@ -271,7 +271,7 @@
 		return;
 	if (g_nexball && w == WEP_GRENADE_LAUNCHER)
 		return;
-	if (!cvar("g_pickup_items"))
+	if (!cvar("g_pickup_items") || g_ca)
 		return;
 	if(!W_IsWeaponThrowable(w))
 		return;

Modified: trunk/data/qcsrc/server/clientcommands.qc
===================================================================
--- trunk/data/qcsrc/server/clientcommands.qc	2009-11-28 10:26:56 UTC (rev 8327)
+++ trunk/data/qcsrc/server/clientcommands.qc	2009-11-28 10:41:07 UTC (rev 8328)
@@ -776,7 +776,9 @@
 
 
 	readyrestart_happened = 1;
-	game_starttime = time + RESTART_COUNTDOWN;
+	game_starttime = time;
+	if(!g_ca)
+		game_starttime += RESTART_COUNTDOWN;
 	restart_mapalreadyrestarted = 0; //reset this var, needed when cvar sv_ready_restart_repeatable is in use
 
 	inWarmupStage = 0; //once the game is restarted the game is in match stage
@@ -818,8 +820,7 @@
 void ReadyRestart()
 {
 	// no arena, assault support yet...
-	// TODO: CA support
-	if(g_arena | g_ca | g_assault | gameover | intermission_running | race_completing)
+	if(g_arena | g_assault | gameover | intermission_running | race_completing)
 		localcmd("restart\n");
 	else
 		localcmd("\nsv_hook_gamerestart;");

Modified: trunk/data/qcsrc/server/miscfunctions.qc
===================================================================
--- trunk/data/qcsrc/server/miscfunctions.qc	2009-11-28 10:26:56 UTC (rev 8327)
+++ trunk/data/qcsrc/server/miscfunctions.qc	2009-11-28 10:41:07 UTC (rev 8328)
@@ -1036,7 +1036,7 @@
         warmup_start_armorvalue = start_armorvalue;
         warmup_start_weapons = start_weapons;
 
-        if (!g_weaponarena && !g_nixnex && !g_minstagib)
+        if (!g_weaponarena && !g_nixnex && !g_minstagib && !g_ca)
         {
             if (cvar("g_use_ammunition"))
             {
@@ -1262,7 +1262,7 @@
 	if(g_ghost_items >= 1)
 		g_ghost_items = 0.13; // default alpha value
 
-	if not(inWarmupStage)
+	if not(inWarmupStage && !g_ca)
 		game_starttime = cvar("g_start_delay");
 
 	sv_pitch_min = cvar("sv_pitch_min");



More information about the nexuiz-commits mailing list