xxxxxxxxxx
by V-Jankaitis on the Unity Forum
public static Transform GetTopLevelChildren(Transform Parent)
{
Transform[] Children = new Transform[Parent.childCount];
for (int ID = 0; ID < Parent.childCount; ID++)
{
Children[ID] = Parent.GetChild(ID);
}
return Children;
}