]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make sure g_team_entities don't spawn twice
authorterencehill <piuntn@gmail.com>
Fri, 2 Aug 2019 13:02:10 +0000 (15:02 +0200)
committerterencehill <piuntn@gmail.com>
Fri, 2 Aug 2019 13:02:10 +0000 (15:02 +0200)
qcsrc/server/teamplay.qc

index 2839817657262724b38ea8d086b53052fd1ca79a..81c97fcab9315e04e45117a6816902a516740416 100644 (file)
@@ -48,6 +48,8 @@ entity g_team_entities[NUM_TEAMS]; ///< Holds global team entities.
 
 void Team_InitTeams()
 {
+       if (g_team_entities[0])
+               return;
        for (int i = 0; i < NUM_TEAMS; ++i)
        {
                g_team_entities[i] = spawn();