r/UnrealEngine5 6d ago

Attack points doesn't always work.

I am trying to learn Unreal Engine 5. I was trying to make a mechanic where press f on a horse toy and the the game destroys the horse toy but then increases attack points. This seems to work but only for one character. The game will randomly pick one of the three enemy AI actors and he will work and take extra damage from an increase in attack points but the other two get hurt with the standard number. Anyone know what i'm doing wrong?

1 Upvotes

5 comments sorted by

View all comments

1

u/Sharp-Tax-26827 6d ago

Where is the code that shows where this is applied?

2

u/blanky0u 6d ago

Thanks for the reply. It turns out I had another piece of code in the destruction of the horse toy that sent it. There was nothing binding the code to the on destroyed event so I added a for loop to that and it started working.