Package | Description |
---|---|
org.bukkit |
The root package of the Bukkit API, contains generalized API classes.
|
org.bukkit.attribute |
Classes relevant to attributes.
|
org.bukkit.inventory.meta |
The interfaces used when manipulating extra data can can be stored inside
item stacks . |
Modifier and Type | Method and Description |
---|---|
com.google.common.collect.Multimap<Attribute,AttributeModifier> |
Material.getDefaultAttributeModifiers(EquipmentSlot slot)
Return an immutable copy of all default
Attribute s and their
AttributeModifier s for a given EquipmentSlot . |
com.google.common.collect.Multimap<Attribute,AttributeModifier> |
UnsafeValues.getDefaultAttributeModifiers(Material material,
EquipmentSlot slot)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
static AttributeModifier |
AttributeModifier.deserialize(Map<String,Object> args) |
Modifier and Type | Method and Description |
---|---|
Collection<AttributeModifier> |
AttributeInstance.getModifiers()
Get all modifiers present on this instance.
|
Modifier and Type | Method and Description |
---|---|
void |
AttributeInstance.addModifier(AttributeModifier modifier)
Add a modifier to this instance.
|
void |
AttributeInstance.removeModifier(AttributeModifier modifier)
Remove a modifier from this instance.
|
Modifier and Type | Method and Description |
---|---|
com.google.common.collect.Multimap<Attribute,AttributeModifier> |
ItemMeta.getAttributeModifiers()
Return an immutable copy of all Attributes and
their modifiers in this ItemMeta.
Returns null if none exist. |
Collection<AttributeModifier> |
ItemMeta.getAttributeModifiers(Attribute attribute)
Return an immutable copy of all
AttributeModifier s
for a given Attribute |
com.google.common.collect.Multimap<Attribute,AttributeModifier> |
ItemMeta.getAttributeModifiers(EquipmentSlot slot)
Return an immutable copy of all
Attribute s and their
AttributeModifier s for a given EquipmentSlot .Any AttributeModifier that does have have a given
EquipmentSlot will be returned. |
Modifier and Type | Method and Description |
---|---|
boolean |
ItemMeta.addAttributeModifier(Attribute attribute,
AttributeModifier modifier)
Add an Attribute and it's Modifier.
|
boolean |
ItemMeta.removeAttributeModifier(Attribute attribute,
AttributeModifier modifier)
Remove a specific
Attribute and AttributeModifier . |
Modifier and Type | Method and Description |
---|---|
void |
ItemMeta.setAttributeModifiers(com.google.common.collect.Multimap<Attribute,AttributeModifier> attributeModifiers)
Set all
Attribute s and their AttributeModifier s. |
Copyright © 2022. All rights reserved.