http://www.gamesas.com/index.php?/topic/1067015-scripting-questions/page__view__findpost__p__15504216
I'm only concerned about the door timers though.
---------------------------------Entry |1| |2|---------------x-----------------
Door 1 is open by default, Door 2 isn't. x is the switch that toggles the state of both doors so when you walk in door 1 will close before door 2 can open. I've got this part working, but both doors activate at the same time. So I tried using the VaultDOORscript but all that does is delay both doors and they still open together. What I need is something that works like this;
1. When the switch is activated it would probably be a good idea to lock it out for 12 seconds until it can be used again.
2. If Door 1 is open, close immediately. If Door 1 isn't closed, wait 10 seconds and then make it open.
3. If Door 2 is open, close immediately. If Door 2 isn't closed, wait 10 seconds and then make it open
Below is my attempt at translating this into something the game can use. I bet I've missed something (please help if you can)
scn ContDoorScriptfloat timerBegin Onactivate if isactivated == 0 set isactivated to 1 endifendBegin GameMode if isactivated == 1 ;If the switch is activated, qualify the following conditions: elseif Door1.GetOpenState == 1 ;If door1 is open Door1.SetOpenState 0 ;close it immediately Door 2.GetOpenState ==1; If door2 is open Door2.SetOpenState 0 ;close it immediately endif elseif elseif Door1.GetOpenState == 0 ;If door1 is closed if timer > 10 ;and 10 seconds have passed, Door1.SetOpenState 1 ;open door1. Door2.GetOpenState == 0 ;If door2 is closed if timer > 10 ;and 10 seconds have passed, Door2.SetOpenState 0 ;open door2. endif endifend