Class DurabilityStat
java.lang.Object
studio.magemonkey.divinity.stats.items.api.ItemLoreStat<double[]>
studio.magemonkey.divinity.stats.items.attributes.stats.DurabilityStat
- All Implemented Interfaces:
TypedStat
-
Nested Class Summary
Nested classes/interfaces inherited from interface studio.magemonkey.divinity.stats.items.attributes.api.TypedStat
TypedStat.Type -
Field Summary
Fields inherited from class studio.magemonkey.divinity.stats.items.api.ItemLoreStat
dataType, format, keys, metaId, name, placeholder -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanformatValue(org.bukkit.inventory.ItemStack item, double[] values) doubleClass<double[]> getType()booleanisBroken(org.bukkit.inventory.ItemStack item) booleanisDamaged(org.bukkit.inventory.ItemStack item) booleanisMainItem(org.bukkit.inventory.ItemStack item) Deprecated.booleanbooleanisUnbreakable(org.bukkit.inventory.ItemStack item) booleanreduceDurability(org.bukkit.entity.LivingEntity li, org.bukkit.inventory.ItemStack item, int amount) voidsetCapability(double cap) Methods inherited from class studio.magemonkey.divinity.stats.items.api.ItemLoreStat
add, getFormat, getFormat, getId, getKey, getKeys, getLoreIndex, getMetaId, getMetaId, getName, getPlaceholder, getRaw, hasPlaceholder, isApplied, isSingle, preparePlaceholder, removeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface studio.magemonkey.divinity.stats.items.attributes.api.TypedStat
fineValue, getId, getPlaceholder, hasPlaceholder, isApplied
-
Constructor Details
-
DurabilityStat
-
-
Method Details
-
getParameterClass
- Specified by:
getParameterClassin classItemLoreStat<double[]>
-
getType
-
getCapability
public double getCapability()- Specified by:
getCapabilityin interfaceTypedStat
-
setCapability
public void setCapability(double cap) - Specified by:
setCapabilityin interfaceTypedStat
-
getItemType
- Specified by:
getItemTypein interfaceTypedStat
-
isPercent
public boolean isPercent() -
canBeNegative
public boolean canBeNegative()- Specified by:
canBeNegativein interfaceTypedStat
-
isMainItem
Deprecated.- Specified by:
isMainItemin interfaceTypedStat
-
getDependStat
- Specified by:
getDependStatin interfaceTypedStat
-
isUnbreakable
public boolean isUnbreakable(@NotNull org.bukkit.inventory.ItemStack item) -
isDamaged
public boolean isDamaged(@NotNull org.bukkit.inventory.ItemStack item) -
isBroken
public boolean isBroken(@NotNull org.bukkit.inventory.ItemStack item) -
reduceDurability
public boolean reduceDurability(@NotNull org.bukkit.entity.LivingEntity li, @NotNull org.bukkit.inventory.ItemStack item, int amount) -
formatValue
- Specified by:
formatValuein classItemLoreStat<double[]>
-