Animation

  1. Home
  2. Computing & Technology
  3. Animation

Dynamic Animation in Flash: Moving Dynamically Drawn Shapes

By Adrien-Luc Sanders, About.com

6 of 7

Because the drawing is contained inside a movie clip, you can animate it the same way that you might animate an object that you drew on-stage rather than having to redraw each line to give the illusion of animation. All you need is another onClipEvent and the x and y coordinates of the movie clip:
onClipEvent (enterFrame) {
_root.box._x+=1;
_root.box._y+=1;
}

Each time the movie clip’s timeline cycles through its single frame, Flash gets the x and y coordinates in pixels of the square’s center and adds one to it, moving it to the right and down. Animation, but short-lived animation as it moves off the screen and continues moving perpetually. In the next step we’ll shake things up a little.

6 of 7

Index: Dynamic Animation in Flash: Moving Dynamically Drawn Shapes

  1. Part 1
  2. Part 2
  3. Part 3
  4. Part 4
  5. Part 5
  6. Part 6
  7. Part 7

Explore Animation

More from About.com

Animation

  1. Home
  2. Computing & Technology
  3. Animation
  4. Flash Animation Tutorials
  5. Dynamic Animation in Flash: Moving Dynamically Drawn Shapes

©2008 About.com, a part of The New York Times Company.

All rights reserved.