Developing HTML5 Games from Scratch: Handling Input

Watch the first few minutes on us! If you'd like to watch the entire video and hundreds more like it, download code samples, access offline videos and skills assessments, and use the discussion forums, log in or purchase a subscription.


Instructor

G. Andrew Duthie

Description

Once you've gotten the hang of animation in your HTML5 games, you'll want to make them interactive. When it comes to input, there are many options to choose from, including keyboard, mouse, and touch. And some browsers are even making early efforts at including gamepad support. The challenge for developers is that there are many different device form factors that you may want to support, and each tends to favor a particular input paradigm, with the most obvious being that mobile devices will largely rely on touch. In this video, we'll look at how to handle all these forms of input, and how to tie the event-driven world of input into the game loop, updating the state of game elements, to put the user in control.

Table of Contents

{{toc.Position}} {{toc.Text}}

Related Links

  • {{link.LinkText}} (requires a paid subscription)

Series

This course is part of the following series: