21.12.2013, 19:56
How to make /locate command also works without typing the playerid that i want to locate.
example:
/locate 4 --> Player 4 location is %s
/locate (without ID) --> your location is %s
so how to make it work for me also ?
example:
/locate 4 --> Player 4 location is %s
/locate (without ID) --> your location is %s
so how to make it work for me also ?
pawn Код:
CMD:locate(playerid,params[])
{
new string[128], targetid;
if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, COLOR_WHITE, "/locate [playerid]");
format(string,sizeof(string),"his location is %s", GetPlayerZone(targetid));
SendClientMessage(playerid,COLOR_WHITE,string);
return 1;
}