Interface PiercingWeaponComponent
- All Superinterfaces:
ConfigurationSerializable
Represents a component which can turn any item into piercing weapon that
damages multiple entities.
-
Method Summary
Modifier and TypeMethodDescriptionGets the sound to play when the item successfully hits a target.getSound()Gets the sound to play when the item is used.booleanGets whether the attack deals knockback to the target.booleanGets whether the attack dismounts the target.voidsetDealsKnockback(boolean knockback) Sets whether the attack deals knockback to the target.voidsetDismounts(boolean dismounts) Sets whether the attack dismounts the target.voidsetHitSound(Sound sound) Sets the sound to play when the item successfully hits a target.voidSets the sound to play when the item is used.Methods inherited from interface org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
Method Details
-
isDealsKnockback
boolean isDealsKnockback()Gets whether the attack deals knockback to the target.- Returns:
- true if knockback
-
setDealsKnockback
void setDealsKnockback(boolean knockback) Sets whether the attack deals knockback to the target.- Parameters:
knockback- true if knockback
-
isDismounts
boolean isDismounts()Gets whether the attack dismounts the target.- Returns:
- true if dismounts
-
setDismounts
void setDismounts(boolean dismounts) Sets whether the attack dismounts the target.- Parameters:
dismounts- true if dismounts
-
getSound
Gets the sound to play when the item is used.- Returns:
- the sound
-
setSound
Sets the sound to play when the item is used.- Parameters:
sound- sound or null for current default
-
getHitSound
Gets the sound to play when the item successfully hits a target.- Returns:
- the sound
-
setHitSound
Sets the sound to play when the item successfully hits a target.- Parameters:
sound- sound or null for current default
-