08.08.2013, 00:44
pawn Код:
new name[24], ip[16];
GetPlayerIp(playerid, ip, sizeof ip);
GetPlayerName(playerid, name, sizeof name);
for(new id; < 24; id++)
{
if(!strmcp(name,TempBans[id][BannedName]))
{
SendClientMessage(playerid, Red,"Your ban has not expired");
Kick(playerid);
return 1;
}
if(!strmcp(ip,TempBans[id][BannedIP]))
{
SendClientMessage(playerid, Red, "Your ban has not expired");
Kick(playerid);
return 1;
}
}
if(fexist(Path(playerid)))
{
INI_ParseFile(Path(playerid),"loadaccount_%s", .bExtra = true, .extra = playerid);
ShowPlayerDialog(playerid,login,DIALOG_STYLE_INPUT,"Login","Welcome Back!\n Please login with your password","Login","Quit");
}
else
{
ShowPlayerDialog(playerid,register,DIALOG_STYLE_INPUT,"Register","Welcome! This account is not registered.\nEnter your own password to create a new account.\nPlease enter the password!","Register","Quit");
return 1;
}
return 1;
}