Legacy Documentation: Version 5.1
LanguageEnglish
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

PrefabUtility.FindRootGameObjectWithSameParentPrefab

Switch to Manual
public static function FindRootGameObjectWithSameParentPrefab(target: GameObject): GameObject;

Parameters

Description

Returns the topmost game object that has the same prefab parent as target.