AnimationGraphPlayer
Plays an animation graph and exposes its parameters, layers, and events.
Behavior
AnimationGraphPlayer plays an animation graph and exposes its parameters, layers, and events.
Summary
The runtime type name.
The AnimationGraph used by this player.
Whether playback is currently active.
The runtime value name.
The animation priority used to resolve competing joint poses.
The root-motion transform produced by graph playback.
Speed: numberThe playback speed multiplier.
The active state name, or nil when no state is active.
Weight: numberThe current blend weight.
AdjustSpeed(speed: number): ()Changes the playback speed multiplier.
AdjustWeight(weight: number, fadeTime: number?): ()Changes the target blend weight over the supplied fade duration, in seconds.
CrossFade(state: string, fadeTime: number?, layer: string?): ()Changes to the target state with the supplied fade duration, in seconds.
Destroy(): ()Stops playback and releases this playback object.
Fire(name: string): ()Sets the named trigger parameter.
Get(name: string): number | booleanReturns the current value of a numeric or boolean graph parameter.
GetLayer(name: string): AnimationGraphLayerReturns the control interface for the named graph layer.
GetLayers(): { AnimationGraphLayer }Returns the graph's layer control interfaces.
GetMarkerReachedSignal(name: string): AstScriptSignal<string, string>Returns the signal for the named animation marker.
GetParameters(): { [string]: number | boolean }Returns the current numeric and boolean graph parameters.
GetState(layer: string?): string?Returns the active state of the selected layer.
IsA(className: string): booleanReturns whether the value matches the supplied type name.
Play(fadeTime: number?): ()Starts playback with optional fade, weight, or speed parameters.
ResetTrigger(name: string): ()Clears the named trigger parameter.
Set(name: string, value: number | boolean): ()Sets a numeric or boolean graph parameter.
Stop(fadeTime: number?): ()Stops playback with an optional fade duration, in seconds.
Travel(state: string, layer: string?): ()Requests a transition path to the target state through the graph's transitions.
Fires when playback reaches an animation marker.
Fires when the active graph state changes.
Fires when playback stops.
Properties
ClassName
AnimationGraphPlayer.ClassName: stringThe runtime type name.
Graph
AnimationGraphPlayer.Graph: AnimationGraphThe AnimationGraph used by this player.
IsPlaying
AnimationGraphPlayer.IsPlaying: booleanWhether playback is currently active.
Name
AnimationGraphPlayer.Name: stringThe runtime value name.
Priority
AnimationGraphPlayer.Priority: EnumItemThe animation priority used to resolve competing joint poses.
RootMotion
AnimationGraphPlayer.RootMotion: CFrameThe root-motion transform produced by graph playback.
Speed
AnimationGraphPlayer.Speed: numberThe playback speed multiplier.
State
AnimationGraphPlayer.State: string?The active state name, or nil when no state is active.
Weight
AnimationGraphPlayer.Weight: numberThe current blend weight.
Methods
AdjustSpeed
AnimationGraphPlayer:AdjustSpeed(speed: number): ()Changes the playback speed multiplier.
AdjustWeight
AnimationGraphPlayer:AdjustWeight(weight: number, fadeTime: number?): ()Changes the target blend weight over the supplied fade duration, in seconds.
CrossFade
AnimationGraphPlayer:CrossFade(state: string, fadeTime: number?, layer: string?): ()Changes to the target state with the supplied fade duration, in seconds.
Destroy
AnimationGraphPlayer:Destroy(): ()Stops playback and releases this playback object.
Fire
AnimationGraphPlayer:Fire(name: string): ()Sets the named trigger parameter.
Get
AnimationGraphPlayer:Get(name: string): number | booleanReturns the current value of a numeric or boolean graph parameter.
GetLayer
AnimationGraphPlayer:GetLayer(name: string): AnimationGraphLayerReturns the control interface for the named graph layer.
GetLayers
AnimationGraphPlayer:GetLayers(): { AnimationGraphLayer }Returns the graph's layer control interfaces.
GetMarkerReachedSignal
AnimationGraphPlayer:GetMarkerReachedSignal(name: string): AstScriptSignal<string, string>Returns the signal for the named animation marker.
GetParameters
AnimationGraphPlayer:GetParameters(): { [string]: number | boolean }Returns the current numeric and boolean graph parameters.
GetState
AnimationGraphPlayer:GetState(layer: string?): string?Returns the active state of the selected layer.
IsA
AnimationGraphPlayer:IsA(className: string): booleanReturns whether the value matches the supplied type name.
Play
AnimationGraphPlayer:Play(fadeTime: number?): ()Starts playback with optional fade, weight, or speed parameters.
ResetTrigger
AnimationGraphPlayer:ResetTrigger(name: string): ()Clears the named trigger parameter.
Set
AnimationGraphPlayer:Set(name: string, value: number | boolean): ()Sets a numeric or boolean graph parameter.
Stop
AnimationGraphPlayer:Stop(fadeTime: number?): ()Stops playback with an optional fade duration, in seconds.
Travel
AnimationGraphPlayer:Travel(state: string, layer: string?): ()Requests a transition path to the target state through the graph's transitions.
Events
MarkerReached
AnimationGraphPlayer.MarkerReached: RBXScriptSignalFires when playback reaches an animation marker.
StateChanged
AnimationGraphPlayer.StateChanged: RBXScriptSignalFires when the active graph state changes.
Stopped
AnimationGraphPlayer.Stopped: RBXScriptSignalFires when playback stops.
Operators
__type