mirror of
https://github.com/ineedbots/iw4_bot_warfare.git
synced 2025-06-27 14:41:49 +00:00
oops lol
This commit is contained in:
@ -1328,13 +1328,13 @@ nearAnyOfWaypoints(dist, waypoints)
|
||||
getNearestWaypointOfWaypoints(waypoints)
|
||||
{
|
||||
answer = undefined;
|
||||
closestDist = -1;
|
||||
closestDist = 999999999999;
|
||||
for (i = 0; i < waypoints.size; i++)
|
||||
{
|
||||
waypoint = waypoints[i];
|
||||
thisDist = DistanceSquared(self.origin, waypoint.origin);
|
||||
|
||||
if (isDefined(answer) && thisDist < closestDist)
|
||||
if (thisDist > closestDist)
|
||||
continue;
|
||||
|
||||
answer = waypoint;
|
||||
|
Reference in New Issue
Block a user