このコンポーネントはゲームオブジェクトにアタッチされます。コンポーネントはいつもゲームオブジェクトにアタッチされています。
print (gameObject.name);
using UnityEngine; using System.Collections; public class ExampleClass : MonoBehaviour { void Example() { print(gameObject.name); } }
import UnityEngine import System.Collections public class ExampleClass(MonoBehaviour): def Example() as void: print(gameObject.name)