Skip to content

Commit

Permalink
revert needless changes to UtilityCommands
Browse files Browse the repository at this point in the history
  • Loading branch information
dordsor21 committed Sep 18, 2023
1 parent 807227f commit d35e568
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ public int fill(Actor actor, LocalSession session, EditSession editSession,
radius = Math.max(1, radius);
we.checkMaxRadius(radius);
depth = Math.max(1, depth);
we.checkMaxRadius(depth);

BlockVector3 pos = session.getPlacementPosition(actor);
int affected = editSession.fillXZ(pos, pattern, radius, depth, false);
Expand All @@ -124,8 +123,8 @@ public int fillr(Actor actor, LocalSession session, EditSession editSession,
Integer depth) throws WorldEditException {
radius = Math.max(1, radius);
we.checkMaxRadius(radius);
depth = depth == null ? (int) Math.round(radius) : Math.max(1, depth);
we.checkMaxRadius(depth);
depth = depth == null ? Integer.MAX_VALUE : Math.max(1, depth);
we.checkMaxRadius(radius);

BlockVector3 pos = session.getPlacementPosition(actor);
int affected = editSession.fillXZ(pos, pattern, radius, depth, true);
Expand Down

0 comments on commit d35e568

Please sign in to comment.