Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Override standard gizmos and handles in editor

Discussion in 'Scripting' started by DrDecipher, Sep 12, 2014.

  1. DrDecipher

    DrDecipher

    Joined:
    Dec 5, 2012
    Posts:
    54
    It is possible to intercept and override the keyboard shortcuts.

    Does anyone know how I might go about intercepting the Handles or Gizmos calls?

    I'd like to change the light gizmos and drawing on top of the existing ones would create clutter. Ideally I'd like to override them with new ones.

    Thanks Doc
     
  2. LightStriker

    LightStriker

    Joined:
    Aug 3, 2013
    Posts:
    2,716
    You'll have to write a custom editor for it...

    Code (CSharp):
    1.     [CanEditMultipleObjects]
    2.     [CustomEditor(typeof(Light), true)]
    3.     public class LightEditor : Editor
    4.     {
    With the "OnSceneGUI" method.
     
  3. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    If you're on OS X you can override any regular menu shortcut in any program via system preferences, at least.
     
  4. DrDecipher

    DrDecipher

    Joined:
    Dec 5, 2012
    Posts:
    54
    Wonderful thank you!