aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/api/0484-Add-FeatureFlag-API.patch
diff options
context:
space:
mode:
authorBjarne Koll <[email protected]>2024-12-02 18:36:54 +0100
committerBjarne Koll <[email protected]>2024-12-02 18:36:54 +0100
commitb46007fbfa32c08c9228a604b7a66a5897114a81 (patch)
tree94535ef3645529d0471c1ea6b8b9cf1ba31bc0ef /patches/api/0484-Add-FeatureFlag-API.patch
parentc2294d7067959d264eb8ad275557f194a3e2656f (diff)
downloadPaper-upstream-update.tar.gz
Paper-upstream-update.zip
Updated Upstream (Bukkit/CraftBukkit/Spigot)upstream-update
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Bukkit Changes: ed0ec489 SPIGOT-7965: Unknown TransformReason for Hoglins 9db03457 SPIGOT-7964: Fix typo in Deprecation annotation d14119af PR-1082: Add "since" to Deprecation annotations e8a318d4 PR-1067: Add method to get Advancement requirements CraftBukkit Changes: 40dd796db SPIGOT-7971: NotSerializableException on serialize CraftUseCooldownComponent fa85c5e0a SPIGOT-7968: ProjectileHitEvent not trigerred when arrow hits entity b75b792ec SPIGOT-7970: World#getMaxHeight() returning incorrect value 2b9a094bb SPIGOT-7965: Unknown TransformReason for Hoglins fd3f5a380 SPIGOT-7966: Some trees do not generate with #generateTree f2822317c PR-1515: Add a Class reader and Class node argument provider 07abf6852 PR-1514: Add a test case for ClassTraverser a7577cb24 Fix Inventory#addItem not respecting max stack size 066a74e74 PR-1490: Add method to get Advancement requirements 4a1df30e4 PR-1512: Test Art class based on specific values instead of the implementation, to better catch implementation changes 53254c56f PR-1503: Simplify CAS loop to getAndSet e9447dc5e Make BlockDataMeta#setBlockData hide unspecified states dd08a7120 SPIGOT-7960: Fix inconsistency between natural item drop coordinates e9e8ed753 SPIGOT-7960: Improve natural item drop methods Spigot Changes: 60c9969b Rebuild patches
Diffstat (limited to 'patches/api/0484-Add-FeatureFlag-API.patch')
-rw-r--r--patches/api/0484-Add-FeatureFlag-API.patch46
1 files changed, 22 insertions, 24 deletions
diff --git a/patches/api/0484-Add-FeatureFlag-API.patch b/patches/api/0484-Add-FeatureFlag-API.patch
index 008c2d793c..211e999df1 100644
--- a/patches/api/0484-Add-FeatureFlag-API.patch
+++ b/patches/api/0484-Add-FeatureFlag-API.patch
@@ -104,7 +104,7 @@ index 0000000000000000000000000000000000000000..0955699df65ccbb8711cfa48f0b34d5a
+ @Unmodifiable Set<FeatureFlag> getFeatureFlags();
+}
diff --git a/src/main/java/org/bukkit/FeatureFlag.java b/src/main/java/org/bukkit/FeatureFlag.java
-index 20eb27ee041f77f295eb271f878c524ce5592251..0acea3e8d639c252b44cd5da5e3584aa6e6c9b5c 100644
+index 79144c8594ea5cbd57e94cd60642459832b94181..15e2d70732751187b66d6737c2178eb92870b561 100644
--- a/src/main/java/org/bukkit/FeatureFlag.java
+++ b/src/main/java/org/bukkit/FeatureFlag.java
@@ -1,17 +1,24 @@
@@ -138,37 +138,35 @@ index 20eb27ee041f77f295eb271f878c524ce5592251..0acea3e8d639c252b44cd5da5e3584aa
/**
* <strong>AVAILABLE BETWEEN VERSIONS:</strong> 1.19.3 - 1.21.1
-@@ -19,34 +26,43 @@ public interface FeatureFlag extends Keyed {
+@@ -19,18 +26,19 @@ public interface FeatureFlag extends Keyed {
* @deprecated not available since 1.21.2
*/
- @Deprecated
+ @Deprecated(since = "1.21.2")
- public static final FeatureFlag BUNDLE = Bukkit.getUnsafe().getFeatureFlag(NamespacedKey.minecraft("bundle"));
+ FeatureFlag BUNDLE = deprecated("bundle");
/**
-- * <strong>AVAILABLE BETWEEN VERSIONS:</strong> 1.19 - 1.19.4
-- *
-- * @deprecated not available since 1.20
+ * <strong>AVAILABLE BETWEEN VERSIONS:</strong> 1.19 - 1.19.4
+ *
+ * @deprecated not available since 1.20
+ * The {@code trade_rebalance} feature flag.
*/
-- @Deprecated
+- @Deprecated(since = "1.20.2")
- public static final FeatureFlag UPDATE_1_20 = Bukkit.getUnsafe().getFeatureFlag(NamespacedKey.minecraft("update_1_20"));
--
++ @Deprecated(since = "1.20")
++ FeatureFlag UPDATE_1_20 = deprecated("update_1_20");
+
@ApiStatus.Experimental // Paper - add missing annotation
- public static final FeatureFlag TRADE_REBALANCE = Bukkit.getUnsafe().getFeatureFlag(NamespacedKey.minecraft("trade_rebalance"));
+ FeatureFlag TRADE_REBALANCE = create("trade_rebalance");
-- /**
-- * <strong>AVAILABLE BETWEEN VERSIONS:</strong> 1.20.5 - 1.20.6
-- *
-- * @deprecated not available since 1.21
-- */
-- @Deprecated
+ /**
+ * <strong>AVAILABLE BETWEEN VERSIONS:</strong> 1.20.5 - 1.20.6
+@@ -38,15 +46,31 @@ public interface FeatureFlag extends Keyed {
+ * @deprecated not available since 1.21
+ */
+ @Deprecated(since = "1.21")
- public static final FeatureFlag UPDATE_121 = Bukkit.getUnsafe().getFeatureFlag(NamespacedKey.minecraft("update_1_21"));
-+ @Deprecated(since = "1.20")
-+ FeatureFlag UPDATE_1_20 = deprecated("update_1_20");
-+
-+ @Deprecated(since = "1.21")
+ FeatureFlag UPDATE_121 = deprecated("update_1_21");
@ApiStatus.Experimental // Paper - add missing annotation
@@ -247,7 +245,7 @@ index eb33e8e671972aa308ad75a7ce9aa9ac526f470f..05ecf3cb38ff42c8b52405d900197e6b
/**
* Gets the {@link Biome} at the given {@link Location}.
diff --git a/src/main/java/org/bukkit/UnsafeValues.java b/src/main/java/org/bukkit/UnsafeValues.java
-index 307439827b401acb96f0df1cf4ef31835bd1d513..e8dc8a6abebf6c31cb095ca3646eb4909e42f105 100644
+index 6b1cb9c49b44b2137c20018d2644310f9727fa7f..98fe2763dcb45e1a89629c01098569fa477593cb 100644
--- a/src/main/java/org/bukkit/UnsafeValues.java
+++ b/src/main/java/org/bukkit/UnsafeValues.java
@@ -111,8 +111,7 @@ public interface UnsafeValues {
@@ -261,7 +259,7 @@ index 307439827b401acb96f0df1cf4ef31835bd1d513..e8dc8a6abebf6c31cb095ca3646eb490
/**
* Do not use, method will get removed, and the plugin won't run
diff --git a/src/main/java/org/bukkit/block/BlockType.java b/src/main/java/org/bukkit/block/BlockType.java
-index c080c2a3323d19cb3d549aa0fe6c164666d7da75..ed534fe4983873a2d5f623f0d9d5e3ce254615eb 100644
+index 80e98f444c64b6106bad98c26c0293c298c2fbbf..e795eacd86e15d8f7db3ad834c85bbf54cb3cf91 100644
--- a/src/main/java/org/bukkit/block/BlockType.java
+++ b/src/main/java/org/bukkit/block/BlockType.java
@@ -129,7 +129,7 @@ import org.jetbrains.annotations.Nullable;
@@ -284,7 +282,7 @@ index c080c2a3323d19cb3d549aa0fe6c164666d7da75..ed534fe4983873a2d5f623f0d9d5e3ce
/**
diff --git a/src/main/java/org/bukkit/entity/EntityType.java b/src/main/java/org/bukkit/entity/EntityType.java
-index 9e115cec6232b22760e91ade671f81461c0c0364..c1aa59bab82aee8fd42f7149c520b45660b29082 100644
+index 4d82a7b88c713222383b16be29bddf889d0d6edb..348f82b2be6cace6bd74802e8ebc36a712addfc6 100644
--- a/src/main/java/org/bukkit/entity/EntityType.java
+++ b/src/main/java/org/bukkit/entity/EntityType.java
@@ -45,7 +45,7 @@ import org.jetbrains.annotations.Contract;
@@ -310,7 +308,7 @@ index 5067f1371433cccd3287af7f03e152f2c3c1ece3..e0cb282541548ac3bd24cce86b3413f5
/**
* Gets the unique name of this world
diff --git a/src/main/java/org/bukkit/inventory/ItemType.java b/src/main/java/org/bukkit/inventory/ItemType.java
-index ef3a30d5cca29c7a7c546791be3c333e63e425f4..72803c00e4af576f286d2af34bf300ee554a7f3c 100644
+index 79d99a915d8ec16e4a50a58752f15bb2ed6f453f..5981e6f2c15d4eaa524817fad4af621d03128630 100644
--- a/src/main/java/org/bukkit/inventory/ItemType.java
+++ b/src/main/java/org/bukkit/inventory/ItemType.java
@@ -48,7 +48,7 @@ import org.jetbrains.annotations.Nullable;
@@ -346,7 +344,7 @@ index 34d45a105da72481a7c4f2e3831f5d2a676c91c6..529143c9007d6da4f671576f9934933f
/**
* A MenuType which represents a chest with 1 row.
diff --git a/src/main/java/org/bukkit/potion/PotionEffectType.java b/src/main/java/org/bukkit/potion/PotionEffectType.java
-index d02bb37768404422969d8b93e009960d0a693a93..294ba70f1e446ec8d502e5c14f82ae52547aeb21 100644
+index 5f32728fad44c3c5f3f5382b0ad6fd9b1ef5e0fd..e4cfdc80c9e49fc7992183022bdf2f36aae0d95a 100644
--- a/src/main/java/org/bukkit/potion/PotionEffectType.java
+++ b/src/main/java/org/bukkit/potion/PotionEffectType.java
@@ -17,7 +17,7 @@ import org.jetbrains.annotations.Nullable;
@@ -359,7 +357,7 @@ index d02bb37768404422969d8b93e009960d0a693a93..294ba70f1e446ec8d502e5c14f82ae52
/**
diff --git a/src/main/java/org/bukkit/potion/PotionType.java b/src/main/java/org/bukkit/potion/PotionType.java
-index 453c626092caa734a0af5800699f299fc6fd0e43..c82cc9d9db5cb0e0e3c02f6a9564fc935ee594aa 100644
+index ca79f97be64cd2dba2ac2cac46072f7ab976b6ff..912eb2f48c5d5b17bbd34100bb3d8e1f23f82ca3 100644
--- a/src/main/java/org/bukkit/potion/PotionType.java
+++ b/src/main/java/org/bukkit/potion/PotionType.java
@@ -14,7 +14,7 @@ import org.jetbrains.annotations.Nullable;