From 5e0fe6d89759854e98278a312542ad0c5f70cbe1 Mon Sep 17 00:00:00 2001 From: Leijurv Date: Wed, 25 Aug 2021 22:18:23 -0700 Subject: [PATCH] fix the comment explaining the sign flip bug originates from august 17 2018 in https://github.com/cabaletta/baritone/commit/f3d9ada6750db5969ea70ef8d60259deb302acf4#diff-b9b328a67abb41c2f842f367f83d95a2793c95cba83ab2e4542b31ed4c157819R101-R103 absolutely wild how long this took to notice, see PR #2954 --- src/api/java/baritone/api/pathing/goals/GoalBlock.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/api/java/baritone/api/pathing/goals/GoalBlock.java b/src/api/java/baritone/api/pathing/goals/GoalBlock.java index 0b7ff3207..7a612deda 100644 --- a/src/api/java/baritone/api/pathing/goals/GoalBlock.java +++ b/src/api/java/baritone/api/pathing/goals/GoalBlock.java @@ -87,8 +87,8 @@ public class GoalBlock implements Goal, IGoalRenderPos { public static double calculate(double xDiff, int yDiff, double zDiff) { double heuristic = 0; - // if yDiff is 1 that means that pos.getY()-this.y==1 which means that we're 1 block below where we should be - // therefore going from 0,0,0 to a GoalYLevel of pos.getY()-this.y is accurate + // if yDiff is 1 that means that pos.getY()-this.y==1 which means that we're 1 block above where we should be + // therefore going from 0,pos.getY()-this.y,0 to a GoalYLevel of 0 is accurate heuristic += GoalYLevel.calculate(0, yDiff); //use the pythagorean and manhattan mixture from GoalXZ