aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch')
-rw-r--r--patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch9
1 files changed, 4 insertions, 5 deletions
diff --git a/patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch b/patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch
index 54490f6aae..472a9fe2d4 100644
--- a/patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch
+++ b/patches/server/0799-Correctly-handle-interactions-with-items-on-cooldown.patch
@@ -30,18 +30,17 @@ index da8a60fbbba3866780615e65d6e242774a965bc6..88b71210d0845e8a4a2cd424ba238c4b
this.interactResult = event.useItemInHand() == Event.Result.DENY;
this.interactPosition = blockposition.immutable();
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-index 52a4a2b90f5b4684ffb94bf1db6020490e14942d..944bb12b14d50cdd7064ae7300c71465e15cb217 100644
+index 531eeb68bc0623b3c71e67789603ab7946e05818..a1860e21fd53b801ffd651cd27f5a8f9fcd02ee0 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-@@ -543,7 +543,13 @@ public class CraftEventFactory {
- return CraftEventFactory.callPlayerInteractEvent(who, action, position, direction, itemstack, false, hand, null);
+@@ -544,6 +544,12 @@ public class CraftEventFactory {
}
-+
-+ // Paper start - cancelledItem param
public static PlayerInteractEvent callPlayerInteractEvent(net.minecraft.world.entity.player.Player who, Action action, BlockPos position, Direction direction, ItemStack itemstack, boolean cancelledBlock, InteractionHand hand, Vec3 targetPos) {
++ // Paper start - cancelledItem param
+ return CraftEventFactory.callPlayerInteractEvent(who, action, position, direction, itemstack, cancelledBlock, false, hand, targetPos);
+ }
++
+ public static PlayerInteractEvent callPlayerInteractEvent(net.minecraft.world.entity.player.Player who, Action action, BlockPos position, Direction direction, ItemStack itemstack, boolean cancelledBlock, boolean cancelledItem, InteractionHand hand, Vec3 targetPos) {
+ // Paper end - cancelledItem param
Player player = (who == null) ? null : (Player) who.getBukkitEntity();