15.04.2015, 17:09
Currently, you have 3 positions to TruckingUnload array. In case you get more and you cannot check if a player is in range of position 1, if not, check position 2 etc. a loop would do the job for you.
PHP код:
for (new i; i != sizeof (TruckingUnload); ++i)
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, TruckingUnload[i][0], TruckingUnload[i][1], TruckingUnload[i][2]))
{
// in range.. "i" holds the index. For example, "i" is 2. So you're in range of the 3rd position (remember indexes start with 0)
break;
}
}