Tag Archives: game

Generic Game Loop

  1. Summary
  2. Objectives
  3. Article
    1. What is the game loop?
    2. Variable and Fixed time step
    3. Defining Game, GameState, and GameInput
    4. GameLoop interface
    5. GameLoopVariable implementation
    6. GameLoopInterpolated implementation
    7. GameLoopFixed implementation
    8. Smooth drawing technique
  4. Expanding
  5. Code Download
  6. Applet
  7. Next Article


Welcome to my first article! This article will discuss game loop theory and implementation. This should be valuable if you’re new to game programming, useful if you’re working on a game engine, and might be interesting even if you’re a seasoned programmer! I’ll touch on the common implementations, add functionality to them, and introduce new concepts! (I think?)


  • To design a simple game engine with flexible game loop configuration.
  • To have working code with various game loop implementations.
  • To implement smooth drawing for fixed time-step game loops.

Continue reading