Quote:
Originally Posted by OciXCrom
So, where's the code?
|
PHP Code:
#include <amxmodx>
#include <zombieplague>
#include <fun>
#include <hamsandwich>
new bool: g_knife[33]
new g_class_powerknife
new cvar_damage_multi
new const hclass4_name[] = ""
new const hclass4_info[] = ""
new const hclass4_model[] = ""
new const hclass4_clawmodel[] = ""
const hclass4_health = 2600
const hclass4_speed = 295
const Float:hclass4_gravity = 0.7
public plugin_init()
{
RegisterHam( Ham_TakeDamage, "player", "fw_TakeDamage" )
g_class_powerknife = zp_register_human_class(hclass4_name, hclass4_info, hclass4_model, hclass4_clawmodel, hclass4_health, hclass4_speed, hclass4_gravity)
}
public fw_TakeDamage(victim, inflictor, attacker, Float:damage, damage_type)
{
if (!is_user_connected(attacker))
return HAM_IGNORED
if (g_knife[attacker])
{
if (get_user_weapon(attacker) == CSW_KNIFE)
{
SetHamParamFloat(4, damage * 2.0)
}
}
return HAM_IGNORED;
}
__________________