public abstract class InventoryTileEntity extends net.minecraft.tileentity.TileEntity implements IBasicInventory, net.minecraft.inventory.container.INamedContainerProvider
| Modifier | Constructor and Description |
|---|---|
protected |
InventoryTileEntity(net.minecraft.tileentity.TileEntityType<?> type,
java.lang.String inventoryName,
int rows) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addToInventory(net.minecraft.item.ItemStack stack) |
net.minecraft.inventory.container.Container |
createMenu(int id,
net.minecraft.entity.player.PlayerInventory playerInventory,
net.minecraft.entity.player.PlayerEntity playerIn) |
int |
getContainerSize() |
net.minecraft.util.NonNullList<net.minecraft.item.ItemStack> |
getContents() |
java.lang.String |
getCustomName() |
net.minecraft.util.text.ITextComponent |
getDisplayName() |
net.minecraft.item.ItemStack |
getItem(int index) |
int |
getMaxStackSize() |
boolean |
hasCustomName() |
boolean |
isEmpty() |
void |
load(net.minecraft.block.BlockState state,
net.minecraft.nbt.CompoundNBT nbt) |
net.minecraft.item.ItemStack |
removeItem(int index,
int count) |
net.minecraft.item.ItemStack |
removeItemNoUpdate(int index) |
net.minecraft.nbt.CompoundNBT |
save(net.minecraft.nbt.CompoundNBT nbt) |
void |
setItem(int index,
net.minecraft.item.ItemStack stack) |
boolean |
stillValid(net.minecraft.entity.player.PlayerEntity player) |
clearCache, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getTileData, getType, getUpdatePacket, getUpdateTag, getViewDistance, hasLevel, isRemoved, loadStatic, logInvalidState, mirror, onChunkUnloaded, onlyOpCanSetNbt, rotate, setChanged, setLevelAndPosition, setPosition, setRemoved, triggerEventareCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCapsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcanPlaceItem, clearContent, startOpen, stopOpenprotected InventoryTileEntity(net.minecraft.tileentity.TileEntityType<?> type,
java.lang.String inventoryName,
int rows)
public net.minecraft.util.NonNullList<net.minecraft.item.ItemStack> getContents()
public void load(net.minecraft.block.BlockState state,
net.minecraft.nbt.CompoundNBT nbt)
load in class net.minecraft.tileentity.TileEntitypublic boolean addToInventory(net.minecraft.item.ItemStack stack)
public net.minecraft.nbt.CompoundNBT save(net.minecraft.nbt.CompoundNBT nbt)
save in class net.minecraft.tileentity.TileEntitypublic boolean isEmpty()
isEmpty in interface net.minecraft.inventory.IInventorypublic net.minecraft.item.ItemStack getItem(int index)
getItem in interface net.minecraft.inventory.IInventorypublic net.minecraft.item.ItemStack removeItem(int index,
int count)
removeItem in interface IBasicInventoryremoveItem in interface net.minecraft.inventory.IInventorypublic net.minecraft.item.ItemStack removeItemNoUpdate(int index)
removeItemNoUpdate in interface net.minecraft.inventory.IInventorypublic void setItem(int index,
net.minecraft.item.ItemStack stack)
setItem in interface net.minecraft.inventory.IInventorypublic int getMaxStackSize()
getMaxStackSize in interface IBasicInventorygetMaxStackSize in interface net.minecraft.inventory.IInventorypublic boolean stillValid(net.minecraft.entity.player.PlayerEntity player)
stillValid in interface net.minecraft.inventory.IInventorypublic java.lang.String getCustomName()
public boolean hasCustomName()
public net.minecraft.util.text.ITextComponent getDisplayName()
getDisplayName in interface net.minecraft.inventory.container.INamedContainerProvider@Nullable
public net.minecraft.inventory.container.Container createMenu(int id,
net.minecraft.entity.player.PlayerInventory playerInventory,
net.minecraft.entity.player.PlayerEntity playerIn)
createMenu in interface net.minecraft.inventory.container.IContainerProviderpublic int getContainerSize()
getContainerSize in interface net.minecraft.inventory.IInventory