#

API Docs for: 1.4.0
Show: Inherited Protected Private Deprecated

# MovieClip Class

Extends Sprite
Defined in: `src/pixi/display/MovieClip.js:5`
Module: PIXI

A MovieClip is a simple way to display an animation depicted by a list of textures.

## Constructor

### `MovieClip`

(

- `textures`

)

Defined in `src/pixi/display/MovieClip.js:5`

#### Parameters:

- `textures` Array

  an array of {Texture} objects that make up the animation

- Index
- Methods
- Properties

## Item Index

### Methods

- gotoAndPlay
- gotoAndStop
- play
- stop

### Properties

- animationSpeed
- currentFrame
- loop
- onComplete
- playing
- textures
- totalFrames

## Methods

### `gotoAndPlay`

(

- `frameNumber`

)

Defined in `src/pixi/display/MovieClip.js:126`

Goes to a specific frame and begins playing the MovieClip

#### Parameters:

- `frameNumber` Number

  frame index to start at

### `gotoAndStop`

(

- `frameNumber`

)

Defined in `src/pixi/display/MovieClip.js:112`

Stops the MovieClip and goes to a specific frame

#### Parameters:

- `frameNumber` Number

  frame index to stop at

### `play`

()

Defined in `src/pixi/display/MovieClip.js:102`

Plays the MovieClip

### `stop`

()

Defined in `src/pixi/display/MovieClip.js:92`

Stops the MovieClip

## Properties

### `animationSpeed`

Number

Defined in `src/pixi/display/MovieClip.js:25`

The speed that the MovieClip will play at. Higher is faster, lower is slower

Default: 1

### `currentFrame`

Number

Defined in `src/pixi/display/MovieClip.js:51`

[read-only] The index MovieClips current frame (this may not have to be a whole number)

Default: 0

### `loop`

Boolean

Defined in `src/pixi/display/MovieClip.js:34`

Whether or not the movie clip repeats after playing.

Default: true

### `onComplete`

Function

Defined in `src/pixi/display/MovieClip.js:43`

Function to call when a MovieClip finishes playing

### `playing`

Boolean

Defined in `src/pixi/display/MovieClip.js:61`

[read-only] Indicates if the MovieClip is currently playing

### `textures`

Array

Defined in `src/pixi/display/MovieClip.js:17`

The array of textures that make up the animation

### `totalFrames`

Number

Defined in `src/pixi/display/MovieClip.js:75`

[read-only] totalFrames is the total number of frames in the MovieClip. This is the same as number of textures assigned to the MovieClip.

Default: 0