public class TileEntityHopper extends TileEntity implements IHopper
blockMetadata, blockType, INFINITE_EXTENT_AABB, tileEntityInvalid, worldObj, xCoord, yCoord, zCoord
Constructor and Description |
---|
TileEntityHopper() |
Modifier and Type | Method and Description |
---|---|
void |
closeInventory() |
ItemStack |
decrStackSize(int par1,
int par2)
Removes from an inventory slot (first arg) up to a specified number (second arg) of items and returns them in a
new stack.
|
static IInventory |
func_145884_b(IHopper p_145884_0_) |
void |
func_145886_a(java.lang.String p_145886_1_) |
boolean |
func_145887_i() |
boolean |
func_145888_j() |
static ItemStack |
func_145889_a(IInventory p_145889_0_,
ItemStack p_145889_1_,
int p_145889_2_) |
static boolean |
func_145891_a(IHopper p_145891_0_) |
static IInventory |
func_145893_b(World p_145893_0_,
double p_145893_1_,
double p_145893_3_,
double p_145893_5_) |
void |
func_145896_c(int p_145896_1_) |
static EntityItem |
func_145897_a(World p_145897_0_,
double p_145897_1_,
double p_145897_3_,
double p_145897_5_) |
static boolean |
func_145898_a(IInventory p_145898_0_,
EntityItem p_145898_1_) |
java.lang.String |
getInventoryName()
Returns the name of the inventory
|
int |
getInventoryStackLimit()
Returns the maximum stack size for a inventory slot.
|
int |
getSizeInventory()
Returns the number of slots in the inventory.
|
ItemStack |
getStackInSlot(int par1)
Returns the stack in slot i
|
ItemStack |
getStackInSlotOnClosing(int par1)
When some containers are closed they call this on each slot, then drop whatever it returns as an EntityItem -
like when you close a workbench GUI.
|
double |
getXPos()
Gets the world X position for this hopper entity.
|
double |
getYPos()
Gets the world Y position for this hopper entity.
|
double |
getZPos()
Gets the world Z position for this hopper entity.
|
boolean |
hasCustomInventoryName()
Returns if the inventory is named
|
boolean |
isItemValidForSlot(int par1,
ItemStack par2ItemStack)
Returns true if automation is allowed to insert the given stack (ignoring stack size) into the given slot.
|
boolean |
isUseableByPlayer(EntityPlayer par1EntityPlayer)
Do not make give this method the name canInteractWith because it clashes with Container
|
void |
markDirty()
For tile entities, ensures the chunk containing the tile entity is saved to disk later - the game won't think it
hasn't changed and skip it.
|
void |
openInventory() |
void |
readFromNBT(NBTTagCompound p_145839_1_) |
void |
setInventorySlotContents(int par1,
ItemStack par2ItemStack)
Sets the given item stack to the specified slot in the inventory (can be crafting or armor sections).
|
void |
updateEntity() |
void |
writeToNBT(NBTTagCompound p_145841_1_) |
addMapping, canUpdate, createAndLoadEntity, func_145828_a, getBlockMetadata, getBlockType, getDescriptionPacket, getDistanceFrom, getMaxRenderDistanceSquared, getRenderBoundingBox, getWorldObj, hasWorldObj, invalidate, isInvalid, onChunkUnload, onDataPacket, receiveClientEvent, setWorldObj, shouldRefresh, shouldRenderInPass, updateContainingBlockInfo, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getWorldObj
public void readFromNBT(NBTTagCompound p_145839_1_)
readFromNBT
in class TileEntity
public void writeToNBT(NBTTagCompound p_145841_1_)
writeToNBT
in class TileEntity
public void markDirty()
markDirty
in interface IInventory
markDirty
in class TileEntity
public int getSizeInventory()
getSizeInventory
in interface IInventory
public ItemStack getStackInSlot(int par1)
getStackInSlot
in interface IInventory
public ItemStack decrStackSize(int par1, int par2)
decrStackSize
in interface IInventory
public ItemStack getStackInSlotOnClosing(int par1)
getStackInSlotOnClosing
in interface IInventory
public void setInventorySlotContents(int par1, ItemStack par2ItemStack)
setInventorySlotContents
in interface IInventory
public java.lang.String getInventoryName()
getInventoryName
in interface IInventory
public boolean hasCustomInventoryName()
hasCustomInventoryName
in interface IInventory
public void func_145886_a(java.lang.String p_145886_1_)
public int getInventoryStackLimit()
getInventoryStackLimit
in interface IInventory
public boolean isUseableByPlayer(EntityPlayer par1EntityPlayer)
isUseableByPlayer
in interface IInventory
public void openInventory()
openInventory
in interface IInventory
public void closeInventory()
closeInventory
in interface IInventory
public boolean isItemValidForSlot(int par1, ItemStack par2ItemStack)
isItemValidForSlot
in interface IInventory
public void updateEntity()
updateEntity
in class TileEntity
public boolean func_145887_i()
public static boolean func_145891_a(IHopper p_145891_0_)
public static boolean func_145898_a(IInventory p_145898_0_, EntityItem p_145898_1_)
public static ItemStack func_145889_a(IInventory p_145889_0_, ItemStack p_145889_1_, int p_145889_2_)
public static IInventory func_145884_b(IHopper p_145884_0_)
public static EntityItem func_145897_a(World p_145897_0_, double p_145897_1_, double p_145897_3_, double p_145897_5_)
public static IInventory func_145893_b(World p_145893_0_, double p_145893_1_, double p_145893_3_, double p_145893_5_)
public double getXPos()
public double getYPos()
public double getZPos()
public void func_145896_c(int p_145896_1_)
public boolean func_145888_j()