ClipTransition Class

Summary

A serializable Animancer.ITransition which can create a particular type of Animancer.AnimancerState when passed into Animancer.AnimancerPlayable.Play(Animancer.ITransition).
graph BT Type-->Base0["AnimancerTransition<ClipState>"] Base0-->Base1["Object"] Type-.->Interface0["ITransitionDetailed"] click Interface0 "/animancer/api/Animancer/ITransitionDetailed" Type-.->Interface1["ITransitionWithEvents"] click Interface1 "/animancer/api/Animancer/ITransitionWithEvents" Type-.->Interface2["IHasEvents"] click Interface2 "/animancer/api/Animancer/IHasEvents" Type-.->Interface3["ClipState.ITransition"] click Interface3 "/animancer/api/Animancer/ITransition" Type-.->Interface4["ITransition<ClipState>"] Type-.->Interface5["ITransition"] click Interface5 "/animancer/api/Animancer/ITransition" Type-.->Interface6["IHasKey"] click Interface6 "/animancer/api/Animancer/IHasKey" Type-.->Interface7["IPolymorphic"] click Interface7 "/animancer/api/Animancer/IPolymorphic" Type-.->Interface8["IMotion"] click Interface8 "/animancer/api/Animancer/IMotion" Type-.->Interface9["IAnimationClipCollection"] click Interface9 "/animancer/api/Animancer/IAnimationClipCollection" Type["ClipTransition"] class Type type-node Derived0["ClipTransitionSequence"]-->Type click Derived0 "/animancer/api/Animancer/ClipTransitionSequence" Derived1["RootMotion.MotionTransition"]-->Type click Derived1 "/animancer/api/Animancer.Examples.Locomotion/MotionTransition"

Syntax

[Serializable]
public class ClipTransition : AnimancerTransition<ClipState>, ITransitionDetailed, 
    ITransitionWithEvents, IHasEvents, ClipState.ITransition, ITransition<ClipState>, ITransition, 
    IHasKey, IPolymorphic, IMotion, IAnimationClipCollection

Remarks

Documentation: Transitions

Attributes

Type Description
SerializableAttribute

Properties

Name Value Summary
AverageAngularSpeed float
The initial UnityEngine.Motion.averageAngularSpeed that the created state will have.
AverageVelocity Vector3
The initial UnityEngine.Motion.averageSpeed that the created state will have.
Clip AnimationClip
[UnityEngine.SerializeField] The animation to play.
FadeMode FadeMode
If this transition will set the Animancer.AnimancerState.Time, then it needs to use Animancer.FadeMode.FromStart.
IsLooping bool
[Animancer.ITransitionDetailed] Returns UnityEngine.Motion.isLooping.
IsValid bool
Can this transition create a valid Animancer.AnimancerState?
Key Object
Returns the Animancer.ClipTransition.Clip to use as the Animancer.AnimancerState.Key.
MainObject Object
The Animancer.AnimancerState.MainObject that the created state will have.
MaximumDuration float
The maximum amount of time the animation is expected to take (in seconds).
NormalizedStartTime float
The Animancer.AnimancerState.NormalizedTime to start the animation at.
Speed float
The Animancer.AnimancerNode.Speed to play the animation at.

Methods

Name Value Summary
Apply(AnimancerState) void
Called by Animancer.AnimancerPlayable.Play(Animancer.ITransition) to apply any modifications to the `state`.
CreateState() ClipState
Creates and returns a new TState.
GatherAnimationClips(ICollection<AnimationClip>) void
[Animancer.IAnimationClipCollection] Adds the Animancer.ClipTransition.Clip to the collection.