ProxDetector
#4

Quote:
Originally Posted by Denis1
Посмотреть сообщение
Other answers?
Well, yeah you should use IsPlayerInRangeOfPoint

Quote:
Originally Posted by Denis1
Посмотреть сообщение
and I have to know what is the best way to check if the player is in a given range to see another player's sent message
You can youse this function:

Код:
stock SendRangeMessage(playerid,color,Float:range,const string[]) {
    new Float:p[3],i;
    GetPlayerPos(playerid,p[0],p[1],p[2]);
    for(;i<MAX_PLAYERS; i++) if(IsPlayerInRangeOfPoint(i,range,p[0],p[1],p[2])) SendClientMessage(i,color,string);
    return 1;
}

//Example:
SendRangeMessage(playerid,-1,15.0,"Hallo"); //Sends a Message to all players in a range of 15.0
Greekz
Reply


Messages In This Thread
ProxDetector - by Denis1 - 12.03.2015, 07:13
Re: ProxDetector - by oliverrud - 12.03.2015, 07:34
Re: ProxDetector - by Denis1 - 12.03.2015, 12:07
AW: Re: ProxDetector - by Kaliber - 12.03.2015, 12:22
Re: ProxDetector - by Denis1 - 12.03.2015, 12:43
Re: ProxDetector - by CalvinC - 12.03.2015, 12:46

Forum Jump:


Users browsing this thread: 1 Guest(s)