Skip to main content
TikTok Effect House Platform Logo
Download
लॉग इन करें
Utility

Animation Sequence Controller

Use Animation Sequence Controller control animation sequence playback and its relevant properties. The animation sequence frame index starts from zero. When From is equal to To, only one frame will be played. When the first frame index is greater than the last frame index, the animation sequence is played backward. Animation Sequence Controller is in the Utility category.

Input

NameData typeDescription
PlayExecPlay the animation sequence from the index set in From
StopExecStop the animation sequence playback and turn off the visibility of the current animation component
PauseExecPause the animation sequence playback without turning off the visibility
ResumeExecResume the animation sequence playback from the paused index
ComponentAnimation SequenceThe animation sequence component
FromNumberThe frame index of the animation sequence that will be played first
ToNumberThe frame index of the animation sequence that will be played at last. The maximum available index is the total frame count minus 1.
LoopNumberThe number of times of playing the animation sequence
Stop on LastBoolSelect it to stop the animation sequence playback after playing the last frame

Output

NameData typeDescription
ExitExecExecute the next node
On PlayExecExecute the next node when plays the first frame for the first time
On Each PlayExecExecute the next node when plays the first frame
On Each StopExecExecute the next node when plays the last frame
On StopExecExecute the next node when the animation sequence playback stops
Current FrameNumberThe current playback frame index

Example

In this example, we use the Animation Sequence Controller component to control the play, pause, resume and stop of an animation sequence in Effect House. First of all, we import a texture sequence that is composed of ten images of random questions.

Then we add the Animation Controller to the scene by adding an image entity and then attaching an animation sequence component to that entity. We then replace the texture sequence with the one we have just imported. For the ease of this demo, we uncheck the AutoPlay checkbox on the Animation Sequence component.

We can also play with some parameters to customize the sequence play. For example, here we let the sequence play from the third frame (index 2) to the 9th frame (index 8). Note that animation sequences are 0-indexed in this node.

Then we use the Animation Sequence Controller node to control the sequence. We use the index finger up gesture to trigger the play of animation sequence:

Then we use the Facial Movement Detection node and the Eye Blink event to pause the play of animation sequence. We also use the Victory gesture to trigger the resume of the sequence play. In this case, the sequence will be paused but not disappear.

Last but not least, we use the mouth open event to trigger the stop of the sequence. In this case, the entire animation sequence will disappear.