Status Component
Add StatusEffectManager Component to your character
Invent some fancy StatusEffect-GameplayTags and add them to your RPGTags list
Add StatusEffect-GameplayTags to your character’s StatisticsComponent
Create the StatusEffect itself and overrides those functions to define your behaviours:
a. Inherit from following:
InstantlyStatusEffect: All the functions are called at the creations and just once
ForDurationStatusEffect: Calls OnStatusEffectsStarts and OnTriggerStatusEffect at start andOnStatusEffectsEnds after the duration
PeriodicallyOverDurationStatusEffect: Calls OnStatusEffectsStarts at start, OnTriggerStatusEffect periodically every duration / triggerCount times and OnStatusEffectsEnds at the end.
c. Modify the class default as you wish.
Adding a Status
● Apply and configure the StatusEffectManager Component also to your Enemy.
● You can easily add status effects to terrain, traps, or weapons by just getting from the collided actor the StatusEffectManager and apply the corresponding status effect.
● For example the slow effect you also need to adjust the logic in the PlayerCharacter, otherwise the sprint logic will negate the slow effect.