26.07.2011, 10:01
GetPlayerIp
pawn Код:
public OnRconLoginAttempt(ip[], password[], success) {
if(success == 1) {
new
i,
tmp[64];
for( ; i != MAX_PLAYERS; ++i) {
if(!GetPlayerIp(i, tmp, 16) || strcmp(tmp, ip)) {
continue;
}
GetPlayerName(i, tmp, MAX_PLAYER_NAME);
format(tmp, sizeof tmp, "* %s has logged into rcon.", tmp);
SendClientMessageToAll(COLOR_ORANGE, tmp);
break;
}
}
return true;
}