fixed part isGameOver() method