From c706937cece32f1411b124a0f651dc9d5025c9bd Mon Sep 17 00:00:00 2001 From: RealFD Date: Sun, 5 Jun 2022 22:06:08 +0200 Subject: [PATCH] a --- config-definitions.json | 21 ++++++++++++++++ scripts/downloadscreen.lua | 5 +++- scripts/multi/roomList/getroom.lua | 40 ++++++++++++++++-------------- 3 files changed, 46 insertions(+), 20 deletions(-) diff --git a/config-definitions.json b/config-definitions.json index 28af1f3..0f343e5 100644 --- a/config-definitions.json +++ b/config-definitions.json @@ -79,6 +79,27 @@ "default": true }, + "gameplay_earlyLateFor": { + "label": "Show Early/Late display for", + "type": "selection", + "default": "NEAR (or worse)", + "values": ["CRITICAL (or worse)", "NEAR (or worse)", "OFF"] + }, + + "gameplay_earlyLatePosition": { + "label": "Early/Late display position", + "type": "selection", + "default": "STANDARD", + "values": ["UPPER+", "UPPER", "STANDARD", "LOWER"] + }, + + "gameplay_msFor": { + "label": "Show millisecond display for", + "type": "selection", + "default": "NEAR (or worse)", + "values": ["ALL", "CRITICAL (or worse)", "NEAR (or worse)", "NONE"] + }, + "separator_f": {}, "Debug": { "type": "label" }, diff --git a/scripts/downloadscreen.lua b/scripts/downloadscreen.lua index a78d819..2593c31 100644 --- a/scripts/downloadscreen.lua +++ b/scripts/downloadscreen.lua @@ -111,6 +111,9 @@ function render_song(song, x,y) gfx.Save() gfx.Translate(x,y) + if song.jacket_url ~= nil and song.jacket == jacketFallback then + webjacket = gfx.LoadWebImageJob(song.jacket_url, jacketFallback, 250, 250) + end getroom(song,x,y,downloaded) gfx.Restore() @@ -285,7 +288,7 @@ function button_pressed(button) local song = songs[cursorPos + 1] if song == nil then return end dlScreen.DownloadArchive(encodeURI(song.cdn_download_url), header, song.id, archive_callback) - downloaded[song.id] = "Downloading..." + downloaded[song.id] = "Downloading" elseif screenState == 1 then if selectedLevels[levelcursor + 1] then selectedLevels[levelcursor + 1] = false diff --git a/scripts/multi/roomList/getroom.lua b/scripts/multi/roomList/getroom.lua index 516f9d7..4e5d775 100644 --- a/scripts/multi/roomList/getroom.lua +++ b/scripts/multi/roomList/getroom.lua @@ -79,8 +79,6 @@ local getroom = function(song,x,y,downloaded) difbar.render(deltaTime, x+260+(1*115),y+106, jw/150, diff.difficulty, diff.level); elseif diff.difficulty == 4 then ---mxm and up difbar.render(deltaTime, x+260+(2*115),y+106, jw/150, diff.difficulty, diff.level); - elseif diff.difficulty == 4 then ---mxm and up - difbar.render(deltaTime, x+260+(2*115),y+106, jw/150, diff.difficulty+1, diff.level); end end @@ -89,33 +87,37 @@ local getroom = function(song,x,y,downloaded) gfx.ImageRect(x+650,y+69, jw, jh, n_cost,1,0); - local buy = 8000 + local buy = "Not Downloaded" - + local jw,jh = gfx.ImageSize(n_play_dot); + if song.status == "Playing" then + gfx.BeginPath() + gfx.TextAlign(gfx.TEXT_ALIGN_RIGHT + gfx.TEXT_ALIGN_MIDDLE) + gfx.FontSize(24) + gfx.SetImageTint(255,255,255) + gfx.Text(song.status, x+878-50, y+24) + gfx.BeginPath(); + gfx.ImageRect(x+764, y+11, jw, jh, n_play_dot,1,0); + gfx.SetImageTint(0,246,2) + + end gfx.FontSize(30) if not downloaded[song.id] then gfx.BeginPath() - - gfx.TextAlign(gfx.TEXT_ALIGN_CENTER + gfx.TEXT_ALIGN_MIDDLE) - gfx.Text(buy.." AP",x+830,y+92) + gfx.TextAlign(gfx.TEXT_ALIGN_RIGHT + gfx.TEXT_ALIGN_MIDDLE) + gfx.Text(buy,x+850,y+92) elseif downloaded[song.id] then - buy = "0"--downloaded[song.id] + buy = "Downloaded" gfx.BeginPath() - gfx.TextAlign(gfx.TEXT_ALIGN_CENTER + gfx.TEXT_ALIGN_MIDDLE) - - gfx.Text(buy.." AP", x+830,y+92) - end - if song.status == "Playing" then - gfx.BeginPath() - gfx.TextAlign(gfx.TEXT_ALIGN_CENTER + gfx.TEXT_ALIGN_MIDDLE) - gfx.FontSize(24) - gfx.Text(song.status, x+878-50, y+24) + + gfx.TextAlign(gfx.TEXT_ALIGN_RIGHT + gfx.TEXT_ALIGN_MIDDLE) + gfx.Text(buy, x+830,y+92) - local jw,jh = gfx.ImageSize(n_play_dot); gfx.BeginPath(); - gfx.SetImageTint(0,246,2) + gfx.SetImageTint(240,246,0) gfx.ImageRect(x+764, y+11, jw, jh, n_play_dot,1,0); gfx.SetImageTint(255,255,255) + end end end