diff --git a/scripts/songselect/songwheel.lua b/scripts/songselect/songwheel.lua index 56a0af1..cd284b3 100644 --- a/scripts/songselect/songwheel.lua +++ b/scripts/songselect/songwheel.lua @@ -425,37 +425,39 @@ function drawData() -- Draws the song data on the left panel end gfx.Save() + -- Draw best score + gfx.BeginPath() + if bestScore then - -- Draw best score - gfx.BeginPath() draw_number(100, 793, 1.0, math.floor(bestScore.score / 10000), 4, scoreNumbers, true, 0.3, 1.12) draw_number(253, 798, 1.0, bestScore.score, 4, scoreNumbers, true, 0.22, 1.12) - - -- Draw grade - local gradeImage = gradeImages.none; - local gradeAlpha = transitionAfterscrollGradeAlpha; - if bestScore then - gradeImage = getGradeImageForScore(bestScore.score) - - if (transitionAfterscrollGradeAlpha == 1 and bestScore.score >= gradeCutoffs.S) then - gradeAlpha = transitionFlashAlpha; -- If S, flash the badge - end - end - - gfx.BeginPath(); - gfx.ImageRect(360, 773, 45, 45, gradeImage, gradeAlpha, 0); - - -- Draw badge - badgeImage = badgeImages[diff.topBadge+1]; - - local badgeAlpha = transitionAfterscrollBadgeAlpha; - if (transitionAfterscrollBadgeAlpha == 1 and diff.topBadge >= 3) then - badgeAlpha = transitionFlashAlpha; -- If hard clear or above, flash the badge, but only after the initial transition - end - - gfx.BeginPath() - gfx.ImageRect(425, 724, 93/1.1, 81/1.1, badgeImage, badgeAlpha, 0) end + + -- Draw grade + local gradeImage = gradeImages.none; + local gradeAlpha = transitionAfterscrollGradeAlpha; + if bestScore then + gradeImage = getGradeImageForScore(bestScore.score) + + if (transitionAfterscrollGradeAlpha == 1 and bestScore.score >= gradeCutoffs.S) then + gradeAlpha = transitionFlashAlpha; -- If S, flash the badge + end + end + + gfx.BeginPath(); + gfx.ImageRect(360, 773, 45, 45, gradeImage, gradeAlpha, 0); + + -- Draw badge + badgeImage = badgeImages[diff.topBadge+1]; + + local badgeAlpha = transitionAfterscrollBadgeAlpha; + if (transitionAfterscrollBadgeAlpha == 1 and diff.topBadge >= 3) then + badgeAlpha = transitionFlashAlpha; -- If hard clear or above, flash the badge, but only after the initial transition + end + + gfx.BeginPath() + gfx.ImageRect(425, 724, 93/1.1, 81/1.1, badgeImage, badgeAlpha, 0) + gfx.Restore() -- Draw BPM