Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Please note that this build includes changes to meet upstreams requirements for nullability annotations. While we aim for a level of accuracy, these might not be 100% correct, if there are any issues, please speak to us on discord, or open an issue on the tracker to discuss. Bukkit Changes: 9a6a1de3 Remove nullability annotations from enum constructors 3f0591ea SPIGOT-2540: Add nullability annotations to entire Bukkit API CraftBukkit Changes: 8d8475fc SPIGOT-4666: Force parameter in HumanEntity#sleep 8b1588e2 Fix ExplosionPrimeEvent#setFire not working with EnderCrystals 39a287b7 Don't ignore newlines in PlayerListHeader/Footer Spigot Changes: cf694d87 Add nullability annotations
This commit is contained in:
@@ -8,13 +8,13 @@ Currently the server only supports the English language. To override this,
|
||||
You must replace the language file embedded in the server jar.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/inventory/ItemFactory.java b/src/main/java/org/bukkit/inventory/ItemFactory.java
|
||||
index 3012aec2..63dd1b32 100644
|
||||
index 8e602cf51..dca77bbaf 100644
|
||||
--- a/src/main/java/org/bukkit/inventory/ItemFactory.java
|
||||
+++ b/src/main/java/org/bukkit/inventory/ItemFactory.java
|
||||
@@ -0,0 +0,0 @@ public interface ItemFactory {
|
||||
* @return A potentially Data Converted ItemStack
|
||||
*/
|
||||
ItemStack ensureServerConversions(ItemStack item);
|
||||
@NotNull
|
||||
ItemStack ensureServerConversions(@NotNull ItemStack item);
|
||||
+
|
||||
+ /**
|
||||
+ * Gets the Display name as seen in the Client.
|
||||
@@ -24,11 +24,12 @@ index 3012aec2..63dd1b32 100644
|
||||
+ * @param item Item to return Display name of
|
||||
+ * @return Display name of Item
|
||||
+ */
|
||||
+ String getI18NDisplayName(ItemStack item);
|
||||
+ @Nullable
|
||||
+ String getI18NDisplayName(@Nullable ItemStack item);
|
||||
// Paper end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/inventory/ItemStack.java b/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
index 5e8de115..c3cb1247 100644
|
||||
index e8f97c949..b1c02ac0d 100644
|
||||
--- a/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
+++ b/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
@@ -0,0 +0,0 @@ public class ItemStack implements Cloneable, ConfigurationSerializable {
|
||||
@@ -43,6 +44,7 @@ index 5e8de115..c3cb1247 100644
|
||||
+ *
|
||||
+ * @return Display name of Item
|
||||
+ */
|
||||
+ @Nullable
|
||||
+ public String getI18NDisplayName() {
|
||||
+ return Bukkit.getServer().getItemFactory().getI18NDisplayName(this);
|
||||
+ }
|
||||
|
||||
Reference in New Issue
Block a user