Example #1
0
        public int GetSiblingIndex()
        {
            if (Father.IsNull)
            {
                return(0);
            }
            Transform father = Father.GetAsset(File);

            for (int i = 0; i < father.Children.Count; i++)
            {
                PPtr <Transform> child = father.Children[i];
                if (child.PathID == PathID)
                {
                    return(i);
                }
            }
            throw new Exception("Transorm hasn't been found among father's children");
        }