From 21d8c11cfeb7cc0980f3ba7163f6bb29f5945d8a Mon Sep 17 00:00:00 2001 From: Leijurv Date: Tue, 4 Dec 2018 15:33:29 -0800 Subject: [PATCH] go in the opposite order --- .../baritone/pathing/movement/movements/MovementParkour.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/baritone/pathing/movement/movements/MovementParkour.java b/src/main/java/baritone/pathing/movement/movements/MovementParkour.java index 5520d1c1..949598ea 100644 --- a/src/main/java/baritone/pathing/movement/movements/MovementParkour.java +++ b/src/main/java/baritone/pathing/movement/movements/MovementParkour.java @@ -212,7 +212,7 @@ public class MovementParkour extends Movement { if (!MovementHelper.canWalkOn(ctx, dest.down()) && !ctx.player().onGround) { BlockPos positionToPlace = dest.down(); - for (int i = 0; i < 5; i++) { + for (int i = 4; i >= 0; i--) { // go in the opposite order to check DOWN before all horizontals -- down is preferable because you don't have to look to the side while in midair, which could mess up the trajectory BlockPos against1 = positionToPlace.offset(HORIZONTALS_BUT_ALSO_DOWN____SO_EVERY_DIRECTION_EXCEPT_UP[i]); if (against1.up().equals(src.offset(direction, 3))) { // we can't turn around that fast continue;