mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2025-02-05 03:00:27 +00:00
[BUGFIX] Fixed Ranks not appearing in freeplay for custom variations
Freeplay tries to access a song's rank using the current difficulty name alone, but custom variation ranks are being saved with a variation prefix. This PR makes freeplay look for the variation prefix when necessary.
This commit is contained in:
parent
9908f973cf
commit
1f1fe62a06
|
@ -2094,8 +2094,13 @@ class FreeplaySongData
|
|||
{
|
||||
this.albumId = songDifficulty.album;
|
||||
}
|
||||
|
||||
// TODO: This line of code makes me sad, but you can't really fix it without a breaking migration.
|
||||
// `easy`, `erect`, `normal-pico`, etc.
|
||||
var suffixedDifficulty = (songDifficulty.variation != Constants.DEFAULT_VARIATION
|
||||
&& songDifficulty.variation != 'erect') ? '$currentDifficulty-${songDifficulty.variation}' : currentDifficulty;
|
||||
|
||||
this.scoringRank = Save.instance.getSongRank(songId, currentDifficulty);
|
||||
this.scoringRank = Save.instance.getSongRank(songId, suffixedDifficulty);
|
||||
|
||||
this.isNew = song.isSongNew(currentDifficulty);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue