コード例 #1
0
        public List <GameObject> GetSceneObjectsExceptPlacementGuide()
        {
            List <GameObject> sceneObjects = GetSceneObjects();

            if (ObjectPlacementGuide.ExistsInScene)
            {
                sceneObjects.RemoveAll(item => ObjectPlacementGuide.Equals(item) || ObjectPlacementGuide.ContainsChild(item.transform));
            }

            return(sceneObjects);
        }
コード例 #2
0
        public List <GameObject> GetImmediateChildrenExcludingPlacementGuide()
        {
            List <GameObject> immediateChildren = gameObject.GetImmediateChildren();

            if (ObjectPlacementGuide.ExistsInScene)
            {
                immediateChildren.RemoveAll(item => ObjectPlacementGuide.Equals(item) || ObjectPlacementGuide.ContainsChild(item.transform));
            }

            return(immediateChildren);
        }
コード例 #3
0
 public static bool IsGameObjectPartOfPlacementGuideHierarchy(GameObject gameObject)
 {
     return(ObjectPlacementGuide.ExistsInScene && (ObjectPlacementGuide.Equals(gameObject) || ObjectPlacementGuide.ContainsChild(gameObject.transform)));
 }