[Ajuda] Sistema de ban dando crash
#3

Nгo viaja cara.

16 Caracteres й IP
24 Й Nome!

pawn Код:
forward mBan(playerid, id, motivo[128]);
public mBan(playerid, id, motivo[128]){
    new str[128],Data[3],Hora[3], NomeID[24], arquivo[64], NomeA[24], pIP[16];
    GetPlayerName(id, NomeID, 24);
    GetPlayerName(playerid, NomeA, 24);
    getdate(Data[0], Data[1], Data[2]);
    gettime(Hora[0], Hora[1], Hora[2]);
    GetPlayerIp(id, pIP, sizeof pIP);
    format(str, 128, " ||SERVER|| O Player (%s) foi banido pelo Administrador (%s) motivo: (%s) ",NomeID, NomeA, motivo);
    SendClientMessageToAll(Vermelho,str);
    format(arquivo, 64,"Bans/%s.ini",NomeID);
    DOF2_CreateFile(arquivo);
    DOF2_SetString(arquivo, "Admin", NomeA);
    DOF2_SetString(arquivo, "Nome", NomeID);
    DOF2_SetString(arquivo, "IP", pIP);
    DOF2_SetString(arquivo, "Motivo", motivo);
    format(str, sizeof(str), "%02d/%02d/%02d", Data[0],Data[1],Data[2]);
    DOF2_SetString(arquivo, "Data", str);
    format(str, sizeof(str), "%02d:%02d:%02d", Hora[0],Hora[1],Hora[2]);
    DOF2_SetString(arquivo, "Horas", str);
    DOF2_SaveFile();
    return true;
}
Reply


Messages In This Thread
Sistema de ban dando crash - by MatheusAlcapone - 20.02.2013, 01:14
Re: Sistema de ban dando crash - by ViniBorn - 20.02.2013, 01:38
Re: Sistema de ban dando crash - by zSuYaNw - 20.02.2013, 05:43
Re: Sistema de ban dando crash - by MatheusAlcapone - 20.02.2013, 11:41
Re: Sistema de ban dando crash - by Schocc - 20.02.2013, 12:48
Re: Sistema de ban dando crash - by MatheusAlcapone - 20.02.2013, 12:50

Forum Jump:


Users browsing this thread: 1 Guest(s)