diff --git a/src/main/java/dan200/computercraft/shared/turtle/core/TurtlePlaceCommand.java b/src/main/java/dan200/computercraft/shared/turtle/core/TurtlePlaceCommand.java index 46f65f632..1e9d339bc 100644 --- a/src/main/java/dan200/computercraft/shared/turtle/core/TurtlePlaceCommand.java +++ b/src/main/java/dan200/computercraft/shared/turtle/core/TurtlePlaceCommand.java @@ -312,17 +312,11 @@ public class TurtlePlaceCommand implements ITurtleCommand { } if (!placed && (item instanceof BucketItem || item instanceof BoatItem || item instanceof LilyPadItem || item instanceof GlassBottleItem)) { - TypedActionResult actionResult = stackCopy.use(turtle.getWorld(), turtlePlayer, Hand.MAIN_HAND); - if (actionResult != null && actionResult.getResult() - .isAccepted()) { + TypedActionResult result = stackCopy.use(turtle.getWorld(), turtlePlayer, Hand.MAIN_HAND); + if (result.getResult() + .isAccepted() && !ItemStack.areEqual(stack, result.getValue())) { placed = true; - } else if (actionResult == null) { - TypedActionResult result = stackCopy.use(turtle.getWorld(), turtlePlayer, Hand.MAIN_HAND); - if (result.getResult() - .isAccepted() && !ItemStack.areEqual(stack, result.getValue())) { - placed = true; - turtlePlayer.loadInventory(result.getValue()); - } + turtlePlayer.loadInventory(result.getValue()); } }