AnimationState.layer 层

var layer : int

Description描述

The layer of the animation. When calculating the final blend weights, animations in higher layers will get their weights distributed first.

动画层。当计算最终混合权重时,高层的动画优先获得他们优先分发的权重。

Lower layer animations only receive blend weights if the higher layers didn't use up all blend weights.

只有较高层没有使用全部权值时,较低层才能接收混合权值。

using UnityEngine;

using System.Collections;



public class example : MonoBehaviour {

	public void Awake() {

		animation["Walk"].layer = 1;

		animation["Run"].layer = 1;

	}

}

// Puts the walk and run animation in layer 1

// 置walk 和 run动画到层1



animation["Walk"].layer = 1;

animation["Run"].layer = 1;

Page last updated: 2011-2-23