Quote:
Originally Posted by Napoleon_be
You'll need to update the damage everytime u kill a zombie then. use DeathMsg event or Ham_Killed. Use a variable to store the bonus damage in, and increase it using get_pcvar_num(). Hook TakeDamage & TraceAttack.
https://forums.alliedmods.net/showthread.php?t=80208 : This is a great example of how you could do it.
|
Actually i already have that in my forwardPlayerKilled...
Heres my code:
PHP Code:
// Zombie killed human, add up the extra frags for kill
if (g_zombie[attacker] && get_pcvar_num(cvar_fragsinfect) > 1)
set_pcvar_num(cvar_ammodamage_human, get_pcvar_num(cvar_ammodamage_human) +5)
UpdateFrags(attacker, victim, get_pcvar_num(cvar_fragsinfect) - 1, 0, 0)