mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-30 06:24:06 +01:00
32 lines
1003 B
Diff
32 lines
1003 B
Diff
--- a/net/minecraft/server/InventoryEnderChest.java
|
|
+++ b/net/minecraft/server/InventoryEnderChest.java
|
|
@@ -1,11 +1,27 @@
|
|
package net.minecraft.server;
|
|
|
|
+import org.bukkit.Location;
|
|
+import org.bukkit.inventory.InventoryHolder;
|
|
+
|
|
public class InventoryEnderChest extends InventorySubcontainer {
|
|
|
|
private TileEntityEnderChest a;
|
|
+ // CraftBukkit start
|
|
+ private final EntityHuman owner;
|
|
+
|
|
+ public InventoryHolder getBukkitOwner() {
|
|
+ return owner.getBukkitEntity();
|
|
+ }
|
|
+
|
|
+ @Override
|
|
+ public Location getLocation() {
|
|
+ return new Location(this.a.getWorld().getWorld(), this.a.getPosition().getX(), this.a.getPosition().getY(), this.a.getPosition().getZ());
|
|
+ }
|
|
|
|
- public InventoryEnderChest() {
|
|
+ public InventoryEnderChest(EntityHuman owner) {
|
|
super(new ChatMessage("container.enderchest", new Object[0]), 27);
|
|
+ this.owner = owner;
|
|
+ // CraftBukkit end
|
|
}
|
|
|
|
public void a(TileEntityEnderChest tileentityenderchest) {
|