From 1e342a5d58bf67d988f510dc63d3089f9fa8b25b Mon Sep 17 00:00:00 2001 From: Wlowscha <54003515+Wlowscha@users.noreply.github.com> Date: Mon, 12 May 2025 22:55:44 +0200 Subject: [PATCH] Making logic for return button more expressive --- src/ui/party-ui-handler.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/ui/party-ui-handler.ts b/src/ui/party-ui-handler.ts index 90c0a074f11..d15688495c6 100644 --- a/src/ui/party-ui-handler.ts +++ b/src/ui/party-ui-handler.ts @@ -774,10 +774,14 @@ export default class PartyUiHandler extends MessageUiHandler { } this.showOptions(); ui.playSelect(); - } else if (this.partyUiMode === PartyUiMode.FAINT_SWITCH || this.partyUiMode === PartyUiMode.REVIVAL_BLESSING) { - ui.playError(); - } else { - return this.processInput(Button.CANCEL); + } + // Pressing return button + if (this.cursor === 6) { + if (this.partyUiMode === PartyUiMode.FAINT_SWITCH || this.partyUiMode === PartyUiMode.REVIVAL_BLESSING) { + ui.playError(); + } else { + return this.processInput(Button.CANCEL); + } } return true; }