1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2024-11-14 19:05:15 +00:00

fix: Don't restart the FreeplayState song preview when changing the difficulty within the same variation

pulled from the wrong branch, oops!

last update i hope

wrong spellings im gonna kms
This commit is contained in:
Kolo 2024-10-05 10:29:26 +02:00 committed by Cameron Taylor
parent 0d60929f18
commit 903b3fc599

View file

@ -1689,6 +1689,7 @@ class FreeplayState extends MusicBeatSubState
function changeDiff(change:Int = 0, force:Bool = false):Void
{
touchTimer = 0;
var previousVariation:String = currentVariation;
// Available variations for current character. We get this since bf is usually `default` variation, and `pico` is `pico`
// but sometimes pico can be the default variation (weekend 1 songs), and bf can be `bf` variation (darnell)
@ -1784,7 +1785,7 @@ class FreeplayState extends MusicBeatSubState
}
// Reset the song preview in case we changed variations (normal->erect etc)
playCurSongPreview();
if (currentVariation != previousVariation) playCurSongPreview();
}
// Set the album graphic and play the animation if relevant.