diff --git a/pages/live/lobby.js b/pages/live/lobby.js index 6c68f17..450ef37 100644 --- a/pages/live/lobby.js +++ b/pages/live/lobby.js @@ -201,21 +201,23 @@ async function lobbyEventHandler (event) { // Handle game starting setTimeout(function () { + showPopup("Game starting", "Everyone is ready. The game will now start."); - }, 1000); - // Hide the popup after 5 seconds - const startPopupTimeout = setTimeout(function () { - hidePopup(); - }, 5000); - - // Prevent other popups getting hidden by this - const oldShowPopup = showPopup; - showPopup = function (title, text, type = POPUP_INFO, hasCancel = false) { - clearTimeout(startPopupTimeout); - showPopup = oldShowPopup; - showPopup(title, text, type, hasCancel); - }; + // Hide the popup after 5 seconds + const startPopupTimeout = setTimeout(function () { + hidePopup(); + }, 5000); + + // Prevent other popups getting hidden by this + const oldShowPopup = showPopup; + showPopup = function (title, text, type = POPUP_INFO, hasCancel = false) { + clearTimeout(startPopupTimeout); + showPopup = oldShowPopup; + showPopup(title, text, type, hasCancel); + }; + + }, 1000); return; }