I already gave you a working code...
PHP Code:
#include <amxmodx>
#include <cstrike>
#include <engine>
#include <fakemeta>
#include <fun>
#include <hamsandwich>
#define OFFSET_PRIMARYWEAPON 116
#define OFFSET_C4_SLOT 372
StripUserWeapons(id)
{
new iC4Ent = get_pdata_cbase(id, OFFSET_C4_SLOT)
if( iC4Ent > 0 )
{
set_pdata_cbase(id, OFFSET_C4_SLOT, FM_NULLENT)
}
strip_user_weapons(id)
set_pdata_int(id, OFFSET_PRIMARYWEAPON, 0)
if( iC4Ent > 0 )
{
entity_set_int(id, EV_INT_weapons, entity_get_int(id, EV_INT_weapons) | (1<<CSW_C4))
set_pdata_cbase(id, OFFSET_C4_SLOT, iC4Ent)
cs_set_user_bpammo(id, CSW_C4, 1)
cs_set_user_plant(id, 1)
}
return PLUGIN_HANDLED
}
__________________