public abstract class UContainer
extends net.minecraft.inventory.container.Container
Modifier and Type | Class and Description |
---|---|
static interface |
UContainer.SlotHandlerFunction
Used as a function to customize slots with the append methods
|
static interface |
UContainer.SlotInventoryFunction
Used as a function to customize slots with the append methods
|
Constructor and Description |
---|
UContainer(net.minecraft.inventory.container.ContainerType<?> type,
int id) |
Modifier and Type | Method and Description |
---|---|
void |
appendInventory(net.minecraft.inventory.IInventory inventory,
int inventoryHeight,
int inventoryWidth,
int x,
int y)
This methods can add any
IInventory to the container. |
void |
appendInventory(net.minecraft.inventory.IInventory inventory,
UContainer.SlotInventoryFunction function,
int inventoryHeight,
int inventoryWidth,
int x,
int y)
This methods can add any
IInventory to the container. |
void |
appendInventory(net.minecraftforge.items.IItemHandler handler,
int inventoryHeight,
int inventoryWidth,
int x,
int y)
This methods can add any
IItemHandler to the container. |
void |
appendInventory(net.minecraftforge.items.IItemHandler handler,
UContainer.SlotHandlerFunction function,
int inventoryHeight,
int inventoryWidth,
int x,
int y)
This methods can add any
IItemHandler to the container. |
void |
appendPlayerInventory(net.minecraft.entity.player.PlayerInventory playerInventory,
int x,
int y)
This methods adds a player inventory to the container.
|
boolean |
canInteractWith(net.minecraft.entity.player.PlayerEntity player) |
addListener, addSlot, areItemsAndTagsEqual, assertIntArraySize, assertInventorySize, calcRedstone, calcRedstoneFromInventory, canAddItemToSlot, canDragIntoSlot, canMergeSlot, clearContainer, computeStackSize, detectAndSendChanges, enchantItem, extractDragMode, getCanCraft, getDragEvent, getInventory, getNextTransactionID, getQuickcraftMask, getSlot, getType, isValidDragMode, isWithinUsableDistance, mergeItemStack, onContainerClosed, onCraftMatrixChanged, putStackInSlot, removeListener, resetDrag, setAll, setCanCraft, slotClick, trackInt, trackIntArray, transferStackInSlot, updateProgressBar
public UContainer(net.minecraft.inventory.container.ContainerType<?> type, int id)
public boolean canInteractWith(net.minecraft.entity.player.PlayerEntity player)
canInteractWith
in class net.minecraft.inventory.container.Container
public void appendPlayerInventory(net.minecraft.entity.player.PlayerInventory playerInventory, int x, int y)
playerInventory
- Player inventoryx
- Start xy
- Start ypublic void appendInventory(net.minecraft.inventory.IInventory inventory, int inventoryHeight, int inventoryWidth, int x, int y)
IInventory
to the container. You can specialize the inventory height (slot rows) and
width (slot columns).inventory
- Some inventoryinventoryHeight
- Slot rowsinventoryWidth
- Slot columnsx
- Start xy
- Start ypublic void appendInventory(net.minecraft.inventory.IInventory inventory, UContainer.SlotInventoryFunction function, int inventoryHeight, int inventoryWidth, int x, int y)
IInventory
to the container. You can specialize the inventory height (slot rows) and
width (slot columns). You must supplier a function that create a slot. With this you can set your own slot.
implementations.inventory
- Some inventoryfunction
- Function to create a slot.inventoryHeight
- Slot rowsinventoryWidth
- Slot columnsx
- Start xy
- Start ypublic void appendInventory(net.minecraftforge.items.IItemHandler handler, int inventoryHeight, int inventoryWidth, int x, int y)
IItemHandler
to the container. You can specialize the inventory height (slot rows)
and width (slot columns).handler
- Some item handlerinventoryHeight
- Slot rowsinventoryWidth
- Slot columnsx
- Start xy
- Start ypublic void appendInventory(net.minecraftforge.items.IItemHandler handler, UContainer.SlotHandlerFunction function, int inventoryHeight, int inventoryWidth, int x, int y)
IItemHandler
to the container. You can specialize the inventory height (slot rows)
and width (slot columns). You must supplier a function that create a slot. With this you can set your own slot.
implementations.handler
- Some item handlerfunction
- Function to create a slot.inventoryHeight
- Slot rowsinventoryWidth
- Slot columnsx
- Start xy
- Start y