10.07.2012, 21:04
Hi, I Need A Script That You Can Not Make More Than 1 Account Per IP
Thankz
Thankz
//Put it in register function.
new pIP[18];
GetPlayerIp(playerid, pIP, sizeof(pIP));
new string[64];
new File:example = fopen("IPS.txt", io_read);
while(fread(example, string))
{
if(strfind(string, pIP, true) != -1)
{
SendClientMessage(playerid, -1, "IP found");
Kick(playerid);
}
}
fclose(example);
//After registration:
new fPiP[32];
format(fPiP, sizeof(fPiP), "%s\r\n", pIP);
new File:log = fopen("IPS.txt", io_write);
if(log)
{
fwrite(log, fPiP);
fclose(log);
}
//Put it in register function.
new pIP[18];
GetPlayerIp(playerid, pIP, sizeof(pIP));
if(fexist(pIP)){SendClientMessage(playerid, -1, "This ip is already registered."); Kick(playerid);}
//After registration
new pIP[18];
GetPlayerIp(playerid, pIP, sizeof(pIP));
new File:log = fopen(pIP, io_write);
fwrite(log, pIP);
fclose(log);