Figured out the loop at the end of the level generation.