Class AnimationPlayer

Class Hierarchy

Use the Animation Player to play back an animation timeline that you set using the TimelineProperty property in that Animation Player. Kanzi resolves paths to animated nodes relative to the node where you attach an Animation Player.

To control the playback of an Animation Player, send these messages to the node where you attached the Animation Player:

  • PlayMessage to start an animation timeline.
  • PauseMessage to pause a running animation timeline.
  • ResumeMessage to resume a paused or stopped animation timeline.
  • StopMessage to stop a running or paused animation timeline.

By default, an Animation Player does not start playback until you send the PlayMessage message to the node. To set an Animation Player to start the playback when you attach the Animation Player to a node, enable the AutoplayEnabledProperty property.

When you start the playback of an Animation Player by sending to it the PlayMessage or ResumeMessage message, or if the AutoplayEnabledProperty property is enabled, the player adds its timeline as a child to a parallel timeline and applies all playback settings from its PlaybackModeProperty, DurationScaleProperty and RepeatCountProperty properties to it. If you start the playback by sending a PlayMessage message with playback arguments, the player adds its parallel timeline as a child to yet another parallel timeline and applies playback settings from the PlayMessageArguments to it.

Controls animation playback.

Inherits properties and message types from AnimationPlayerMetadata.

Synopsis

Methods
create()

Creates animation player

AnimationPlayer.AnimationPlayer:create(name)

Creates animation player.

Parameters
name (string)

Name of animation player.

Return Values
(AnimationPlayer)

animation player.