Ai not attacking updated health

So I just started using unreal engine and I am new to all of the programming and such. I made an Ai enemy and a health bar for myself. He will attack my health bar as it should but after I regenerate my health he doesn’t attack the updated percent but the previous percentage I was at before I picked up more health.

Hey @Llamalover2003! Welcome to the forums!

Can you show the code you’re using? We should be able to figure it out pretty quickly if you show any relevant code! It’s probably something to do with saving a value somewhere you shouldn’t or something like that.

Get back to us soon and let’s get you rolling again! :slight_smile:

I am seeing almost everything… What about your damage event on your player? That would call UpdateHealthUI as well, correct? The only time I’m seeing it called is the one that sets current health and Max health to the same value on OnComponentBeginOverlap (Box).

Hey @Llamalover2003 ! Did you get it figured out? Let us know how it’s going! :slight_smile: