Refactored some code and added the find_ceiling() function to all games.