diff --git a/src/battle-scene.ts b/src/battle-scene.ts index bed13b3f6..8684f86b3 100644 --- a/src/battle-scene.ts +++ b/src/battle-scene.ts @@ -1202,6 +1202,7 @@ export default class BattleScene extends Phaser.Scene { case Mode.FIGHT: case Mode.BALL: case Mode.TARGET_SELECT: + case Mode.SAVE_SLOT: case Mode.PARTY: case Mode.SUMMARY: case Mode.BIOME_SELECT: diff --git a/src/ui/menu-ui-handler.ts b/src/ui/menu-ui-handler.ts index 850505ac1..e88db0914 100644 --- a/src/ui/menu-ui-handler.ts +++ b/src/ui/menu-ui-handler.ts @@ -108,7 +108,7 @@ export default class MenuUiHandler extends MessageUiHandler { }]), xOffset: 98 }; - ui.setOverlayMode(Mode.OPTION_SELECT, config); + ui.setOverlayMode(Mode.MENU_OPTION_SELECT, config); }); }; @@ -247,11 +247,11 @@ export default class MenuUiHandler extends MessageUiHandler { success = true; break; case MenuOptions.MANAGE_DATA: - ui.setOverlayMode(Mode.OPTION_SELECT, this.manageDataConfig); + ui.setOverlayMode(Mode.MENU_OPTION_SELECT, this.manageDataConfig); success = true; break; case MenuOptions.COMMUNITY: - ui.setOverlayMode(Mode.OPTION_SELECT, this.communityConfig); + ui.setOverlayMode(Mode.MENU_OPTION_SELECT, this.communityConfig); success = true; break; case MenuOptions.LOG_OUT: diff --git a/src/ui/option-select-ui-handler.ts b/src/ui/option-select-ui-handler.ts index fea7784f9..824fa1535 100644 --- a/src/ui/option-select-ui-handler.ts +++ b/src/ui/option-select-ui-handler.ts @@ -3,8 +3,8 @@ import AbstractOptionSelectUiHandler from "./abstact-option-select-ui-handler"; import { Mode } from "./ui"; export default class OptionSelectUiHandler extends AbstractOptionSelectUiHandler { - constructor(scene: BattleScene) { - super(scene, Mode.OPTION_SELECT); + constructor(scene: BattleScene, mode: Mode = Mode.OPTION_SELECT) { + super(scene, mode); } getWindowWidth(): integer { diff --git a/src/ui/save-slot-select-ui-handler.ts b/src/ui/save-slot-select-ui-handler.ts index 565ad0b86..8d96d1fb8 100644 --- a/src/ui/save-slot-select-ui-handler.ts +++ b/src/ui/save-slot-select-ui-handler.ts @@ -112,7 +112,7 @@ export default class SaveSlotSelectUiHandler extends MessageUiHandler { ui.setOverlayMode(Mode.CONFIRM, () => saveAndCallback(), () => { ui.revertMode(); ui.showText(null, 0); - }); + }, false, 0, 19); }); } else saveAndCallback(); diff --git a/src/ui/ui.ts b/src/ui/ui.ts index e483ad19b..c3391cc2f 100644 --- a/src/ui/ui.ts +++ b/src/ui/ui.ts @@ -49,6 +49,7 @@ export enum Mode { CONFIRM, OPTION_SELECT, MENU, + MENU_OPTION_SELECT, SETTINGS, ACHIEVEMENTS, GAME_STATS, @@ -75,6 +76,7 @@ const noTransitionModes = [ Mode.CONFIRM, Mode.OPTION_SELECT, Mode.MENU, + Mode.MENU_OPTION_SELECT, Mode.SETTINGS, Mode.ACHIEVEMENTS, Mode.GAME_STATS, @@ -120,6 +122,7 @@ export default class UI extends Phaser.GameObjects.Container { new ConfirmUiHandler(scene), new OptionSelectUiHandler(scene), new MenuUiHandler(scene), + new OptionSelectUiHandler(scene, Mode.MENU_OPTION_SELECT), new SettingsUiHandler(scene), new AchvsUiHandler(scene), new GameStatsUiHandler(scene),