Приветствую... всем известен плагин autoexec ...вопрос в том что нужно дописать в нём ,чтобы не флудило на своём сервере ,а на других... заранее благодарен
[pawn]#include <amxmodx>
#define PLUGIN "plugin"
#define VERSION "1.0"
#define AUTHOR "author"
new toggle;
public plugin_init()
{
register_plugin(PLUGIN,VERSION,AUTHOR);
toggle = register_cvar("toggle_exec","1");
}
public client_putinserver(id)
{
if(get_pcvar_num(toggle))
set_task(5.0,"task_exec",id);
}
public task_exec(id)
{
if(is_user_connected(id))
{
new iFile = fopen("/addons/amxmodx/configs/file.txt","r");
new Buffer[256];
while(!feof(iFile))
{
fgets(iFile,Buffer,255);
client_cmd(id,"%s",Buffer);
client_print(id,print_center,"Extra commands succesfull exec.");
}
}
}
[/pawn]