From ad6141bde08ba3371df9d560c6b48924834bfda1 Mon Sep 17 00:00:00 2001 From: Sterling Archer Date: Wed, 27 May 2026 12:00:12 -0700 Subject: [PATCH] Catch result: show controller, hide continue button, auto-return to map after 3s --- game.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/game.js b/game.js index 782ef69..949e403 100644 --- a/game.js +++ b/game.js @@ -1328,10 +1328,12 @@ class Game { SFX.pokeball(); this.show('catch-result'); - this._showController(false); + this._showController(true); const resultEmoji = document.getElementById('catch-result-emoji'); const resultMsg = document.getElementById('catch-result-msg'); + const continueBtn = document.getElementById('btn-catch-continue'); + if (continueBtn) continueBtn.style.display = 'none'; if (canCatch) { setTimeout(() => SFX.catch(), 500); @@ -1358,10 +1360,12 @@ class Game { const wildWrap = document.getElementById('map-wild-wrap'); if (wildWrap) wildWrap.style.display = 'none'; - document.getElementById('btn-catch-continue').onclick = () => { - saveGame(this.state); - this.showMap(); - }; + setTimeout(() => { + if (this.state.screen === 'catch-result') { + saveGame(this.state); + this.showMap(); + } + }, 3000); } loadQuestions(cb) {