implement skin config for search controls window

This commit is contained in:
Kyle Humphrey 2022-03-10 19:02:48 -06:00
parent 59cf769508
commit 4cabc5990f
2 changed files with 19 additions and 9 deletions

View File

@ -57,6 +57,12 @@
"default": false "default": false
}, },
"gameplay_showSearchControls": {
"label": "Show song select controls when searching",
"type": "bool",
"default": true
},
"separator_f": {}, "separator_f": {},
"Debug": { "type": "label" }, "Debug": { "type": "label" },

View File

@ -35,6 +35,8 @@ local searchInfoPanelImage = gfx.CreateSkinImage("song_select/search_info_panel.
local defaultJacketImage = gfx.CreateSkinImage("song_select/loading.png", 0) local defaultJacketImage = gfx.CreateSkinImage("song_select/loading.png", 0)
local difficultyLabelImages = { local difficultyLabelImages = {
gfx.CreateSkinImage("song_select/plate/difficulty_labels/novice.png", 1), gfx.CreateSkinImage("song_select/plate/difficulty_labels/novice.png", 1),
gfx.CreateSkinImage("song_select/plate/difficulty_labels/advanced.png", 1), gfx.CreateSkinImage("song_select/plate/difficulty_labels/advanced.png", 1),
@ -705,9 +707,11 @@ function drawSearch()
sh = sh * infoResize; sh = sh * infoResize;
local infoXPos = 0; local infoXPos = 0;
local infoYStartPos = desh - sh - 772 + 242; local infoYStartPos = desh - sh - 772 + 242;
local infoYPos = infoYStartPos + transitionSearchInfoOffsetY; local infoYPos = infoYStartPos + transitionSearchInfoOffsetY;
if (game.GetSkinSetting('gameplay_showSearchControls')) then
gfx.ImageRect(infoXPos, infoYPos, sw, sh, searchInfoPanelImage, transitionSearchBackgroundInfoAlpha, 0) gfx.ImageRect(infoXPos, infoYPos, sw, sh, searchInfoPanelImage, transitionSearchBackgroundInfoAlpha, 0)
end
-- Draw Search is Active text -- Draw Search is Active text
gfx.BeginPath(); gfx.BeginPath();