Combining a ladder and a door

Combining a ladder and a door

Re: Combining a ladder and a door Posted by still_CJ on Thu Nov 20th 2003 at 9:56pm
still_CJ
23 posts
Posted 2003-11-20 9:56pm
still_CJ
member
23 posts 2 snarkmarks Registered: Sep 7th 2003
I'm trying to create a feature where the players see a ladder leaning against some boxes, providing access to an obviously broken light fitting. What they need to do is pivot the ladder to lean in the opposite direction to get access to a duct entrance (yeh, I know, but every level needs at least one duct). I can get the ladder pivotable by creating it as rotating door, with the origin at the bottom and the pivot in the x axis. Snag is, I can't group the func_door_rotating with the necessary func_ladders (one each side of the ladder textured door)..

I'm considering creating the ladder as a door, with a ladder on one side then, when moved by the players using a multimanager to kill the original func_ladder and create a new one in the new position, but I'm not 100% sure this will work. Before I spend a lot of time on this, does anyone have a better solution.

Thanks,

CJ
Re: Combining a ladder and a door Posted by Neural Scan on Thu Nov 20th 2003 at 10:14pm
Neural Scan
150 posts
Posted 2003-11-20 10:14pm
150 posts 85 snarkmarks Registered: Jun 28th 2003 Occupation: Student Location: England.
I'm not sure about this, but there's something called 'Spirit of Half Life', and basically it's the same as half life, but with added features you can do with entities and stuff. It's just an 'improvement' on the original half life fgd, in the form of a mod (like tfc or cs).

With Spirit you can add a 'moves with' thingy, which allows you to do things like you asked here (moving ladders with doors or platforms). All you gotta do is search for Spirit of Half Life and download it, then set up the fgd and everything in Hammer or whatever program you use, then you load up the mod and test it out.

Fun thing is Spirit comes with a short map which displays some of the capabilities that Spirit offers.

I don't know of any other way of doing what you asked, so I just went with what I knew.
Re: Combining a ladder and a door Posted by Dr Brasso on Thu Nov 20th 2003 at 10:29pm
Dr Brasso
1878 posts
Posted 2003-11-20 10:29pm
1878 posts 198 snarkmarks Registered: Aug 30th 2003 Occupation: cad drafter Location: Omaha,NE
how about this.....

create yer ladderfrom a func_rot_door so it pivots....on the opposite side of the ladder, create your func ladder with aaa texture and clip it so that when the ladder is pivoted, it drops just inside the boundaries of the func ladder ....no fuss, no muss....mission accomplished

itll still look like yer going up the ladder(which is in reality a func_rot_door) but youll in actuality be using the func ladder.....follow?

Doc brass... :dodgy:
Re: Combining a ladder and a door Posted by Dr Brasso on Thu Nov 20th 2003 at 10:29pm
Dr Brasso
1878 posts
Posted 2003-11-20 10:29pm
1878 posts 198 snarkmarks Registered: Aug 30th 2003 Occupation: cad drafter Location: Omaha,NE
damn double post....grrr
Re: Combining a ladder and a door Posted by Gollum on Thu Nov 20th 2003 at 11:05pm
Gollum
1268 posts
Posted 2003-11-20 11:05pm
Gollum
member
1268 posts 525 snarkmarks Registered: Oct 26th 2001 Occupation: Student Location: Oxford, England
Doc, unless I've misunderstood you, your solution has the actual func_ladder entity staying in its final position all the time. That would mean there is an invisible ladder that can be climbed without moving the visible func_door_rotating.

Unfortunately I don't believe that you can turn on a func_ladder by triggering it :sad: This means that there is no perfect solution to your problem. If a ladder exists, it can be removed by killtargeting, but you can't spawn a new one. However, you could cover the func_ladder with a func_wall_toggle. This would stop the player from going up the ladder, but he would also be unable to walk through the space it occupies - so this solution only works if the final position of the ladder is flush against a wall.

The func_wall_toggle can be triggered to allow the player up the new ladder, and the old ladder can be killtargeted.

