changes is_game_over to check for a win first