use of org.bukkit.craftbukkit.v.inventory.CraftInventoryPlayer in project Arclight by IzzelAliz.
the class ChestContainerMixin method getBukkitView.
@Override
public CraftInventoryView getBukkitView() {
if (bukkitEntity != null) {
return bukkitEntity;
}
CraftInventory inventory;
if (this.lowerChestInventory instanceof PlayerInventory) {
inventory = new CraftInventoryPlayer((PlayerInventory) this.lowerChestInventory);
} else if (this.lowerChestInventory instanceof DoubleSidedInventory) {
inventory = new CraftInventoryDoubleChest((DoubleSidedInventory) this.lowerChestInventory);
} else {
inventory = new CraftInventory(this.lowerChestInventory);
}
bukkitEntity = new CraftInventoryView(((PlayerEntityBridge) this.playerInventory.player).bridge$getBukkitEntity(), inventory, (Container) (Object) this);
return bukkitEntity;
}
Aggregations