using System.Collections; using System.Collections.Generic; using UnityEditor; using UnityEngine; [CustomEditor(typeof(EZXR.Glass.Inputs.InputSystem))] [CanEditMultipleObjects] public class InputSystemInspector : Editor { private SerializedProperty dynamicMode; private SerializedProperty controllerType; void OnEnable() { dynamicMode = serializedObject.FindProperty("dynamicMode"); controllerType = serializedObject.FindProperty("m_ControllerType"); //Debug.Log($"dynamicMode: {dynamicMode.boolValue}"); //Debug.Log($"controllerType: {controllerType.enumValueIndex}"); } public override void OnInspectorGUI() { EditorGUILayout.PropertyField(dynamicMode); if (!dynamicMode.boolValue) { EditorGUILayout.PropertyField(controllerType); } serializedObject.ApplyModifiedProperties(); } }