update litris with board detection

This commit is contained in:
2023-07-29 21:30:00 +02:00
parent 332190394d
commit c3e677ca0a
2 changed files with 6 additions and 1 deletions

View File

@@ -70,7 +70,7 @@ class Litris(GameBase):
self.move_stone(column - offset_col, rotation)
self.drop_down()
print(self.field)
if self.field.get_line_count() >= 6 and self.field.height() <= 1 and self.field.state[19][9] == ' ':
if self.field.get_line_count() >= 6 and self.field.height() <= 2 and self.field.check_crucial_pos_to_be_free():
if self.field.predict_gaps_in_next_rotation() <= 3:
self.update_move_mode()