diff options
Diffstat (limited to 'patches/api/0209-Add-methods-to-get-translation-keys.patch')
-rw-r--r-- | patches/api/0209-Add-methods-to-get-translation-keys.patch | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/patches/api/0209-Add-methods-to-get-translation-keys.patch b/patches/api/0209-Add-methods-to-get-translation-keys.patch index 282a4c0520..d504fbdf2a 100644 --- a/patches/api/0209-Add-methods-to-get-translation-keys.patch +++ b/patches/api/0209-Add-methods-to-get-translation-keys.patch @@ -144,10 +144,10 @@ index dc66bd69646ac949d1386ce8f6ff913e9475439d..4482e8f2c617c2f51b2b53762e775d11 + // Paper end } diff --git a/src/main/java/org/bukkit/Material.java b/src/main/java/org/bukkit/Material.java -index c605da711c032f7091390e50b4a5d332c992d3d1..61e0739f002a949a204c7591dfa3074560d1459e 100644 +index feebabf946913263461e1d0f13a478cf4bfd0f68..d6e2ec415eab4f55fd925a3b0982e869befbd088 100644 --- a/src/main/java/org/bukkit/Material.java +++ b/src/main/java/org/bukkit/Material.java -@@ -126,7 +126,7 @@ import org.jetbrains.annotations.Nullable; +@@ -129,7 +129,7 @@ import org.jetbrains.annotations.Nullable; * An enum of all material IDs accepted by the official server and client */ @SuppressWarnings({"DeprecatedIsStillUsed", "deprecation"}) // Paper @@ -156,7 +156,7 @@ index c605da711c032f7091390e50b4a5d332c992d3d1..61e0739f002a949a204c7591dfa30745 //<editor-fold desc="Materials" defaultstate="collapsed"> AIR(9648, 0), STONE(22948), -@@ -4740,6 +4740,15 @@ public enum Material implements Keyed, Translatable { +@@ -4743,6 +4743,15 @@ public enum Material implements Keyed, Translatable { } return false; } @@ -172,7 +172,7 @@ index c605da711c032f7091390e50b4a5d332c992d3d1..61e0739f002a949a204c7591dfa30745 // Paper end /** -@@ -11481,9 +11490,11 @@ public enum Material implements Keyed, Translatable { +@@ -5494,9 +5503,11 @@ public enum Material implements Keyed, Translatable { * material * @see #getBlockTranslationKey() * @see #getItemTranslationKey() @@ -183,7 +183,7 @@ index c605da711c032f7091390e50b4a5d332c992d3d1..61e0739f002a949a204c7591dfa30745 + @Deprecated(forRemoval = true) // Paper public String getTranslationKey() { if (this.isItem()) { - return Bukkit.getUnsafe().getItemTranslationKey(this); + return asItemType().getTranslationKey(); diff --git a/src/main/java/org/bukkit/MusicInstrument.java b/src/main/java/org/bukkit/MusicInstrument.java index eae90e72b1dff5ab3b1a4fdcfe57187e85fe4d49..62d2b3f950860dee0898d77b0a29635c3f9a7e23 100644 --- a/src/main/java/org/bukkit/MusicInstrument.java @@ -480,10 +480,10 @@ index 5bd252c0ae3b09fe141d131360c67bb9bfbf5422..78587d9fabe6371a23a7963917b054db + } diff --git a/src/main/java/org/bukkit/inventory/ItemStack.java b/src/main/java/org/bukkit/inventory/ItemStack.java -index e82eeadc7cb53572351670761c4e592a33345c6b..645cff10eef90826bb44bbe937b141289f182cde 100644 +index 066f99a1f4cc42cf0e87d495f97a0685817dfa18..23686519b8c1338dd6e9f1c5a0e73467c0b59a4f 100644 --- a/src/main/java/org/bukkit/inventory/ItemStack.java +++ b/src/main/java/org/bukkit/inventory/ItemStack.java -@@ -25,7 +25,7 @@ import org.jetbrains.annotations.Nullable; +@@ -27,7 +27,7 @@ import org.jetbrains.annotations.Nullable; * use this class to encapsulate Materials for which {@link Material#isItem()} * returns false.</b> */ @@ -492,7 +492,7 @@ index e82eeadc7cb53572351670761c4e592a33345c6b..645cff10eef90826bb44bbe937b14128 private Material type = Material.AIR; private int amount = 0; private MaterialData data = null; -@@ -620,6 +620,7 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, Translat +@@ -626,6 +626,7 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, Translat @Override @NotNull @@ -500,7 +500,7 @@ index e82eeadc7cb53572351670761c4e592a33345c6b..645cff10eef90826bb44bbe937b14128 public String getTranslationKey() { return Bukkit.getUnsafe().getTranslationKey(this); } -@@ -879,5 +880,16 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, Translat +@@ -885,5 +886,16 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, Translat ItemMeta itemMeta = getItemMeta(); return itemMeta != null && itemMeta.hasItemFlag(flag); } |