17.10.2011, 13:49
I need to make a getip cmd but I am confused how can I make that? I am using dini, so anyone can help me?
I need to make a getip cmd but I am confused how can I make that? I am using dini, so anyone can help me?
|
dcmd_getip(playerid, params) {
new pid = strval(params);
if(pid<0 || pid>MAX_PLAYERS || !IsPlayerConnected(pid))
return SendClientMessage(playerid, 0xFF0000, "USAGE: /GetIp [playerid]");
new pip[32];
GetPlayerip(pid, pip, sizeof(pip));
new str[128];
format(str, sizeof(str), "This player's IP is: %s", pip);
SendClientMessage(playerid, 0x00FF00, str);
return 1;
}