Exemplo n.º 1
0
 //-------------------------------------------------
 void OnEnable()
 {
     if (Selection.activeTransform != null)
     {
         VRTRIXGloveTelportArea teleportArea = Selection.activeTransform.GetComponent <VRTRIXGloveTelportArea>();
         if (teleportArea != null)
         {
             teleportArea.UpdateVisualsInEditor();
         }
     }
 }
Exemplo n.º 2
0
        //-------------------------------------------------
        public override void OnInspectorGUI()
        {
            DrawDefaultInspector();

            if (Selection.activeTransform != null)
            {
                VRTRIXGloveTelportArea teleportArea = Selection.activeTransform.GetComponent <VRTRIXGloveTelportArea>();
                if (GUI.changed && teleportArea != null)
                {
                    teleportArea.UpdateVisualsInEditor();
                }
            }
        }