Creating Multi-part Doors, How I Did It

SylverSylver Join Date: 2003-02-12 Member: 13446Members
At first I wanted to put this as a question, but since I kinda answered it myself, I'll just tell what I did.

<span style='color:white'><b>THE BIG DOOR THAT IS MADE OUT OF MORE THAN ONE PART THAT ALSO MOVE IN DIFFERENT DIRRECTIONS:</b></span>

The first thing I did was create three seperate shapes, and put them together like this:
<!--c1--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>CODE</b> </td></tr><tr><td id='CODE'><!--ec1-->
____________
|                   |
|                   |
|___________|
|         |         |
|_____|_____|

<!--c2--></td></tr></table><span class='postcolor'><!--ec2-->

Now the effect I'm trying to get here is that the upper part A moves up, and the lower parts B and C move left and right, as soon as I approach the door. Then after some time the door must close automatically. When you've got the shapes you want and you've textured them we'll move on to the entity part.

First off: part A
- select the shape and choose 'Tie to entity'
- select 'func_door' from the pulldown menu
In the attributes section, change the following values:
- Name: give the door a name like "door1". be sure to give all the sections the same name!
- Speed: standard is 100, change it if you like, but 100 is recommended
- Move Sound: The sound the door makes when it opens/closes
- Stop Sound: The sound the door makes when it stops opening/closing
- delay before close: change it to whatever you want, I use 4 myself. use -1 and the door won't close again
- Lip: this one might need some explaining:

When a standard door opens, the parts move a distance equal to their own height/width, depending on if they move horizontal/vertikal.
What the Lip does is that it changes that distance, by substractic the Lip value from it. So a door with width 60 and a Lip 5 will move 55 units. You can also use negative values for the Lip.

- Damage...: number of damage inflicted on entities blocking the doors path
- Select 'Up' from the pulldown menu 'Angle' to make the door move up when it opens.
- If you want your door to open if someone uses the 'use' key on it, press the 'flags' tab and check 'use only'

Second: parts B and C
- Same thing as with part A, but change the 'Angle' to different values. You might want to experiment a little on these.

These are the only values I used/changed in my own door, you can change other attributes if you want to.

IMPORTANT:
Make absolutely sure that the moving distance (height/width - lip) devided by the speed is the same for ALL the different parts of the door. Otherwise, the door will open quite weird if you open it at the moment it closes.

<span style='color:white'>EXTRA:</span>
Only follow the following procedure if you want the door to open automatically.

Create another world shape, preferably using the block tool. Change it to the size you want people to walk in it in order to open the door. Position it on both sides of the door. Texture is of no importance. Select the shape and choose 'Tie to entity' again.

- select 'trigger_multiple' from the pulldown menu
- Target: this should be the same as the name you gave your door.

------------
Any questions, comments or whatever are appreciated

Comments

  • ToneeTonee Wub wuB UK Join Date: 2003-10-25 Member: 21926Members, Constellation
    Thanks was gonna be asking this question soner or later for myself anways <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
Sign In or Register to comment.