Home arrow Flash arrow Page 2 - Flash 101 (part 5): Spiralling Out Of Control

Recycle Bin - Flash

This week, find out why movie clip symbols are a Good Thing, andlearn to add interactivity to your Flash movies with the built-in Actions.And when you're done, use the new Flash Projector to distribute your moviesto all and sundry. Who needs Hollywood when you can just roll your own?!

  1. Flash 101 (part 5): Spiralling Out Of Control
  2. Recycle Bin
  3. Rebirth
  4. Dynamic Buttons
  5. Mousing Around
  6. Remote Control
  7. Projecting Your Image
By: Vikram Vaswani, (c) Melonfire
Rating: starstarstarstarstar / 5
January 25, 2001

print this article


Thus far, you've learnt how to use two types of symbols: buttons and graphic symbols. However, Flash also allows you to create a third type of symbol - the movie clip.

Unlike buttons and graphic symbols (which are largely static), movie clip symbols are reusable pieces of animation, each with its own Timeline, layers and objects. Think of a movie clip symbol as a mini-movie, which can be dropped into a larger movie and used over and over again.

This may sound a trifle confusing - after all, how can you place one animation clip within another? - but it's not as complicated as it appears. Consider the following situation: you have a Flash clip which includes an object performing some repetitive motion (for example, a ball bouncing up and down, or a segment of blinking text). If your animation clip is a long one, it is tiresome to animate this repetitive movement for the entire length of the clip.

A simpler alternative is to animate the repetitive sequence once, turn it into a movie clip symbol, and then insert this movie clip into the larger Flash movie, where it can play repetitively. And since this is now a symbol, you can reuse the animation sequence at different points in our movie without adding to file size - a significant advantage.

An example might help to make this clearer. Open up a new Flash clip, and create a new movie clip symbol named "spiral-movie". Flash will drop you into symbol-editing mode (you'll notice that this symbol has its own timeline and layers)

Next, create a simple spiral using the various drawing tools - it might look something like this:

Still in symbol-editing mode, convert this spiral object into a graphic symbol, called "spiral-image". You should now see two symbols in your Library, one a movie clip and the other a graphic.

Still in symbol-editing mode, insert a new keyframe at frame #30, and create a motion tween between the frames. On the Frame panel, set the symbol to rotate counter-clockwise as it tweens. You can have it rotate as many times as you like. When you play the clip, you'll see something like this.

Note that this animation sequence is actually a movie clip symbol - if you take a look at its entry in the Library, you'll notice a tiny play/stop button in the preview window, which lets you play the movie clip symbol.

Now that your movie clip symbol has been created and is functioning as advertised, switch back to the Stage. Your Timeline should be empty, with no objects on the Stage.

Drop the movie clip symbol you just created from the Library on to the Stage, and use the Control -> Test Movie command to play the clip. You'll notice that although your Flash clip contains only a single frame, the instance of the movie clip symbol in that frame will play continuously in a loop.

Since the movie clip is a symbol, you can place multiple instances of it on the Stage, and manipulate the visible characteristics of each one - as the following example demonstrates.

Obviously, for repetitive animation, converting the sequence to a movie clip symbol offers numerous advantages: it reduces file size, improves performance, and makes changing object properties a simpler and more efficient process.

This article copyright Melonfire 2001. All rights reserved.

>>> More Flash Articles          >>> More By Vikram Vaswani, (c) Melonfire

blog comments powered by Disqus
escort Bursa Bursa escort Antalya eskort


- An Overview of Flash and ActionScript
- Building Web Forms In Flash
- Building Data-Driven Flash Movies
- Flash 101 (part 6): The Final Countdown
- Flash 101 (part 5): Spiralling Out Of Control
- Flash 101 (Part 4): Don't Touch Me!
- Flash 101 (part 3): Bouncing Around

Developer Shed Affiliates


Dev Shed Tutorial Topics: