Mouse.addListener(mouseListener);
The
MovieClip.getNextHighestDepth()
7 or later. If your SWF file includes a version 2 component, use the version 2 components
DepthManager class instead of the
See also
getBounds (MovieClip.getBounds method)
(MovieClip.localToGlobal method)
gotoAndPlay (MovieClip.gotoAndPlay method)
public gotoAndPlay(frame:Object) : Void
Starts playing the SWF file at the specified frame. To specify a scene as well as a frame, use
.
gotoAndPlay()
You can extend the methods and event handlers of the MovieClip class by creating a subclass.
Availability: ActionScript 1.0; Flash Player 5
Parameters
- A number representing the frame number, or a string representing the label
frame:Object
of the frame, to which the playhead is sent.
Example
The following example uses the
frames are loaded. If all of the frames aren't loaded, the
movie clip instance is increased proportionally to create a progress bar.
Enter the following ActionScript on Frame 1 of the Timeline:
var pctLoaded:Number = Math.round(this.getBytesLoaded()/
this.getBytesTotal()*100);
bar_mc._xscale = pctLoaded;
Add the following code on Frame 2:
if (this._framesloaded<this._totalframes) {
this.gotoAndPlay(1);
} else {
this.gotoAndStop(3);
}
Place your content on or after Frame 3. Then add the following code on Frame 3:
stop();
876
ActionScript classes
method used in this example requires Flash Player
MovieClip.getNextHighestDepth()
,
localToGlobal
,
Object
property to start a SWF file when all of the
_framesloaded
method.
property of the
_xscale
loader
Need help?
Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?