20.10.2017, 18:49
Quote:
|
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;
}
|
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;
}


