From 90c5802057cad59362f6e6a4254477bebf48b7af Mon Sep 17 00:00:00 2001 From: Ne_Eo Date: Sat, 14 Sep 2024 18:53:15 +0200 Subject: [PATCH 1/3] Fix rotation on flxanimate --- source/funkin/backend/FlxAnimate.hx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/funkin/backend/FlxAnimate.hx b/source/funkin/backend/FlxAnimate.hx index c6559dfd..9f49f9ff 100644 --- a/source/funkin/backend/FlxAnimate.hx +++ b/source/funkin/backend/FlxAnimate.hx @@ -18,7 +18,7 @@ class FlxAnimate extends flxanimate.FlxAnimate { for (camera in cameras) { rMatrix.identity(); - rMatrix.translate(-limb.offset.x, -limb.offset.y); + limb.prepareMatrix(rMatrix, FlxFrameAngle.ANGLE_0, _checkFlipX() != camera.flipX, _checkFlipY() != camera.flipY); rMatrix.concat(_rMatrix); if (!camera.visible || !camera.exists || !limbOnScreen(limb, _rMatrix, camera)) return; From 615206769c1781a046cc68b41f937cac1fe2e815 Mon Sep 17 00:00:00 2001 From: Ne_Eo Date: Sun, 15 Sep 2024 10:29:13 +0200 Subject: [PATCH 2/3] Small change :3 --- source/funkin/backend/FunkinSprite.hx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/funkin/backend/FunkinSprite.hx b/source/funkin/backend/FunkinSprite.hx index 21a35962..d18585ae 100644 --- a/source/funkin/backend/FunkinSprite.hx +++ b/source/funkin/backend/FunkinSprite.hx @@ -219,10 +219,12 @@ class FunkinSprite extends FlxSkewedSprite implements IBeatReceiver implements I animateAtlas.flipX = flipX; animateAtlas.flipY = flipY; animateAtlas.shader = shader; + animateAtlas.shaderEnabled = shaderEnabled; animateAtlas.antialiasing = antialiasing; animateAtlas.skew = skew; animateAtlas.transformMatrix = transformMatrix; animateAtlas.matrixExposed = matrixExposed; + animateAtlas.colorTransform = colorTransform; } } From d8005a316648e0d219110c000cf1c124c0e0c786 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=8D=9A=7ENex?= <87421482+NexIsDumb@users.noreply.github.com> Date: Mon, 16 Sep 2024 00:06:04 +0200 Subject: [PATCH 3/3] fixing notes disappearing early when exiting songs --- source/funkin/game/NoteGroup.hx | 12 +++++++++--- source/funkin/menus/PauseSubState.hx | 4 ++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/source/funkin/game/NoteGroup.hx b/source/funkin/game/NoteGroup.hx index 0d45a41f..9feda854 100644 --- a/source/funkin/game/NoteGroup.hx +++ b/source/funkin/game/NoteGroup.hx @@ -34,10 +34,16 @@ class NoteGroup extends FlxTypedGroup { return FlxSort.byValues(FlxSort.DESCENDING, n1.strumTime, n2.strumTime); }); } + + @:dox(hide) public var __forcedSongPos:Null = null; + + @:dox(hide) private inline function __getSongPos() + return __forcedSongPos == null ? Conductor.songPosition : __forcedSongPos; + public override function update(elapsed:Float) { i = length-1; __loopSprite = null; - __time = Conductor.songPosition; + __time = __getSongPos(); while(i >= 0) { __loopSprite = members[i--]; if (__loopSprite == null || !__loopSprite.exists || !__loopSprite.active) { @@ -58,7 +64,7 @@ class NoteGroup extends FlxTypedGroup { i = length-1; __loopSprite = null; - __time = Conductor.songPosition; + __time = __getSongPos(); while(i >= 0) { __loopSprite = members[i--]; if (__loopSprite == null || !__loopSprite.exists || !__loopSprite.visible) @@ -81,7 +87,7 @@ class NoteGroup extends FlxTypedGroup { public override function forEach(noteFunc:Note->Void, recursive:Bool = false) { i = length-1; __loopSprite = null; - __time = Conductor.songPosition; + __time = __getSongPos(); var oldCur = __currentlyLooping; __currentlyLooping = true; diff --git a/source/funkin/menus/PauseSubState.hx b/source/funkin/menus/PauseSubState.hx index 2366990c..fb2326e5 100644 --- a/source/funkin/menus/PauseSubState.hx +++ b/source/funkin/menus/PauseSubState.hx @@ -12,6 +12,7 @@ import flixel.tweens.FlxTween; import flixel.util.FlxColor; import funkin.options.keybinds.KeybindsOptions; import funkin.menus.StoryMenuState; +import funkin.backend.system.Conductor; import funkin.backend.utils.FunkinParentDisabler; class PauseSubState extends MusicBeatSubstate @@ -162,6 +163,9 @@ class PauseSubState extends MusicBeatSubstate PlayState.resetSongInfos(); if (Charter.instance != null) Charter.instance.__clearStatics(); + // prevents certain notes to disappear early when exiting - Nex + game.strumLines.forEachAlive(function(grp) grp.notes.__forcedSongPos = Conductor.songPosition); + CoolUtil.playMenuSong(); FlxG.switchState(PlayState.isStoryMode ? new StoryMenuState() : new FreeplayState()); }