Skip to content

Commit

Permalink
Fix incorrect casting to float before clamping attribute values
Browse files Browse the repository at this point in the history
  • Loading branch information
Axionize committed Oct 5, 2024
1 parent ea85282 commit 55c0842
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public double with(WrapperPlayServerUpdateAttributes.Property property) {
d1 *= 1.0D + attributemodifier.getAmount();
}

double newValue = GrimMath.clampFloat((float) d1, (float) min, (float) max);
double newValue = GrimMath.clamp(d1, min, max);
if (setRewriter != null) {
newValue = setRewriter.apply(this.value, newValue);
}
Expand Down

0 comments on commit 55c0842

Please sign in to comment.