boolean or for map cap?


josh_u[RR]
04-22-2005, 11:29 AM
is this possible? I have an idea for a map where I want the axis to be able to win by capturing an area OR by getting an object to a destination. can it be done?

Mac50
04-22-2005, 11:51 AM
Yes. Victory can be achieved via the standard way: cap all flags;
in the meantime the round entity can be triggered at any time by an independant phenomenon (in your case the object_cap_area).

josh_u[RR]
04-22-2005, 12:41 PM
thank you...that should have been obvious :rolleyes:

sometimes I overthink everything....

Eric the Pixie
04-22-2005, 06:18 PM
Josh, dunno if this is helpful, but...

You can monitor flag states, or just about anything else by using a multiwatcher entity.

In the multiwatcher entity, you decide what kind of input will make it activate by specifying a boolean test.

Lets say you have two different doors in your map. You could target an env_state entity from each door. When the doors are shut, the env_state entity for each is set to '0'. If any door is opened, it targets the corresponding env_state entity with a toggle (sets it to '1'). If you set the watcher to monitor the two env_state entities (and hence the state of the doors) you can make the watcher trigger another entity by specifying a boolean test for the two inputs.

In other words, if you wanted an alarm to sound if both doors were in the open state, you would specify an 'AND' boolean for the two inputs. When both inputs were true (set to 1) then the boolean condition would be true and the multiwatcher would target a sound entity.

If you wanted the alarm to sound if either door was opened, you would specify an 'OR' boolean test on the two inputs.

You could set up really complex interactions by expanding on this.

Pix

josh_u[RR]
04-22-2005, 07:24 PM
cool, thank you eric. I do have some fairly complex ideas and it sounds like that is the exact entity that I was looking for.

Mac50
04-23-2005, 12:03 PM
You think too much.
:rolleyes: You already have 2 dod_score_ent in your map. They have a name? Yes they do. They can be triggered? Yes they can.
What happens when a dod_score_ent is triggered is simply... the end of the round in favour of the targeted entity :) ... And, it's usually best to keep the entity count low, very low.

josh_u[RR]
04-23-2005, 12:19 PM
you're right mac, I was overthinking THIS problem and your way will definately be the best, but it is nice to know that I can do some boolean stuff for other things I wanted to do. plus, its always nice to learn about how all these entities work...assuming they aren't all completely different in source.

Day of Defeat Forum Archive created by Neil Jedrzejewski.

This in an partial archive of the old Day of Defeat forums orignally hosted by Valve Software LLC.
Material has been archived for the purpose of creating a knowledge base from messages posted between 2003 and 2008.