Added a game loop end