Interface EquippableComponent
- All Superinterfaces:
- ConfigurationSerializable
Represents a component which can turn any item into equippable armor.
- 
Method SummaryModifier and TypeMethodDescriptionGets the entities which can equip this item.Gets the key of the camera overlay to use when equipped.Gets the sound to play when the item is equipped.getModel()Gets the key of the model to use when equipped.getSlot()Gets the slot the item can be equipped to.booleanGets if the item will be damaged when the wearing entity is damaged.booleanGets whether the item can be equipped by a dispenser.booleanGets if the item is swappable by right clicking.voidsetAllowedEntities(Collection<EntityType> entities) Sets the entities which can equip this item.voidsetAllowedEntities(EntityType entities) Sets the entities which can equip this item.voidsetAllowedEntities(Tag<EntityType> tag) Set the entity types (represented as an entityTag) which can equip this item.voidSets the key of the camera overlay to use when equipped.voidsetDamageOnHurt(boolean damage) Sets if the item will be damaged when the wearing entity is damaged.voidsetDispensable(boolean dispensable) Sets whether the item can be equipped by a dispenser.voidsetEquipSound(Sound sound) Sets the sound to play when the item is equipped.voidsetModel(NamespacedKey key) Sets the key of the model to use when equipped.voidsetSlot(EquipmentSlot slot) Sets the slot the item can be equipped to.voidsetSwappable(boolean swappable) Sets if the item is swappable by right clicking.Methods inherited from interface org.bukkit.configuration.serialization.ConfigurationSerializableserialize
- 
Method Details- 
getSlotGets the slot the item can be equipped to.- Returns:
- slot
 
- 
setSlotSets the slot the item can be equipped to.- Parameters:
- slot- new slot
 
- 
getEquipSoundGets the sound to play when the item is equipped.- Returns:
- the sound
 
- 
setEquipSoundSets the sound to play when the item is equipped.- Parameters:
- sound- sound or null for current default
 
- 
getModelGets the key of the model to use when equipped.- Returns:
- model key
 
- 
setModelSets the key of the model to use when equipped.- Parameters:
- key- model key
 
- 
getCameraOverlayGets the key of the camera overlay to use when equipped.- Returns:
- camera overlay key
 
- 
setCameraOverlaySets the key of the camera overlay to use when equipped.- Parameters:
- key- camera overlay key
 
- 
getAllowedEntitiesGets the entities which can equip this item.- Returns:
- the entities
 
- 
setAllowedEntitiesSets the entities which can equip this item.- Parameters:
- entities- the entity types
 
- 
setAllowedEntitiesSets the entities which can equip this item.- Parameters:
- entities- the entity types
 
- 
setAllowedEntitiesSet the entity types (represented as an entityTag) which can equip this item.- Parameters:
- tag- the entity tag
- Throws:
- IllegalArgumentException- if the passed- tagis not an entity tag
 
- 
isDispensableboolean isDispensable()Gets whether the item can be equipped by a dispenser.- Returns:
- equippable status
 
- 
setDispensablevoid setDispensable(boolean dispensable) Sets whether the item can be equipped by a dispenser.- Parameters:
- dispensable- new equippable status
 
- 
isSwappableboolean isSwappable()Gets if the item is swappable by right clicking.- Returns:
- swappable status
 
- 
setSwappablevoid setSwappable(boolean swappable) Sets if the item is swappable by right clicking.- Parameters:
- swappable- new status
 
- 
isDamageOnHurtboolean isDamageOnHurt()Gets if the item will be damaged when the wearing entity is damaged.- Returns:
- whether the item will be damaged
 
- 
setDamageOnHurtvoid setDamageOnHurt(boolean damage) Sets if the item will be damaged when the wearing entity is damaged.- Parameters:
- damage- whether the item will be damaged
 
 
-