Fidcal on 2/8/2003 at 18:55
Rotation has been driving me crazy with doors flying off into the sunset or flipping through hyperspace to a new angle, etc. So I sat down and determined to work out the exact rules. Several hours later on and off I think I've cracked it so I made these notes for myself so I'll never again have to bang my head on the wall over this...
This tutorial only covers rotation and orientation door issues. It does not cover locking, textures, sounds, etc...
A newly created door normally has a H heading of 0 (shown in Dromed at bottom left). This new door is oriented north-south with the hinge to the north and the handle edge to the south at 0. If you change this heading then 90 would put the handle edge to the east, 180 to the north, and 270 to the west, etc.
Change the door's rotation in its properties under door > rotating...
The 'closed angle' and 'open angle' are NOT geographical orientations but OFFSETS from the doors H heading...
ALWAYS LEAVE THE DOOR'S CLOSED ANGLE AT 0.
A door always begins closed even if you trigger it to open at the start. The 'open' state property doesn't seem to work. I can't think of any reason to ever change this closed angle from 0. If you do change it then the door opens and closes normally but just after closing snaps instantly to this closed angle. Since the door always closes to 0 first it will then snap to this setting which makes no sense except for some special effect I guess. Remember, this is an OFFSET from the door's H heading. So even if the door's H heading is at 90 then this 'closed angle' still wants to be 0 NOT 90.
THE DOOR'S OPEN ANGLE
This should be the amount that the door is ajar from its H heading when open. It is nothing to do with the geographical angle of orientation but is an offset from the door's heading.
RECOMMENDED SAFE OPEN ANGLE RANGE:
ANTI-CLOCKWISE : 0 TO 176
CLOCKWISE : 359 TO 184
As the open angle gets near to 180 then door flip errors can occur depending on the door's orientation in the X, Y, and Z planes. I have found the above ranges to be safe but if you do get an odd door flip (eg door snaps to a new place or floats away to the South Pole) then if you are near to 180 then try reducing slightly. In many cases you can get as close as 179 and 181 if you really need to but note that these flip errors sometimes don't occur on the first test so open and close your door several times to make sure!
You will see a checkbox to set clockwise or anti-clockwise. The default depends on the door type; many are clockwise but eg, the gateSmall is anti-clockwise by default.
The anti-clockwise angle is easy to visualize: 45 degrees means the door is 45 degrees ajar, ie, half-open whereas 90 means it is open and 170 means it is wide open with the door virtually swung back to the wall.
The clockwise angle needs to be subtracted from 360, so 45 becomes 315; 90 becomes 270; and 170 becomes 190 for the same example effects only in the opposite direction.
'TURNED' DOOR, EG, TRAPDOOR, CATFLAP
To get eg, a trap door in a roof, set the BANK B to eg, 90 for horizontal, 45 for a sloping roof, coal bunker, etc. This sets the door sloping up from bottom to top with the hinge at the side.
To get the door sloping from side to side with the hinge at the top like a catflap set the P pitch.
The rotation follows the same rules as before: Leave the closed angle at zero and set the open angle at the offset you want, eg, 90 for normal open, 170 for wide open.
The door will normally open UP for anti-clockwise and DOWN for clockwise unless you set the B BANK to greater than 180 (ie, turn the door over)
To get it opening in the direction you want, set the H heading.
Then PORTALIZE (see black pane below)
RESIZING DOORS
After changing the depth D, width W, and H height settings of the door, in the door's properties, change the X, Y, Z settings (respectively) to match exactly in:
Physics > Model > Dimensions
then PORTALIZE (see black pane below)
CENTRE ROTATION & OTHER ROTATION OFFSETS
The door rotation axis offset is set in the door's properties at...
Physics > Model > Attributes > COG Offset
The centre of the door is 0.
X is the offset from the centre if the door is rotating normally along its height axis (even if tilted over as a trapdoor, etc.) so is normally half the width of the door.
Set X to the offset you need, eg, to rotate around an axis one third of the way across the width of the door set X to the door width divided by 3. Double that for two thirds of the way across the door. YOU MUST THEN PORTALIZE (see black pane below)
To rotate around the centre of the door you would expect to set X to 0 but in practice I have found this gives an error and though the door rotates correctly around the centre its speed is infinite so it snaps instantly back and forth instead of rotating. Instead, set X to a minimum of 0.15. This looks pretty central. YOU MUST THEN PORTALIZE. (see black pane below)
You won't normally need to alter the Y or Z settings (leave at 0) unless you are rotating your door oddly, eg, falling away or towards you as you go through it, or rotating along its thin edge, eg, like its sliding to one side and up.
BLACK PANE OF DEATH
If you get a black pane or panel in or near the door this is used to block the vision of AI in the game and is normally not visible. You might get this after resizing the door or changing its rotation axis offset. You should be able to remove it by re-portalizing. If not, undo what you changed and re-portalize and try again then portalize.
As a last resort and a quick fix you can UNcheck the checkbox in the door's properties at...
door > rotating > Blocks vision
... but keep in mind that AI can then see you through the door.
Additional notes from R. Soul:
If a door opens into a hallway the same width as the door itself (ie door 4 units wide, hallway 4 units wide), the door can sometimes dissapear if rotation is set to 90 or 270 as the centre just goes into the solid (happens in Framed near a door leading to the courtyard).
When the hallway is the same width as the door, it may be best to add/subract a few degrees from the doors Open angle. Doors with windows (eg French doors), will benefit from this if their windows disappear when opened.
and:
When double doors are created, the one on the left opens in the opposite direction to the one on the right (and if one opens to 90, the other will open to 270)
Comments and corrections welcome.
R Soul on 2/8/2003 at 19:19
"BEARING"
I think it's actually BANK (Heading, Pitch, Bank - like how the orientation of an aircraft is described).
As far as I know, the rest is correct.
You may want to add:
If a door opens into a hallway the same width as the door itself (ie door 4 units wide, hallway 4 units wide), the door can sometimes dissapear if rotation is set to 90 or 270 as the centre just goes into the solid (happens in Framed near a door leading to the courtyard).
When the hallway is the same width as the door, it may be best to add/subract a few degrees from the doors Open angle. Doors with windows (eg French doors), will benefit from this if their windows disappear when opened.
and:
When double doors are created, the one on the left opens in the opposite direction to the one on the right (and if one opens to 90, the other will open to 270)
It's nice to have so much door stuff in one place
Fidcal on 4/8/2003 at 14:40
R. Soul, you said,
"I think it's actually BANK (Heading, Pitch, Bank - like how the orientation of an aircraft is described)."
Doh! :rolleyes: Of course. My 'bearing' is probably just another name for heading. What was I thinking! And I couldn't remember the P - I was thinking of 'perpendicularity'! Thanks, R. Soul, I'll change it and add your other comments. :thumb:
I'll probably also change what I said about scale. I found yesterday if you change the scale back to 1 then the dimensions shown at the bottom of Dromed also change back.:)
Garrett2014 on 15/1/2015 at 08:17
Where are the doors to be found ? Object Hiearchy ? Too many Tutorials dont consider the Newbie Dromed'r and the basic tutorials seem to just repeat all the same stuff. Sorry for ranting but its such hard work learning new software without a structured manual.
Never mind. Ive found them ! :D Now to make them work :/
fibanocci on 15/1/2015 at 08:27
press F5-->type "*door"
-->physical-->TerrainLike-->Door
Garrett2014 on 15/1/2015 at 09:28
Quote Posted by fibanocci
press F5-->type "*door"
-->physical-->TerrainLike-->Door
Ahh ok thanks. Hadnt refreshed TAB in browser so didnt see your update. Man this is like paying your tax bill. The better you get at it, the more complicated it gets :D
Garrett2014 on 15/1/2015 at 10:00
OK So ive inserted my door into the airbrush between two rooms. I Alt G into game mode and i see the door but the handle is pointing at the floor ! This cant be right. Also it wont open. Can someone break down the steps i need to ensure a standard door opens as you would expect given that the wall thickness / air brush is 2 deep, 4 wide and 8 high. Im trying to learn the basics here and have no idea if i need to 'Do' something other than portalising to update the 'Level' so tat everything works. Thanks again guys. Your Help is much appreciated.
In the tutorial the Door Properties is mentioned. How do i view / edit these anyway ?