summaryrefslogtreecommitdiffstats
path: root/nms-patches/DispenserRegistry.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/DispenserRegistry.patch')
-rw-r--r--nms-patches/DispenserRegistry.patch11
1 files changed, 6 insertions, 5 deletions
diff --git a/nms-patches/DispenserRegistry.patch b/nms-patches/DispenserRegistry.patch
index 85c1dd22..9246d281 100644
--- a/nms-patches/DispenserRegistry.patch
+++ b/nms-patches/DispenserRegistry.patch
@@ -164,7 +164,7 @@
@@ -169,9 +265,48 @@
ItemBucket itembucket = (ItemBucket) itemstack.getItem();
- BlockPosition blockposition = isourceblock.getBlockPosition().shift(BlockDispenser.e(isourceblock.f()));
+ BlockPosition blockposition = isourceblock.getBlockPosition().shift((EnumDirection) isourceblock.e().get(BlockDispenser.FACING));
+ // CraftBukkit start
+ World world = isourceblock.getWorld();
@@ -246,7 +246,7 @@
itemstack.setItem(item);
@@ -220,11 +379,39 @@
World world = isourceblock.getWorld();
- BlockPosition blockposition = isourceblock.getBlockPosition().shift(BlockDispenser.e(isourceblock.f()));
+ BlockPosition blockposition = isourceblock.getBlockPosition().shift((EnumDirection) isourceblock.e().get(BlockDispenser.FACING));
+ // CraftBukkit start
+ org.bukkit.block.Block block = world.getWorld().getBlockAt(isourceblock.getBlockPosition().getX(), isourceblock.getBlockPosition().getY(), isourceblock.getBlockPosition().getZ());
@@ -289,7 +289,7 @@
world.setAir(blockposition);
@@ -252,6 +439,30 @@
World world = isourceblock.getWorld();
- BlockPosition blockposition = isourceblock.getBlockPosition().shift(BlockDispenser.e(isourceblock.f()));
+ BlockPosition blockposition = isourceblock.getBlockPosition().shift((EnumDirection) isourceblock.e().get(BlockDispenser.FACING));
+ // CraftBukkit start
+ org.bukkit.block.Block block = world.getWorld().getBlockAt(isourceblock.getBlockPosition().getX(), isourceblock.getBlockPosition().getY(), isourceblock.getBlockPosition().getZ());
@@ -321,7 +321,7 @@
@@ -279,11 +490,40 @@
protected ItemStack b(ISourceBlock isourceblock, ItemStack itemstack) {
World world = isourceblock.getWorld();
- BlockPosition blockposition = isourceblock.getBlockPosition().shift(BlockDispenser.e(isourceblock.f()));
+ BlockPosition blockposition = isourceblock.getBlockPosition().shift((EnumDirection) isourceblock.e().get(BlockDispenser.FACING));
- EntityTNTPrimed entitytntprimed = new EntityTNTPrimed(world, (double) blockposition.getX() + 0.5D, (double) blockposition.getY(), (double) blockposition.getZ() + 0.5D, (EntityLiving) null);
+ // EntityTNTPrimed entitytntprimed = new EntityTNTPrimed(world, (double) blockposition.getX() + 0.5D, (double) blockposition.getY(), (double) blockposition.getZ() + 0.5D, (EntityLiving) null);
+
@@ -355,8 +355,9 @@
+ // CraftBukkit end
world.addEntity(entitytntprimed);
- world.a((EntityHuman) null, entitytntprimed.locX, entitytntprimed.locY, entitytntprimed.locZ, SoundEffects.gk, SoundCategory.BLOCKS, 1.0F, 1.0F);
+- world.a((EntityHuman) null, entitytntprimed.locX, entitytntprimed.locY, entitytntprimed.locZ, SoundEffects.gz, SoundCategory.BLOCKS, 1.0F, 1.0F);
- --itemstack.count;
++ world.a((EntityHuman) null, entitytntprimed.locX, entitytntprimed.locY, entitytntprimed.locZ, SoundEffects.gk, SoundCategory.BLOCKS, 1.0F, 1.0F);
+ // --itemstack.count; // CraftBukkit - handled above
return itemstack;
}