Updated Upstream (Bukkit/CraftBukkit) (#7936)

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:
c1d911a2 Add compat constructor to PlayerAnimationEvent

CraftBukkit Changes:
effea36a2 PR-1065: Add missing calls for BlockSpreadEvent when Sculk spreads
This commit is contained in:
Jake Potrebic 2022-06-11 02:02:57 -07:00 committed by GitHub
parent d7165b0d56
commit 55201f00e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 19 deletions

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Adds PlayerArmSwingEvent
diff --git a/src/main/java/io/papermc/paper/event/player/PlayerArmSwingEvent.java b/src/main/java/io/papermc/paper/event/player/PlayerArmSwingEvent.java
new file mode 100644
index 0000000000000000000000000000000000000000..1a4550a73e89f9cf92d2831d21bcfb46f92fd189
index 0000000000000000000000000000000000000000..ce76b07cfaa9173c78e2844add2bc5bb437b1106
--- /dev/null
+++ b/src/main/java/io/papermc/paper/event/player/PlayerArmSwingEvent.java
@@ -0,0 +1,27 @@
@ -23,7 +23,7 @@ index 0000000000000000000000000000000000000000..1a4550a73e89f9cf92d2831d21bcfb46
+ private final EquipmentSlot equipmentSlot;
+
+ public PlayerArmSwingEvent(@NotNull Player player, @NotNull EquipmentSlot equipmentSlot) {
+ super(player, PlayerAnimationType.ARM_SWING);
+ super(player, equipmentSlot == EquipmentSlot.HAND ? PlayerAnimationType.ARM_SWING : PlayerAnimationType.OFF_ARM_SWING);
+ this.equipmentSlot = equipmentSlot;
+ }
+
@ -38,7 +38,7 @@ index 0000000000000000000000000000000000000000..1a4550a73e89f9cf92d2831d21bcfb46
+ }
+}
diff --git a/src/main/java/org/bukkit/event/player/PlayerAnimationEvent.java b/src/main/java/org/bukkit/event/player/PlayerAnimationEvent.java
index b7ca545c3574d4639f2783f2367de871086a5704..e93bb1ed0fdb99b38ecb84eba99bf08f150f75f0 100644
index eb722a1e3b987b86fae2fa8346606fa15fada26f..11c27b1a4a749e129ed4b2d906c315d97a4b66e7 100644
--- a/src/main/java/org/bukkit/event/player/PlayerAnimationEvent.java
+++ b/src/main/java/org/bukkit/event/player/PlayerAnimationEvent.java
@@ -7,6 +7,7 @@ import org.jetbrains.annotations.NotNull;
@ -49,17 +49,3 @@ index b7ca545c3574d4639f2783f2367de871086a5704..e93bb1ed0fdb99b38ecb84eba99bf08f
*/
public class PlayerAnimationEvent extends PlayerEvent implements Cancellable {
private static final HandlerList handlers = new HandlerList();
@@ -24,6 +25,13 @@ public class PlayerAnimationEvent extends PlayerEvent implements Cancellable {
animationType = playerAnimationType;
}
+ // Paper start - readd old constructor
+ @Deprecated
+ public PlayerAnimationEvent(@NotNull final Player player) {
+ this(player, PlayerAnimationType.ARM_SWING);
+ }
+ // Paper end
+
/**
* Get the type of this animation event
*

@ -1 +1 @@
Subproject commit 45d9c73c34736f64e2bbdf4227081be5d41dc093
Subproject commit c1d911a2b4f2aaf85aa6cf9030230fe5940d49da

@ -1 +1 @@
Subproject commit cc7edd6bc52f405818c8b995e576cfdcb537d88b
Subproject commit effea36a28a3a0796a6ac0cc35609573c404e73c