How to make an object not block AI perception sight?

I am trying to make the default FirstPersonProjectile not block the line of sight of my AI perception because my enemy shoots, stops seeing the player because the projectile spawns near his face, and runs off looking for the player. I looked in the FirstPersonProjectile blueprint but couldn’t find what I was looking for. I was able to make it entirely invisible, but I don’t want that.

Thanks for the help.

See if this answer helps:

Then you need to explain some more. AIPerception, by default, detects actors at their world location. For a character, the world location is around the mid-section (center of capsule). So, if the bullet hits the face then the AI should not be losing sight of the target.

The easiest thing to try is to go into the bullet collision settings and turn the “Visibility” trace response to “Ignore”. Bullets won’t be traced in that channel at all but maybe you don’t need them to. At least, I think the AI is using the Visibility channel.

The better but harder way is to not use the array of perceived actors directly. You use that list to add/remove from your bots “KnownTargets” array. Really, your problem is that the bots have no memories so the minute you dissappear, you don’t exist anymore… Like a baby, you’re playing peek-a-boo. It’s called “object permanence”.

No, the “can ever affect navigation” is already set to false and setting it to true didn’t change anything. Changing the nav mesh didn’t change anything either.

thanks for the reply

I have two internal arrays, one is a list of who is visible right now and one is a list of all known threats. I use the visible list to update the known list and I don’t remove them from the known list just because they aren’t visible.

You can get by with just one internal “known targets” array though, if you prefer.

Here’s my BP code. The incoming array is from the “On Perception Updated (AIPerception)” event. Between the event node and the ForEach loop, I check that the controlling bot IsValid and then I make sure the bot is still alive.

I hope that helps you.

Turning the visability trace response to ignore worked perfectly. I understand what you’re doing with the arrays, but thats a bit more than I want to implement on my first game. I might go back and polish it up later.

Thank you!

Did work for me too, The option “can ever affect navigation” did not help at all