Hello there i need some help about writing a damage stacking system.
Current goal is everytime player attack a player the damage will be more and more higher, for example first time is 1, 2nd time will be 2, 3rd time will be 3(...), but if target change this will clear to basic damage 1.
The question is how to check target change? and how to count damage stacking? don't know the right way to get damage done and how many time attacker attack the target.
P.S: i know sdktools have a function can get everytime damage done, but don't know how to stacking it.
PHP Code:
public Action:OnTakeDamage(victim, &attacker, &inflictor, &Float:damage, &damagetype)
{
//...
damage = damage;
PrintToChat(client, "%.0f", damage);
}