+ search drawing support to songwheel
This commit is contained in:
parent
01139f48ae
commit
6597b53799
|
@ -14,6 +14,8 @@ local songPlateBottomBarOverlayImage = gfx.CreateSkinImage("song_select/plate/bo
|
|||
local cursorImage = gfx.CreateSkinImage("song_select/cursor.png", 1)
|
||||
local diffCursorImage = gfx.CreateSkinImage("song_select/level_cursor.png", 1)
|
||||
|
||||
local searchBgImage = gfx.CreateSkinImage("song_select/search_bg.png", 1)
|
||||
|
||||
local defaultJacketImage = gfx.CreateSkinImage("song_select/loading.png", 0)
|
||||
|
||||
local difficultyLabelImages = {
|
||||
|
@ -404,6 +406,19 @@ function drawData() -- Draws the song data on the left panel
|
|||
gfx.GlobalAlpha(1);
|
||||
end
|
||||
|
||||
function drawSearch()
|
||||
if (not songwheel.searchInputActive) then
|
||||
return;
|
||||
end
|
||||
|
||||
gfx.BeginPath();
|
||||
local tw, th = gfx.ImageSize(searchBgImage)
|
||||
gfx.ImageRect(desw-tw/2, 0, tw/2, th/2, searchBgImage, 1, 0)
|
||||
|
||||
gfx.FontSize(28);
|
||||
gfx.Text(songwheel.searchText, desw-200, 30);
|
||||
end
|
||||
|
||||
function tickTransitions(deltaTime)
|
||||
if transitionScrollScale < 1 then
|
||||
transitionScrollScale = transitionScrollScale + deltaTime / 0.1 -- transition should last for that time in seconds
|
||||
|
@ -499,6 +514,8 @@ render = function (deltaTime)
|
|||
|
||||
drawData()
|
||||
|
||||
drawSearch();
|
||||
|
||||
|
||||
gfx.BeginPath();
|
||||
gfx.FontSize(18)
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 32 KiB |
Loading…
Reference in New Issue