Unity Engine documentationScript ReferenceUnity.HierarchyHierarchyFlattenedNodeDepthThe depth of the node.Read time 1 minuteLast updated 13 days agoDefinition Type: Property Namespace: Unity.Hierarchy Assembly: UnityEngine.HierarchyCoreModule public int Depth { get; }