summaryrefslogtreecommitdiffstats
path: root/nms-patches/EntityItem.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/EntityItem.patch')
-rw-r--r--nms-patches/EntityItem.patch24
1 files changed, 10 insertions, 14 deletions
diff --git a/nms-patches/EntityItem.patch b/nms-patches/EntityItem.patch
index 998260b9..bcc5bdca 100644
--- a/nms-patches/EntityItem.patch
+++ b/nms-patches/EntityItem.patch
@@ -1,18 +1,14 @@
--- a/net/minecraft/server/EntityItem.java
+++ b/net/minecraft/server/EntityItem.java
-@@ -4,15 +4,18 @@
+@@ -3,6 +3,7 @@
+ import java.util.Iterator;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
-
+import org.bukkit.event.player.PlayerPickupItemEvent; // CraftBukkit
-+
+
public class EntityItem extends Entity {
- private static final Logger b = LogManager.getLogger();
- private int age;
-- private int pickupDelay;
-+ public int pickupDelay; // CraftBukkit - public
- private int e;
+@@ -13,6 +14,7 @@
private String f;
private String g;
public float a;
@@ -20,7 +16,7 @@
public EntityItem(World world, double d0, double d1, double d2) {
super(world);
-@@ -28,6 +31,11 @@
+@@ -28,6 +30,11 @@
public EntityItem(World world, double d0, double d1, double d2, ItemStack itemstack) {
this(world, d0, d1, d2);
@@ -32,7 +28,7 @@
this.setItemStack(itemstack);
}
-@@ -52,9 +60,12 @@
+@@ -52,9 +59,12 @@
this.die();
} else {
super.t_();
@@ -48,7 +44,7 @@
this.lastX = this.locX;
this.lastY = this.locY;
-@@ -90,12 +101,21 @@
+@@ -90,12 +100,21 @@
this.motY *= -0.5D;
}
@@ -70,7 +66,7 @@
this.die();
}
-@@ -183,6 +203,11 @@
+@@ -183,6 +202,11 @@
} else if (this.getItemStack() != null && this.getItemStack().getItem() == Items.NETHER_STAR && damagesource.isExplosion()) {
return false;
} else {
@@ -82,7 +78,7 @@
this.ac();
this.e = (int) ((float) this.e - f);
if (this.e <= 0) {
-@@ -228,7 +253,18 @@
+@@ -228,7 +252,18 @@
NBTTagCompound nbttagcompound1 = nbttagcompound.getCompound("Item");
@@ -102,7 +98,7 @@
if (this.getItemStack() == null) {
this.die();
}
-@@ -240,6 +276,26 @@
+@@ -240,6 +275,26 @@
ItemStack itemstack = this.getItemStack();
int i = itemstack.count;