new const PLUGIN[] = "SpecList";
new const VERSION[] = "1.2a";
new const AUTHOR[] = "FatalisDK";
new gMaxPlayers;
new gCvarOn;
new gCvarImmunity;
new bool:gOnOff[33] = { true, ... };
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR);
register_cvar(PLUGIN, VERSION, FCVAR_SERVER, 0.0);
gCvarOn = register_cvar("amx_speclist", "1", 0, 0.0);
gCvarImmunity = register_cvar("amx_speclist_immunity", "1", 0, 0.0);
register_clcmd("say /speclist", "cmdSpecList", -1, "");
gMaxPlayers = get_maxplayers();
set_task(UPDATEINTERVAL, "tskShowSpec", 123094, "", 0, "b", 0);
}
public cmdSpecList(id)
{
if( gOnOff[id] )
{
client_print(id, print_chat, "[AMXX] You will no longer see who's spectating you.");
gOnOff[id] = false;
}
else
{
client_print(id, print_chat, "[AMXX] You will now see who's spectating you.");
gOnOff[id] = true;
(e o código continua... mas acho que isto chega)