An interface to handle calls from Melee Combat System.
Use this interface when you want to call a method when an object is hit by the attacker, for things such as a health script ,destroying an object on hit and any sort of custom on-hit behavior.
Note - there must be a script with this interface in the target GameObject to avoid errors.
Based on the reaction you want to trigger in Reaction Module, select one of the following.
int AttackId{get;set;}
Internally handled do not modify manually.
An internal variable, used to assign a unique ID to each attack instance to make sure no duplicate calls are made to the same GameObject even with overlapping colliders. ****
void TakeDamage(MeleeCombatSystem meleeCombatSystem,DamageType damageType,Attack attack);
Default method used by Melee Combat System when a target collider is hit. Use this method to assign your custom function that should take place on impact.
void TakeDamage(MeleeCombatSystem meleeCombatSystem);
Overload for TakeDamage