Multiple Actors in Triggerbox

I am having some trouble with my triggerbox when multiple actors enters it. When people enter the box they take x damage per second, but when a second character step inside the first character don’t take damage anymore and only the second one.

I am not sure what way would be best to say that all actors who enter should get the damage.
I am using normal trigger box with oncomponentbeginoverlap and using other actors to say who to damage.

You could add an array keeping track of all actors currently in the trigger box. When an actor enters the box, add them to the array. When they leave again, remove them. Then, in reaction to your Fire event, you use a ForEach loop over the entire array and call ApplyDamage for each actor.

I’ve attached some screenshots to a similar question I just answered: How to reduce stamina when player enters a box? - Blueprint - Epic Developer Community Forums

You’ll need to make sure to also remove any killed actors from the array. Maybe you can use the DamageCauser variable to inform the trigger box if an actor is killed.

I cant see the Whole blueprint but on event begin , and apply damage, are both event that fire just 1 time.
I am sure that there are many solution , all with different problem , for now i suggest you this.

Here my working example.
You can use the trigger to access “who” is entering… i have my bot., so cast to bot .
In my Bot i created the variable get damage, and set that variable.
Now on the tick event i check costantly if i am “damaged” checking the var, and apply damage.

Thanks for the answers! This worked perfect :slight_smile: