diff --git a/server/Game.js b/server/Game.js index 1e567ae..0ab527d 100644 --- a/server/Game.js +++ b/server/Game.js @@ -78,11 +78,10 @@ async function createGame(gameId, targetTiles, image, ts, scoreMode) { function addPlayer(gameId, playerId, ts) { const idx = GameCommon.getPlayerIndexById(gameId, playerId) + const diff = ts - GameCommon.getStartTs(gameId) if (idx === -1) { - const diff = ts - GameCommon.getStartTs(gameId) GameLog.log(gameId, Protocol.LOG_ADD_PLAYER, playerId, diff) } else { - const diff = ts - GameCommon.getStartTs(gameId) GameLog.log(gameId, Protocol.LOG_UPDATE_PLAYER, idx, diff) }