Anyone ever done this? Created 15 years ago2008-12-19 22:23:20 UTC by Guinea Pirate Guinea Pirate

Created 15 years ago2008-12-19 22:23:20 UTC by Guinea Pirate Guinea Pirate

Posted 15 years ago2008-12-19 22:23:20 UTC Post #260313
I'm in the progress of making an elevator that does the following:

-When you press the button, and the elevator is not on that floor, it will be called to that floor.
-The elevator itself has doors that open and close and move with the elevator.

Now it sounds simple enough, but I was surprised when I got into it how much logic it required. I drew up a logic diagram and not even halfway through it has become ridiculously complex. I'm gonna try to implement it but I don't even know if it will work.
Posted 15 years ago2008-12-19 22:31:53 UTC Post #260316
the doors can be done with spirit or HL2, but as for the call button, I have no Idea.
Notewell NotewellGIASFELFEBREHBER
Posted 15 years ago2008-12-19 23:25:44 UTC Post #260317
Actually it is possible, it requires use of the entity func_train for both the doors and and elevator and some serious coodination, if you don't have a good working knowledge of func_trains then it is really hard to explain. Basically, all buttons target a multimanager which will first target the doors to close, remember they are trains and that path_corners have the 'wait for retrigger' flag. What the doors do is move sideways to close and then when triggered again they move upwards to a path corner on the second floor. At exactly the same time, trigger the elevator to move up to the second floor with the doors. It doesn't always look perfect but it does the trick. Please let me know if you need more explaining
Posted 15 years ago2008-12-20 02:35:39 UTC Post #260330
I know how it's done, just the control logic is a nightmare. I'm looking to build a foolproof design, so that if someone blocks a door or presses a button while the elevator is operating, it won't affect operation. But I'm an EE student so I'm familiar with the design process for digital logic.
Posted 15 years ago2008-12-20 03:05:54 UTC Post #260331
just make it so it kills the player if they block it. Buttons shouldn't be hard to disable, it doesn't seem... just use masters for them or whatever.

You didn't say whether this is multiplayer or not though. I would assume it is, but single player obviously opens up a lot more possibilities in terms of visual trickery.
Posted 15 years ago2008-12-20 03:29:08 UTC Post #260333
I intend the design to be both for single and multiplayer. So that makes it rather tough. And if a button is pressed while the elevator is in motion, I want it to wait til the elevator has stopped at its destination, then call it back. In other words, very complex logic.
Posted 15 years ago2008-12-20 11:49:44 UTC Post #260339
Have the elevator target a relay for each floor.
The relay targets the buttons to be active only when the elevator has stopped.
Tetsu0 Tetsu0Positive Chaos
Posted 15 years ago2008-12-20 11:59:24 UTC Post #260340
It's going to be pretty tricky, yes. I remember doing this years ago. I ended up with 100+ entities or such. trains, targetchange's, relays, invisible buttons... and I don't know if that was even completely fool-proof.

For multiplayer, I'd go for a simple platform, nothing fancy. Doors slow down gameplay and an elevator that's more often than not on another floor is just too slow for most people.

For singleplayer, it could be useful here and there, but at that point, why not use Spirit to make it yourself easier?
Posted 15 years ago2008-12-20 19:13:14 UTC Post #260366
Possible with a fairly complex train, path, path change, changetarget, button and possibly multisource setup.
Daubster DaubsterVault Dweller
Posted 15 years ago2008-12-20 21:35:05 UTC Post #260371
Ok, so I've figured out what I'd need. For a 2 story elevator, I'd need at least 18 path_corners, 4 buttons, 3 sets of double doors, 1 elevator, 8 changetargets, and a ton of multisources and multimanagers.

Not very practical and an absolute entity nightmare; but it would be a fun challenge to get the whole system working.
Posted 15 years ago2009-02-24 07:44:37 UTC Post #263196
The biggest problem ANY time you have multiple entities moving in synch is that they get out of synch if one is blocked -- and there's no way for you to detect the blockage and trigger the other entities accordingly. The only solution, as srry said, is to apply large amounts of damage so it doesn't actually stop moving.

The rest is all just juggling of path_corners! Good luck! I've got a 3-level (simple platform) lift in my Lab11 level with call buttons at each floor. Adding doors would be intriguingly complicated. Better yet, you really need a pair of doors which moves with the lift, and a pair of doors covering each entry to the lift shaft... ;-) Ooh, now there's a thought...
You must be logged in to post a response.