It can be activated by a pullchain and by a triggerbox.
I want to add a line to the Default2State script so that it will be activated if it is already open or if it is activated by pullchain.
If it is closed I only want the pullchain to work.
The part of the script that needs conditional added is this section (I think):
auto STATE waiting ; waiting to be activated
EVENT onActivate (objectReference triggerRef)
; Debug.Trace("d2SA RESETS: " + Self + " " + isOpen)
if ( isOpen || (activator is the pullchain) )
; switch open state when activated
SetOpen(!isOpen)
if (doOnce)
gotostate("done")
endif
endif
endEVENT
endState
How do I check to see if the activator was the pullchain and not the triggerbox?