If you are uncluding fun than instead of this:
Code:
stock ham_strip_weapon(id, weapon[])
{
if(!equal(weapon,"weapon_",7))
return 0
new idd = get_weaponid(weapon)
if(!idd) return 0
new wEnt
while((wEnt = find_ent_by_class(wEnt, weapon)) && entity_get_edict(wEnt, EV_ENT_owner) != id) {}
if(!wEnt) return 0
if(get_user_weapon(id) == idd)
ExecuteHamB(Ham_Weapon_RetireWeapon,wEnt);
if(!ExecuteHamB(Ham_RemovePlayerItem,id,wEnt))
return 0
ExecuteHamB(Ham_Item_Kill, wEnt)
entity_set_int(id, EV_INT_weapons, entity_get_int(id, EV_INT_weapons) & ~(1<<idd))
return 1
}
Use strip_user_weapon from fun module bcoz it is more efficient and faster
__________________