Small change.

This commit is contained in:
Murat65536
2025-07-23 00:29:03 -04:00
parent 5d8136b02e
commit 8ee7a1e39d
2 changed files with 2 additions and 3 deletions

View File

@@ -661,8 +661,7 @@ public interface MovementHelper extends ActionCosts, Helper {
)).setInput(Input.MOVE_FORWARD, true);
}
static void moveTowardsWithRotation(IPlayerContext ctx, MovementState state, BlockPos dest, Rotation rotation) {
state.setTarget(new MovementTarget(rotation, true));
static void moveTowardsWithoutRotation(IPlayerContext ctx, MovementState state, BlockPos dest) {
float ax = Mth.sin(ctx.playerRotations().getYaw() * DEG_TO_RAD_F);
float az = Mth.cos(ctx.playerRotations().getYaw() * DEG_TO_RAD_F);
Rotation blockRotation = RotationUtils.calcRotationFromVec3d(ctx.playerHead(),

View File

@@ -352,7 +352,7 @@ public class MovementTraverse extends Movement {
}
return state;
}
MovementHelper.moveTowardsWithRotation(ctx, state, dest, ctx.playerRotations());
MovementHelper.moveTowardsWithoutRotation(ctx, state, dest);
return state;
// TODO MovementManager.moveTowardsBlock(to); // move towards not look at because if we are bridging for a couple blocks in a row, it is faster if we dont spin around and walk forwards then spin around and place backwards for every block
}