Page 1 of 1

AI completely ignoring barriers...

Posted: Wed Sep 07, 2011 8:20 pm
by Locutus
Well, the title says it basically: The AI ignores one of my barriers at all.
Hidden/Spoiler:
Image
I made a conquest map and then I decided to add CTF1 mode.
Everything is working fine but due to the changed cp layout in this mode I needed to change a couple of objects etc.
When I run conquest I've added this line to my lua:

Code: Select all

DisableBarriers("Barrier192") 
and for ctf:

Code: Select all

  BlockPlanningGraphArcs("Connection48")
  BlockPlanningGraphArcs("Connection50")
  BlockPlanningGraphArcs("Connection58")
  BlockPlanningGraphArcs("Connection59")
  BlockPlanningGraphArcs("Connection109")
This is how it looks in the ZE (the red marked barrier is the one ignored):
Hidden/Spoiler:
Image
So in conquest the bots ignore the barrier as they should but in ctf they're totally ignoring it.
I've tried everything that came into my mind, cleaned the munger etc but with no success...

Any idea why or how I can avoid this?

Re: AI completely ignoring barriers...

Posted: Wed Sep 07, 2011 11:01 pm
by Cerfon Rournes
Try this.
Just add the barriers you want to be in ctf mode, to the ctf layer. It should work fine.

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 12:34 am
by DarthFannel
Cerfon Rournes wrote:Try this.
Just add the barriers you want to be in ctf mode, to the ctf layer. It should work fine.
Unless I am missing something, barriers are present in all layers.

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 12:58 am
by Noobasaurus
Try putting them in the base layer.

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 9:36 am
by FragMe!
DarthFannel wrote:
Cerfon Rournes wrote:Try this.
Just add the barriers you want to be in ctf mode, to the ctf layer. It should work fine.
Unless I am missing something, barriers are present in all layers.
You should be able to have different sets of barriers (and paths for that matter) for different game modes as was mentioned. You just put them into a layer that is associated with that mode, eg conquest, ctf, 1flag. The only time you would need to put them into a lua is if they were all on one common layer (easier if 90% are common and you only want to disable a few)
By the same token if you only want to block AI from going to a certain area in one mode, add just that barrier to that modes layer.

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 4:15 pm
by Locutus
Mhhh, I've tried adding barriers to both layers (base and ctf) but with no success. I placed about 5 barriers between the spawnpoints but that didn't help - the AI still gets stuck in the wall.
But the AI is aware of all other barriers (except for 2 solder-only barriers which they ignore when playing ctf (and only in this mode)).
Image
I'm really getting mad about this, my map would be complete if there wasn't just this !X@? barrier...

Any other ideas what I can try except for "redoing base layout"?

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 4:28 pm
by CressAlbane
I've had problems before with the AI ignoring the barriers if the mode is CTF. I think they try to run straight toward the flag, yes? I think it has something to do with the AI trying to get the flag picked up (like if it was dropped behind barriers) I coudln't find a fix though.

Re: AI completely ignoring barriers...

Posted: Thu Sep 08, 2011 4:51 pm
by Locutus
Nearly.
The bots run to the flag and get it and then they return to their own cp from where're trying to reach the enemy base as it seems to be the shortest route (pic from my last post).