10.09.2013, 13:25
It depends on what you want.
This code sends the message "ERROR" if you're in range of those coordinates. If you're not, then it sends the message "Police duty".
In case you want the opposite, do what Areax said at his first post.
Also, if you want the health, armour and colour when they're on police duty, you need to use it inside a block { }.
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 5.0,-2500.2500,250.2500,5.2500))
SendClientMessage(playerid, COLOR_ERROR,"ERROR.");
else
SendClientMessage(playerid, COLOR_WHITE, "Police duty");
In case you want the opposite, do what Areax said at his first post.
Also, if you want the health, armour and colour when they're on police duty, you need to use it inside a block { }.
pawn Код:
else
{
SendClientMessage(playerid, COLOR_WHITE, "Police duty");
SetPlayerHealth(playerid, 100.100);
SetPlayerArmour(playerid, 100.100);
SetPlayerColor(playerid, COLOR_WHITE);
}