void InitializeHierarchyIfNeeded() { if (children != null) { return; } parent = CachedGameObject.GetComponentInParent <EntityBehaviour>(true); var childList = new List <EntityBehaviour>(); PopulateChildren(CachedTransform, childList); children = childList.ToArray(); }