I can't get this to work could anyone help me with this please.
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#define PLUGIN "test"
#define VERSION "1.0"
#define AUTHOR "none"
#define ADMIN ADMIN_LEVEL_A
new bool:Invisible[33];
new bool:viewInvisible[33];
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR);
register_concmd("amx_testit","testit",ADMIN,"<nick, #userid> : Make user not see other users");
register_forward(FM_AddToFullPack, "addtofullpack",1);
}
public addtofullpack(es_handle,e,ent,id,host,player,pSet) {
if(!player)
return FMRES_IGNORED;
if(Invisible[ent] && viewInvisible[host])
{
set_es(es_handle,ES_RenderMode,kRenderTransTexture);
set_es(es_handle,ES_RenderAmt,0);
}
return FMRES_IGNORED;
}
public client_connect(id)
{
Invisible[id] = true;
}
public client_disconnect(id)
{
if (Invisible[id])
{
Invisible[id] = false;
}
}
public testit(id,level,cid)
{
if (!cmd_access(id, level, cid, 2))
return PLUGIN_HANDLED;
new arg[32];
read_argv(1, arg, 31)
new player = cmd_target(id, arg, CMDTARGET_OBEY_IMMUNITY | CMDTARGET_ALLOW_SELF);
if (!player)
return PLUGIN_HANDLED;
viewInvisible[player] = true;
return PLUGIN_HANDLED;
}
__________________