PaperMC/patches/server/0402-Add-playPickupItemAnimation-to-LivingEntity.patch
Riley Park f17519338b
Expose server build information (#10729)
* Expose server build information

* squash patches

* final tweaks

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
Co-authored-by: masmc05 <masmc05@gmail.com>
2024-05-15 17:06:59 -07:00

22 lines
1 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <blake.galbreath@gmail.com>
Date: Sun, 23 Aug 2020 19:36:22 +0200
Subject: [PATCH] Add playPickupItemAnimation to LivingEntity
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index a5026d470b8651ddf4b79fc29cbc598ac55217ff..aff940a7bacf53571f8e7bcd520419994596ebb3 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -977,4 +977,11 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
}
}
// Paper end - entity jump API
+
+ // Paper start - pickup animation API
+ @Override
+ public void playPickupItemAnimation(final org.bukkit.entity.Item item, final int quantity) {
+ this.getHandle().take(((CraftItem) item).getHandle(), quantity);
+ }
+ // Paper end - pickup animation API
}