用户工具

站点工具


侧边栏

script:unityengine:classes:transform:transform.getsiblingindex

Transform.GetSiblingIndex 获取同级索引

JavaScript ⇒ GetSiblingIndex(): int;
C# ⇒ int GetSiblingIndex();

Description 描述

Gets the sibling index.

获取该对象的同级索引。

JavaScript:

Debug.Log(this.transform.GetSiblingIndex());

C#:

using UnityEngine;
using System.Collections;
 
public class Example : MonoBehaviour {
 
	void Start () {
		Debug.Log(this.transform.GetSiblingIndex());
 
	}
}

Transform

script/unityengine/classes/transform/transform.getsiblingindex.txt · 最后更改: 2016/08/02 05:37 (外部编辑)