From 87d1fa13e39de5390d24db3a24bbb3c0fa555621 Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 30 Aug 2015 21:47:56 +1000 Subject: [PATCH] Don't use TDM team entities with no cnt set (supposedly fixes breakage on some maps) --- qcsrc/server/mutators/gamemode_tdm.qc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qcsrc/server/mutators/gamemode_tdm.qc b/qcsrc/server/mutators/gamemode_tdm.qc index ad3a15b5f..fda2161a6 100644 --- a/qcsrc/server/mutators/gamemode_tdm.qc +++ b/qcsrc/server/mutators/gamemode_tdm.qc @@ -10,7 +10,7 @@ Keys: "cnt" Scoreboard color of the team (for example 4 is red and 13 is blue)... */ void spawnfunc_tdm_team() { - if(!g_tdm) { remove(self); return; } + if(!g_tdm || !self.cnt) { remove(self); return; } self.classname = "tdm_team"; self.team = self.cnt + 1; @@ -38,7 +38,7 @@ void tdm_DelayedInit() { LOG_INFO("No ""tdm_team"" entities found on this map, creating them anyway.\n"); - float numteams = min(4, autocvar_g_tdm_teams_override); + int numteams = min(4, autocvar_g_tdm_teams_override); if(numteams < 2) { numteams = autocvar_g_tdm_teams; } numteams = bound(2, numteams, 4); -- 2.39.2