diff options
author | Tamion <[email protected]> | 2023-11-04 21:20:13 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2023-11-04 13:20:13 -0700 |
commit | bffb08c2f99a5527b7357d005cb10ba21cf048d9 (patch) | |
tree | c25ad5490b0ede8ce30bc0f23b5e0255eecc0dbc /patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch | |
parent | 6592fed511ee2ea17de9e05463579bd1923cf8aa (diff) | |
download | Paper-bffb08c2f99a5527b7357d005cb10ba21cf048d9.tar.gz Paper-bffb08c2f99a5527b7357d005cb10ba21cf048d9.zip |
Deprecate Player#boostElytra (#9899)
The Paper method was chosen for deprecation because it was more
restrictive in that it has an isGliding check.
Diffstat (limited to 'patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch')
-rw-r--r-- | patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch b/patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch new file mode 100644 index 0000000000..581ad00ec1 --- /dev/null +++ b/patches/server/0903-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch @@ -0,0 +1,19 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: NonSwag <[email protected]> +Date: Tue, 6 Dec 2022 23:04:21 +0100 +Subject: [PATCH] Fix NPE on Allay#stopDancing while not dancing + + +diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java +index 1d04df8752af74ae73231922041d09df9d7492bb..c64918175ec08d20cde2bda9e0cac8b474385fe0 100644 +--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java ++++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java +@@ -78,7 +78,7 @@ public class CraftAllay extends CraftCreature implements org.bukkit.entity.Allay + public void stopDancing() { + this.getHandle().forceDancing = false; + this.getHandle().jukeboxPos = null; +- this.getHandle().setJukeboxPlaying(null, false); ++ this.getHandle().setDancing(false); // Paper - Directly modify set dancing to avoid NPE + } + + @Override |