Organise imports

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2021-03-09 08:47:33 +11:00
parent 1ae7bcc4d0
commit b2efd58164
188 changed files with 879 additions and 825 deletions

View File

@@ -1,17 +1,18 @@
--- a/net/minecraft/server/EntityItem.java
+++ b/net/minecraft/server/EntityItem.java
@@ -5,6 +5,10 @@
import java.util.Objects;
@@ -6,6 +6,11 @@
import java.util.UUID;
import javax.annotation.Nullable;
+// CraftBukkit start
+import org.bukkit.event.entity.EntityPickupItemEvent;
+import org.bukkit.event.player.PlayerPickupItemEvent;
+// CraftBukkit end
+
public class EntityItem extends Entity {
@@ -15,6 +19,7 @@
private static final DataWatcherObject<ItemStack> ITEM = DataWatcher.a(EntityItem.class, DataWatcherRegistry.g);
@@ -15,6 +20,7 @@
private UUID thrower;
private UUID owner;
public final float b;
@@ -19,7 +20,7 @@
public EntityItem(EntityTypes<? extends EntityItem> entitytypes, World world) {
super(entitytypes, world);
@@ -50,9 +55,12 @@
@@ -50,9 +56,12 @@
this.die();
} else {
super.tick();
@@ -35,7 +36,7 @@
this.lastX = this.locX();
this.lastY = this.locY();
@@ -108,9 +116,11 @@
@@ -108,9 +117,11 @@
}
}
@@ -47,7 +48,7 @@
this.impulse |= this.aK();
if (!this.world.isClientSide) {
@@ -122,6 +132,12 @@
@@ -122,6 +133,12 @@
}
if (!this.world.isClientSide && this.age >= 6000) {
@@ -60,7 +61,7 @@
this.die();
}
@@ -197,10 +213,11 @@
@@ -197,10 +214,11 @@
private static void a(EntityItem entityitem, ItemStack itemstack, ItemStack itemstack1) {
ItemStack itemstack2 = a(itemstack, itemstack1, 64);
@@ -73,7 +74,7 @@
a(entityitem, itemstack, itemstack1);
entityitem.pickupDelay = Math.max(entityitem.pickupDelay, entityitem1.pickupDelay);
entityitem.age = Math.min(entityitem.age, entityitem1.age);
@@ -224,6 +241,11 @@
@@ -224,6 +242,11 @@
} else if (!this.getItemStack().getItem().a(damagesource)) {
return false;
} else {
@@ -85,7 +86,7 @@
this.velocityChanged();
this.f = (int) ((float) this.f - f);
if (this.f <= 0) {
@@ -285,6 +307,46 @@
@@ -285,6 +308,46 @@
Item item = itemstack.getItem();
int i = itemstack.getCount();
@@ -132,7 +133,7 @@
if (this.pickupDelay == 0 && (this.owner == null || this.owner.equals(entityhuman.getUniqueID())) && entityhuman.inventory.pickup(itemstack)) {
entityhuman.receive(this, i);
if (itemstack.isEmpty()) {
@@ -328,7 +390,9 @@
@@ -328,7 +391,9 @@
}
public void setItemStack(ItemStack itemstack) {