整理master_ex代码,修复结束前分数上限错误
This commit is contained in:
@@ -1,11 +1,11 @@
|
|||||||
local sectionName={"D","C","B","A","A+","S-","S","S+","SS","SS","SS","U","U","U","X"}
|
local sectionName={"D","C","B","A","A+","S-","S","S+","SS","SS","SS","U","U","U","X"}
|
||||||
local function score(P)
|
local function score(P)
|
||||||
--If Less then MM
|
--If Less then X
|
||||||
if P.modeData.rankScore<130 then
|
if P.modeData.rankScore<130 then
|
||||||
local R=#P.clearedRow
|
local R=#P.clearedRow
|
||||||
if R>0 then
|
if R>0 then
|
||||||
if R==4 then R=10 end--Techrash bonus
|
if R==4 then R=10 end--Techrash bonus
|
||||||
P.modeData.rankScore=math.min(P.modeData.rankScore+R,120)
|
P.modeData.rankScore=math.min(P.modeData.rankScore+R,130)
|
||||||
P.modeData.rankName=sectionName[math.floor(P.modeData.rankScore/10)+1]
|
P.modeData.rankName=sectionName[math.floor(P.modeData.rankScore/10)+1]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -56,6 +56,12 @@ return{
|
|||||||
comp=function(a,b)return a[1]>b[1]or a[1]==b[1]and a[2]>b[2]end,
|
comp=function(a,b)return a[1]>b[1]or a[1]==b[1]and a[2]>b[2]end,
|
||||||
getRank=function(P)
|
getRank=function(P)
|
||||||
P=P.modeData.rankScore
|
P=P.modeData.rankScore
|
||||||
return P==140 and 5 or P>=110 and 4 or P>=80 and 3 or P>=50 and 2 or P>=30 and 1 or P>=10 and 0
|
return
|
||||||
|
P==140 and 5 or
|
||||||
|
P>=110 and 4 or
|
||||||
|
P>=80 and 3 or
|
||||||
|
P>=50 and 2 or
|
||||||
|
P>=30 and 1 or
|
||||||
|
P>=10 and 0
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user