set ghost Y when trying to hang with the current piece (#1066)
This commit is contained in:
@@ -1281,6 +1281,7 @@ function Player:hold_norm(ifpre)
|
|||||||
ins(self.holdQueue,self:_getBlock(C.id,C.name,C.color))
|
ins(self.holdQueue,self:_getBlock(C.id,C.name,C.color))
|
||||||
|
|
||||||
if self:willDieWith(self.nextQueue[1]) then
|
if self:willDieWith(self.nextQueue[1]) then
|
||||||
|
self.ghoY=self:getSpawnY(self.nextQueue[1])
|
||||||
self.cur=nil
|
self.cur=nil
|
||||||
self.waiting=ENV.hang
|
self.waiting=ENV.hang
|
||||||
self.holdIXSFromNext={ifpre}
|
self.holdIXSFromNext={ifpre}
|
||||||
@@ -1313,6 +1314,7 @@ function Player:hold_norm(ifpre)
|
|||||||
if C then
|
if C then
|
||||||
ins(self.holdQueue,self:_getBlock(C.id,C.name,C.color))
|
ins(self.holdQueue,self:_getBlock(C.id,C.name,C.color))
|
||||||
if self:willDieWith(self.holdQueue[1]) then
|
if self:willDieWith(self.holdQueue[1]) then
|
||||||
|
self.ghoY=self:getSpawnY(self.holdQueue[1])
|
||||||
self.cur=nil
|
self.cur=nil
|
||||||
self.waiting=ENV.hang
|
self.waiting=ENV.hang
|
||||||
return
|
return
|
||||||
@@ -1368,6 +1370,7 @@ function Player:hold_swap(ifpre)
|
|||||||
ins(self.holdQueue,self.nextQueue[hid])
|
ins(self.holdQueue,self.nextQueue[hid])
|
||||||
self.nextQueue[hid]=hb
|
self.nextQueue[hid]=hb
|
||||||
if self:willDieWith(self.holdQueue[1]) then
|
if self:willDieWith(self.holdQueue[1]) then
|
||||||
|
self.ghoY=self:getSpawnY(self.holdQueue[1])
|
||||||
self.cur=nil
|
self.cur=nil
|
||||||
self.waiting=ENV.hang
|
self.waiting=ENV.hang
|
||||||
return
|
return
|
||||||
@@ -2072,6 +2075,7 @@ do
|
|||||||
-- Prevent sudden death if hang>0
|
-- Prevent sudden death if hang>0
|
||||||
if ENV.hang>ENV.wait then
|
if ENV.hang>ENV.wait then
|
||||||
if self:willDieWith(self.nextQueue[1]) then
|
if self:willDieWith(self.nextQueue[1]) then
|
||||||
|
self.ghoY=self:getSpawnY(self.nextQueue[1])
|
||||||
self.waiting=self.waiting+ENV.hang
|
self.waiting=self.waiting+ENV.hang
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user