diff --git a/patches/api/0490-Improve-entity-effect-API.patch b/patches/api/0490-Improve-entity-effect-API.patch index 582a502735..6ec450bcea 100644 --- a/patches/api/0490-Improve-entity-effect-API.patch +++ b/patches/api/0490-Improve-entity-effect-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Improve entity effect API diff --git a/src/main/java/org/bukkit/EntityEffect.java b/src/main/java/org/bukkit/EntityEffect.java -index 5341957b10cccd7bce5a7595699b1d90412a01d0..912dafd5a8884d7973b2126f97ecdbe54e78937f 100644 +index 5341957b10cccd7bce5a7595699b1d90412a01d0..ef0acab253db878f1edee51b585fd1b20ef9161d 100644 --- a/src/main/java/org/bukkit/EntityEffect.java +++ b/src/main/java/org/bukkit/EntityEffect.java @@ -112,11 +112,25 @@ public enum EntityEffect { @@ -76,7 +76,7 @@ index 5341957b10cccd7bce5a7595699b1d90412a01d0..912dafd5a8884d7973b2126f97ecdbe5 HURT_BERRY_BUSH(44, LivingEntity.class), /** * Fox chews the food in its mouth -@@ -331,7 +355,24 @@ public enum EntityEffect { +@@ -331,7 +355,25 @@ public enum EntityEffect { * Sniffer must have a target and be in {@link Sniffer.State#SEARCHING} or * {@link Sniffer.State#DIGGING} */ @@ -97,6 +97,7 @@ index 5341957b10cccd7bce5a7595699b1d90412a01d0..912dafd5a8884d7973b2126f97ecdbe5 + * creaking heart. + */ + @MinecraftExperimental(MinecraftExperimental.Requires.WINTER_DROP) ++ @org.jetbrains.annotations.ApiStatus.Experimental + SHAKE(66, org.bukkit.entity.CreakingTransient.class); + // Paper end - add missing EntityEffect diff --git a/patches/server/0936-Fix-possible-StackOverflowError-and-NPE-for-some-dis.patch b/patches/server/0936-Fix-possible-StackOverflowError-and-NPE-for-some-dis.patch index 2070223780..25ace4aa41 100644 --- a/patches/server/0936-Fix-possible-StackOverflowError-and-NPE-for-some-dis.patch +++ b/patches/server/0936-Fix-possible-StackOverflowError-and-NPE-for-some-dis.patch @@ -45,7 +45,7 @@ index 39c96f5db6e90a470404c6387fa0c1d5531822e5..8aae1d113e84dfad9f2b6f0bcd203ca6 idispensebehavior.dispense(sourceblock, eventStack); } else { diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 18304349c9ab24657c4152aff800dba969174665..94b2647f69035dce9a3d56b6978e3884e06c5583 100644 +index 18304349c9ab24657c4152aff800dba969174665..681c38f4457fc10806c10518b16159580c0f2619 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java @@ -124,7 +124,7 @@ public interface DispenseItemBehavior { @@ -73,7 +73,7 @@ index 18304349c9ab24657c4152aff800dba969174665..94b2647f69035dce9a3d56b6978e3884 - DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); - if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE) { + DispenseItemBehavior idispensebehavior = DispenserBlock.getDispenseBehavior(pointer, eventStack); // Paper - Fix NPE with equippable and items without behavior -+ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE && idispensebehavior != this) { // Paper - fix possible StackOverflowError ++ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != this) { // Paper - fix possible StackOverflowError idispensebehavior.dispense(pointer, eventStack); return stack; } @@ -84,7 +84,7 @@ index 18304349c9ab24657c4152aff800dba969174665..94b2647f69035dce9a3d56b6978e3884 - DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); - if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE) { + DispenseItemBehavior idispensebehavior = DispenserBlock.getDispenseBehavior(pointer, eventStack); // Paper - Fix NPE with equippable and items without behavior -+ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE && idispensebehavior != this) { // Paper - fix possible StackOverflowError ++ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != this) { // Paper - fix possible StackOverflowError idispensebehavior.dispense(pointer, eventStack); return stack; } @@ -185,7 +185,7 @@ index 18304349c9ab24657c4152aff800dba969174665..94b2647f69035dce9a3d56b6978e3884 - DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); - if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE) { + DispenseItemBehavior idispensebehavior = DispenserBlock.getDispenseBehavior(pointer, eventStack); // Paper - Fix NPE with equippable and items without behavior -+ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != EquipmentDispenseItemBehavior.INSTANCE && idispensebehavior != this) { // Paper - fix possible StackOverflowError ++ if (idispensebehavior != DispenseItemBehavior.NOOP && idispensebehavior != this) { // Paper - fix possible StackOverflowError idispensebehavior.dispense(pointer, eventStack); return stack; } diff --git a/patches/server/0940-Properly-track-the-changed-item-from-dispense-events.patch b/patches/server/0940-Properly-track-the-changed-item-from-dispense-events.patch index d653a24df5..872400fdee 100644 --- a/patches/server/0940-Properly-track-the-changed-item-from-dispense-events.patch +++ b/patches/server/0940-Properly-track-the-changed-item-from-dispense-events.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Properly track the changed item from dispense events diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 94b2647f69035dce9a3d56b6978e3884e06c5583..a09b089565f9167e1a2d53116ae879d9f868342e 100644 +index 681c38f4457fc10806c10518b16159580c0f2619..8f9b86e50717746e55232293d9e5ac05b8616aa0 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java @@ -129,10 +129,14 @@ public interface DispenseItemBehavior {