61
Chapter 4: Sprites
A
sprite
is an object that controls when, where, and how cast members appear in an Adobe
®
Director
®
movie.
Multiple sprites can use the same cast member. You can also switch cast members assigned to a sprite as the movie
plays. Use the Stage to control where a sprite appears, and use the Score to control when it appears in your movie.
Sprites appear on the Stage layered according to the channel in which they are assigned in the Score. Sprites in
higher-numbered channels appear in front of sprites in lower-numbered channels. A movie can include as many as
1000 sprite channels. Use the Movie tab of the Property inspector to control the number of channels.
Sprite properties include the sprite’s size and location, the cast member assigned to the sprite, the sprite’s name, and
the frames in which the sprite occurs. Different properties can alter the appearance of a sprite. You can rotate, skew,
flip, and change the color of sprites without affecting cast members. You can change sprite properties with the
Property inspector or Lingo or JavaScript syntax.
The Filters property of a sprite enables you to apply effects to any non-Direct To Score sprite, using the Filters tab in
the Property inspector. For more information about filters, see
Bitmap filters
.
You can also give each sprite a unique name. You can assign a name by using the Property inspector, and then view
the sprite by name in the Score and on the Stage. Assigning a name lets you refer to the sprite by that name in Lingo
or JavaScript™ syntax and not just by the channel number that it occupies. You can move a sprite to a different
channel and not worry about changing scripts. Editing scores and code scripts is much easier when you refer to a
sprite by its name.
In Lingo or JavaScript syntax, some properties are available only for certain types of sprites. Such properties typically
are characteristics that are related to the specific sprite type. For example, Lingo or JavaScript syntax has several
digital video properties that determine the contents of tracks in digital video sprites.
Creating sprites
Create a sprite by dragging a cast member to either the Stage or the Score; the sprite appears in both places. New
sprites, by default, span 30 frames.
1
Click to select the frame in the Score where you want the sprite to begin.
2
From the Cast window, in either List or Thumbnail view, do one of the following:
•
Drag a cast member to the position on the Stage where you want to place the sprite.
•
Drag a cast member to the Score. Director places the new sprite in the center of the Stage.
•
To create a sprite one frame long, press Alt (Windows®) or Option (Mac®) and drag a cast member to the
Stage or Score.
Setting sprite general preferences
Use the Sprite Preferences dialog box to control the way sprites behave and appear in the Score window and on the
Stage.