mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-12-29 12:37:37 +01:00
Allow 50,000 iterations of A*
This commit is contained in:
parent
3e1a15e347
commit
54eb4e31da
@ -29,7 +29,7 @@ public class AStarNavigationStrategy extends AbstractPathStrategy {
|
|||||||
this.npc = npc;
|
this.npc = npc;
|
||||||
Location location = npc.getBukkitEntity().getEyeLocation();
|
Location location = npc.getBukkitEntity().getEyeLocation();
|
||||||
plan = ASTAR.runFully(new VectorGoal(dest, (float) params.distanceMargin()), new VectorNode(location,
|
plan = ASTAR.runFully(new VectorGoal(dest, (float) params.distanceMargin()), new VectorNode(location,
|
||||||
new ChunkBlockSource(location, params.range()), params.examiners()), (int) (params.range() * 10));
|
new ChunkBlockSource(location, params.range()), params.examiners()), 50000);
|
||||||
if (plan == null || plan.isComplete()) {
|
if (plan == null || plan.isComplete()) {
|
||||||
setCancelReason(CancelReason.STUCK);
|
setCancelReason(CancelReason.STUCK);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user