接口 PiercingWeaponComponent
- 所有超级接口:
ConfigurationSerializable
Represents a component which can turn any item into piercing weapon that
damages multiple entities.
-
方法概要
修饰符和类型方法说明Gets 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(@Nullable Sound sound) Sets the sound to play when the item successfully hits a target.voidSets the sound to play when the item is used.从接口继承的方法 org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
方法详细资料
-
isDealsKnockback
boolean isDealsKnockback()Gets whether the attack deals knockback to the target.- 返回:
- true if knockback
-
setDealsKnockback
void setDealsKnockback(boolean knockback) Sets whether the attack deals knockback to the target.- 参数:
knockback- true if knockback
-
isDismounts
boolean isDismounts()Gets whether the attack dismounts the target.- 返回:
- true if dismounts
-
setDismounts
void setDismounts(boolean dismounts) Sets whether the attack dismounts the target.- 参数:
dismounts- true if dismounts
-
getSound
Gets the sound to play when the item is used.- 返回:
- the sound
-
setSound
Sets the sound to play when the item is used.- 参数:
sound- sound or null for current default
-
getHitSound
Gets the sound to play when the item successfully hits a target.- 返回:
- the sound
-
setHitSound
Sets the sound to play when the item successfully hits a target.- 参数:
sound- sound or null for current default
-