修正堆叠模式超额消除奖励

This commit is contained in:
MrZ_26
2022-07-17 23:58:59 +08:00
parent a4d6585e9c
commit 9606cb2dc9
2 changed files with 23 additions and 17 deletions

View File

@@ -10,17 +10,20 @@ return{
hook_die=function(P)
local cc=P:clearFilledLines(P.garbageBeneath+1,#P.field-P.garbageBeneath)
if cc>0 then
local h=20-cc-P.garbageBeneath-3
if h<-1 and P.garbageBeneath>0 then
for i=1,math.min(P.garbageBeneath,-h-1) do
LINE.discard(table.remove(P.field,1))
LINE.discard(table.remove(P.visTime,1))
end
elseif h>0 then
P:garbageRise(21,h,2e10-1)
if P.garbageBeneath>=20 then
local clearH=cc+P.garbageBeneath
if clearH<17 then
P:garbageRise(21,17-clearH,2e10-1)
if P.garbageBeneath>=17 then
P:lose()
end
elseif P.garbageBeneath>0 and clearH>17 then
local bonus=math.min(P.garbageBeneath,clearH-17)
if bonus>0 then
for _=1,bonus do
LINE.discard(table.remove(P.field,1))
LINE.discard(table.remove(P.visTime,1))
end
end
end
end
end,