コード例 #1
0
ファイル: FR2_Ref.cs プロジェクト: rekart0/Battle-City
        //ref in scene
        public FR2_RefDrawer Reset(string[] assetGUIDs, IWindow window)
        {
            refs  = FR2_SceneRef.FindRefInScene(assetGUIDs, true, SetRefInScene, window);
            dirty = true;
            if (list != null)
            {
                list.Clear();
            }

            return(this);
        }
コード例 #2
0
ファイル: FR2_Ref.cs プロジェクト: rekart0/Battle-City
        public FR2_RefDrawer ResetSceneUseSceneObjects(GameObject[] objs)
        {
            refs  = FR2_SceneRef.FindSceneUseSceneObjects(objs);
            dirty = true;
            if (list != null)
            {
                list.Clear();
            }

            return(this);
        }
コード例 #3
0
ファイル: FR2_Ref.cs プロジェクト: rekart0/Battle-City
        private string GetGroup(FR2_Ref rf)
        {
            // Debug.Log(Lable + "  " + FR2_Setting.GroupMode);
            if (FR2_Setting.GroupMode == Mode.None)
            {
                return(string.Empty);
            }

            if (rf.depth == 0)
            {
                return("Selection");
            }

            FR2_SceneRef sr = null;

            if (rf.isSceneRef)
            {
                sr = rf as FR2_SceneRef;
                if (sr == null)
                {
                    return(string.Empty);
                }
            }

            switch (FR2_Setting.GroupMode)
            {
            case Mode.Extension: return(rf.isSceneRef ? sr.targetType : rf.asset.extension);

            case Mode.Type:
            {
                return(rf.isSceneRef ? sr.targetType : AssetType.FILTERS[rf.type].name);
            }

            case Mode.Folder: return(rf.isSceneRef ? sr.scenePath : rf.asset.assetFolder);

            case Mode.Dependency:
            {
                return(rf.depth == 1 ? "Direct Usage" : "Indirect Usage");
            }
            }

            return(string.Empty);
        }