diff --git a/src/py2048/board.py b/src/py2048/board.py index 05d7d03..b8654f0 100644 --- a/src/py2048/board.py +++ b/src/py2048/board.py @@ -79,3 +79,6 @@ class Board(pygame.sprite.Group): return True return False + def is_game_over(self) -> bool: + """Check if the game is over.""" + return self._is_full() and not self._can_move()