Added rough game loop code