Graphics Reference
In-Depth Information
4.5.3 Symbols and Control Through Script
The third sample project uses triggers to control nested symbols. This example
illustrates the operation of script-based control through a simple traffic scene in
which a car drives into the scene from the left and drives out the right side of
the image. A traffic light symbol in the background shows two red lights where
the car will stop for one second. The lights turn green, and the car moves again.
Up to this point, the main Timeline was sufficient for all the animations, with-
out any additional procedures. Now, even the wheels of the car are supposed
to turn in a continuous loop and stop temporarily when the car stops. This is
done through the use of nested symbols, which we control from the outside by
means of scripts.
Figure 4.22
Sample project for controlling symbols
with script
First, create a new composition and draw the road and sky with simple
rectangles. Simple forms are all that are needed to create the traffic light.
Initially, the lights have a red background color. We will use keyframes to
switch this to green at about 0:03 seconds.
4 Project
The files for this example can be
downloaded from http://edgebuch.
Project Name: Animation_Car
The car is also composed of simple shapes. To make the rotation of the
wheels more visible, create them in Photoshop. Designing more complex
rims with primitive shapes is too tedious in Edge Animate.
Take all parts of the car, including the wheels, and convert them into a sym-
bol by choosing the Convert to Symbol function in the right-click context
menu. Name the symbol “car” so that we can modify it later via script. The
Autoplay Timeline checkbox is checked. Now we go into the symbol with a
double-click and convert the two wheels to a symbol named “tires.” Again,
double-click the symbol to work within it and create the rotation animation
of both wheels on two separate animation lanes.
Search WWH ::

Custom Search