In This Chapter
Pushing data to arrays
Retrieving array elements with Pop
Introducing the Vector class
Using string identifiers in Vector elements
Starting and stopping drag operations
Drawing with ActionScript 3.0
Creating triangles with vertices and indices
Too often, we hear Web designers and developers pine for the "good old days" when ActionScript consisted of just a few lines of code spread all over the place. Well, we disagree. ActionScript 3.0 has a learning curve for people accustomed to using previous versions, but the good thing about ActionScript 3.0 is that now that it has been retooled into a standardized, more efficient form, it will be around for a while, and, even though some changes will inevitably be made in future versions, you don't have to figure out how to use it from scratch every time a new version is released and you want to sit down to make the world's greatest Flash application.
In this chapter, we show you how to use grouping structures that corral more than a single element and give each one a unique value, and we tell you about arrays that have been included in several generations of ActionScript. Using arrays, you can easily have several values different types of data stored in the same place for ease of access. In addition, you see vectors, ...