mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2024-12-04 04:33:24 +00:00
Fix an issue where returning to Freeplay from gameplay would let you interact with the menu underneath
This commit is contained in:
parent
dae7d71b17
commit
e7a09fcee2
|
@ -946,16 +946,16 @@ class FreeplayState extends MusicBeatSubState
|
||||||
caps.doJumpOut = true;
|
caps.doJumpOut = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Type.getClass(FlxG.state) == MainMenuState)
|
if (Type.getClass(_parentState) == MainMenuState)
|
||||||
{
|
{
|
||||||
FlxG.state.persistentUpdate = false;
|
_parentState.persistentUpdate = false;
|
||||||
FlxG.state.persistentDraw = true;
|
_parentState.persistentDraw = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
new FlxTimer().start(longestTimer, (_) -> {
|
new FlxTimer().start(longestTimer, (_) -> {
|
||||||
FlxTransitionableState.skipNextTransIn = true;
|
FlxTransitionableState.skipNextTransIn = true;
|
||||||
FlxTransitionableState.skipNextTransOut = true;
|
FlxTransitionableState.skipNextTransOut = true;
|
||||||
if (Type.getClass(FlxG.state) == MainMenuState)
|
if (Type.getClass(_parentState) == MainMenuState)
|
||||||
{
|
{
|
||||||
FunkinSound.playMusic('freakyMenu',
|
FunkinSound.playMusic('freakyMenu',
|
||||||
{
|
{
|
||||||
|
|
|
@ -54,8 +54,9 @@ class MainMenuState extends MusicBeatState
|
||||||
|
|
||||||
playMenuMusic();
|
playMenuMusic();
|
||||||
|
|
||||||
persistentUpdate = true;
|
// If something else overrides these, we should keep those values.
|
||||||
persistentDraw = true;
|
// persistentUpdate = true;
|
||||||
|
// persistentDraw = true;
|
||||||
|
|
||||||
var bg:FlxSprite = new FlxSprite(Paths.image('menuBG'));
|
var bg:FlxSprite = new FlxSprite(Paths.image('menuBG'));
|
||||||
bg.scrollFactor.x = 0;
|
bg.scrollFactor.x = 0;
|
||||||
|
|
Loading…
Reference in a new issue