From 64e1bd768ee2f8a7d2e2427242c6ef4b3d6f7189 Mon Sep 17 00:00:00 2001 From: NeeEoo Date: Sun, 26 Mar 2023 18:42:31 +0200 Subject: [PATCH] Fixed warning --- source/funkin/menus/PauseSubState.hx | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/source/funkin/menus/PauseSubState.hx b/source/funkin/menus/PauseSubState.hx index 853c319a..e6ee4ce3 100644 --- a/source/funkin/menus/PauseSubState.hx +++ b/source/funkin/menus/PauseSubState.hx @@ -146,12 +146,13 @@ class PauseSubState extends MusicBeatSubstate FlxG.switchState(new OptionsMenu()); case "Exit to menu": FlxG.switchState(PlayState.isStoryMode ? new StoryMenuState() : new FreeplayState()); - CoolUtil.playMenuSong(); + CoolUtil.playMenuSong(); } } override function destroy() { - FlxG.cameras.remove(camera, true); + if(FlxG.cameras.list.contains(camera)) + FlxG.cameras.remove(camera, true); pauseScript.call("onDestroy"); if (pauseMusic != null) pauseMusic.destroy(); pauseScript.destroy(); @@ -175,14 +176,10 @@ class PauseSubState extends MusicBeatSubstate item.targetY = bullShit - curSelected; bullShit++; - item.alpha = 0.6; - // item.setGraphicSize(Std.int(item.width * 0.8)); - if (item.targetY == 0) - { item.alpha = 1; - // item.setGraphicSize(Std.int(item.width)); - } + else + item.alpha = 0.6; } } }