Main. This is the game loop.