1) Is this correct to get a players weapons and check if they are all correct? (wep_ok does the checking)
Code:
public check_wep(id)
{
new weapons[32]
new numWeapons,i,weapon,j
get_user_weapons(id,weapons,numWeapons)
for(i=0;i<numWeapons;i++)
{
new alright
alright = wep_ok(id,weapons[i],i)
if(alright != -1)
{
strip_user_weapons(id)
for(j=0;j<numWeapons;j++)
{
if(alright != j)
give_coitem(id,weapon[j])
}
check_wep(id)
}
}
}
2) Is there an event I can register which happens when a player picks up a defuse kit or nightvision?
3) How do I give a C4?
Thanks in advance.
__________________