Fixed controls crash
This commit is contained in:
+5
-1
@@ -5,6 +5,10 @@ echo Commiting with the message %1...
|
||||
echo ==============================
|
||||
git commit -a -m %1
|
||||
echo ==============================
|
||||
echo Pushing...
|
||||
echo Pushing to dev repo...
|
||||
echo ==============================
|
||||
git push -u origin dev
|
||||
echo ==============================
|
||||
echo Pushing to public repo...
|
||||
echo ==============================
|
||||
git push -u origin main
|
||||
@@ -13,7 +13,9 @@ class FunkinSave {
|
||||
public static var highscores:Map<HighscoreEntry, SongScore> = [];
|
||||
|
||||
|
||||
// STUFF
|
||||
/**
|
||||
* ONLY OPEN IF YOU WANT TO EDIT FUNCTIONS RELATED TO SAVING, LOADING OR HIGHSCORES.
|
||||
*/
|
||||
#if REGION
|
||||
@:dox(hide) @:doNotSave
|
||||
private static var __eventAdded = false;
|
||||
|
||||
@@ -253,7 +253,8 @@ class MusicBeatSubstate extends FlxSubState implements IBeatReceiver
|
||||
if (subState != null && subState is MusicBeatSubstate) {
|
||||
cast(subState, MusicBeatSubstate).parent = this;
|
||||
super.resetSubState();
|
||||
cast(subState, MusicBeatSubstate).onSubstateOpen();
|
||||
if (subState != null)
|
||||
cast(subState, MusicBeatSubstate).onSubstateOpen();
|
||||
return;
|
||||
}
|
||||
super.resetSubState();
|
||||
|
||||
@@ -6,6 +6,8 @@ import funkin.utils.FunkinParentDisabler;
|
||||
|
||||
class MusicBeatTransition extends MusicBeatSubstate {
|
||||
var nextFrameSkip:Bool = false;
|
||||
|
||||
public var transitionTween:FlxTween = null;
|
||||
public var transitionCamera:FlxCamera;
|
||||
public var newState:FlxState;
|
||||
|
||||
@@ -45,7 +47,7 @@ class MusicBeatTransition extends MusicBeatSubstate {
|
||||
add(transitionSprite);
|
||||
|
||||
transitionCamera.scroll.y = transitionCamera.height;
|
||||
FlxTween.tween(transitionCamera.scroll, {y: -transitionCamera.height}, 2/3, {
|
||||
transitionTween = FlxTween.tween(transitionCamera.scroll, {y: -transitionCamera.height}, 2/3, {
|
||||
ease: FlxEase.sineOut,
|
||||
onComplete: function(_) {
|
||||
finish();
|
||||
@@ -79,6 +81,9 @@ class MusicBeatTransition extends MusicBeatSubstate {
|
||||
}
|
||||
|
||||
public override function destroy() {
|
||||
if (transitionTween != null)
|
||||
transitionTween.cancel();
|
||||
transitionTween = FlxDestroyUtil.destroy(transitionTween);
|
||||
if (newState == null && FlxG.cameras.list.contains(transitionCamera))
|
||||
FlxG.cameras.remove(transitionCamera);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user