So, I’ve got a behavior tree set up, it works when there is a single NPC using it. It can find a player within sensing range, chase them, stop short and attack, and if there’s nobody in range it moves to investigate and if it finds nothing it goes about its patrol path. Pretty simple and not too polished, but it works with just one NPC in my navmesh on my level. The NPC does not ever react to me unless I trigger one of its senses within its defined ranges/etc.
However, when I spawn in multiple NPCs/set up a group of them, as soon as my character goes into the nav mesh, some but not all of the NPCs immediately start running at me. Way out of sensing range, no other NPC should be able to see me so its not an issue of one NPC being set up to alert others. They just immediately come at me like they are somehow herd-sharing senses as well as picking up on my location despite nobody being in range.
It’s been baffling me for a while, so I’m reaching out to see if there’s something I’ve done that’s just obviously wrong here.
I’ve linked my Behavior Tree below:
The issue appears to me to be in the first section, the ChasePlayer section, as if I disconnect everything else, the issue of them immediately chasing to where I am from a mile away still happens. It is worth noting that I’ve tuned the Sight perception value all over, including the Auto Success Range from Last Seen Location setting, which I’ve tuned down to 0 and the issue persists, although it takes the NPCs infinitely longer to get to me since they are losing track of me constantly on their way with that setup.
Linking a few other screenshots that are relevant I think below. Let me know if anything pops out that might be causing this, it is driving me mad!
Long question many attach. Last image below is link to what I have set by default as AI Percetion senses config. Again, even with auto success at 0, they still move about in the distance, indicating they are sensing something that is prompting them to do something other than just fail the whole behavior tree series. They do not currently have patrol paths set and they are not intended to just randomly move about unless they’ve recently seen something for now, so they should just be standing completely still and sensing nothing until I come into range to my understanding of my setup.
I appreciate anything you think might help, as you can see I am very new to this
Lastly, a gif of the issue I am describing.
I haven’t given anyone a patrol path in this, so nothing should be moving at all unless they sense something. I spawned in and did not move and was out of any sensory range I’ve set for AIPerception prior to recording this, but you will notice even the NPCs all the way down the road are shuffling about trying to make their way to me, yet others closer than they are standing still as they should until they too join in on the herd-behavior a bit later.