Page 1 of 2

shooting doors to open them (health)

Posted: Tue Dec 30, 2003 6:41 pm
by m4rine
I have a func->rotating door with an origin and everything working fine. However I want this door to be shot open, and i have tried key:health value:100 (and i have tried loads of other values ranging from 1 to 400)but it doesn't seem to work. It won't open; and it wont be shot open. I have posted about this before about almost a year ago, but i got no solution.

I have also tried the door without 'health' set, but in the console when i try to open it it says 'Door is jammed'. I supposed this was something to do with the numerous models surrounding my door, which don't visually touch the door, but the boundry of them (in the 2d view, when they are selected) does. But that's not the main problem; i can easily remove the models if possible.

I wonder if I should attempt to set 'health' in my script? Or would this have no effect if the key/values wouldn't work?

Anyway, another theory of mine (they're all probably way off the mark) is that some of the other key/values i have set interfere with this setting. There are no checkboxes set. This is a list of the settings:

Key - Value
classname - func->rotatingdoor //well, obviously this is ok
angle - 90 //doubt this is a problem
alwaysaway - 1 //unsure, see below*
health - 100 //obviously a problem - it doesnt work

*Can I use key:alwaysaway value:1 on this door? Because I would want the door to be shot open away from the player. This may be causing the problem, but i am positive i have tested it with and without this setting and both have the same affect: a door that won't, in any way, open.

Anyway, that's about it. I have included the most information I thought relevent, i know how anoying if people post 'My door won't work, please help me!' and don't give any symtoms or information like what type of door it is (I'm talking about posts in general there; not just posts about doors).

Any help would be absoblutely great (i've been trying to get this sorted for so long; and i have tried myself to get it working, and there are so many better mappers than me at .map).

Cheers,

m4rine

Posted: Tue Dec 30, 2003 9:53 pm
by wacko
seems not to work. but u can script it like
make the door (doorbrush+originbrush) not a func_rotatingdoor but a script_object (with e.g. targetname/door)
place 2 func_multiple on each side (with e.g. setthread/open1 or setthread/open2, and DAMAGE checked)

and do a script like

Code: Select all

open1:
	$door time 1
	$door rotateYdown 90
	$door waitmove
	wait 5
	$door time 1
	$door rotateYup 90
	$door waitmove
end

open2:
	$door time 1
	$door rotateYup 90
	$door waitmove
	wait 5
	$door time 1
	$door rotateYdown 90
	$door waitmove
end

Posted: Tue Dec 30, 2003 11:29 pm
by bdbodger
For your func_rotateingdoor set the targeted flag

make a trigger_multiple and set the damage flag

Have the trigger target the door and have it covering it .

shoot the door :)

Posted: Tue Dec 30, 2003 11:37 pm
by wacko
:oops: looks a bit easier, i should have triggered more brains before posting :roll:

scripted

Posted: Wed Dec 31, 2003 3:37 am
by tltrude
You can also have the trigger_multiple run a setthread like this.

door_1_opener:

local.player = parm.other
$door_1 open local.player

end

Or, you can use a script_origin (with a targetname) as a fake player. Doing that comes in handy for remote doors. Be sure to set your trigger to "not_player" or it will open when a player just touches the trigger.

Another option is to just make the door a func_crate.

Posted: Thu Jan 01, 2004 1:59 am
by omniscient
alwaysaway doesnt do anything, and probably never will, u might aswell take it out, though i dought it is ur problem.

Posted: Thu Jan 01, 2004 6:57 pm
by m4rine
omniscient wrote:alwaysaway doesnt do anything, and probably never will, u might aswell take it out, though i dought it is ur problem.
Um, sorry do disagree with you but, yes alwaysaway does do something. It does exactly what it says - makes the door open always away from you. But you have to team it up with something - here is how it should work (and believe me it does):

If you want the door to open always away from the player, enter key/value alwaysaway/1.
Now, give the door a key/value angle/***, where *** depends on how your door is positioned in the top-view:
A | like door gets no angle or 0 or 180
a ----- like door gets an angle of 90 or 270 .
A / like door gets 135 and a \ gets 45. Always perpendicular to the door brush.

I have tried and tested it, it works :wink:

Posted: Fri Jan 02, 2004 2:40 am
by omniscient
the angels work without alwaysaway, but alwaysaway wont work without an angle so i dont see why u would bother putting it in.

Posted: Fri Jan 02, 2004 3:47 am
by small_sumo
For a cs map I did once I had a little breakable chunk around the door knob. You shoot and break that bit and it triggers the regular old door to open.

Posted: Fri Jan 02, 2004 7:51 am
by bdbodger
If you use both ideas the setthread and trigger you can do that sumo . The trigger does not have to cover the door it can cover a script_object that looks like a chain or something and the setthread can explode it useing the global/exploder.scr with the exploderfire model being one from the models/emitters directory , what does the adamspark.tik look like?.

Posted: Fri Jan 02, 2004 8:27 am
by tltrude
m4rine -- Alwaysaway 1 is default for rotating doors, so setting it is redundent. Alwaysaway 0 will make the door open only in the direction of the set angle.

Posted: Fri Jan 02, 2004 2:54 pm
by Krane
I'm with omniscient: this thing never worked with me. I've try what tltrude says and....0..nothing. I was always very curious about that issue...So I use the angle stuff. :?

Posted: Fri Jan 02, 2004 3:52 pm
by m4rine
um.. i aint just sayin this but, really, it worked for me. My door used to open away one direction and towards me the other - alwaysaway sorted that for me.

o well, prob my brain :?

angle

Posted: Fri Jan 02, 2004 5:21 pm
by tltrude
The default angle, if no angle is set, is 0 (same as 360). So, if your door is facing that direction, it will work normally with no angle set. But, doors on the other axis must have the angle set correctly.

Image

A door with a bad angle will sometime appear to work fine, depending on which side of the door (left or right) you are looking at when you hit use.

You don't have to take my word for it, you can make a test map like the one above. Try "alwaysaway 1" on the bad doors and you'll see it does nothing. Then try "alwaysaway 0" on the good doors--they will only open one way. My Door2 tutorial map has some "alwaysaway 0" doors--kitchen cupboards and the elevator doors below.

http://pages.sbcglobal.net/tltrude/Temp/door2.zip

Image

Posted: Fri Jan 02, 2004 8:26 pm
by m4rine
actually it was Wacko who first told me about alwaysaway - see this post - scroll down till you see his reply.

i still stand by my word - it worked for me.

cmon wacko, back me up pls!