18.06.2014, 20:34
First thing first, markers are reprsented by MapIcons, SetPlayerMapIcon search this function and learn it.
Secondly, for the verificaiton part, you need a function that is called IsPlayerInRangeOfPoint, search and learn it.
Thirdly, I will show you an example of using both of them.
Also an example for usage of IsPlayerInRangeOfPoint
Secondly, for the verificaiton part, you need a function that is called IsPlayerInRangeOfPoint, search and learn it.
Thirdly, I will show you an example of using both of them.
Код:
public OnPlayerConnect(playerid) { SetPlayerMapIcon(playerid, 0, yourxhere, youryhere, yourzhere, 10, yourcolorhere, 3); return 1; }
Код:
public OnPlayerCommandText(playerid, cmdtext[]) { if(!strcmp(cmdtext, "/test", false)) { if(!IsPlayerInRangeOfPoint(playerid, yourmaxradiussizehere, yourxhere, youryhere, yourzhere)) { return SendClientMessage(playerid, yourcolorhere, yourmessagehere) } } return 0; }