How to deal damage to AI?

Hello,

I was looking for some AI tutorials nut the most of them where pretty useless so I tried myself.
At first I want just a shootable NPC. I managed it by adding to ‘Hitboxes’ (Sphere and Capsule Component) add an Event on Hit and change the Health variable.
The Problem is the it’s not working everytime. The head hitbox works great everytime, the body hitbox works sometimes from the front but never from the sides and the back.
If I’m workin with only 1 hitbox it’s working everytime (like the head hitbox). The question is why is this happening and how is the best way to deal damage by a projectile?

Thank you!

I’m on mobile so here is my guess, the reason your event doesn’t trigger is probably from your mesh extrude out side of collision capsules, and somehow your skeleton mesh also have collision enabled and generate hit events. if this happens, then your skeleton mesh eats away the hit enent and your capsule does not get hit by projectile.

try see the settings on your skeleton mesh and turn off collision than try again.

Thank you. I was just looking for the root capsule component and ignored the mesh collision. Now with the mesh collision off it’s working just great!