+ top50 to song plates

This commit is contained in:
FajsiEx 2021-08-16 15:50:53 +02:00
parent e3561a8785
commit f88765d14d
1 changed files with 9 additions and 0 deletions

View File

@ -12,6 +12,7 @@ local effectedBgImage = gfx.CreateSkinImage("song_select/data_panel/effected_bg.
local illustratedBgImage = gfx.CreateSkinImage("song_select/data_panel/illust_bg.png", 1) local illustratedBgImage = gfx.CreateSkinImage("song_select/data_panel/illust_bg.png", 1)
local songPlateBg = gfx.CreateSkinImage("song_select/plate/bg.png", 1) local songPlateBg = gfx.CreateSkinImage("song_select/plate/bg.png", 1)
local songPlateBottomBarOverlayImage = gfx.CreateSkinImage("song_select/plate/bottom_bar_overlay.png", 1) local songPlateBottomBarOverlayImage = gfx.CreateSkinImage("song_select/plate/bottom_bar_overlay.png", 1)
local top50OverlayImage = gfx.CreateSkinImage("song_select/top50.png", 1)
local cursorImages = { local cursorImages = {
gfx.CreateSkinImage("song_select/cursor.png", 1), -- Effective rate or fallback gfx.CreateSkinImage("song_select/cursor.png", 1), -- Effective rate or fallback
@ -107,6 +108,8 @@ local selectedDifficulty = 1;
local jacketCache = {} local jacketCache = {}
local top50diffs = {}
local transitionScrollScale = 0; local transitionScrollScale = 0;
local transitionScrollOffsetY = 0; local transitionScrollOffsetY = 0;
local scrollingUp = false; local scrollingUp = false;
@ -317,6 +320,11 @@ function drawSong(song, y)
gfx.BeginPath(); gfx.BeginPath();
gfx.ImageRect(songX+391, y+47, 60, 60, gradeImage, 1, 0); gfx.ImageRect(songX+391, y+47, 60, 60, gradeImage, 1, 0);
-- Draw top 50 label if applicable
if (top50diffs[selectedSongDifficulty.id]) then
gfx.BeginPath();
gfx.ImageRect(songX+82, y+109, 506*0.85, 26*0.85, top50OverlayImage, 1, 0);
end
end end
function drawSongList() function drawSongList()
@ -627,6 +635,7 @@ songs_changed = function (withAll)
totalForce = 0 totalForce = 0
for i = 1, 50 do for i = 1, 50 do
if diffs[i] then if diffs[i] then
top50diffs[diffs[i].id] = true;
totalForce = totalForce + diffs[i].force totalForce = totalForce + diffs[i].force
end end
end end