Flash 8 Documentation |
|||
| ActionScript 2.0 Language Reference > ActionScript classes > MovieClip | |||
Object
|
+-MovieClip
public dynamic class MovieClip
extends Object
The methods for the MovieClip class provide the same functionality as actions that target movie clips. Some additional methods do not have equivalent actions in the Actions toolbox in the Actions panel.
You do not use a constructor method to create a movie clip. You can choose from among three methods to create movie clip instances:
attachMovie() method allows you to create a movie clip instance based on a movie clip symbol that exists in the library.createEmptyMovieClip() method allows you to create an empty movie clip instance as a child based on another movie clip.duplicateMovieClip() method allows you to create a movie clip instance based on another movie clip.To call the methods of the MovieClip class you reference movie clip instances by name, using the following syntax, where my_mc is a movie clip instance:
my_mc.play(); my_mc.gotoAndPlay(3);
You can extend the methods and event handlers of the MovieClip class by creating a subclass.
Availability: ActionScript 1.0; Flash Player 3
|
Modifiers |
Property |
Description |
|---|---|---|
|
|
_alpha |
The alpha transparency value of the movie clip. |
|
|
blendMode |
The blend mode for this movie clip. |
|
|
cacheAsBitmap |
If set to |
|
|
_currentframe |
Returns the number of the frame in which the playhead is located in the movie clip's timeline. |
|
|
_droptarget |
Returns the absolute path in slash-syntax notation of the movie clip instance on which this movie clip was dropped. |
|
|
enabled |
A Boolean value that indicates whether a movie clip is enabled. |
|
|
filters |
An indexed array containing each filter object currently associated with the movie clip. |
|
|
focusEnabled |
If the value is |
|
|
_focusrect |
A Boolean value that specifies whether a movie clip has a yellow rectangle around it when it has keyboard focus. |
|
|
_framesloaded |
The number of frames that are loaded from a streaming SWF file. |
|
|
_height |
The height of the movie clip, in pixels. |
|
|
_highquality |
Deprecated since Flash Player 7. This property was deprecated in favor of Specifies the level of anti-aliasing applied to the current SWF file. |
|
|
hitArea |
Designates another movie clip to serve as the hit area for a movie clip. |
|
|
_lockroot |
A Boolean value that specifies what |
|
|
menu |
Associates the specified ContextMenu object with the movie clip. |
|
|
_name |
The instance name of the movie clip. |
|
|
opaqueBackground |
The color of the movie clip's opaque (not transparent) background of the color specified by the number (an RGB hexadecimal value). |
|
|
_parent |
A reference to the movie clip or object that contains the current movie clip or object. |
|
|
_quality |
Sets or retrieves the rendering quality used for a SWF file. |
|
|
_rotation |
Specifies the rotation of the movie clip, in degrees, from its original orientation. |
|
|
scale9Grid |
The rectangular region that defines the nine scaling regions for the movie clip. |
|
|
scrollRect |
The |
|
|
_soundbuftime |
Specifies the number of seconds a sound prebuffers before it starts to stream. |
|
|
tabChildren |
Determines whether the children of a movie clip are included in the automatic tab ordering. |
|
|
tabEnabled |
Specifies whether the movie clip is included in automatic tab ordering. |
|
|
tabIndex |
Lets you customize the tab ordering of objects in a movie. |
|
|
_target |
Returns the target path of the movie clip instance, in slash notation. |
|
|
_totalframes |
Returns the total number of frames in the movie clip instance specified in the |
|
|
trackAsMenu |
A Boolean value that indicates whether other buttons or movie clips can receive mouse release events. |
|
|
transform |
An object with properties pertaining to a movie clip's matrix, color transform, and pixel bounds. |
|
|
_url |
Retrieves the URL of the SWF, JPEG, GIF, or PNG file from which the movie clip was downloaded. |
|
|
useHandCursor |
A Boolean value that indicates whether the pointing hand (hand cursor) appears when the mouse rolls over a movie clip. |
|
|
_visible |
A Boolean value that indicates whether the movie clip is visible. |
|
|
_width |
The width of the movie clip, in pixels. |
|
|
_x |
An integer that sets the x coordinate of a movie clip relative to the local coordinates of the parent movie clip. |
|
|
_xmouse |
Returns the x coordinate of the mouse position. |
|
|
_xscale |
Determines the horizontal scale (percentage) of the movie clip as applied from the registration point of the movie clip. |
|
|
_y |
Sets the y coordinate of a movie clip relative to the local coordinates of the parent movie clip. |
|
|
_ymouse |
Indicates the y coordinate of the mouse position. |
|
|
_yscale |
Sets the vertical scale (percentage) of the movie clip as applied from the registration point of the movie clip. |
Properties inherited from class Object
|
Event |
Description |
|---|---|
|
onData |
Invoked when a movie clip receives data from a |
|
onDragOut |
Invoked when the mouse button is pressed and the pointer rolls outside the object. |
|
onDragOver |
Invoked when the pointer is dragged outside and then over the movie clip. |
|
onEnterFrame |
Invoked repeatedly at the frame rate of the SWF file. |
|
onKeyDown |
Invoked when a movie clip has input focus and user presses a key. |
|
onKeyUp |
Invoked when a key is released. |
|
onKillFocus |
Invoked when a movie clip loses keyboard focus. |
|
onLoad |
Invoked when the movie clip is instantiated and appears in the timeline. |
|
onMouseDown |
Invoked when the mouse button is pressed. |
|
onMouseMove |
Invoked when the mouse moves. |
|
onMouseUp |
Invoked when the mouse button is released. |
|
onPress |
Invoked when the user clicks the mouse while the pointer is over a movie clip. |
|
onRelease |
Invoked when a user releases the mouse button over a movie clip. |
|
onReleaseOutside |
Invoked after a user presses the mouse button inside the movie clip area and then releases it outside the movie clip area. |
|
onRollOut |
Invoked when a user moves the pointer outside a movie clip area. |
|
onRollOver |
Invoked when user moves the pointer over a movie clip area. |
|
onSetFocus |
Invoked when a movie clip receives keyboard focus. |
|
onUnload |
Invoked in the first frame after the movie clip is removed from the Timeline. |
|
Modifiers |
Signature |
Description |
|---|---|---|
|
|
attachAudio |
Specifies the audio source to be played. |
|
|
attachBitmap |
Attaches a bitmap image to a movie clip. |
|
|
attachMovie |
Takes a symbol from the library and attaches it to the movie clip. |
|
|
beginBitmapFill |
Fills a drawing area with a bitmap image. |
|
|
beginFill |
Indicates the beginning of a new drawing path. |
|
|
beginGradientFill |
Indicates the beginning of a new drawing path. |
|
|
clear |
Removes all the graphics created during runtime by using the movie clip draw methods, including line styles specified with |
|
|
createEmptyMovieClip |
Creates an empty movie clip as a child of an existing movie clip. |
|
|
createTextField |
Creates a new, empty text field as a child of the movie clip on which you call this method. |
|
|
curveTo |
Draws a curve using the current line style from the current drawing position to ( |
|
|
duplicateMovieClip |
Creates an instance of the specified movie clip while the SWF file is playing. |
|
|
endFill |
Applies a fill to the lines and curves that were since the last call to |
|
|
getBounds |
Returns properties that are the minimum and maximum x and y coordinate values of the movie clip, based on the |
|
|
getBytesLoaded |
Returns the number of bytes that have already loaded (streamed) for the movie clip. |
|
|
getBytesTotal |
Returns the size, in bytes, of the movie clip. |
|
|
getDepth |
Returns the depth of the movie clip instance. |
|
|
getInstanceAtDepth |
Determines if a particular depth is already occupied by a movie clip. |
|
|
getNextHighestDepth |
Determines a depth value that you can pass to |
|
|
getRect |
Returns properties that are the minimum and maximum x and y coordinate values of the movie clip, based on the |
|
|
getSWFVersion |
Returns an integer that indicates the Flash Player version for the movie clip was published. |
|
|
getTextSnapshot |
Returns a TextSnapshot object that contains the text in all the static text fields in the specified movie clip; text in child movie clips is not included. |
|
|
getURL |
Loads a document from the specified URL into the specified window. |
|
|
globalToLocal |
Converts the |
|
|
gotoAndPlay |
Starts playing the SWF file at the specified frame. |
|
|
gotoAndStop |
Brings the playhead to the specified frame of the movie clip and stops it there. |
|
|
hitTest |
Evaluates the movie clip to see if it overlaps or intersects with the hit area that the |
|
|
lineGradientStyle |
Specifies a line style that Flash uses for subsequent calls to the |
|
|
lineStyle |
Specifies a line style that Flash uses for subsequent calls to the |
|
|
lineTo |
Draws a line using the current line style from the current drawing position to (x, y); the current drawing position is then set to (x, y). |
|
|
loadMovie |
Loads a SWF, JPEG, GIF, or PNG file into a movie clip in Flash Player while the original SWF file is playing. |
|
|
loadVariables |
Reads data from an external file and sets the values for variables in the movie clip. |
|
|
localToGlobal |
Converts the |
|
|
moveTo |
Moves the current drawing position to (x, y). |
|
|
nextFrame |
Sends the playhead to the next frame and stops it. |
|
|
play |
Moves the playhead in the timeline of the movie clip. |
|
|
prevFrame |
Sends the playhead to the previous frame and stops it. |
|
|
removeMovieClip |
Removes a movie clip instance created with |
|
|
setMask |
Makes the movie clip in the parameter |
|
|
startDrag |
Lets the user drag the specified movie clip. |
|
|
stop |
Stops the movie clip that is currently playing. |
|
|
stopDrag |
Ends a |
|
|
swapDepths |
Swaps the stacking, or depth level (z-order), of this movie clip with the movie clip that is specified by the |
|
|
unloadMovie |
Removes the contents of a movie clip instance. |
Methods inherited from class Object addProperty, hasOwnProperty, isPropertyEnumerable, isPrototypeOf, registerClass, toString, unwatch, valueOf, watch
Version 8
RSS feed | Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/flash/8/main/00002436.html
Comments
Flash Doode said on May 23, 2007 at 1:07 PM :