Improved invis/fading roll modes (#697)

* Added target line in master_ex

* Added roll target line in master_g

* Added roll countdown during transition in master_g
This commit is contained in:
NOT_A_ROBOT
2022-05-04 17:06:42 +07:00
committed by GitHub
parent 5d05583e26
commit 8d4e2fa0d0
2 changed files with 29 additions and 0 deletions

View File

@@ -104,6 +104,21 @@ local function addGrade(row, cmb, lvl) -- IGS = internal grade system
int_grade=int_grade+1
end
end
local function getRollGoal()
-- get amount of grades needed for TM+
local rem=#gradeList-(int_grade_boosts[math.min(int_grade+1,#int_grade_boosts)]+rollGrades+cools+1-regrets)
if rem<=0 then return 0 end
local goal=0
if cools>8 then
goal=math.floor(rem)*4
rem=rem%1
return goal + (rem>0.3 and 4 or rem*10)
else
goal=math.floor(rem/0.26)*4
rem=rem%0.26
return goal + (rem>0.12 and 4 or rem*25)
end
end
return{
drop=64,
@@ -145,6 +160,7 @@ return{
t=t/60
gc.setColor(1.7*t,2.3-2*t,.3)
mStr(T,63,248)
PLY.draw.drawTargetLine(P,getRollGoal())
else
-- draw level counter
setFont(20)
@@ -295,10 +311,13 @@ return{
TABLE.cut(P.visTime)
elseif P.waiting==180 then
playReadySFX(3,3)
P:_showText("3",0,-120,120,'fly',1)
elseif P.waiting==120 then
playReadySFX(2,1)
P:_showText("2",0,-120,120,'fly',1)
elseif P.waiting==60 then
playReadySFX(1,1)
P:_showText("1",0,-120,120,'fly',1)
elseif P.waiting==1 then
playReadySFX(0,1)
isInRollTrans=false