オブジェクトの親子関係をスクリプトから操作する方法をまとめてみました。 オブジェクトを取得する 子オブジェクト → 親オブジェクト 子オブジェクトのスクリプトから親オブジェクトを取得します。 using UnityEngine; using System.Collections; public class ChildScript : MonoBehaviour { private GameObject _parent; void Start(){ //親オブジェクトを取得 _parent = transform.root.gameObject; Debug.Log ("Parent:" + _parent.name); } } using UnityEngine; using System.Collections; public class ParentScript : MonoBehav