mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2024-11-15 11:22:55 +00:00
accidentally also put the save changes oops
This commit is contained in:
parent
3bb981adb0
commit
99657da1f9
|
@ -598,15 +598,11 @@ class Save
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//percent also accounts for different ranks
|
|
||||||
var oldPerc = (previousScoreData.tallies.sick + previousScoreData.tallies.good) / previousScoreData.tallies.totalNotes;
|
|
||||||
var newPerc = (newScoreData.tallies.sick + newScoreData.tallies.good) / newScoreData.tallies.totalNotes;
|
|
||||||
|
|
||||||
// Set the high score and the high rank separately.
|
// Set the high score and the high rank separately.
|
||||||
var newScore:SaveScoreData =
|
var newScore:SaveScoreData =
|
||||||
{
|
{
|
||||||
score: Std.int(Math.max(previousScoreData.score, newScoreData.score)),
|
score: (previousScoreData.score > newScoreData.score) ? previousScoreData.score : newScoreData.score,
|
||||||
tallies: (oldPerc > newPerc ? previousScoreData.tallies : newScoreData.tallies)
|
tallies: (previousRank > newRank) ? previousScoreData.tallies : newScoreData.tallies
|
||||||
};
|
};
|
||||||
|
|
||||||
song.set(difficultyId, newScore);
|
song.set(difficultyId, newScore);
|
||||||
|
|
Loading…
Reference in a new issue