PHP Code:
public plugin_init()
{
register_clcmd("drop","anticrashserver")
}
public anticrashserver(id)
{
new num;
new weapons[32];
get_user_weapons(id, weapons, num);
if (num == 1)
{
if (num > 0)
return PLUGIN_HANDLED;
}
return PLUGIN_CONTINUE;
}
something like this.
I am trying to force the client to have at least 1 weapon in his/her hand.
which should work with just
however we have snarks,satchels and tripmines which are not recognized by amxmodx as part of the weapon index.
so Im first trying to isolate if it is 1 weapon.
then if it is one weapon I will disable the ability to drop by checking if its > 0.
so people wouldn't be able to drop further if they got an snarks,satchels,tripmines with 1 weapon in hand.
but I dont know how to check the same value against two different operators, if possible.