Version: Unity 6.6 Alpha (6000.6)
LanguageEnglish
  • C#

GraphMotion.Pause

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public void Pause(NodeReference node);

Parameters

Parameter Description
node The node on which to pause the animation.

Description

Pauses the looping animation on the referenced node's accent without hiding it.

Freezes the looping animation at its current state and keeps the accent bar visible on the node. Call GraphMotion.Play again to resume the animation at the requested speed. If you pause a node that has no active animation there is no visible effect.

 NodeReference nodeRef = context.GetNodeReference(nodeID);
 context.Motion.Play(nodeRef, animationSpeed: 1f);
 // Pause the animation; call Play again to resume.
 context.Motion.Pause(nodeRef);