Search in sources :

Example 1 with CraftInventory

use of org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory in project Denizen-For-Bukkit by DenizenScript.

the class ImprovedOfflinePlayer_v1_11_R1 method getEnderChest.

@Override
public Inventory getEnderChest() {
    if (offlineEnderChests.containsKey(getUniqueId())) {
        return offlineEnderChests.get(getUniqueId());
    }
    InventoryEnderChest endchest = new InventoryEnderChest(null);
    endchest.a(((CompoundTag_v1_11_R1) this.compound).toNMSTag().getList("EnderItems", 10));
    org.bukkit.inventory.Inventory inv = new CraftInventory(endchest);
    offlineEnderChests.put(getUniqueId(), inv);
    return inv;
}
Also used : CraftInventory(org.bukkit.craftbukkit.v1_11_R1.inventory.CraftInventory) CompoundTag_v1_11_R1(net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_11_R1) Inventory(org.bukkit.inventory.Inventory)

Example 2 with CraftInventory

use of org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory in project Denizen-For-Bukkit by DenizenScript.

the class ImprovedOfflinePlayer_v1_9_R2 method getEnderChest.

@Override
public Inventory getEnderChest() {
    if (offlineEnderChests.containsKey(getUniqueId())) {
        return offlineEnderChests.get(getUniqueId());
    }
    InventoryEnderChest endchest = new InventoryEnderChest();
    endchest.a(((CompoundTag_v1_9_R2) this.compound).toNMSTag().getList("EnderItems", 10));
    Inventory inv = new CraftInventory(endchest);
    offlineEnderChests.put(getUniqueId(), inv);
    return inv;
}
Also used : CraftInventory(org.bukkit.craftbukkit.v1_9_R2.inventory.CraftInventory) CompoundTag_v1_9_R2(net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_9_R2) CraftInventory(org.bukkit.craftbukkit.v1_9_R2.inventory.CraftInventory) Inventory(org.bukkit.inventory.Inventory)

Example 3 with CraftInventory

use of org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory in project Denizen-For-Bukkit by DenizenScript.

the class ImprovedOfflinePlayer_v1_8_R3 method getEnderChest.

@Override
public Inventory getEnderChest() {
    if (offlineEnderChests.containsKey(getUniqueId())) {
        return offlineEnderChests.get(getUniqueId());
    }
    InventoryEnderChest endchest = new InventoryEnderChest();
    endchest.a(((CompoundTag_v1_8_R3) this.compound).toNMSTag().getList("EnderItems", 10));
    Inventory inv = new CraftInventory(endchest);
    offlineEnderChests.put(getUniqueId(), inv);
    return inv;
}
Also used : CraftInventory(org.bukkit.craftbukkit.v1_8_R3.inventory.CraftInventory) CompoundTag_v1_8_R3(net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_8_R3) CraftInventory(org.bukkit.craftbukkit.v1_8_R3.inventory.CraftInventory) Inventory(org.bukkit.inventory.Inventory)

Example 4 with CraftInventory

use of org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory in project Denizen-For-Bukkit by DenizenScript.

the class ImprovedOfflinePlayer_v1_10_R1 method getEnderChest.

@Override
public Inventory getEnderChest() {
    if (offlineEnderChests.containsKey(getUniqueId())) {
        return offlineEnderChests.get(getUniqueId());
    }
    InventoryEnderChest endchest = new InventoryEnderChest();
    endchest.a(((CompoundTag_v1_10_R1) this.compound).toNMSTag().getList("EnderItems", 10));
    org.bukkit.inventory.Inventory inv = new CraftInventory(endchest);
    offlineEnderChests.put(getUniqueId(), inv);
    return inv;
}
Also used : CraftInventory(org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory) CompoundTag_v1_10_R1(net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_10_R1) Inventory(org.bukkit.inventory.Inventory)

Aggregations

Inventory (org.bukkit.inventory.Inventory)4 CompoundTag_v1_10_R1 (net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_10_R1)1 CompoundTag_v1_11_R1 (net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_11_R1)1 CompoundTag_v1_8_R3 (net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_8_R3)1 CompoundTag_v1_9_R2 (net.aufdemrand.denizen.nms.impl.jnbt.CompoundTag_v1_9_R2)1 CraftInventory (org.bukkit.craftbukkit.v1_10_R1.inventory.CraftInventory)1 CraftInventory (org.bukkit.craftbukkit.v1_11_R1.inventory.CraftInventory)1 CraftInventory (org.bukkit.craftbukkit.v1_8_R3.inventory.CraftInventory)1 CraftInventory (org.bukkit.craftbukkit.v1_9_R2.inventory.CraftInventory)1