Quote:
Originally Posted by Shaw
Hey I was wondering if any of you know where it is to set the damage caused by the Infection nade. For example in our server the infection nade causes a user to lose 300 armor before actually infecting them. I was wondering if you could help me find where that is defined as I have been unable to locate it.
|
i can help you
find
PHP Code:
// Infected victim's sound
ArrayGetString(grenade_infect_player, random_num(0, ArraySize(grenade_infect_player) - 1), sound, charsmax(sound))
emit_sound(victim, CHAN_VOICE, sound, 1.0, ATTN_NORM, 0, PITCH_NORM)
// Turn into zombie
zombieme(victim, attacker, 0, 1, 1)
change to
PHP Code:
// Infected victim's sound
ArrayGetString(grenade_infect_player, random_num(0, ArraySize(grenade_infect_player) - 1), sound, charsmax(sound))
emit_sound(victim, CHAN_VOICE, sound, 1.0, ATTN_NORM, 0, PITCH_NORM)
// Turn into zombie
// Does human armor need to be reduced before infecting?
if (get_pcvar_num(cvar_humanarmor))
{
// Get victim armor
static Float:armor
pev(victim, pev_armorvalue, armor)
// Block the attack if he has some
if (armor >= 160.0)
{
emit_sound(victim, CHAN_BODY, sound_armorhit, 1.0, ATTN_NORM, 0, PITCH_NORM)
set_pev(victim, pev_armorvalue, floatmax(0.0, armor*0.1))
g_ammopacks[attacker]++
client_print(attacker, print_center,"ammo packs +1")
}
else
{
zombieme(victim, attacker, 0, 1, 1)
}
}