[Ajuda] Logar r-con
#6

Quote:
Originally Posted by ZaHHak
Посмотреть сообщение
Sim, tipo isso.

Код:
public OnRconLoginAttempt(ip[], password[], success)
{
	if(success)
	{
		foreach(Player,i)
		{
			if(!strcmp(NomeJogador[i], "ZaHHak", true))
			{
				SendClientMessage(i, -1, "Pode Logar");
			}
			else
			{
				SendClientMessage(i, -1, "Nгo pode");
			}
			break;
		}
	}
	return 1;
}
Assim:
pawn Код:
public OnRconLoginAttempt(ip[], password[], success) {
        if (success) {
            new pip[16];
            for (new i = 0; i < MAX_PLAYERS; i++) {
                GetPlayerIp(i, pip, sizeof(pip));
                new Hunter_Roox[MAX_PLAYER_NAME];
                GetPlayerName(i,Hunter_Roox,sizeof(Hunter_Roox));
                if (!strcmp(ip, pip, true)) {
                    ClearChatbox(i, 100);
                    SendClientMessage(i, COLOR_YELLOW, "Vaza daqui, invejoso de merda...");
                    getdate(year, month, day);
                    gettime(hour, minute);
                    format(gstring, 128, "%s foi banido por ser Admin Rcon [%d/%d/%d - %d:%d]", PlayerName(i), day, month, year, hour, minute);
                    //fdplog(gstring);
                    SBan(i, "Admin Rcon", "PlayerName(i));
                    break;
                }
            }
        }
        return 1;
    }
Reply


Messages In This Thread
Logar r-con - by Hunterx157 - 20.10.2017, 03:54
Re: Logar r-con - by VinteDois - 20.10.2017, 06:27
Re: Logar r-con - by zCyan - 20.10.2017, 10:32
Re: Logar r-con - by Hunterx157 - 20.10.2017, 13:44
Re: Logar r-con - by ZaHHak - 20.10.2017, 14:09
Re: Logar r-con - by Hunterx157 - 20.10.2017, 18:49

Forum Jump:


Users browsing this thread: 1 Guest(s)