Page 1 of 1
locked doors
Posted: September 17th, 2010, 9:39 pm
by swift shot01
can someone tell me how to trigger a door to open when i interact with a lever?
Re: locked doors
Posted: September 17th, 2010, 9:49 pm
by chocolatepie33
Set the door to trigger type 11, set the level trigger to #, then place a lever, set the trigger type to 8, then set the level trigger to # (same as door). This should let you open/close the door as the lever is activated each time (trigger 8 is like an on/off trigger).
A more complicated, but possibly better way, is to do this:
place a door mapmodel, hit F3 and change to trigtype 11, levtrig #. Then in another spot, add an invisible model (a -1 value) and change the trigtype to 12 and levtrig to a different #. Save your map, reload it, then go into edit mode and hit F6. Then add this code:
Code: Select all
on_start = [
key1 = 0
]
level_trigger_2 = [ key1 = ( + $key1 1 ) ]
level_trigger_3 = [ if ( > $key1 0 ) [ trigger 3 1 ] ]
levtrig 2 is a key, levtrig 3 is the door. if the key value is more than 0, then the door should lock.
This was based offa Arcones' tut like this.
Re: locked doors
Posted: September 17th, 2010, 9:49 pm
by daltonds1
Like what do you mean?
Give more info
Re: locked doors
Posted: September 18th, 2010, 6:16 am
by Runescapedj
he wants 2 make a locked door, which you can open by touching a lever
Re: locked doors
Posted: September 19th, 2010, 1:06 pm
by swift shot01
would the same thing work for a moving platform or elevator
Re: locked doors
Posted: September 19th, 2010, 2:22 pm
by daltonds1
Umm.. Im sure it would if it doesn't just ask me and ill help you
But actually im not sure if it would.. just go see
Re: locked doors
Posted: September 19th, 2010, 3:39 pm
by chocolatepie33
yes, you can. I think the script's a bit different, but you can. I remember doing this a while back, but I don't remember the exact code...
Sorry if I wasn't much help.