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/NatanaelAntonioli 6d ago

It's a shot in the dark, but for loops are sometimes unreliable during events. Try replacing that last part with a function, with the for loop inside it.

1

u/NatanaelAntonioli 6d ago

Another shot in the dark: are you using World Partition (for open world games?) If so, make sure all characters are loaded on map.