21.12.2013, 22:17
pawn Код:
CMD:locate(playerid, params[])
{
if (isnull(params))
{
new
string[64];
format(string, sizeof (string),"Your location is %s", GetPlayerZone(playerid));
SendClientMessage(playerid, COLOR_WHITE, string);
}
else
{
new
targetid;
if (!sscanf(params, "u", targetid))
{
if (targetid == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_WHITE, "Invalid player");
new
string[64];
format(string, sizeof (string), "Target's location is %s", GetPlayerZone(targetid));
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
return 1;
}