Chapter 7. USER INTERACTION: MOVING OBJECTS AROUND

What we'll cover in this chapter:

  • Pressing and releasing a sprite

  • Dragging a sprite

  • Throwing

It's likely that a primary goal of your animation is to allow smooth user interaction, and a lot of this interaction will be through the mouse. I talked about mouse events back in Chapter 2, but you haven't really done much with them yet. Now, you'll get some hands-on practice with them.

In this chapter, you're going to take your first steps into the field of user interaction. You'll learn how to handle dragging, dropping, and throwing. But first, let's get started with the basics of press and release.

Pressing and releasing a sprite

The mouse is a pretty cool invention, but in essence, it's a simple device. ...

Get Foundation ActionScript 3.0 Animation: Making Things Move! now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.