Main Page
 The gatekeeper of reality is
 quantified imagination.

Stay notified when site changes by adding your email address:

Your Email:

Bookmark and Share
Email Notification
Project "Flash Movieclip"
Purpose
The purpose of this project is to demonstrate how to call different movie clips in a scene using actionscript and detect when a movie clip has finished playing.

Introduction
Once you have seen how to select different movie clips (symbols you've created and have in your library) from the scene and play them independently (when one movie clip plays the others will not until it is finished), it's quite simple. This could allow you to create different types of animations for a region (or the whole scene) for simulating behaviors or interactivity.

Let's Make A Scene With Multiple Movie clips
This tutorial assumes you are using Adobe Flash 10; the actionscript and movie clip processes should work the same in Flash MX (Flash 6).

STEP 1

(Enlarge)
  1. Drag each movie clip into a separate frame of the scene, starting with frame 2.
STEP 2

(Enlarge)
  1. On the first frame of the scene, add actionscript as shown to enable the random triggering of movie clips in the scene.
STEP 3

(Enlarge)
  1. On each frame of the scene containing a movie clip, plase the stop() actionscript function.
STEP 4

(Enlarge)
  1. Don't forget to provide a name for each frame of the scene so that they can be intuitively referenced.
STEP 5

(Enlarge)
  1. Go into each movie clip. Go to the last frame of a movie clip and add a call to a function that will exist in the scene. This allows you to have the movie clip signal when it is done playing.
STEP 6

(Enlarge)
  1. On the actionscript layer of the scene, add the _global function names (which the last name of each movie clip calls). Finally, "clipChoose" (in this example) generates a random number which determines which frame of the scene to go to and play; this enables the movie clip in the frame to play. The stop() function in each frame prevents the main timeline from moving on to the next frame.
About Joe