diff --git a/src/menu/pause_menu.rs b/src/menu/pause_menu.rs index 131c9ce..1884931 100644 --- a/src/menu/pause_menu.rs +++ b/src/menu/pause_menu.rs @@ -94,7 +94,12 @@ impl PauseMenu { self.controller.update(state, ctx)?; self.controller.update_trigger(); + // Shortcut for quick restart if ctx.keyboard_context.is_key_pressed(ScanCode::F2) { + state.sound_manager.stop_sfx(40); + state.sound_manager.stop_sfx(41); + state.sound_manager.stop_sfx(58); + state.sound_manager.play_song(0, &state.constants, &state.settings, ctx)?; state.load_or_start_game(ctx)?; } @@ -108,6 +113,10 @@ impl PauseMenu { } } MenuSelectionResult::Selected(1, _) => { + state.sound_manager.stop_sfx(40); + state.sound_manager.stop_sfx(41); + state.sound_manager.stop_sfx(58); + state.sound_manager.play_song(0, &state.constants, &state.settings, ctx)?; state.load_or_start_game(ctx)?; } MenuSelectionResult::Selected(2, _) => { diff --git a/src/scene/game_scene.rs b/src/scene/game_scene.rs index 98003ea..967d251 100644 --- a/src/scene/game_scene.rs +++ b/src/scene/game_scene.rs @@ -1748,7 +1748,7 @@ impl Scene for GameScene { self.tilemap.set_prev()?; self.inventory_dim += 0.1 - * if state.textscript_vm.mode == ScriptMode::Inventory { + * if state.textscript_vm.mode == ScriptMode::Inventory || self.pause_menu.is_paused() { state.frame_time as f32 } else { -(state.frame_time as f32)