diff --git a/patches/server/PlayerReadyArrowEvent.patch b/patches/server/PlayerReadyArrowEvent.patch index 38acbec8e0..4c3dd15c72 100644 --- a/patches/server/PlayerReadyArrowEvent.patch +++ b/patches/server/PlayerReadyArrowEvent.patch @@ -28,12 +28,17 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 @Override public ItemStack getProjectile(ItemStack stack) { if (!(stack.getItem() instanceof ProjectileWeaponItem)) { -@@ -0,0 +0,0 @@ public abstract class Player extends LivingEntity { + return ItemStack.EMPTY; + } else { +- Predicate predicate = ((ProjectileWeaponItem) stack.getItem()).getSupportedHeldProjectiles(); ++ Predicate predicate = ((ProjectileWeaponItem) stack.getItem()).getSupportedHeldProjectiles().and(item -> tryReadyArrow(stack, item)); // Paper + ItemStack itemstack1 = ProjectileWeaponItem.getHeldProjectile(this, predicate); + + if (!itemstack1.isEmpty()) { + return itemstack1; + } else { +- predicate = ((ProjectileWeaponItem) stack.getItem()).getAllSupportedProjectiles(); ++ predicate = ((ProjectileWeaponItem) stack.getItem()).getAllSupportedProjectiles().and(item -> tryReadyArrow(stack, item)); // Paper + for (int i = 0; i < this.inventory.getContainerSize(); ++i) { ItemStack itemstack2 = this.inventory.getItem(i); - -- if (predicate.test(itemstack2)) { -+ if (predicate.test(itemstack2) && tryReadyArrow(stack, itemstack2)) { // Paper - return itemstack2; - } - }