Attaching a ToggleElement instead of a ColliderElement works the same way but keeps track of its on/off state so you can do things like turn a light on/off with repeated button presses.
ToggleElement has the following properties to control its behaviour:
In addition to the OnEnter/OnExit events that it inherits from ColliderElement, ToggleElement adds the following additional Unity event triggers:
You can also trigger the toggle to change state by a Unity event in the Inspector using the following methods:
All other options are identical to ColliderElement.