im useing 1.7
Code:
#include <amxmodx>
#include <amxmisc>
#include <engine>
#include <tsfun>
new PLUGIN[]="WEAPONS"
new AUTHOR[]="Siddhartha"
new VERSION[]="2.00"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_srvcmd("item_gun","item_gun")
}
public item_gun(id)
{
new arg[32], arg2[32], arg3[32], wepid, ammo, spwnflg
read_argv(1,arg,31)
read_argv(2,arg2,31)
read_argv(3,arg3,31)
wepid = str_to_num(arg)
ammo = str_to_num(arg2)
spwnflg = str_to_num(arg3)
if(wepid == 0) {
return PLUGIN_HANDLED
}
ts_giveweapon (id,wepid,ammo,spwnflg)
return PLUGIN_HANDLED
}
it compiles yes but then i try and use the item in the game it gives me
run time error 10: native error (native "ts_giveweapon")
[0] weaponasitems.sma: :item_gun ( line 32 )
__________________