Free course · Videos & slides

A Course in
Computer Game
Programming.

Learn how games actually work by making them yourself. This practical course builds 2D games from scratch with JavaScript and HTML Canvas, without relying on a game engine.

Why I made it

The nuts and bolts
of games.

I created this course for the University of Iceland and began teaching it in 2013. Hundreds of students have taken it, producing their own small games along the way. I made the videos from the 2021 edition publicly available so anyone with some programming experience can follow along.

The course is self-contained and uses no textbook or third-party engine. It concentrates on 2D systems so there is time to understand the moving parts: updates, drawing, objects, collisions, and behaviour. It assumes a grounding in programming, such as Java or C++; it isn't an introduction to coding from zero.

What you'll cover

From a blank canvas
to a working game.

The lectures start with a little computing and games history, move through JavaScript basics, then build up the systems behind playable 2D games.

  • Computing and games history
  • JavaScript for programmers
  • The main loop and time steps
  • HTML Canvas rendering and input
  • PONG! and Breakout
  • Sprites and animation
  • Dynamics and collision
  • Object management
  • Game AI and a little networking
  • Putting the pieces together
Start here

Pick your way in.

Watch the full 2021 lecture series, use the public slide collection alongside it, or read the original introduction on Medium.