PaperMC/paper-server/nms-patches/net/minecraft/world/level/block/SculkShriekerBlock.patch

22 lines
919 B
Diff
Raw Normal View History

--- a/net/minecraft/world/level/block/SculkShriekerBlock.java
+++ b/net/minecraft/world/level/block/SculkShriekerBlock.java
@@ -140,10 +140,17 @@
@Override
public void spawnAfterBreak(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, ItemStack itemstack, boolean flag) {
super.spawnAfterBreak(iblockdata, worldserver, blockposition, itemstack, flag);
+ // CraftBukkit start - Delegate to getExpDrop
+ }
+
+ @Override
+ public int getExpDrop(IBlockData iblockdata, WorldServer worldserver, BlockPosition blockposition, ItemStack itemstack, boolean flag) {
if (flag) {
- this.tryDropExperience(worldserver, blockposition, itemstack, ConstantInt.of(5));
+ return this.tryDropExperience(worldserver, blockposition, itemstack, ConstantInt.of(5));
}
+ return 0;
+ // CraftBukkit end
}
@Nullable