I'm trying to cut out execution if fall damage happened to the client with the following code. But it never catches the fall damage. I've tried a number of ways including
get_param(3) & DMG_FALL but nothing works. Am i making a mistake or does event_damage really not work like that?
PHP Code:
register_event("Damage", "Event_Damage", "be", "2!0")
public Event_Damage(victimID)
{
if(!is_user_alive(victimID) || !is_user_connected(victimID))
return PLUGIN_CONTINUE
new attackerID = get_user_attacker(victimID)
if(!(0 < attackerID <= g_maxPlayers && attackerID == victimID)
|| get_param(3) & DMG_FALL
|| !is_user_alive(attackerID)
|| get_user_weapon(attackerID) != CSW_KNIFE
|| hasBrass(attackerID) == 0)
return PLUGIN_CONTINUE
// more code
__________________