From 9dc317a26b52d80ee3817a44f1265adbfe876532 Mon Sep 17 00:00:00 2001 From: Stefan Murawski Date: Wed, 11 Nov 2020 10:35:13 +0100 Subject: [PATCH] Possible workaround for roundbreaking bug. It seems that the game breaks when a person joins while the czar is trying to select a winner. This should possibly block the ability to join during this time. This is completely untested and mostly speculated from observation of the behaviour in-game and this code. --- client/game.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/game.js b/client/game.js index 345b03f..16a55e0 100755 --- a/client/game.js +++ b/client/game.js @@ -872,6 +872,7 @@ var lockIds = null; function cardSelectionComplete(selections) { gameState = 'czarSelectionPending'; + joinBlocked = True; // put responses in some random order var displayList = []; @@ -1053,6 +1054,7 @@ var lockIds = null; function winnerSelection(playerId) { gameState = 'roundFinished'; + joinBlocked = False; // track winner event if(czarId === playerInfo.id && submissionMap[playerId].length > 0)