]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/scores.qc
Fix a mistake that potentially causes jump sounds where they shouldn't be
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / scores.qc
index 2eca07bc94843d8e8a9c75bebe3067e9e2febe62..03f3dbba37208d2eed5c5c8cc26fd18e628d3f49 100644 (file)
@@ -533,21 +533,20 @@ void WinningConditionHelper()
                if(fullstatus)
                {
                        s = GetPlayerScoreString(p, 1);
-                       if(IS_REAL_CLIENT(p))
-                               s = strcat(s, ":human");
-                       else
-                               s = strcat(s, ":bot");
+                       s = strcat(s, IS_REAL_CLIENT(p) ? ":human" : ":bot");
+                       ret_string = string_null;
                        if(!IS_PLAYER(p) && !MUTATOR_CALLHOOK(GetPlayerStatus, p, s))
                                s = strcat(s, ":spectator");
-                       s = strcat(s, ret_string);
+                       if (ret_string) s = strcat(s, ret_string);
                }
                else
                {
-                       if(IS_PLAYER(p) || MUTATOR_CALLHOOK(GetPlayerStatus, p, s))
+                       ret_string = string_null;
+                       if (IS_PLAYER(p) || MUTATOR_CALLHOOK(GetPlayerStatus, p, s))
                                s = GetPlayerScoreString(p, 2);
                        else
                                s = "-666";
-                       s = strcat(s, ret_string);
+                       if (ret_string) s = strcat(s, ret_string);
                }
 
                if(p.clientstatus)