diff --git a/patches/api/Add-missing-effects.patch b/patches/api/Add-missing-effects.patch index df6d3deb48..78e2975368 100644 --- a/patches/api/Add-missing-effects.patch +++ b/patches/api/Add-missing-effects.patch @@ -21,6 +21,16 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 * additional info. */ POTION_BREAK(2002, Type.VISUAL, Color.class), +@@ -0,0 +0,0 @@ public enum Effect { + PORTAL_TRAVEL(1032, Type.SOUND), + /** + * The sound played when launching an endereye ++ * @deprecated No longer exists + */ ++ @Deprecated(forRemoval = true, since = "1.21") // Paper + ENDEREYE_LAUNCH(1003, Type.SOUND), + /** + * The sound played when launching a firework @@ -0,0 +0,0 @@ public enum Effect { /** * Particles displayed when a villager grows a plant, data @@ -208,7 +218,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + /** + * {@link Boolean} param is true for "ominous" vaults + */ -+ TRIAL_SPAWNER_SPAWN_ITEM(3021, Type.VISUAL, Boolean.class) ++ TRIAL_SPAWNER_SPAWN_ITEM(3021, Type.VISUAL, Boolean.class), ++ ++ SOUND_WITH_CHARGE_SHOT(1051, Type.SOUND), ; + private static final org.apache.logging.log4j.Logger LOGGER = org.apache.logging.log4j.LogManager.getLogger(); + // Paper end diff --git a/patches/api/Fix-equipment-slot-and-group-API.patch b/patches/api/Fix-equipment-slot-and-group-API.patch index 05173a0f30..58fcf467bd 100644 --- a/patches/api/Fix-equipment-slot-and-group-API.patch +++ b/patches/api/Fix-equipment-slot-and-group-API.patch @@ -47,14 +47,29 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 */ @NotNull public ItemStack getItem(@NotNull EquipmentSlot slot); +diff --git a/src/main/java/org/bukkit/inventory/EquipmentSlot.java b/src/main/java/org/bukkit/inventory/EquipmentSlot.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/org/bukkit/inventory/EquipmentSlot.java ++++ b/src/main/java/org/bukkit/inventory/EquipmentSlot.java +@@ -0,0 +0,0 @@ public enum EquipmentSlot { + /** + * Only for certain entities such as horses and wolves. + */ +- BODY(() -> EquipmentSlotGroup.ARMOR); ++ BODY(() -> EquipmentSlotGroup.BODY); // Paper - add missing slot type + + private final Supplier group; // Supplier because of class loading order, since EquipmentSlot and EquipmentSlotGroup reference each other on class init + diff --git a/src/main/java/org/bukkit/inventory/EquipmentSlotGroup.java b/src/main/java/org/bukkit/inventory/EquipmentSlotGroup.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/inventory/EquipmentSlotGroup.java +++ b/src/main/java/org/bukkit/inventory/EquipmentSlotGroup.java @@ -0,0 +0,0 @@ public final class EquipmentSlotGroup implements Predicate { + public static final EquipmentSlotGroup LEGS = get("legs", EquipmentSlot.LEGS); public static final EquipmentSlotGroup CHEST = get("chest", EquipmentSlot.CHEST); public static final EquipmentSlotGroup HEAD = get("head", EquipmentSlot.HEAD); - public static final EquipmentSlotGroup ARMOR = get("armor", (test) -> test == EquipmentSlot.FEET || test == EquipmentSlot.LEGS || test == EquipmentSlot.CHEST || test == EquipmentSlot.HEAD, EquipmentSlot.CHEST); +- public static final EquipmentSlotGroup ARMOR = get("armor", (test) -> test == EquipmentSlot.FEET || test == EquipmentSlot.LEGS || test == EquipmentSlot.CHEST || test == EquipmentSlot.HEAD, EquipmentSlot.CHEST); ++ public static final EquipmentSlotGroup ARMOR = get("armor", (test) -> test == EquipmentSlot.FEET || test == EquipmentSlot.LEGS || test == EquipmentSlot.CHEST || test == EquipmentSlot.HEAD || test == EquipmentSlot.BODY, EquipmentSlot.CHEST); // Paper - add missing slot type + public static final EquipmentSlotGroup BODY = get("body", EquipmentSlot.BODY); // Paper - add missing slot group // private final String key; diff --git a/patches/server/Add-RegistryAccess-for-managing-Registries.patch b/patches/server/Add-RegistryAccess-for-managing-Registries.patch index aa5c78db20..4651447b7c 100644 --- a/patches/server/Add-RegistryAccess-for-managing-Registries.patch +++ b/patches/server/Add-RegistryAccess-for-managing-Registries.patch @@ -922,7 +922,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 class RegistryKeyTest extends AbstractTestingBase { @@ -0,0 +0,0 @@ class RegistryKeyTest extends AbstractTestingBase { void testApiRegistryKeysExist(final RegistryKey key) { - final Optional> registry = AbstractTestingBase.REGISTRY_CUSTOM.registry(ResourceKey.createRegistryKey(new ResourceLocation(key.key().asString()))); + final Optional> registry = AbstractTestingBase.REGISTRY_CUSTOM.registry(ResourceKey.createRegistryKey(ResourceLocation.parse(key.key().asString()))); assertTrue(registry.isPresent(), "Missing vanilla registry for " + key.key().asString()); + } diff --git a/patches/server/Remap-fixes.patch b/patches/server/Remap-fixes.patch index b636a13b75..db2b065511 100644 --- a/patches/server/Remap-fixes.patch +++ b/patches/server/Remap-fixes.patch @@ -90,7 +90,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 public void checkColor(DyeColor dye) { Color color = dye.getColor(); - int nmsColorArray = DyeColor.byId(dye.getWoolData()).getTextureDiffuseColor(); -+ int nmsColorArray = net.minecraft.world.item.DyeColor.byId(dye.getWoolData()).getTextureDiffuseColors(); // Paper - remap fix ++ int nmsColorArray = net.minecraft.world.item.DyeColor.byId(dye.getWoolData()).getTextureDiffuseColor(); // Paper - remap fix Color nmsColor = Color.fromARGB(nmsColorArray); assertThat(color, is(nmsColor)); } diff --git a/patches/server/Test-changes.patch b/patches/server/Test-changes.patch index 8d0763841b..09d9291418 100644 --- a/patches/server/Test-changes.patch +++ b/patches/server/Test-changes.patch @@ -63,7 +63,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + @ParameterizedTest + @MethodSource("data") + void testApiRegistryKeysExist(final RegistryKey key) { -+ final Optional> registry = AbstractTestingBase.REGISTRY_CUSTOM.registry(ResourceKey.createRegistryKey(new ResourceLocation(key.key().asString()))); ++ final Optional> registry = AbstractTestingBase.REGISTRY_CUSTOM.registry(ResourceKey.createRegistryKey(ResourceLocation.parse(key.key().asString()))); + assertTrue(registry.isPresent(), "Missing vanilla registry for " + key.key().asString()); + + }