#BeginOverlap Damage Per Second?

1 messages · Page 1 of 1 (latest)

mint grove
#

I'm trying to make it so that when an Enemy's "AttackCapsule" component overlaps with the player it will deal damage every second they are overlapping. The same goes for multiple enemies all damaging the player when in contact while all having their own independent cooldowns before they can attack again.

In a sense I'm trying to replicate a PainCausingVolume with damage per second and a pain interval. What I've done so far was create an OnComponentBeginOverlap which branched to set a timer and damage the player. The issue with this is that when a 2nd enemy overlaps with the player, it resets the timer.

mint grove
#

Okay, so I made some quick corrections: I now have a PlayerCollide Boolean which will apply damage. However the issue I'm running into now is that If you Clear and Invalidate the Timer when you EndOverlap you can reset it multiple times if you are skirting around the edge of the enemy's AttackCapsule 🤔