Spirit of Half-Life will almost certainly allow you to do this, as Neural Scan has said (although it's more than just an FGD improvement....that would be useless on its own).
Re: Combining a ladder and a door Posted by Gollum on Thu Nov 20th 2003 at 11:19pm
Gollum
1268 posts
Posted 2003-11-20 11:19pm
Gollum
member
1268 posts 525 snarkmarks Registered: Oct 26th 2001 Occupation: Student Location: Oxford, England
Ha! I've just thought of a possible cunning alternative that should work in situations where the ladder, instead of being flush with a wall, is leaning at an angle.

Make a very steep series of steps along the path of the ladder. If the steps are thin enough, then the player will "teleport" up them instead of standing on any individual step (this is a bizarre feature of the player movement code). The steps should have only a one-unit depth each, so that they don't touch the ground.

Test that this works in a "normal" situation. The player should move very quickly up the steps, despite the extremely steep angle. Now make this into a func_door and make it invisible (see Hornpipe's correction below). The func_door should be set to rise out the ground when you push the "ladder", and will substitute for a real func_ladder.

Obviously you will need to adjust the steps for the required length and angle of the ladder. Note that if the ladder is at an angle of 45 degrees or less, you don't even need to bother with the steps but can just use a uniform slope.

Also, depending on which is least likely to get in the way, you could make the func_door appear out of the ceiling or the walls. Bear in mind that it must not be blocked, or it will bounce back or damage the player until he gets out the way (if you set the delay before reset to -1). Another option is to use a func_wall_toggle instead, but then you must be careful to prevent the player becoming stuck inside the wall when it toggles on! If necessary you can use trigger_push entities to force the player out of the way of the door/wall.
Re: Combining a ladder and a door Posted by Dr Brasso on Thu Nov 20th 2003 at 11:22pm
Dr Brasso
1878 posts
Posted 2003-11-20 11:22pm
1878 posts 198 snarkmarks Registered: Aug 30th 2003 Occupation: cad drafter Location: Omaha,NE
well, not knowing the layout or actually seeing what hes trying to do, i suppose yer right....i defer to my more enlightened counterpart..... :biggrin:

Doc Brass.... :dodgy:

sure would like to see what hes doing tho.... :wink:

ps....i freakin love the way yer mind works mikee.... :lol: reminds me of a more educated me.... :heee:

i also just had a thought..... :lol: you dont have a sex life either do you... :rofl:

////runs like hell on fire....W00T! :outtahere:
Re: Combining a ladder and a door Posted by Gollum on Thu Nov 20th 2003 at 11:38pm
Gollum
1268 posts
Posted 2003-11-20 11:38pm
Gollum
member
1268 posts 525 snarkmarks Registered: Oct 26th 2001 Occupation: Student Location: Oxford, England
Dr Brasso said:
i also just had a thought..... :lol: you dont have a sex life either do you... :rofl:
Now that was below the belt. But actually, I find a good hardcore editing puzzle always warms me up for night-time frolics. Oh yes.

chases Brasso away with apocryphal Pringles tube
Re: Combining a ladder and a door Posted by Hornpipe2 on Fri Nov 21st 2003 at 2:02am
Hornpipe2
636 posts
Posted 2003-11-21 2:02am
636 posts 123 snarkmarks Registered: Sep 7th 2003 Occupation: Programmer Location: Conway, AR, USA
Uh... Don't texture it with NULL - any face covered with NULL is not just invisible, it's not even there! Zoner's Compile Tools discards every face painted with NULL during the compile.

Instead, cover it with {BLUE. Then, when you set up the door, make the render mode Solid and the FX amount 255. That way it will still exist but will not be visible.

Another solution - If the player cannot get to where the ladder's final position (e.g. it's not in the middle of the room but more against the wall or something) then you could put down a func_ladder and completely surrounding that a func_wall covered with clip. Now the climbable ladder already exists, but the player can't reach it because it's surrounded by the larger func_wall. When the player Uses the func_rotating visual part of the ladder, set the Killtarget to the name of the invisible func_wall so it deletes the wall around the ladder, thus the player can reach it and climb up. Nyet? (You might also try Target instead of Killtarget, that way it just turns the wall off instead of deleting it... for example if you wanted a way to put the ladder back where it was)

EDIT: Crap, that was exactly what Gollum was just suggesting. Carry on.
Re: Combining a ladder and a door Posted by Tracer Bullet on Fri Nov 21st 2003 at 4:37am
Tracer Bullet
2271 posts
Posted 2003-11-21 4:37am
2271 posts 445 snarkmarks Registered: May 22nd 2003 Occupation: Graduate Student (Ph.D) Location: Seattle WA, USA
Gollum said:
Ha! I've just thought of a possible cunning alternative that should work in situations where the ladder, instead of being flush with a wall, is leaning at an angle.

Make a very steep series of steps along the path of the ladder. If the steps are thin enough, then the player will "teleport" up them instead of standing on any individual step (this is a bizarre feature of the player movement code).
So you can make the player move up a very steep slope without a ladder? intriguing. I'll have to find a way to use that.
Re: Combining a ladder and a door Posted by Cash Car Star on Fri Nov 21st 2003 at 8:20am
Cash Car Star
1260 posts
Posted 2003-11-21 8:20am
1260 posts 345 snarkmarks Registered: Apr 7th 2002 Occupation: post-student Location: Connecticut (sigh)
Orph did it in his map for the first SP mapping contest, Double Trouble. It works fine going up but coming down feels rather rocky.
Re: Combining a ladder and a door Posted by Loco on Fri Nov 21st 2003 at 8:29am
Loco
615 posts
Posted 2003-11-21 8:29am
Loco
member
615 posts 121 snarkmarks Registered: Aug 29th 2003 Occupation: Student Location: UK
If you want Spirit, you can find it on http://spirit.valve-erc.com, and the new Spirit 1.2 also comes with the Dark Truths Particle engine...
Re: Combining a ladder and a door Posted by Gollum on Fri Nov 21st 2003 at 10:54am
Gollum
1268 posts
Posted 2003-11-21 10:54am
Gollum
member
1268 posts 525 snarkmarks Registered: Oct 26th 2001 Occupation: Student Location: Oxford, England
Hornpipe2 said:
Uh... Don't texture it with NULL - any face covered with NULL is not just invisible, it's not even there! Zoner's Compile Tools discards every face painted with NULL during the compile.
Actually that's a good point. You can make entirely nulled entities (I do), and they will still work, but they won't be solid.

In fact, it doesn't matter what texture you use (well, as long as it's not sky or origin etc.). Setting an entity to rendermode solid and renderamount 0 will make it invisible, and the game won't draw its polygons (there is a difference).

edits answer
Re: Combining a ladder and a door Posted by still_CJ on Sat Nov 22nd 2003 at 8:45am
still_CJ
23 posts
Posted 2003-11-22 8:45am
still_CJ
member
23 posts 2 snarkmarks Registered: Sep 7th 2003
Thanks guys. Gollums idea certainly works and is easy to implement.

I've ticked him as the answer.

CJ