O'Reilly logo

Beginning HTML5 Games with CreateJS by Brad Manderscheid

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 3

image

Capturing User Input

Now that you have a solid understanding of how graphics are created and how you can animate them, some player interaction is in order to turn your visuals into playable, interactive content.

I’ll discuss using both mouse and keyboard controls to capture user input, and you’ll view a few practical examples that show how to accomplish some common gaming features. Text will also be introduced to display the necessary messaging to provide feedback to the player.

Mouse Events

EaselJS not only handles your canvas drawing, but also the management of mouse positions and actions, and whether they intersect with any of your ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required