Adjust order.
This commit is contained in:
@@ -686,7 +686,6 @@ public interface MovementHelper extends ActionCosts, Helper {
|
|||||||
VecUtils.getBlockPosCenter(dest),
|
VecUtils.getBlockPosCenter(dest),
|
||||||
ctx.playerRotations()
|
ctx.playerRotations()
|
||||||
).getYaw();
|
).getYaw();
|
||||||
moveTowardsWithoutRotation(ctx, state, idealYaw);
|
|
||||||
float distance = Rotation.yawDistanceFromOffset(ctx.playerRotations().getYaw(), idealYaw) % 45f;
|
float distance = Rotation.yawDistanceFromOffset(ctx.playerRotations().getYaw(), idealYaw) % 45f;
|
||||||
float newYaw = distance > 0f ?
|
float newYaw = distance > 0f ?
|
||||||
distance > 22.5f ? distance - 45f : distance :
|
distance > 22.5f ? distance - 45f : distance :
|
||||||
@@ -695,6 +694,7 @@ public interface MovementHelper extends ActionCosts, Helper {
|
|||||||
ctx.playerRotations().getYaw() - newYaw,
|
ctx.playerRotations().getYaw() - newYaw,
|
||||||
ctx.playerRotations().getPitch()
|
ctx.playerRotations().getPitch()
|
||||||
), true));
|
), true));
|
||||||
|
moveTowardsWithoutRotation(ctx, state, idealYaw);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user