PHP Code:
#define DMG_HE (1<<24)
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
RegisterHam(Ham_TakeDamage, "player", "Damage")
}
public Damage(vict, inf, atk, Float:damage, dmgb)
{
if(dmgb & DMG_HE |/*ooor the other way*/| inf == CSW_HEGRENADE)
SetHamParamFloat(4, damage*0)
}
This code sets the damage from grenades to 0, in other words, not a single damage caused by grenade. If you want it to be in some special conditions, I advise you to use a boolean.
__________________