From d55cbbe6136702ed184ae1a7bf099e2b28130220 Mon Sep 17 00:00:00 2001 From: terencehill Date: Sun, 8 Jan 2012 22:14:11 +0100 Subject: [PATCH] First round in CA: detect when the first player joins the game and try to start the countdown. It fixes bots never joining the game if added right at map start (bot_number already set when starting the server). --- qcsrc/server/arena.qc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/qcsrc/server/arena.qc b/qcsrc/server/arena.qc index f66ddb2cef..31698e9229 100644 --- a/qcsrc/server/arena.qc +++ b/qcsrc/server/arena.qc @@ -210,10 +210,10 @@ void Arena_Warmup() f = ceil(warmup - time); - allowed_to_spawn = 0; - if(inWarmupStage) allowed_to_spawn = 1; + else if(!g_ca) + allowed_to_spawn = 0; if(time < warmup && !inWarmupStage) { @@ -379,6 +379,12 @@ void count_alive_players() */ void Spawnqueue_Check() { + if(warmup == 0 && g_ca) + { + if(red_players || blue_players) + reset_map(TRUE); + return; + } if(time < warmup + 1 || inWarmupStage || intermission_running) return; -- 2.39.2