How to block a door with a cube properly?
I tried several workarounds, but I can't seem to get it to work properly. I tried to trigger DisableMotion on the cube, but then the door just moves through the cube. Changing the mass of the cube also had no succes, and trying to trigger some func_push brushes also had little succes.
I'm trying workarounds that are just insane, there has to be a better option, that I've overlooked. Can someone enlighten me? Because I'm spending too much time on a small problem now.
- Pushes on block until its shot out or destroyed (fairly short timeframe, but it WILL happen).
- Immediately opens when obstruction is in the way (but I think it will keep trying, and eventually moves the cube).
There is a flag for these two behaviosr; I think its "forceclosed" or something.
In my own work (I have a couple of puzzles where this might occur, and at least one where its important that it does), I've never wanted any long-term opening of the door, and am mostly interested in giving the player a small window to time to get past. . . the above was sufficient for me.
for each side of the door actually use 2 func doors one pareneted to the other. Much like Piston lifts where the pistons expand and contract.
Lets call them Base Door and Func Door as the Base door has no models parented to it, only the Func door. The Func door has the actual door models parented to it.
Now each kind of door would move the door models a little, if you only opened the func door they would stop half opened since the actual doors are thinner than the door model.
Place a trigger in the doorway which is only triggered by the cube, make this trigger disable whatever mechanism is actually closing the Base door, so only the Func door closes, and seems to be jammed open. I usually close doors by Endtouch triggers on either side of the door, you would need to make a seperate one for the Func and Base doors in this example, then just disable one for the door to no fully close.
Hope this helps, note that this idea has not been tested but was thought of on the fly 
OnBlockedClosing
OnBlockedOpening
The func_door have some interesting outputs:
http://developer.valvesoftware.com/wiki/Func_door
Want to try?
Hurricaaane wrote:
Want to try?
Yes 
Maybe I'm wrong, but that's what I'm starting to think.
Edit:
Oh wait, I forgot the block filter... Or no, that was Half-Life: Source only...
Edit2:
Okay, the best workaround seems to be to put a disabled trigger_multiple between the doors, with a filter for the box(es). Let it set the speed of the doors to -1 and movement to Open once it's enabled (shortly after the door closes). Just speed to 0 or -1 didn't seem to work. Maybe add a little delay so it looks better. Make sure the speed is set first, before the movement is set.