Another MvM question

Snowbat

L4: Comfortable Member
Apr 23, 2013
165
74
Here's another round of Snowbat's annoying questions:
As you can see on my blueprint once again, there are three possible areas where the bots can spawn. Depending on where the bomb carrier spawns, he will take a certain path: red path, blue path or green flanking path.
The paths are "forced" through a series of nav_avoids. I have a couple of questions concerning this:

1) Each spawn zone (marked by an S on the blueprint), contains a bunch of info_player_teamspawn entities. Each zone has a few of these named spawnbot, one named spawnbot_sentrybuster, one named spawnbot_spy and one named spawnbot_sniper. Except for green zone, that has no spawnbot_sentrybuster.
I guess I should give each spawnzone different names right? For example:

Green zone: spawnbot_flank, spawnbot_sniper_flank, etc
Blue zone: spawnbot_left, spawnbot_sniper_left, etc
Red zone: spawnzone_right, spawnbot_sniper_right, etc

So that whoever makes my waves (*ahem*Alias*ahem*) can choose in what area certain bots spawn?

I got another question about this, but I'll come back to that later because now I really have to go.
 

UKCS-Alias

Mann vs Machine... or... Mapper vs Meta?
aa
Sep 8, 2008
1,264
816
And to add to that, popfile creators can make bots take a random spawn by simply taking both names. This is how they can randomize between left and right without taking the invasion spawn.

Also, sentry busters usualy use main spawn like spawnbot, spawnbot_left and spawnbot_right. They dont realy need a spawnbot_buster. The popfile maker can decide where they spawn, its just that you can hint them to certain spawn with those names.
 

Snowbat

L4: Comfortable Member
Apr 23, 2013
165
74
Allright, thanks but then another question rises.
The popfile determines where the carrier spawns am I right. It tells the carrier to spawn at green, red or blue.
However, I set up a logic_case that forces a random path on the carrier by activating a set of nav_avoids.
What happens if the logic_case selects for example a road that assumes the carrier spawns at blue, but the popfile says it should spawn at red?

I know it might sound kinda confusing but basically, won't both conflict with each other? The logic_case doesn't know what spawnzone the popfile selects. It will just activate a certain path, regardless of what the popfile says.

How do you deal with that? How did they do it in Mannworks for example? Sometimes the carrier spawns on the left side, sometimes on the right.
 

henke37

aa
Sep 23, 2011
2,075
515
The bots will pass avoid areas if there is no other option. "Avoid" is not "impassable".
 

Snowbat

L4: Comfortable Member
Apr 23, 2013
165
74
The bots will pass avoid areas if there is no other option. "Avoid" is not "impassable".
No I don't think you entirely understood the problem.
I think using the uberawesome blueprint again will make it more clear.
Lets say the logic_case decides that the carrier needs to take the red path. It will assume it spawns in red spawnzone and it will then activate the nav_avoids to force it that way. In this case, the relevant nav_avoids are indicated with red boxes with an X in it.

So far so good.

BUT what if the popfile says that the carrier should spawn in blue spawn. When that happens, I want the carrier to follow the blue path. However,since the nav_avoids relevant to blue path are not active, the carrier is gonna go straight through (yellow path) because that's the shortest way and because the red nav_avoids block the blue path anyway.

That's the conflict I'm talking about :)
 

henke37

aa
Sep 23, 2011
2,075
515
You could tag the nav areas and keep them on all the time. Then the pop file just needs to tag the bot and it will pick the path without the map logic needing to do anything.

There is also the option of using prefer areas. Bots are much easier to control when you hack the entire desired path to score highly.
 

WolfKit

L3: Member
Jun 26, 2012
128
83
Could you set up a func_flagdetectionzone in each of the spawn zones and have those trigger the logic_case/nav_avoids?
 

henke37

aa
Sep 23, 2011
2,075
515
You don't need that for the nav areas, the flag carrier has an automatic tag. There is also the filter_tf_bot_has_tag filter entity.
 
Last edited:

Snowbat

L4: Comfortable Member
Apr 23, 2013
165
74
I have nav_prefers set up for all the possible paths the bots can take.
So basically, I can just get rid of the avoids, get rid of the logic_case and let the popfile determine 100% what path is to be used?