What's New in Director 8.5 > Working with Flash 5 > tellTarget, endTellTarget |
![]() |
tellTarget, endTellTarget
Syntax
sprite(whichSprite
).tellTarget("targetName
"), sprite(whichSprite
).endTellTarget()
Definition
Commands; equivalent to Flash's beginTellTarget
and endTellTarget
methods. The tellTarget
command allows the user to set a target Timeline on which subsequent sprite commands will act. When the target is set to a Flash movie clip or a level containing a loaded Flash movie, certain commands act on the targeted components, rather than on the main Timeline. To switch focus back to the main Timeline, call endTellTarget()
.
The only valid argument for tellTarget
is the target name. There is no valid argument for endTellTarget
.
The Flash sprite functions that are affected by tellTarget
are stop
, play
, getProperty
, setProperty
, gotoFrame
, call(frame)
, and find(label)
. In addition, the sprite property frame
(which returns the current frame) is affected by tellTarget
.
Examples
This command sets the movie clip as the target:
sprite(1).tellTarget("\myMovieClip")
This command stops the movie clip:
sprite(1).stop()
This command causes the movie clip to play:
sprite(1).play()
This command sets the focus back to the main Timeline:
sprite(1).endTellTarget()
This command stops the main movie:
sprite(1).stop()
![]() |