From 727304996a6c20e19a3d510c7a6670328e1b9ed6 Mon Sep 17 00:00:00 2001 From: jwinterm Date: Wed, 18 Feb 2026 20:57:01 -0500 Subject: [PATCH] fix live game list and swap animations --- html/js/display/waitingScreenAnimator.js | 4 ++-- src/network/spectatorManager.js | 5 +---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/html/js/display/waitingScreenAnimator.js b/html/js/display/waitingScreenAnimator.js index 5e80407..29de6a4 100644 --- a/html/js/display/waitingScreenAnimator.js +++ b/html/js/display/waitingScreenAnimator.js @@ -92,8 +92,8 @@ var WaitingScreenAnimator = { // Check if we're in "Awaiting payment" mode - use treasure hunt animation const isAwaitingPayment = typeof Game !== 'undefined' && Game._awaitingPayment; - if (isAwaitingPayment) { - // Use the treasure hunt animation for payment waiting + if (!isAwaitingPayment) { + // Use the treasure hunt animation for queue waiting (the longer wait) this.drawPaymentAnimation(screenWidth, screenHeight, drawCenteredTextFn); return; } diff --git a/src/network/spectatorManager.js b/src/network/spectatorManager.js index 32f2d73..13899e0 100644 --- a/src/network/spectatorManager.js +++ b/src/network/spectatorManager.js @@ -396,10 +396,7 @@ class SpectatorManager { // Add pending games to the response gameListData.pendingGames = pendingGames; - // Only broadcast if there are active or pending games - if (gameListData.pagination.totalGames === 0 && pendingGames.length === 0) return; - - // Broadcast to a "lobby" room - users join this room when not in game + // Always broadcast, even when empty — clients need to clear their lists this.io.to('lobby').emit('active_games', gameListData); }