diff --git a/paper-server/nms-patches/net/minecraft/world/item/ItemBucket.patch b/paper-server/nms-patches/net/minecraft/world/item/ItemBucket.patch index 85cf4e6c9a..4246025561 100644 --- a/paper-server/nms-patches/net/minecraft/world/item/ItemBucket.patch +++ b/paper-server/nms-patches/net/minecraft/world/item/ItemBucket.patch @@ -23,6 +23,7 @@ IFluidSource ifluidsource = (IFluidSource) iblockdata.getBlock(); + // CraftBukkit start + ItemStack dummyFluid = ifluidsource.removeFluid(DummyGeneratorAccess.INSTANCE, blockposition, iblockdata); ++ if (dummyFluid.isEmpty()) return InteractionResultWrapper.fail(itemstack); // Don't fire event if the bucket won't be filled. + PlayerBucketFillEvent event = CraftEventFactory.callPlayerBucketFillEvent((WorldServer) world, entityhuman, blockposition, blockposition, movingobjectpositionblock.getDirection(), itemstack, dummyFluid.getItem()); + + if (event.isCancelled()) {