AI Behavior Tree Worked fine, loaded the project today and now fails

My Behavior tree is very simple.

  • Find a Path Point from :
    BP_PatrolPath(Actor)
  • Move to the path point vector defined
  • Wait

I was able to get it working among adding other tasks and I just recently had an issue where the character just STOPPED. No matter what I do, the live blueprint debug bounces back and forth between FindPathPoint and the Move to within the Behavior Tree
Below are my blueprints:

  1. Find PathPoint(BT _Task):
  2. Base_WW_AI_controller
  3. BehaviorTree

Behavior Tree while running, again bounces between FindPathPoint and Move To see below:

I have my navmesh, set the Ai Character to use the controller. Almost all variables are editable. Am I missing something?
Any thoughts would be very helpful!

Your nav mesh isn’t building perhaps?

I thought it wasn’t so I deleted the entire Nav Mesh bounds + the Recast. I still got the same issue.

Another thought was possibly the AI_Character had an issue, so then I ended up pointing all variables to a new AI_Character I had. I adopted the same controller, blackboard, and Behavior tree. Same result.

When I go to simulate the game and then set the node: FindPathPoint_C_0 in Base_WW_AI_Controller as a Debug filter, it seems to be working as it should, however, the AI are still frozen and the Behavior tree keeps bouncing between FindPathPoint and Move To.

Try checking if the cast is failing? A simple print string on the fail would tell you as much in PIE.

Usually when you get a bounce between a condition and a move to the issue is that the character cannot move.
This could be due to a myriad of things really.
Chief being a bad nav mesh (hence first suggestion).

You can test if it can move with a simple AI move to node called manually from level BP on key input. If your AI won’t go to the location it’s somehow physically stuck.
This could also be because of bad collision on a sub-component or something similar.

Thank you for the suggestion, i will try testing it later today to see if it works with the simple moveTo and if it’ll react accordingly. I will update my findings here. Thank you [USER=“3140864”]MostHost LA[/USER]

[USER=“3140864”]MostHost LA[/USER] ; I used your suggestion and found that the cast was failing, the issue that I found is, the patrolPath Actor was set to two AI characters I placed in the world and it was being received by both. When i need a patrol path actor for each character on patrol.

I fixed that issue by removing all unnecessary AI Characters, and am still receiving the same “Bouncing” Issue with the Behavior tree.

While simulating the game, I can click on the AI character and it will print a bunch of data. One entry i thought was interesting was the “NavData” it doesnt display anything there. Would this be the issue? Even though I can clearly see a navmesh and it definitely rebuilds any time I move the NavMeshBounds volume?

I really appreciate your assistance thus far.

Please see below for screenshots: Navmesh.PNG.jpg

Found the solution. I had placed the Navigation Mesh into one of the Streaming Levels and not the Persistent Level.
I realized after I noticed the recast would disappear after I simulated the game. Everything works now!
Thanks for all your assistance! [USER=“3140864”]MostHost LA[/USER] !

You could try to use NavInvokers and a navmesh in the persistent that covers the whole world.

before you modify the navmesh size go to project settings and enable the option to only build around invokes.

Then you add the invoker to your AI, and you can modify its values if you need a bigger area of navmesh built around them.

Works great for open world with world comp, so it should work perfect on level streaming too.

Thank you! I will try that, that sounds like a better solution in terms of performance as well.