Home page

About these tutorials


Here is how these tutorials work:

First there is a download link to the complete game, and a description of the rules and controls of the game. I recommend playing the game before moving on to the next steps so you have a good understanding of what the game is.

Then there is a basic overview of the game's data and logic. It's kind of like envisioning how the game will be made before you start writing the code.

Then the code is built up step-by-step. This includes intermediary steps that don't appear in the final code but help us get there. I recommend following along in your own code editor and running the code after every step.

These tutorials are for beginners, and the code tries to avoid anything that isn't fundamentally necessary, so there is no object-oriented design, or code split between multiple files, etc. Less fundamental language/API features are also avoided.

However, to keep a level of clarity to the code, a couple of principles are followed:

You can do these tutorials in any order. I recommend experimenting with the code, adding new things to the games, and using ideas that you've seen to create games of your own.

These tutorials are public domain, please do whatever you want with them.

You can see the code that generates the HTML files and images here.

I hope you have fun going through these tutorials!