"And" conditional statement in Hammer?

Radaka

L420: High Member
May 24, 2009
491
244
I'm having a problem currently with spawn room doors, using the startTouchAll and endTouchAll triggers on a trigger_multiple. The map is set to unlock the doors at the start of each round, and the doors work fine, unless you are already touching them right as the round starts. In that case, you have to back up and retry to get the door to open.

Onto the meat though :)

I need to preform a check such as:

If player is touching door and setup time is finished -> Open door

how would I do this :confused:

thank you!
 

zornor

L4: Comfortable Member
Jan 14, 2009
195
23
Have a trigger_multiple, set it up like a normal door trigger, outputs and everything. BUT, set it to start as disabled.

On the round timer, send an output to this trigger_multiple. OnSetupFinished -> Enable.

Now it should only open when setup ends. Make sure you also uncheck the "Touch Opens" flag on the door ;D
 

III_Demon

L2: Junior Member
Sep 28, 2008
57
29
have you tried enabling the trigger on round start, instead of unlocking the door?

someone more experienced than me can probably answer the AND condition question...

[edit]lookit that. beat by 3 minutes, and better. =] what he said!
 
Jan 31, 2008
555
1,482
For a more complete "and" operator in hammer, I recommend you use a math_counter.
Set the max value to 2. Each time one condition is met, it adds one. If the other one is also met, the counter adds up to 2. If your max is 2, then the math_counter will send an output.