Quote (sanya1992)
скажите плиз как увеличить лимит пинга
Code
if(strcmp(cmd, "/setping", true) == 0 ){
{
enum ConfigData {
MaxPing
};
new Config[ConfigData];
new params[256];
params = strtok(cmdtext,idx);
if(!strlen(params)||!(strval(params) >= 0 && strval(params) <= 10000))
return SendClientMessage(playerid,COLOR_RED,"Èñïîëüçóéòå: \"/SETPING <[0 / OFF] - 10,000>\".");
if(!IsNumeric(params)) {
if(!strcmp(params,"off",true)) { Config[MaxPing] = 0; //SetConfigInt("MaxPing",0);
}
else return SendClientMessage(playerid,COLOR_RED,"Èñïîëüçóéòå: \"/SETPING <[0 / OFF] - 10,000>\".");
}
Config[MaxPing] = strval(params); //SetConfigInt("MaxPing",strval(params));
new name[24],Fo[30]; GetPlayerName(playerid,name,24); format(Fo,30,"to %d",Config[MaxPing]); if(!Config[MaxPing]) Fo = "off";
format(string,256,"Administrator \"%s\" has set the Maximum Ping %s.",name,Fo);
SendClientMessageToAll(COLOR_YELLOW,string);
}
return 1;}