public override void OnInspectorGUI() { SwitchCircuit myScript = (SwitchCircuit)target; if (GUILayout.Button("Activate")) { myScript.Activate(); } DrawDefaultInspector(); }
private void Awake() { _switch = GetComponent <SwitchCircuit>(); }
public override void OnInspectorGUI() { SwitchCircuit myScript = (SwitchCircuit)target; if (GUILayout.Button("Activate")) { myScript.Activate(); } DrawDefaultInspector(); }
private void Awake() { _switch = GetComponent <SwitchCircuit>(); }