01.09.2014, 13:26
I have tried to script this cmd like this but does not work.
pawn Код:
CMD:getip(playerid, params[])
{
if(Player[playerid] [pAdmin] >=1)
{
new targetid;
new ip[16];
if(sscanf(params,"u",targetid)) return SendClientMessage(playerid,COLOR_RED,"[ERROR]/getip [ID].");
GetPlayerIp(targetid,ip,sizeof(ip));
format(ip, sizeof(ip), "[SERVER]:TargetID IP is: %s ",ip);
SendClientMessage(playerid,COLOR_YELLOW,ip);
}
else
{
SendClientMessage(playerid,COLOR_RED, "[SERVER]:You are not allowed to use this command.");
}
return 1;
}