should it be like this now??
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <engine>
#include <hamsandwich>
#define PLUGIN "M249"
#define VERSION "1.0"
#define AUTHOR "razieljohn619"
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
RegisterHam(Ham_Spawn, "player", "hasWeapon", 1)
}
public hasWeapon(id, weapid){
new weapons[32], wnum
get_user_weapons(id, weapons, wnum)
for(new i = 0; i < wnum; i++){
if(weapons[i] == weapid) return 1
}
return 0
}
if(user_has_weapon(id, CSW_M249)){
entity_set_int(weapon, EV_INT_iuser4, 1)
set_task(0.1, "//commands..")
{
else
}
set_task(0.1, "//commands2..")
}
public //commands..(id)
{
//commands..
}
public //commands2..(id)
{
//commands..
}
and also is this correct
PHP Code:
else
}
set_task(0.01, "//commands2..")
this here should run if player has that weapon
PHP Code:
public //commands..(id)
{
//commands..
}
and if not this here should run
PHP Code:
public //commands2..(id)
{
//commands..
}
...so im asking if here is right
PHP Code:
set_task(0.01, "//commands..")
{
else
}
set_task(0.01, "//commands2..")
pls help me thanks
__________________