diff --git a/src/main/java/baritone/behavior/PathingBehavior.java b/src/main/java/baritone/behavior/PathingBehavior.java index f10a15cd..14b8db26 100644 --- a/src/main/java/baritone/behavior/PathingBehavior.java +++ b/src/main/java/baritone/behavior/PathingBehavior.java @@ -352,7 +352,12 @@ public final class PathingBehavior extends Behavior implements IPathingBehavior, } else { timeout = Baritone.settings().planAheadTimeoutMS.get(); } - Optional> favoredPositions = previous.map(IPath::positions).map(Collection::stream).map(x -> x.map(BetterBlockPos::longHash)).map(x -> x.collect(Collectors.toList())).map(HashSet::new); // <-- okay this is EPIC + Optional> favoredPositions; + if (Baritone.settings().backtrackCostFavoringCoefficient.get() == 1D) { + favoredPositions = Optional.empty(); + } else { + favoredPositions = previous.map(IPath::positions).map(Collection::stream).map(x -> x.map(BetterBlockPos::longHash)).map(x -> x.collect(Collectors.toList())).map(HashSet::new); // <-- okay this is EPIC + } try { IPathFinder pf = new AStarPathFinder(start, goal, favoredPositions); return pf.calculate(timeout);