Skip to content

Commit

Permalink
Fix inaccurate Y value for <=1.13.2, Fixes #225 (#634)
Browse files Browse the repository at this point in the history
  • Loading branch information
lowercasebtw authored Nov 29, 2024
1 parent a293c14 commit 6b087f9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ private void use1_20_6StepCollisionCalculation(Vec3d movement, CallbackInfoRetur
}

if (vec3d2.horizontalLengthSquared() > adjustedMovement.horizontalLengthSquared()) {
adjustedMovement = vec3d2.add(Entity.adjustMovementForCollisions(thiz, new Vec3d(0D, -vec3d2.y + movement.y, 0D), box.offset(vec3d2), this.getWorld(), collisions));
adjustedMovement = vec3d2.add(Entity.adjustMovementForCollisions(thiz, new Vec3d(0D, -vec3d2.y + (ProtocolTranslator.getTargetVersion().olderThanOrEqualTo(ProtocolVersion.v1_13_2) ? 0 : movement.y), 0D), box.offset(vec3d2), this.getWorld(), collisions));
}
}

Expand Down

0 comments on commit 6b087f9

Please sign in to comment.