06.11.2010, 17:05
Hai all,i need simple anti high ping kicker.
Ex: If player have +500 ping,he got kicked
Ex: If player have +500 ping,he got kicked
if (GetPlayerPing(playerid) > 500) {
SendClientMessage(playerid, COLOR, "You have been kicked for having a high ping.");
Kick(playerid);
}
public OnPlayerUpdate(playerid) { new string[128]; new playername[MAX_PLAYER_NAME]; GetPlayerName(playerid, playername, sizeof(playername)); if((GetPlayerPing(playerid) >= 400 && GetPlayerPing(playerid) != 65535)) SendClientMessage(playerid,COLOR_GREEN,"Kicked - High Ping limit - Max 400.", playername); SendClientMessageToAll(COLOR_GREEN, "%s has been kicked because he excedeed max ping limit (400)."); Kick(playerid); return 1; }
public OnPlayerUpdate(playerid)
{
new string[128];
new playername[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername, sizeof(playername));
if((GetPlayerPing(playerid) >= 400 && GetPlayerPing(playerid) != 65535))
SendClientMessage(playerid,COLOR_GREEN,"Kicked - High Ping limit - Max 400.", playername);
SendClientMessageToAll(COLOR_GREEN, "%s has been kicked because he excedeed max ping limit (400).");
Kick(playerid);
return 1;
}
1.) --> SendClientMessage(playerid,COLOR_GREEN,"Kicked - High Ping limit - Max 400.", playername);
2.) --> SendClientMessageToAll(COLOR_GREEN, "%s has been kicked because he excedeed max ping limit (400).");
SendClientMessage(playerid,COLOR_GREEN,"Kicked - High Ping limit - Max 400.");
new string[128];
format(string, sizeof(string), "%s has been kicked because he excedeed max ping limit (400).",playerame);
SendClientMessageToAll(COLOR_GREEN, string);
public OnPlayerUpdate(playerid)
{
new playername[MAX_PLAYER_NAME], string[128];
if(GetPlayerPing(playerid) > 400 && GetPlayerPing(playerid) != 65535){
GetPlayerName(playerid, playername, MAX_PLAYER_NAME);
SendClientMessage(playerid, COLOR_GREEN, "[KICKED] Max ping exceeded <400>");
Kick(playerid);
format(string, 128, "[KICK] %s has been kicked: Max Ping <400>", playername);
SendClientMessageToAll(COLOR_GREEN, string);
}
}