!!!GameObjectの種類やstaticなどの情報を取得 GameObjectを取得後、そのGameObjectの情報を取得します。 GameObject g = GameObject.Find("xxxx"); // GameObjectを検索. として、あらかじめGameObjectを取得。 !! 形状名を取得 string name = g.name; !! Static状態を取得 bool activeF = g.isStatic; GameObjectがStaticかどうか。 !! アクティブ状態を取得 bool activeF = g.activeSelf; GameObjectがアクティブかどうか。 なお、GameObject.Findは非アクティブのGameObjectを検索できません。 「[[シーン階層をたどる|unity_script_search_hierarchy_gameobject]]」の手順でtransformをたどることにより、非アクティブのものもたどれます。 ---- {{lastmodified}}