use of org.spongepowered.api.item.inventory.entity.UserInventory in project SpongeCommon by SpongePowered.
the class SpongeUserData method loadInventory.
private UserInventory loadInventory() {
if (this.inventory == null) {
this.inventory = new SpongeUserInventory(this);
final ListTag listNBT = this.compound.getList(Constants.Entity.Player.INVENTORY, 10);
this.inventory.readList(listNBT);
this.inventory.currentItem = this.compound.getInt(Constants.Entity.Player.SELECTED_ITEM_SLOT);
}
return (UserInventory) this.inventory;
}
Aggregations