]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fixed warning when manually changing teams for the first time.
authorLyberta <lyberta@lyberta.net>
Thu, 26 Jul 2018 14:18:11 +0000 (17:18 +0300)
committerLyberta <lyberta@lyberta.net>
Thu, 26 Jul 2018 14:18:11 +0000 (17:18 +0300)
qcsrc/server/teamplay.qc

index d19ae95be8236d3a4fd81a33318bc755c3cb01d6..2c41ae18bdfc77b22113f5f36f40df8cb5d7ba23 100644 (file)
@@ -958,5 +958,9 @@ void SV_ChangeTeam(entity this, float _color)
        {
                return;
        }
+       if (source_team_index == -1)
+       {
+               return;
+       }
        TeamBalance_AutoBalanceBots(destination_team_index, source_team_index);
 }