Last active
August 21, 2017 16:04
-
-
Save GordeyChernyy/aebcfd0082bb8530093dcf277f2759eb to your computer and use it in GitHub Desktop.
Unity Editor script for hide/unhide selected. Put this script into Assets/Editor folder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEditor; | |
public class KeyboardShortcuts : EditorWindow { | |
[MenuItem("Window/KeyboardShortcuts/1 _h", false, 999)] | |
static void HideSelection () { | |
foreach (GameObject obj in Selection.gameObjects) { | |
if ( obj.activeSelf) { | |
obj.SetActive (false); | |
} | |
else { | |
obj.SetActive (true); | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment