Trap door

Discussion in 'Mapping Questions & Discussion' started by Kirko, Feb 27, 2008.

  1. Kirko

    Kirko L2: Junior Member

    Messages:
    58
    Positive Ratings:
    0
    I want to make a trap door in the floor that can be opened by pressing the "use" button(E). I want the door when your above it to open upwards when you press "use". Then when you are under it I want it to fall down from the bottom. I want it to have a timer for it to automatically close too because it will be held by a spring so when u open it from underneath and pull it down there will be a spring that will push it up then when ur above it will just fall down to where the spring holds it in place. So is this possible?
     
  2. MangyCarface

    aa MangyCarface Mapper

    Messages:
    1,616
    Positive Ratings:
    1,275
    So you want a hinged door that opens upwards when you're above it? Not sure why, shouldn't it be the other way around? Anyway take the brush you're using for the door, make it a func_door_rotating and move its origin to the edge you want it to hinge upon. Make two triggers_multiples, below and above the door. Finally add a logic_branch. Now check the flag on the door that says ignore use or whatever. Add an output on the door that says on use test the logic_branch. Now go to the trigger above the door and an output saying on player enter set logic_branch to true. Add another one for the bottom trigger that sets it to false. Finally add two outputs to the logic branch, ontrue make the door open up, onfalse make the door open down. To make the door "spring" shut fool around with the "wait" keyvalue on the door. Try using the setspeed input on the door with a negative value to achieve the direction switch. Hope this helps you
     
  3. MangyCarface

    aa MangyCarface Mapper

    Messages:
    1,616
    Positive Ratings:
    1,275
    Also, to do your spring effect, use a pair of cables (move_rope and keyframe_rope entities) with the flags auto resize selected. Then increase their width and change their texture to make them look spring-y. Parent the move_ropes, which should be positioned on the side of the door furthest from its hinge, to the door. Keep their corresponding keyframes in the frame of the door.
     
  4. Kirko

    Kirko L2: Junior Member

    Messages:
    58
    Positive Ratings:
    0
    Thanks

    Yeah upwards when you're above it like you grab it by a handle and lift then drop down. then it will fall down after u go through. It would be weird to push down on a spring pushed door and going down without the door hitting u in the face in reality.
     
  5. MangyCarface

    aa MangyCarface Mapper

    Messages:
    1,616
    Positive Ratings:
    1,275
    Alright, then also make sure you check the "opens even if blocked" or whatever it's called flag. And the door should probably not be accessible from behind its hingepoint, or it will just open up in the player's face