How do i apply damage overtime to enemies?
Currently, my fire spell only hits the enemy once with no additional damage after the attack.
Hey there @Codename_Prince! There’s lots of ways to go about this implementation, but each of them depend on a myriad of other gameplay factors like:
Can you have other status effects?
Do they interact with fire?
Can the enemy/player be put out/off fire/lose the effect at all?
Does your game need to keep track of this effect or will it have no other relevance outside of just damaging the enemy?
Here’s a super basic implementation, but you’d have to expand it for it to fit inside of a status effect system altogether. I’d usually recommend myself for making a system for damage over time effects altogether, but this serves the purpose standalone: