diff options
author | md_5 <git@md-5.net> | 2016-03-04 15:24:51 +1100 |
---|---|---|
committer | md_5 <git@md-5.net> | 2016-03-04 15:24:51 +1100 |
commit | 5a3813d7fe49a683eee4a9fdea1ad0725591eec5 (patch) | |
tree | d7d7dcf386662519de2b973058d41526b6db44a2 /nms-patches/ItemBoat.patch | |
parent | 3e3516e3b29763ccd3c20650a41d378857093280 (diff) | |
download | craftbukkit-5a3813d7fe49a683eee4a9fdea1ad0725591eec5.tar craftbukkit-5a3813d7fe49a683eee4a9fdea1ad0725591eec5.tar.gz craftbukkit-5a3813d7fe49a683eee4a9fdea1ad0725591eec5.tar.lz craftbukkit-5a3813d7fe49a683eee4a9fdea1ad0725591eec5.tar.xz craftbukkit-5a3813d7fe49a683eee4a9fdea1ad0725591eec5.zip |
SPIGOT-1608: Add a way to get the hand used in PlayerInteract*Events
Diffstat (limited to 'nms-patches/ItemBoat.patch')
-rw-r--r-- | nms-patches/ItemBoat.patch | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nms-patches/ItemBoat.patch b/nms-patches/ItemBoat.patch index daeabd5e..410c84fd 100644 --- a/nms-patches/ItemBoat.patch +++ b/nms-patches/ItemBoat.patch @@ -5,7 +5,7 @@ return new InteractionResultWrapper(EnumInteractionResult.PASS, itemstack); } else { + // CraftBukkit start - Boat placement -+ org.bukkit.event.player.PlayerInteractEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(entityhuman, org.bukkit.event.block.Action.RIGHT_CLICK_BLOCK, movingobjectposition.a(), movingobjectposition.direction, itemstack); ++ org.bukkit.event.player.PlayerInteractEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(entityhuman, org.bukkit.event.block.Action.RIGHT_CLICK_BLOCK, movingobjectposition.a(), movingobjectposition.direction, itemstack, enumhand); + + if (event.isCancelled()) { + return new InteractionResultWrapper(EnumInteractionResult.PASS, itemstack); |