Skip to content

Course overview

In this short course, you will learn to create a shooting game from scratch, using elements drawn with Canvas, and gameplay created using JavaScript. You will learn everything from setting up the project and drawing shapes using Canvas, to creating the logic for the opponent, and even completely automating the game to have the players play against themselves, responding to the movements and actions of each other.

Course description

This free online course covers all the steps involved in creating a shooting web game using HTML5, Canvas, and JavaScript. It begins with a demonstration of the process of setting up the project, and how Canvas is used to draw rectangles, circles, and paths. This is followed by demonstrations on animating elements using the animation frame, adding the ability to move elements with user input, as well as setting the conditions for movement and shooting.

The second half begins with an explanation of collision detection, and how it can be used to detect when a player is hit. This is followed by tutorials on creating a scoring system, as well as the ability to reset the game. The material gives detailed demonstrations of how the opponent logic could be created, and how to ensure the movements and shooting appear natural. It concludes with a code recap and a tutorial on how the game can be fully automated.

In addition to teaching the process of creating a dynamic web game, this course covers a range of useful topics in web development using JavaScript and HTML. The concepts include collision detection, animations using the animation frame, drawing paths and shapes using Canvas, dynamically created objects, as well as JavaScript DOM manipulation. New and experienced web developers will find the course useful. Start now, and learn to create a web-shooting game from scratch, using HTML5, Canvas, and JavaScript in just three hours.

Entry requirements

Get in touch with the course provider, or visit their website, for details.

View course on provider website

Learning outcome

In this free course, you will learn how to:

  • Describe the setup process of a Canvas project, using JavaScript
  • Explain the process of drawing circles and rectangles using Canvas
  • Recall the process of drawing paths using Canvas
  • Explain the function of the animation frame in JavaScript
  • Discuss the process of moving elements on a webpage in response to user input
  • Describe the process of making smooth animations with Canvas-drawn elements
  • Define collision detection
  • Explain the process of registering a hit, and updating the player score
  • Describe the process of adding the 'reset' functionality to the web game
  • Discuss the importance of using dynamically generated values for web objects
  • Explain the process of creating the movement logic for the opponent player
  • Describe the process needed to make the opponent move towards the player, and away from bullets

Course options

Course Type: Online
Details
Date: Get in touch with the course provider or visit their website for more informationCost: Get in touch with the course provider or visit their website for more information
Venue details

Not seeing a course venue? Online courses may not have a venue at all or could still be arranging one.

Get in touch with the course provider if you need more information about the venue.