+ remaining things to complete the transition
This commit is contained in:
parent
bdfa9dfcb0
commit
de58e98563
|
@ -251,6 +251,8 @@ function drawFolderList()
|
|||
end
|
||||
|
||||
function drawCursor()
|
||||
if not isFilterWheelActive or transitionLeaveScale ~= 0 then return end
|
||||
|
||||
gfx.BeginPath()
|
||||
|
||||
local cursorImageIndex = game.GetSkinSetting('_gaugeType')
|
||||
|
@ -310,7 +312,7 @@ function tickTransitions(deltaTime)
|
|||
-- This stuff happens right after filterwheel is deactivated
|
||||
end
|
||||
|
||||
transitionLeaveReappearTimer = transitionLeaveReappearTimer - deltaTime / TRANSITION_LEAVE_DURATION + 0.05 -- same reasoning as in the songwheel
|
||||
transitionLeaveReappearTimer = transitionLeaveReappearTimer - deltaTime / (TRANSITION_LEAVE_DURATION + 0.05) -- same reasoning as in the songwheel
|
||||
|
||||
if (transitionLeaveReappearTimer <= 0) then
|
||||
transitionLeaveScale = 0;
|
||||
|
@ -337,6 +339,7 @@ render = function(deltatime, shown)
|
|||
if (transitionEnterScale <= 0) then
|
||||
game.SetSkinSetting('_songWheelDespawnSelectorElements', 0);
|
||||
end
|
||||
|
||||
else
|
||||
game.SetSkinSetting('_songWheelOverlayActive', 1);
|
||||
game.SetSkinSetting('_songWheelDespawnSelectorElements', 1);
|
||||
|
@ -358,7 +361,7 @@ render = function(deltatime, shown)
|
|||
gfx.FillColor(255, 255, 255, 255);
|
||||
gfx.Text('S_M: ' .. selectionMode .. ' // S_F: ' .. selectedFolder ..
|
||||
' // S_L: ' .. selectedLevel .. ' // L_TS: ' ..
|
||||
transitionLeaveScale, 8, 1870);
|
||||
transitionLeaveScale .. ' // L_TRT: ' .. transitionLeaveReappearTimer, 8, 1870);
|
||||
end
|
||||
|
||||
set_selection = function(newIndex, isFolder)
|
||||
|
|
|
@ -49,6 +49,12 @@ local badgeImages = {
|
|||
gfx.CreateSkinImage("song_select/medal/puc.png", 1),
|
||||
}
|
||||
|
||||
local cursorImages = {
|
||||
gfx.CreateSkinImage("song_select/cursor.png", 1), -- Effective rate or fallback
|
||||
gfx.CreateSkinImage("song_select/cursor_exc.png", 1), -- Excessive rate
|
||||
gfx.CreateSkinImage("song_select/cursor_perm.png", 1), -- Premissive rate
|
||||
gfx.CreateSkinImage("song_select/cursor_blast.png", 1), -- Blastive rate
|
||||
}
|
||||
local gradeCutoffs = {
|
||||
D = 0000000,
|
||||
C = 7000000,
|
||||
|
@ -536,6 +542,8 @@ function drawData() -- Draws the song data on the left panel
|
|||
end
|
||||
|
||||
function drawFilterInfo(deltatime)
|
||||
gfx.LoadSkinFont('NotoSans-Regular.ttf')
|
||||
|
||||
gfx.BeginPath()
|
||||
gfx.ImageRect(5, 95, 417*0.85, 163*0.85, filterInfoBgImage, 1, 0)
|
||||
|
||||
|
@ -559,6 +567,17 @@ function drawFilterInfo(deltatime)
|
|||
gfx.Text(sortOptionLabel or '', desw-150, 130);
|
||||
end
|
||||
|
||||
function drawCursor()
|
||||
if isFilterWheelActive or transitionLeaveScale ~= 0 then return false end
|
||||
|
||||
gfx.BeginPath()
|
||||
|
||||
local cursorImageIndex = game.GetSkinSetting('_gaugeType')
|
||||
local cursorImage = cursorImages[cursorImageIndex or 1];
|
||||
|
||||
gfx.ImageRect(desw / 2 - 14, desh / 2 - 213 / 2, 555, 213, cursorImage, 1, 0)
|
||||
end
|
||||
|
||||
function drawSearch()
|
||||
if (not songwheel.searchInputActive) then
|
||||
return;
|
||||
|
@ -709,12 +728,13 @@ function tickTransitions(deltaTime)
|
|||
end
|
||||
transitionLeaveReappearTimer = 1;
|
||||
transitionAfterscrollScale = 0; -- Keep songwheel in the "afterscroll" state while the filterwheel is active
|
||||
transitionJacketBgScrollScale = 0; -- Same thing here, just with the jacket bg
|
||||
else
|
||||
if (transitionLeaveReappearTimer == 1) then
|
||||
-- This stuff happens right after filterwheel is deactivated
|
||||
end
|
||||
|
||||
transitionLeaveReappearTimer = transitionLeaveReappearTimer - deltaTime / TRANSITION_LEAVE_DURATION + 0.05 -- 0.05s is a few frames between the completetion of the fade out and songs reappearing in the AC
|
||||
transitionLeaveReappearTimer = transitionLeaveReappearTimer - deltaTime / (TRANSITION_LEAVE_DURATION + 0.05) -- 0.05s is a few frames between the completetion of the fade out and songs reappearing in the AC
|
||||
|
||||
if (transitionLeaveReappearTimer <= 0) then
|
||||
transitionLeaveScale = 0;
|
||||
|
@ -740,6 +760,7 @@ render = function (deltaTime)
|
|||
isFilterWheelActive = game.GetSkinSetting('_songWheelOverlayActive') == 1;
|
||||
|
||||
drawData()
|
||||
drawCursor()
|
||||
|
||||
drawFilterInfo(deltaTime)
|
||||
|
||||
|
|
Loading…
Reference in New Issue