SRS-X rotate lock reset behavior fixed

This commit is contained in:
Ishaan Bhardwaj 2021-01-30 16:54:09 -05:00
parent 5e02471fb4
commit f0e84a8874

View File

@ -112,8 +112,8 @@ end
function SRS:onPieceRotate(piece, grid) function SRS:onPieceRotate(piece, grid)
piece.lock_delay = 0 -- rotate reset piece.lock_delay = 0 -- rotate reset
self:checkNewLow(piece) self:checkNewLow(piece)
piece.rotations = piece.rotations + 1
if piece.rotations >= self.ROTATIONS_MAX then if piece.rotations >= self.ROTATIONS_MAX then
piece.rotations = piece.rotations + 1
piece:moveInGrid({ x = 0, y = 1 }, 1, grid) piece:moveInGrid({ x = 0, y = 1 }, 1, grid)
if piece:isDropBlocked(grid) then if piece:isDropBlocked(grid) then
piece.locked = true piece.locked = true