mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-02-19 22:33:34 +00:00
Score Restore Exception 2
If a player leaves and their score is 0. Their score will not be save to be restored later.
This commit is contained in:
parent
e61aa959a4
commit
b38b29b871
1 changed files with 7 additions and 5 deletions
|
|
@ -2388,11 +2388,8 @@ function dtStatsMissionDropReady(%game, %client){ // called when client has fini
|
|||
%dtStats.clientLeft = 0;
|
||||
%dtStats.markForDelete = 0;
|
||||
%foundOld =1;
|
||||
if(%dtStats.score !$= 0)
|
||||
{
|
||||
resGameStats(%client,%game.class); // restore stats;
|
||||
messageClient(%client, 'MsgClient', '\crWelcome back %1. Your score has been restored.~wfx/misc/rolechange.wav', %client.name);
|
||||
}
|
||||
resGameStats(%client,%game.class); // restore stats;
|
||||
messageClient(%client, 'MsgClient', '\crWelcome back %1. Your score has been restored.~wfx/misc/rolechange.wav', %client.name);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -2431,12 +2428,17 @@ function dtStatsMissionDropReady(%game, %client){ // called when client has fini
|
|||
|
||||
function dtStatsClientLeaveGame(%game, %client){
|
||||
if(!%client.isAiControlled()){
|
||||
if(%client.score == 0){
|
||||
%client.dtStats.delete();
|
||||
return;
|
||||
}
|
||||
%client.dtStats.clientLeft = 1;
|
||||
%game.gameWinStat(%client);
|
||||
bakGameStats(%client,%game.class);//back up there current game in case they lost connection
|
||||
%client.dtStats.leftPCT = %game.getGamePct();
|
||||
}
|
||||
}
|
||||
|
||||
function dtStatsTimeLimitReached(%game){
|
||||
%game.timeLimitHit = 1;
|
||||
if($dtStats::fullGames[%game.class]){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue