mirror of
https://gitlab.com/phoenix-dvpmt/mmocore.git
synced 2024-11-27 00:45:40 +01:00
Fixed waypoint path calculation
This commit is contained in:
parent
1f344dbe02
commit
0648079232
@ -140,6 +140,10 @@ public class Waypoint extends PostLoadObject implements Unlockable {
|
||||
while (pointsToCheck.size() != 0) {
|
||||
WaypointPath checked = pointsToCheck.get(0);
|
||||
pointsToCheck.remove(0);
|
||||
// If the point has already been checked, pass
|
||||
if (checkedPoints.contains(checked.getFinalWaypoint()))
|
||||
continue;
|
||||
|
||||
paths.add(checked);
|
||||
checkedPoints.add(checked.getFinalWaypoint());
|
||||
|
||||
@ -165,6 +169,10 @@ public class Waypoint extends PostLoadObject implements Unlockable {
|
||||
while (pointsToCheck.size() != 0) {
|
||||
WaypointPath checked = pointsToCheck.get(0);
|
||||
pointsToCheck.remove(0);
|
||||
// If the point has already been checked, pass
|
||||
if (checkedPoints.contains(checked.getFinalWaypoint()))
|
||||
continue;
|
||||
|
||||
paths.add(checked);
|
||||
checkedPoints.add(checked.getFinalWaypoint());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user