24.02.2012, 11:22
Isso resolvera o seu problema!
pawn Код:
#include <a_samp>
#define Banir 0
#define Kickar 1
enum IPs
{
IP[16],
Option
};
new PlayerIP[][IPs] =
{
{"201.50.20.80", Kickar},//Boob_PerfecT
{"200.138.69.245", Kickar},//Spider_Man
{"192.168.1.4", Kickar},//Sammy_Winchester
{"5.83.150.194", Kickar}//Killer_Matador
};
public OnPlayerConnect(playerid)
{
new ip[16];
GetPlayerIp(playerid, ip, 16);
for(new i = 0; i < sizeof PlayerIP; i++)
{
if(strcmp(ip, PlayerIP[i][IP], true) != -1)
{
if(PlayerIP[i][Option] == Banir)
{
SendClientMessage(playerid, 0xFFFFFFFF, "** Voc? foi Banido(a) Pelo Sistema Anti-Hacker.");
Ban(playerid);
}
else if(PlayerIP[i][Option] == Kickar)
{
SendClientMessage(playerid, 0xFFFFFFFF, "** Voc? foi Kickado(a) Pelo Sistema Anti-Hacker.");
Kick(playerid);
}
break;
}
}
return true;
}