CharacterController Class
Character Controller class is designed to play animated sequences on the timeline. This is a flexible way to animate characters on a timeline
Item Index
Methods
Methods
_animationComplete
()
private
When the animation has completed playing
clear
()
Clear any animations for the current character
destroy
()
Don't use after this
gotoFrameAndStop
-
event
If we want to play a static frame
Parameters:
-
event
StringThe frame label to stop on
initialize
()
Initiliazes this Character controller
playClips
-
clips
-
callback
-
interruptable
-
cancelPreviousCallback
-
allowFrameDropping
Will play a sequence of animations
Parameters:
-
clips
Arrayan array of CharacterClip objects
-
callback
FunctionCallback for when the animations are either done, or have been interrupted. Will pass true is interrupted, false if they completed
-
interruptable
BoolIf calling this can interrupt the current animation(s)
-
cancelPreviousCallback
BoolCancel the callback the last time this was called
-
allowFrameDropping
BoolIf frame dropping is allowed for this frame, if the Animator is doing frame drop checks
setCharacter
-
character
Set the current character, setting to null clears character
Parameters:
-
character
createjs.MovieClipMovieClip
startNext
()
Start the next animation in the sequence
Properties
_allowFrameDropping
Bool
private
If frame dropping is allowed for this animation set
_character
createjs.MovieClip
private
The current character
_destroyed
Bool
private
If this instance has been destroyed
_interruptable
Bool
private
If the current animation choreographies can't be interrupted
_loops
Int
private
Current number of loops for the current animation