Skip to content

Commit

Permalink
Use MathHelper for Block::range
Browse files Browse the repository at this point in the history
  • Loading branch information
iamnoksio authored Aug 14, 2024
1 parent 713dfa0 commit d5205f3
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions nPaper-Server/src/main/java/net/minecraft/server/Block.java
Original file line number Diff line number Diff line change
Expand Up @@ -826,13 +826,7 @@ public int getExpDrop(World world, int data, int enchantmentLevel) {

// Spigot start
public static float range(float min, float value, float max) {
if (value < min) {
return min;
}
if (value > max) {
return max;
}
return value;
return MathHelper.limit(value, min, max);
}
// Spigot end
}

0 comments on commit d5205f3

Please sign in to comment.