Quote:
Originally Posted by HY
pawn Код:
CMD:aka(playerid, params[]) { new name[MAX_PLAYER_NAME], IP[20], string[50], ID; if(sscanf(params, "u", ID)) return SendClientMessage(playerid, -1, "/Aka [ID]"); if(!IsPlayerConnected(ID)) return SendClientMessage(playerid, -1, "That player isn't connected."); GetPlayerName(ID, name, sizeof(name)); GetPlayerIp(ID, IP, sizeof(IP)); format(string, sizeof(string), "%s [%d] IP it's %s.", name, ID, IP); SendClientMessage(playerid, -1, string); return 1; }
Wasn't so hard guys.. It's only a function.
EDIT: wrong code. sorry, edited.
|
The theory is correct in your code, but i assumed, he wanted to type /aka id, and then all users registered will be displayed. Your code will only display usernames ip address.