Interface InstrumentRegistryEntry
- All Known Subinterfaces:
InstrumentRegistryEntry.Builder
@NonExtendable
public interface InstrumentRegistryEntry
A data-centric version-specific registry entry for the
MusicInstrument type.- Since:
- 1.21.7
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA mutable builder for theInstrumentRegistryEntryplugins may change in applicable registry events. -
Method Summary
Modifier and TypeMethodDescriptionnet.kyori.adventure.text.ComponentProvides the description of the instrument, which is used in the item tooltip.@NonNegative intProvides the amount of durability to consume on each use.@NonNegative floatduration()Provides the duration of the instrument, which is time to use.@Positive floatrange()Provides the range of the instrument, which is range of the sound.Provides the sound event of the instrument.
-
Method Details
-
soundEvent
Provides the sound event of the instrument.- Returns:
- the sound event
- Since:
- 1.21.7
- See Also:
-
duration
@Contract(pure=true) @NonNegative float duration()Provides the duration of the instrument, which is time to use.- Returns:
- the duration
- Since:
- 1.21.7
- See Also:
-
range
@Contract(pure=true) @Positive float range()Provides the range of the instrument, which is range of the sound.- Returns:
- the range
- Since:
- 1.21.7
- See Also:
-
durabilityDamage
@Contract(pure=true) @NonNegative int durabilityDamage()Provides the amount of durability to consume on each use.- Returns:
- the amount of durability to consume
- Since:
- 26.3
-
description
@Contract(pure=true) net.kyori.adventure.text.Component description()Provides the description of the instrument, which is used in the item tooltip.- Returns:
- the description
- Since:
- 1.21.7
- See Also:
-