public class InventoryPlayer extends java.lang.Object implements IInventory
| Modifier and Type | Field and Description |
|---|---|
ItemStack[] |
armorInventory |
int |
currentItem |
boolean |
inventoryChanged |
ItemStack[] |
mainInventory |
EntityPlayer |
player |
| Constructor and Description |
|---|
InventoryPlayer(EntityPlayer playerIn) |
public ItemStack[] mainInventory
public ItemStack[] armorInventory
public int currentItem
public EntityPlayer player
public boolean inventoryChanged
public InventoryPlayer(EntityPlayer playerIn)
public ItemStack getCurrentItem()
public static int getHotbarSize()
public int getFirstEmptyStack()
public void setCurrentItem(Item p_146030_1_, int p_146030_2_, boolean p_146030_3_, boolean p_146030_4_)
public int func_174925_a(Item p_174925_1_, int p_174925_2_, int p_174925_3_, NBTTagCompound p_174925_4_)
public void changeCurrentItem(int p_70453_1_)
public void decrementAnimations()
public boolean consumeInventoryItem(Item p_146026_1_)
public boolean hasItem(Item p_146028_1_)
public boolean addItemStackToInventory(ItemStack p_70441_1_)
public ItemStack decrStackSize(int index, int count)
decrStackSize in interface IInventorypublic ItemStack getStackInSlotOnClosing(int index)
getStackInSlotOnClosing in interface IInventorypublic void setInventorySlotContents(int index,
ItemStack stack)
setInventorySlotContents in interface IInventorypublic float getStrVsBlock(Block p_146023_1_)
public NBTTagList writeToNBT(NBTTagList p_70442_1_)
public void readFromNBT(NBTTagList p_70443_1_)
public int getSizeInventory()
getSizeInventory in interface IInventorypublic ItemStack getStackInSlot(int index)
getStackInSlot in interface IInventorypublic java.lang.String getName()
getName in interface IWorldNameablepublic boolean hasCustomName()
hasCustomName in interface IWorldNameablepublic IChatComponent getDisplayName()
getDisplayName in interface IWorldNameablepublic int getInventoryStackLimit()
getInventoryStackLimit in interface IInventorypublic boolean func_146025_b(Block p_146025_1_)
public ItemStack armorItemInSlot(int p_70440_1_)
public int getTotalArmorValue()
public void damageArmor(float p_70449_1_)
public void dropAllItems()
public void markDirty()
markDirty in interface IInventorypublic void setItemStack(ItemStack p_70437_1_)
public ItemStack getItemStack()
public boolean isUseableByPlayer(EntityPlayer player)
isUseableByPlayer in interface IInventorypublic boolean hasItemStack(ItemStack p_70431_1_)
public void openInventory(EntityPlayer player)
openInventory in interface IInventorypublic void closeInventory(EntityPlayer player)
closeInventory in interface IInventorypublic boolean isItemValidForSlot(int index,
ItemStack stack)
isItemValidForSlot in interface IInventorypublic void copyInventory(InventoryPlayer p_70455_1_)
public int getField(int id)
getField in interface IInventorypublic void setField(int id,
int value)
setField in interface IInventorypublic int getFieldCount()
getFieldCount in interface IInventorypublic void clear()
clear in interface IInventory