AnimatorStateTransition

class in UnityEditor.Animations

/

Inherits from:Animations.AnimatorTransitionBase

Switch to Manual

Description

过渡了定义状态机在何时以何种方式从一种状态切换为另一种状态。AnimatorStateTransition 始终源自一个 Animator State(或 AnyState)并有时间参数。

当所有过渡条件都满足时,过渡就会发生。AnimatorStateTransition 派生自 AnimatorTransitionBase

Variables

canTransitionToSelf设置为 true 可允许或禁止在 AnyState 过渡期间向自身过渡。
duration过渡持续时间。
exitTimeIf AnimatorStateTransition.hasExitTime is true, exitTime represents the exact time at which the transition can take effect. This is represented in normalized time, so for example an exit time of 0.75 means that on the first frame where 75% of the animation has played, the Exit Time condition will be true. On the next frame, the condition will be false. For looped animations, transitions with exit times smaller than 1 will be evaluated every loop, so you can use this to time your transition with the proper timing in the animation, every loop. Transitions with exit times greater than one will be evaluated only once, so they can be used to exit at a specific time, after a fixed number of loops. For example, a transition with an exit time of 3.5 will be evaluated once, after three and a half loops.
hasExitTime生效时,过渡将有一个退出时间条件。
hasFixedDuration确定过渡的持续时间是以秒还是标准化时间为单位在固定的持续时间报告。
interruptionSource哪个 AnimatorState 过渡可以中断过渡。
offset目标状态的开始时间。
orderedInterruption过渡可被具有较高优先级的过渡中断。

Constructors

AnimatorStateTransition创建新的 Animator State 过渡。

Inherited members

Variables

conditions过渡发生需要满足的 AnimatorCondition 条件。
destinationState过渡的目标状态。
destinationStateMachine过渡的目标状态机。
isExit作为当前状态机退出的过渡目标。
mute关闭过渡。过渡永远不会发生。
solo关闭源状态的所有其他过渡。
hideFlagsShould the object be hidden, saved with the Scene or modifiable by the user?
name对象的名称。

Public Functions

AddConditionUtility 函数,用于添加一个过渡条件。
RemoveConditionUtility 函数,用于删除过渡条件。
GetInstanceID返回对象的实例 ID。
ToString返回 GameObject 的名称。

Static Functions

Destroy删除 GameObject、组件或资源。
DestroyImmediate立即销毁对象 /obj/。强烈建议您改用 Destroy。
DontDestroyOnLoadDo not destroy the target Object when loading a new Scene.
FindObjectOfType返回第一个类型为 type 的已加载的激活对象。
FindObjectsOfType返回所有类型为 type 的已加载的激活对象的列表。
Instantiate克隆 original 对象并返回克隆对象。

Operators

bool该对象是否存在?
operator !=比较两个对象是否引用不同的对象。
operator ==比较两个对象引用,判断它们是否引用同一个对象。