|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EntityEquipment
An interface to a creatures inventory
Method Summary | |
---|---|
void |
clear()
Clears the entity of all armor and held items |
ItemStack[] |
getArmorContents()
Gets a copy of all worn armor |
ItemStack |
getBoots()
Gets a copy of the boots currently being worn by the entity |
float |
getBootsDropChance()
Gets the chance of the boots being dropped upon this creature's death |
ItemStack |
getChestplate()
Gets a copy of the chest plate currently being worn by the entity |
float |
getChestplateDropChance()
Gets the chance of the chest plate being dropped upon this creature's death |
ItemStack |
getHelmet()
Gets a copy of the helmet currently being worn by the entity |
float |
getHelmetDropChance()
Gets the chance of the helmet being dropped upon this creature's death |
Entity |
getHolder()
Get the entity this EntityEquipment belongs to |
ItemStack |
getItemInHand()
Gets a copy of the item the entity is currently holding |
float |
getItemInHandDropChance()
Gets the chance of the currently held item being dropped upon this creature's death |
ItemStack |
getLeggings()
Gets a copy of the leggings currently being worn by the entity |
float |
getLeggingsDropChance()
Gets the chance of the leggings being dropped upon this creature's death |
void |
setArmorContents(ItemStack[] items)
Sets the entities armor to the provided array of ItemStacks |
void |
setBoots(ItemStack boots)
Sets the boots worn by the entity |
void |
setBootsDropChance(float chance)
Sets the chance of the boots being dropped upon this creature's death |
void |
setChestplate(ItemStack chestplate)
Sets the chest plate worn by the entity |
void |
setChestplateDropChance(float chance)
Sets the chance of the chest plate being dropped upon this creature's death |
void |
setHelmet(ItemStack helmet)
Sets the helmet worn by the entity |
void |
setHelmetDropChance(float chance)
Sets the chance of the helmet being dropped upon this creature's death |
void |
setItemInHand(ItemStack stack)
Sets the item the entity is holding |
void |
setItemInHandDropChance(float chance)
Sets the chance of the item this creature is currently holding being dropped upon this creature's death |
void |
setLeggings(ItemStack leggings)
Sets the leggings worn by the entity |
void |
setLeggingsDropChance(float chance)
Sets the chance of the leggings being dropped upon this creature's death |
Method Detail |
---|
ItemStack getItemInHand()
void setItemInHand(ItemStack stack)
stack
- The item to put into the entities handItemStack getHelmet()
void setHelmet(ItemStack helmet)
helmet
- The helmet to put on the entityItemStack getChestplate()
void setChestplate(ItemStack chestplate)
chestplate
- The chest plate to put on the entityItemStack getLeggings()
void setLeggings(ItemStack leggings)
leggings
- The leggings to put on the entityItemStack getBoots()
void setBoots(ItemStack boots)
boots
- The boots to put on the entityItemStack[] getArmorContents()
void setArmorContents(ItemStack[] items)
items
- The items to set the armor asvoid clear()
float getItemInHandDropChance()
A drop chance of 0F will never drop A drop chance of 1F will always drop
void setItemInHandDropChance(float chance)
A drop chance of 0F will never drop A drop chance of 1F will always drop
chance
- the chance of the currently held item being dropped
UnsupportedOperationException
- when called on playersfloat getHelmetDropChance()
A drop chance of 0F will never drop A drop chance of 1F will always drop
void setHelmetDropChance(float chance)
A drop chance of 0F will never drop A drop chance of 1F will always drop
chance
- of the helmet being dropped
UnsupportedOperationException
- when called on playersfloat getChestplateDropChance()
A drop chance of 0F will never drop A drop chance of 1F will always drop
void setChestplateDropChance(float chance)
A drop chance of 0F will never drop A drop chance of 1F will always drop
chance
- of the chest plate being dropped
UnsupportedOperationException
- when called on playersfloat getLeggingsDropChance()
A drop chance of 0F will never drop A drop chance of 1F will always drop
void setLeggingsDropChance(float chance)
A drop chance of 0F will never drop A drop chance of 1F will always drop
chance
- chance of the leggings being dropped
UnsupportedOperationException
- when called on playersfloat getBootsDropChance()
A drop chance of 0F will never drop A drop chance of 1F will always drop
void setBootsDropChance(float chance)
A drop chance of 0F will never drop A drop chance of 1F will always drop
chance
- of the boots being dropped
UnsupportedOperationException
- when called on playersEntity getHolder()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |