Simple Games

Games for Novice Programmers to Deconstruct

Progress Report

This site is a work in progress. The next milestone will be to complete the first two games, attach thorough comments to their code, write walkthroughs through the code, provide students with some exercises and produce Coding Notes for the JavaScript constructs used so far.

Welcome to Learning JavaScript and Web APIs Through Games

This site contains classic-style games and game making tutorials for people who are just beginning learning programming. It doesn't use any point-and-click tools specifically designed for making video games (such as Unity or Clickteam products). You can achieve a lot with those tools without knowing very much about programming. Call me old school but since the skill I excel most at is programming I consider using these products to be a kind of "cheating". Instead, I assume your objectives include a strong desire to learn about the programming techniques involved and how the code works and provides instructions for the machine to carry out on a deep level. However, as the course progresses you will build up skills which will allow you to put together your own toolkit for making your games. At a minimum you'll at least be able borrow pieces from the code examples introduced and discussed during the course and understand how it all works.

We'll start off using only some basic logic and then we'll build on that by gradually beginning to use more of the browser's APIs and some more sophisticated programming techniques. None of the games here are very impressive by modern standards, they're just provided to assist with developing technical skills. An interest in retro games would helpful, as the ways we'll approach problem solving will be similar to techniques that programmers writing for the Amiga, Atari ST, Commodore 64 and MS‑DOS QBasic were forced to use before dedicated game making engines existed. After completing this course you'll have a better understanding of JavaScript and you may choose to carry on programming directly in the browser. Or you might choose to use to use a dedicated game making engine, but if you do you'll be more able to tackle trickier programming issues whilst simultaneously having a greater understanding of how simple tasks you delegate to the game engine are carried out and the strengths and limitations of the algorithms used.

This course will require us (even me) to develop a diverse skill set. Not only is a strong programming capability required but also artwork, animation, sound effects and music. Some games may require us to program the computer with basic laws of physics, while others may need us to model the economics of alien civilizations.

My intention is to hopefully some day have the opportunity to use these course materials in an instructor led setting. Nonetheless they may also be useful to online learners.

Jump to the list of games

Learning Objectives

Techniques Covered

  • Transitioning from making web pages to making games
  • Using maps and tiles to describe worlds
  • Reading keyboard input
  • Using HTML5 Canvas (2D)

Game Genres

  • Puzzle games

Course Prerequisites

Students should already have some degree of familiarity with HTML, basic CSS and Bootstrap and be able to make small web sites from scratch. They should be able to upload their work to the internet using GitHub Desktop. Students should be familiar with the following JavaScript concepts: variables, functions, ifelse and while loops. They might optionally have some previous experience of using basic JQuery.