From a2c0d6c0d4a666b60fabfcb3672953bbd6c73b3b Mon Sep 17 00:00:00 2001 From: Jack <66967891+ASpoonPlaysGames@users.noreply.github.com> Date: Mon, 18 Sep 2023 20:02:03 +0100 Subject: Use `WinnerDetermined` instead of `Epilogue` to grant stats (#713) Use `WinnerDetermined` instead of `Epilogue` to grant stats as some modes (like LTS) don't go into `eGameState.Epilogue` apparently. `eGameState.WinnerDetermined` should be better --- Northstar.CustomServers/mod/scripts/vscripts/mp/_stats.nut | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Northstar.CustomServers/mod') diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/_stats.nut b/Northstar.CustomServers/mod/scripts/vscripts/mp/_stats.nut index 92c0f401..010184ff 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/mp/_stats.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/_stats.nut @@ -36,7 +36,7 @@ void function Stats_Init() AddCallback_OnPlayerRespawned( OnPlayerRespawned ) AddCallback_OnClientConnected( OnClientConnected ) AddCallback_OnClientDisconnected( OnClientDisconnected ) - AddCallback_GameStateEnter( eGameState.Epilogue, OnEpilogueStarted ) + AddCallback_GameStateEnter( eGameState.WinnerDetermined, OnWinnerDetermined ) thread HandleDistanceAndTimeStats_Threaded() thread SaveStatsPeriodically_Threaded() @@ -798,7 +798,7 @@ void function OnPlayerRespawned( entity player ) thread SetLastPosForDistanceStatValid_Threaded( player, true ) } -void function OnEpilogueStarted() +void function OnWinnerDetermined() { // award players for match completed, wins, and losses foreach ( entity player in GetPlayerArray() ) -- cgit v1.2.3