fixed IMS crashing some rotation systems

This commit is contained in:
Ishaan Bhardwaj 2021-01-09 14:55:01 -05:00
parent 6b789d063a
commit b95d66adc8

View File

@ -77,7 +77,7 @@ function JokerGame:onPieceEnter()
for i = 1, 10 do for i = 1, 10 do
local new_piece = self.piece:withOffset({x=-i, y=0}) local new_piece = self.piece:withOffset({x=-i, y=0})
if self.grid:canPlacePiece(new_piece) then if self.grid:canPlacePiece(new_piece) then
self.piece = new_piece self.piece:setOffset({x=-i, y=0})
break break
end end
if not rush then break end if not rush then break end
@ -86,7 +86,7 @@ function JokerGame:onPieceEnter()
for i = 1, 10 do for i = 1, 10 do
local new_piece = self.piece:withOffset({x=i, y=0}) local new_piece = self.piece:withOffset({x=i, y=0})
if self.grid:canPlacePiece(new_piece) then if self.grid:canPlacePiece(new_piece) then
self.piece = new_piece self.piece:setOffset({x=i, y=0})
break break
end end
if not rush then break end if not rush then break end