文档

Unity Engine

Unity Engine

this[]

Returns either the overriding Animation Clip if set or the original Animation Clip named name.
阅读时间1 分钟最后更新于 1 个月前

Definition

  • Type: Property
  • Namespace: UnityEngine
  • Assembly: UnityEngine.AnimationModule

this[string]

Returns either the overriding Animation Clip if set or the original Animation Clip named name.
public AnimationClip this[string name] { get; set; }

Parameters

name

Returns

Type

Description

AnimationClip

Remarks

Note: You should avoid calling this function more than once per frame per Animator as each call will trigger a reallocation of the animator's clip bindings. Instead use AnimatorOverrideController.ApplyOverrides.

this[AnimationClip]

Returns either the overriding Animation Clip if set or the original Animation Clip named name.
public AnimationClip this[AnimationClip clip] { get; set; }

Parameters

Returns

Type

Description

AnimationClip

Remarks

Note: You should avoid calling this function more than once per frame per Animator as each call will trigger a reallocation of the animator's clip bindings. Instead use AnimatorOverrideController.ApplyOverrides.