Game dev
Saved & recent

Game loop

Related terms: tick, update, frame

The loop at the heart of every game. Each pass reads input, updates the world, and draws the result. One pass is one frame.

Unlike a normal app, a game does not wait for events. It runs this loop continuously, even when the player does nothing.

Further reading
Robert Nystrom: Game Loop
input update render next frame
Every frame reads input, updates the ball position and draws the updated scene. Rendering leads back to input for the next frame.

View in the full Game dev collection