17.12.2018, 15:23
Hi guys,
On my server I have gang zones,and I have function IsPlayerInZone,and it check is player in certain zone.Now,i want to make function which will check Is Player In Zone or near by zone(20m for example)
Function IsPlayerInZone
It will work only if player is IN zone,so I want to make new function so that I can check is player in zone or near by it zone..I hope you can understand me.
On my server I have gang zones,and I have function IsPlayerInZone,and it check is player in certain zone.Now,i want to make function which will check Is Player In Zone or near by zone(20m for example)
Function IsPlayerInZone
Код:
IsPlayerInZone(playerid, zoneid) { new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x, y, z); return (x > GZ[zoneid][mX] && x < GZ[zoneid][vX] && y > GZ[zoneid][mY] && y < GZ[zoneid][vY]); }
Quote:
mx = minX mY = minY vX = maxX vY = maxY |