You could also detect grenade launching using FM_SetModel, check there for w_grenade model then check the classname of the entity not to be a weaponbox
PHP Code:
register_forward(FM_SetModel, "fw_SetModel")
public fw_SetModel(iEntity, const szModel[])
{
if(!pev_valid(iEntity))
return FMRES_IGNORED
if(strlen(szModel) < 8)
return FMRES_IGNORED
if(szModel[7] != 'w' || szModel[8] != '_')
return FMRES_IGNORED
if(equal(szModel, "models/w_weaponbox.mdl"))
return FMRES_IGNORED
static szClass[32]
entity_get_string(iEntity, EV_SZ_classname, szClass, charsmax(szClass))
if(!equal(szClass, "weaponbox"))
return FMRES_IGNORED
// Grenade launched ( you can check for model to get what type of grenade it is, ex w_flashbang, w_smokegrenade, w_hegrenade
__________________