From 070b9c7ad679c2e7e5e1e1b711c178c0b7c0be0f Mon Sep 17 00:00:00 2001 From: Dev Date: Mon, 24 Jul 2023 16:38:28 +0100 Subject: [PATCH] Send total in game time on game start --- project/src/controllers/GameController.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/project/src/controllers/GameController.ts b/project/src/controllers/GameController.ts index bf9c3aaa..cc43cbad 100644 --- a/project/src/controllers/GameController.ts +++ b/project/src/controllers/GameController.ts @@ -225,6 +225,8 @@ export class GameController */ public getGameConfig(sessionID: string): IGameConfigResponse { + const profile = this.profileHelper.getPmcProfile(sessionID); + const config: IGameConfigResponse = { languages: this.databaseServer.getTables().locales.languages, ndaFree: false, @@ -243,7 +245,7 @@ export class GameController }, // eslint-disable-next-line @typescript-eslint/naming-convention utc_time: new Date().getTime() / 1000, - totalInGame: 1 + totalInGame: profile.Stats.TotalInGameTime }; return config;