diff --git a/patches/api/Fix-Jukeboxes.patch b/patches/api/Fix-Jukeboxes.patch deleted file mode 100644 index 4135ed985e..0000000000 --- a/patches/api/Fix-Jukeboxes.patch +++ /dev/null @@ -1,58 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Jake Potrebic -Date: Tue, 14 Mar 2023 18:55:47 -0700 -Subject: [PATCH] Fix Jukeboxes - - -diff --git a/src/main/java/org/bukkit/block/Jukebox.java b/src/main/java/org/bukkit/block/Jukebox.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/org/bukkit/block/Jukebox.java -+++ b/src/main/java/org/bukkit/block/Jukebox.java -@@ -0,0 +0,0 @@ import org.jetbrains.annotations.Nullable; - /** - * Represents a captured state of a jukebox. - */ --public interface Jukebox extends TileState { -+public interface Jukebox extends TileState, org.bukkit.inventory.BlockInventoryHolder { // Paper - - /** - * Gets the record inserted into the jukebox. -@@ -0,0 +0,0 @@ public interface Jukebox extends TileState { - * @throws IllegalStateException if this block state is not placed - */ - public boolean eject(); -+ // Paper start -+ /** -+ * @return inventory -+ * @see Container#getInventory() -+ */ -+ @NotNull -+ @Override -+ org.bukkit.inventory.Inventory getInventory(); -+ -+ /** -+ * @return snapshot inventory -+ * @see Container#getSnapshotInventory() -+ */ -+ @NotNull -+ org.bukkit.inventory.Inventory getSnapshotInventory(); -+ // Paper end - } -diff --git a/src/main/java/org/bukkit/event/inventory/InventoryType.java b/src/main/java/org/bukkit/event/inventory/InventoryType.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/org/bukkit/event/inventory/InventoryType.java -+++ b/src/main/java/org/bukkit/event/inventory/InventoryType.java -@@ -0,0 +0,0 @@ public enum InventoryType { - */ - @Deprecated @org.jetbrains.annotations.ApiStatus.Experimental // Paper - 1.20 - SMITHING_NEW(4, "Upgrade Gear"), -+ // Paper start -+ /** -+ * Pseudo jukebox inventory -+ */ -+ @org.jetbrains.annotations.ApiStatus.Experimental -+ JUKEBOX(1, "Jukebox", false); -+ // Paper end - ; - - private final int size; diff --git a/patches/api/Mark-experimental-api-as-such.patch b/patches/api/Mark-experimental-api-as-such.patch index e1e1862691..6ff31ed61f 100644 --- a/patches/api/Mark-experimental-api-as-such.patch +++ b/patches/api/Mark-experimental-api-as-such.patch @@ -1169,14 +1169,15 @@ diff --git a/src/main/java/org/bukkit/entity/Sniffer.java b/src/main/java/org/bu index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/entity/Sniffer.java +++ b/src/main/java/org/bukkit/entity/Sniffer.java -@@ -0,0 +0,0 @@ package org.bukkit.entity; - /** - * Represents a Sniffer. +@@ -0,0 +0,0 @@ import org.jetbrains.annotations.Nullable; + * Note: This entity is part of an experimental feature of Minecraft and + * hence subject to change. */ -+@org.jetbrains.annotations.ApiStatus.Experimental // Paper - 1.20 +-@ApiStatus.Experimental ++@ApiStatus.Experimental // Paper - 1.20 public interface Sniffer extends Animals { - } + /** diff --git a/src/main/java/org/bukkit/entity/memory/MemoryKey.java b/src/main/java/org/bukkit/entity/memory/MemoryKey.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/entity/memory/MemoryKey.java @@ -1200,7 +1201,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + @org.jetbrains.annotations.ApiStatus.Experimental // Paper - 1.20 CHISELED_BOOKSHELF(6, "Chiseled Bookshelf", false), /** - * The new smithing inventory, with 3 CRAFTING slots and 1 RESULT slot. + * Pseudo jukebox inventory with 1 slot of undefined type. +@@ -0,0 +0,0 @@ public enum InventoryType { * * @deprecated draft, experimental 1.20 API */ diff --git a/patches/server/Fix-Jukeboxes.patch b/patches/server/Fix-Jukeboxes.patch deleted file mode 100644 index ac2cc1c503..0000000000 --- a/patches/server/Fix-Jukeboxes.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Jake Potrebic -Date: Tue, 14 Mar 2023 18:55:56 -0700 -Subject: [PATCH] Fix Jukeboxes - - -diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftJukebox.java b/src/main/java/org/bukkit/craftbukkit/block/CraftJukebox.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/org/bukkit/craftbukkit/block/CraftJukebox.java -+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftJukebox.java -@@ -0,0 +0,0 @@ public class CraftJukebox extends CraftBlockEntityState impl - jukebox.popOutRecord(); - return result; - } -+ // Paper start -+ @Override -+ public org.bukkit.inventory.Inventory getInventory() { -+ if (!this.isPlaced()) { -+ return this.getSnapshotInventory(); -+ } -+ return new org.bukkit.craftbukkit.inventory.CraftInventory(this.getTileEntity()); -+ } -+ -+ @Override -+ public org.bukkit.inventory.Inventory getSnapshotInventory() { -+ return new org.bukkit.craftbukkit.inventory.CraftInventory(this.getSnapshot()); -+ } -+ // Paper end - } -diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java -+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java -@@ -0,0 +0,0 @@ public class CraftInventory implements Inventory { - return InventoryType.COMPOSTER; - } else if (this instanceof CraftInventorySmithingNew) { - return InventoryType.SMITHING_NEW; -+ // Paper start -+ } else if (this.inventory instanceof net.minecraft.world.level.block.entity.JukeboxBlockEntity) { -+ return InventoryType.JUKEBOX; -+ // Paper end - } else { - return InventoryType.CHEST; - } diff --git a/work/Bukkit b/work/Bukkit index 150a2861a7..2c64d8c4a8 160000 --- a/work/Bukkit +++ b/work/Bukkit @@ -1 +1 @@ -Subproject commit 150a2861a7399537d077bb754438d12a8741fe36 +Subproject commit 2c64d8c4a880c6aec8ee8ce3abdd0238b0e0d8a3 diff --git a/work/CraftBukkit b/work/CraftBukkit index e5a7921f05..93813509b6 160000 --- a/work/CraftBukkit +++ b/work/CraftBukkit @@ -1 +1 @@ -Subproject commit e5a7921f0597766fd92590317da11ffea85138a4 +Subproject commit 93813509b6dd3476419a5344b252aa1867960090 diff --git a/work/Spigot b/work/Spigot index 41150f3919..6ad4b93c2a 160000 --- a/work/Spigot +++ b/work/Spigot @@ -1 +1 @@ -Subproject commit 41150f3919a43f833c5c81734afc71ad419c6816 +Subproject commit 6ad4b93c2ab4d981910821bd43be6a085177bed9