Esempio n. 1
0
        static void NewGroupFromSelection()
        {
            ProGroups_Window.NewGroupWithObjects(Selection.gameObjects, Selection.gameObjects.Length > 0 ? Selection.gameObjects[0].name : "New Group");

            if (ProGroups_Window.instance != null)
            {
                ProGroups_Window.instance.Repaint();
                ProGroups_Window.instance.OnSelectionChange();
            }
        }
Esempio n. 2
0
        void OnEnable()
        {
            this.autoRepaintOnSceneChange = true;
            this.wantsMouseMove           = true;
            instance = this;

            icon_Rect      = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Rect.png", typeof(Texture2D));
            icon_SnowFlake = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_SnowFlake.png", typeof(Texture2D));
            icon_Eye       = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Eye.png", typeof(Texture2D));
            icon_Select    = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Select.png", typeof(Texture2D));
            // icon_UpdateGroup     = (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_UpdateGroup.png", typeof(Texture2D));
            icon_MoveUp = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_MoveUp.png", typeof(Texture2D));
            icon_Delete = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Delete.png", typeof(Texture2D));
            icon_Gear   = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Gear.png", typeof(Texture2D));
            icon_Drag   = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Drag.png", typeof(Texture2D));
            icon_Add    = (Texture2D)AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Add.png", typeof(Texture2D));
            // icon_MultiPlus       = (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_MultiPlus.png", typeof(Texture2D));
        }
        void OnEnable()
        {
            this.autoRepaintOnSceneChange = true;
            this.wantsMouseMove = true;
            instance = this;

            icon_Rect 			= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Rect.png", typeof(Texture2D));
            icon_SnowFlake 		= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_SnowFlake.png", typeof(Texture2D));
            icon_Eye 			= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Eye.png", typeof(Texture2D));
            icon_Select 		= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Select.png", typeof(Texture2D));
            icon_UpdateGroup 	= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_UpdateGroup.png", typeof(Texture2D));
            icon_MoveUp  		= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_MoveUp.png", typeof(Texture2D));
            icon_Delete  		= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Delete.png", typeof(Texture2D));
            icon_Gear  			= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Gear.png", typeof(Texture2D));
            icon_Drag  			= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Drag.png", typeof(Texture2D));
            icon_Add  			= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_Add.png", typeof(Texture2D));
            icon_MultiPlus 		= (Texture2D) AssetDatabase.LoadAssetAtPath(guiPath + "ProGroupsIcons_MultiPlus.png", typeof(Texture2D));
        }