Version: 2017.3 (switch to 2017.4)
LanguageEnglish
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

AnimationUtility

class in UnityEditor

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

Description

Editor utility functions for modifying animation clips.

Static Properties

onCurveWasModifiedTriggered when an animation curve inside an animation clip has been modified.

Static Methods

CalculateTransformPathCalculates path from root transform to target transform.
GetAnimatableBindingsReturns all the animatable bindings that a specific game object has.
GetAnimatedObjectReturns the animated object that the binding is pointing to.
GetAnimationClipsReturns the array of AnimationClips that are referenced in the Animation component.
GetAnimationEventsRetrieves all animation events associated with the animation clip.
GetCurveBindingsReturns all the float curve bindings currently stored in the clip.
GetEditorCurveReturn the float curve that the binding is pointing to.
GetFloatValueRetrieves the current float value by sampling a curve value on a specific game object.
GetKeyBrokenRetrieve the specified keyframe broken tangent flag.
GetKeyLeftTangentModeRetrieve the left tangent mode of the keyframe at specified index.
GetKeyRightTangentModeRetrieve the right tangent mode of the keyframe at specified index.
GetObjectReferenceCurveReturn the object reference curve that the binding is pointing to.
GetObjectReferenceCurveBindingsReturns all the object reference curve bindings currently stored in the clip.
SetAdditiveReferencePoseSet the additive reference pose from referenceClip at time for animation clip clip.
SetAnimationClipsSets the array of AnimationClips to be referenced in the Animation component.
SetAnimationEventsReplaces all animation events in the animation clip.
SetEditorCurveAdds, modifies or removes an editor float curve in a given clip.
SetKeyBrokenChange the specified keyframe broken tangent flag.
SetKeyLeftTangentModeChange the specified keyframe tangent mode.
SetKeyRightTangentModeChange the specified keyframe tangent mode.
SetObjectReferenceCurveAdds, modifies or removes an object reference curve in a given clip.

Delegates

OnCurveWasModifiedTriggered when an animation curve inside an animation clip has been modified.
对文档有任何疑问,请移步至开发者社区提问,我们将尽快为您解答