]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/playerstats.qc
Merge branch 'master' into divVerent/rank-change
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / playerstats.qc
index 4702a48e2b8d659bef86ef78402f05f526578445..1213fe83bf6407e5482d6c27438b36d6d46e6cce 100644 (file)
@@ -370,14 +370,14 @@ void PlayerStats_AddGlobalInfo(entity p)
 void PlayerStats_EndMatch(float finished)
 {
        entity p;
-       PlayerScore_Sort(score_dummyfield, 0, 0);
-       PlayerScore_Sort(scoreboard_pos, 1, 1);
-       FOR_EACH_CLIENT(p) // spectators intentionally not included
+       PlayerScore_Sort(score_dummyfield, 0, 0, 0);
+       PlayerScore_Sort(scoreboard_pos, 1, 1, 1);
+       FOR_EACH_CLIENT(p)
        {
                //PlayerStats_Accuracy(p); // stats are already written with PlayerStats_AddGlobalInfo(entity), don't double them up.
-               
-               if((g_arena || g_lms || g_ca) && (p.alivetime <= 0)) { continue; }
-               else if(p.classname != "player") { continue; }
+
+               if(p.frags == FRAGS_SPECTATOR)
+                       continue;
 
                if(clienttype(p) == CLIENTTYPE_REAL)
                {