Interface KineticWeaponComponent
- All Superinterfaces:
ConfigurationSerializable
Represents a component which can turn any item into kinetic weapon that deals
damage based on the relative speed of the target and attacker.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceRepresents a condition for an attack effect. -
Method Summary
Modifier and TypeMethodDescriptionintGets the delay before the weapon can be used after hitting an entity.Gets the conditions required for the weapon to damage the target.floatGets the final damage multiplier based on target and attacker relative speed.intGets the delay before the weapon can be used.Gets the conditions required for the weapon to dismount the target.floatGets the forward movement animation of the item.Gets the sound to play when the item successfully hits a target.Gets the conditions required for the weapon to knockback the target.getSound()Gets the sound to play when the item is used.voidsetContactCooldownTicks(int ticks) Sets the delay before the weapon can be used after hitting an entity.voidSets the conditions required for the weapon to damage the target.voidsetDamageMultipler(float multiplier) Sets the final damage multiplier based on target and attacker relative speed.voidsetDelayTicks(int ticks) Sets the delay before the weapon can be used.voidSets the conditions required for the weapon to dismount the target.voidsetForwardMovement(float movement) Sets the forward movement animation of the item.voidsetHitSound(Sound sound) Sets the sound to play when the item successfully hits a target.voidSets the conditions required for the weapon to knockback the target.voidSets the sound to play when the item is used.Methods inherited from interface org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
Method Details
-
getContactCooldownTicks
int getContactCooldownTicks()Gets the delay before the weapon can be used after hitting an entity.- Returns:
- cooldown ticks
-
setContactCooldownTicks
void setContactCooldownTicks(int ticks) Sets the delay before the weapon can be used after hitting an entity.- Parameters:
ticks- new cooldown ticks
-
getDelayTicks
int getDelayTicks()Gets the delay before the weapon can be used.- Returns:
- delay ticks
-
setDelayTicks
void setDelayTicks(int ticks) Sets the delay before the weapon can be used.- Parameters:
ticks- new delay ticks
-
getDismountConditions
Gets the conditions required for the weapon to dismount the target.- Returns:
- dismount condition
-
setDismountConditions
Sets the conditions required for the weapon to dismount the target.- Parameters:
condition- dismount condition
-
getKnockbackConditions
Gets the conditions required for the weapon to knockback the target.- Returns:
- knockback condition
-
setKnockbackConditions
Sets the conditions required for the weapon to knockback the target.- Parameters:
condition- knockback condition
-
getDamageConditions
Gets the conditions required for the weapon to damage the target.- Returns:
- damage condition
-
setDamageConditions
Sets the conditions required for the weapon to damage the target.- Parameters:
condition- damage condition
-
getForwardMovement
float getForwardMovement()Gets the forward movement animation of the item.- Returns:
- forward movement distance
-
setForwardMovement
void setForwardMovement(float movement) Sets the forward movement animation of the item.- Parameters:
movement- new forward movement distance
-
getDamageMultiplier
float getDamageMultiplier()Gets the final damage multiplier based on target and attacker relative speed.- Returns:
- damage multiplier
-
setDamageMultipler
void setDamageMultipler(float multiplier) Sets the final damage multiplier based on target and attacker relative speed.- Parameters:
multiplier- new multiplier
-
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
-