Instantly update stats when players leave

This commit is contained in:
AJ Martinez 2023-04-01 23:15:57 -07:00 committed by toaster
parent 134a5ef9c0
commit d89d06be31
2 changed files with 2 additions and 5 deletions

View file

@ -639,7 +639,8 @@ void K_PlayerForfeit(UINT8 playerNum, boolean pointLoss)
if (pointLoss) if (pointLoss)
{ {
CONS_Printf("Stats update by %d\n", inc); clientpowerlevels[playerNum][powerType] += clientPowerAdd[playerNum];
clientPowerAdd[playerNum] = 0;
SV_UpdateStats(); SV_UpdateStats();
} }
} }

View file

@ -141,8 +141,6 @@ void SV_UpdateStats(void)
if (!server) if (!server)
return; return;
CONS_Printf("SV_UpdateStats\n");
for(i = 0; i < MAXPLAYERS; i++) for(i = 0; i < MAXPLAYERS; i++)
{ {
if (!playeringame[i]) if (!playeringame[i])
@ -153,8 +151,6 @@ void SV_UpdateStats(void)
continue; continue;
} }
CONS_Printf("updating %d\n", i);
boolean match = false; boolean match = false;
for(j = 0; j < numtracked; j++) for(j = 0; j < numtracked; j++)
{ {