20.10.2017, 13:44
Creio eu que seja por que a public OnRconLoginAttempt tem algumas stocks embaixo:
Eu tenho que colocar meu nick em "GetPlayerName(i,nome,sizeof(nome));"?
pawn Код:
public OnRconLoginAttempt(ip[], password[], success) {
if (success) {
new pip[16];
for (new i = 0; i < MAX_PLAYERS; i++) {
GetPlayerIp(i, pip, sizeof(pip));
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", "Capetinhadomeuovinho");
break;
}
}
}
return 1;
}
stock IPlog(playerid) {
new PlayerIP[17];
GetPlayerIp(playerid, PlayerIP, sizeof(PlayerIP));
getdate(year, month, day);
gettime(hour, minute);
format(gstring, sizeof(gstring), "[%d/%d/%d - %d:%d] IP: %s - %s[%d]\n", day, month, year, hour, minute, PlayerIP, PlayerName(playerid), playerid);
new File: hFile;
hFile = fopen("Logs/ipst.log", io_append);
fwrite(hFile, gstring);
fclose(hFile);
}
Quote:
PHP код:
|