diff --git a/src/api/java/baritone/api/pathing/goals/GoalNear.java b/src/api/java/baritone/api/pathing/goals/GoalNear.java index 6f493fa5..c7e932e2 100644 --- a/src/api/java/baritone/api/pathing/goals/GoalNear.java +++ b/src/api/java/baritone/api/pathing/goals/GoalNear.java @@ -56,7 +56,7 @@ public class GoalNear implements Goal, IGoalRenderPos { @Override public double heuristic() {//TODO less hacky solution - int range = (int)Math.ceil(Math.abs(Math.sqrt(rangeSq))); + int range = (int)Math.ceil(Math.sqrt(rangeSq)); HashSet maybeAlwaysInside = new HashSet<>(); HashSet sometimesOutside = new HashSet<>(); for (int dx = -range; dx <= range; dx++) { diff --git a/src/api/java/baritone/api/pathing/goals/GoalRunAway.java b/src/api/java/baritone/api/pathing/goals/GoalRunAway.java index 76f7110c..9ee1b151 100644 --- a/src/api/java/baritone/api/pathing/goals/GoalRunAway.java +++ b/src/api/java/baritone/api/pathing/goals/GoalRunAway.java @@ -85,7 +85,7 @@ public class GoalRunAway implements Goal { @Override public double heuristic() {//TODO less hacky solution - int distance = (int)Math.ceil(Math.abs(Math.sqrt(distanceSq))); + int distance = (int)Math.ceil(Math.sqrt(distanceSq)); int minX = from[0].getX() - distance; int minY = from[0].getY() - distance; int minZ = from[0].getZ() - distance;