Fixed bug am40911 (round kill stats persisting for spectators)

This commit is contained in:
David Anderson 2006-09-25 23:04:33 +00:00
parent 647d226764
commit 44617778c7

View File

@ -1420,7 +1420,15 @@ kill_stats(id)
// Bail out if user stats timer is non-zero, // Bail out if user stats timer is non-zero,
// ie function already called. // ie function already called.
if (g_fzShowUserStatsTime[id] > 0.0) if (g_fzShowUserStatsTime[id] > 0.0)
{
return return
}
new team = get_user_team(id)
if (team < 1 || team > 2)
{
return
}
// Flag kill stats displayed for this player. // Flag kill stats displayed for this player.
g_fzShowUserStatsTime[id] = get_gametime() g_fzShowUserStatsTime[id] = get_gametime()
@ -1546,8 +1554,10 @@ endround_stats()
id = iaPlayers[iPlayer] id = iaPlayers[iPlayer]
if (g_fzShowUserStatsTime[id] == 0.0) if (g_fzShowUserStatsTime[id] == 0.0)
{
kill_stats(id) kill_stats(id)
} }
}
g_sAwardAndScore[0] = 0 g_sAwardAndScore[0] = 0