PHP код:
// Try to load the player's datafile ("PlayerFile_Load" returns "1" is the file has been read, "0" when the file cannot be read)
if (PlayerFile_Load(playerid) == 1)
{
if (APlayerData[playerid][BanTime] < gettime()) // Player ban-time is passed
{
format(Texto, sizeof(Texto), "{FFFFFF}Olб {DB0808}%s{FFFFFF}, Bem-Vindo ao (nome servidor) Novamente\n{FFFFFF}Seu IP: {DB0808}%s\n{FFFFFF}Insira sua Senha Para Logar-se", gtNome(playerid), gtIP(playerid));
ShowPlayerDialog(playerid, DialogLogin, DIALOG_STYLE_PASSWORD, "Dialogo de Login", Texto, "Logar", "Sair");
}
else
{
ShowRemainingBanTime(playerid); // Show the remaining ban-time to the player is days, hours, minutes, seconds
Kick(playerid); // Kick the player
}
}
else
{
format(Texto, sizeof(Texto), "{FFFFFF}Olб {DB0808}%s{FFFFFF}, Bem-Vindo ao (nome servidor) \n{FFFFFF}Seu IP: {DB0808}%s\n{FFFFFF}Insira uma Senha Para Registrar-se", gtNome(playerid), gtIP(playerid));
ShowPlayerDialog(playerid, DialogRegister, DIALOG_STYLE_PASSWORD, "Dialogo de Registro", Texto, "Registrar", "Sair");
}