]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/playerstats.qc
Fix moving turrets failing target check due to non updated tur_shotorg (use origin...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / playerstats.qc
index 43c8d8d8971c6b0ba657e0088f26b6d91674677f..d74cb0f38bb14edda35a797cc094d041524fc7d8 100644 (file)
@@ -344,11 +344,21 @@ void PlayerStats_AddGlobalInfo(entity p)
 void PlayerStats_EndMatch(float finished)
 {
        entity p, winner;
-    winner = PlayerScore_Sort(score_dummyfield);
-       FOR_EACH_PLAYER(p) // spectators intentionally not included
+       winner = PlayerScore_Sort(score_dummyfield);
+       FOR_EACH_CLIENT(p) // spectators intentionally not included
        {
-               PlayerScore_PlayerStats(p);
                PlayerStats_Accuracy(p);
+               if(g_arena || g_lms || g_ca)
+               {
+                       if(p.alivetime <= 0)
+                               continue;
+               }
+               else
+               {
+                       if(p.classname != "player")
+                               continue;
+               }
+               PlayerScore_PlayerStats(p);
                PlayerStats_Event(p, PLAYERSTATS_SCOREBOARD_VALID, 1);
                if(finished)
                {