Is Player In Gang Zone
#1

Hello guys I have got function to check Is Player Is between two points (x,y - x,y), but it doesn't works.
Here is the function:
Quote:

forward IsPlayerInGangZone(playerid, Float:min_x, Float:min_y, Float:max_x, Float:max_y);
public IsPlayerInGangZone(playerid,Float:min_x,Float:min_ y,Float:max_x,Float:max_y)
{
new Float:X1,Float:Y1,Float:Z1;
GetPlayerPos(playerid, X1, Y1, Z1);
if((X1 <= max_x && X1 >= min_x) && (Y1 <= max_y && Y1 >= min_y)) return 1;
return 0;
}

And here is how I'm checking it (using CMD):
Quote:

if(IsPlayerInGangZone(playerid, 2539.976074,-1629.067382, 2504.410400,-1667.414062)) return SendClientMessage(playerid,COLOR_RED,"I'm here");

Reply


Messages In This Thread
Is Player In Gang Zone - by Kraeror - 22.09.2017, 08:46
Re: Is Player In Gang Zone - by oMa37 - 22.09.2017, 09:04
Re: Is Player In Gang Zone - by Kraeror - 22.09.2017, 09:07
Re: Is Player In Gang Zone - by oMa37 - 22.09.2017, 09:09
Re: Is Player In Gang Zone - by Kraeror - 22.09.2017, 09:13
Re: Is Player In Gang Zone - by Kraeror - 22.09.2017, 12:21
Re: Is Player In Gang Zone - by ToiletDuck - 22.09.2017, 13:38
Re: Is Player In Gang Zone - by Kraeror - 22.09.2017, 14:05
Re: Is Player In Gang Zone - by ToiletDuck - 22.09.2017, 14:23
Re: Is Player In Gang Zone - by Kraeror - 22.09.2017, 14:26

Forum Jump:


Users browsing this thread: 1 Guest(s)