Package net.minestom.server.registry
Record Class Registry.BlockSoundTypeEntry
java.lang.Object
java.lang.Record
net.minestom.server.registry.Registry.BlockSoundTypeEntry
- Enclosing class:
Registry
public static record Registry.BlockSoundTypeEntry(@NotNull net.kyori.adventure.key.Key key, float volume, float pitch, SoundEvent breakSound, SoundEvent hitSound, SoundEvent fallSound, SoundEvent placeSound, SoundEvent stepSound)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionBlockSoundTypeEntry
(String namespace, Registry.Properties main) BlockSoundTypeEntry
(@NotNull net.kyori.adventure.key.Key key, float volume, float pitch, SoundEvent breakSound, SoundEvent hitSound, SoundEvent fallSound, SoundEvent placeSound, SoundEvent stepSound) Creates an instance of aBlockSoundTypeEntry
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebreakSound
record component.final boolean
Indicates whether some other object is "equal to" this one.Returns the value of thefallSound
record component.final int
hashCode()
Returns a hash code value for this object.hitSound()
Returns the value of thehitSound
record component.@NotNull net.kyori.adventure.key.Key
key()
Returns the value of thekey
record component.float
pitch()
Returns the value of thepitch
record component.Returns the value of theplaceSound
record component.Returns the value of thestepSound
record component.final String
toString()
Returns a string representation of this record class.float
volume()
Returns the value of thevolume
record component.
-
Constructor Details
-
BlockSoundTypeEntry
-
BlockSoundTypeEntry
public BlockSoundTypeEntry(@NotNull @NotNull net.kyori.adventure.key.Key key, float volume, float pitch, SoundEvent breakSound, SoundEvent hitSound, SoundEvent fallSound, SoundEvent placeSound, SoundEvent stepSound) Creates an instance of aBlockSoundTypeEntry
record class.- Parameters:
key
- the value for thekey
record componentvolume
- the value for thevolume
record componentpitch
- the value for thepitch
record componentbreakSound
- the value for thebreakSound
record componenthitSound
- the value for thehitSound
record componentfallSound
- the value for thefallSound
record componentplaceSound
- the value for theplaceSound
record componentstepSound
- the value for thestepSound
record component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
key
@NotNull public @NotNull net.kyori.adventure.key.Key key()Returns the value of thekey
record component.- Returns:
- the value of the
key
record component
-
volume
public float volume()Returns the value of thevolume
record component.- Returns:
- the value of the
volume
record component
-
pitch
public float pitch()Returns the value of thepitch
record component.- Returns:
- the value of the
pitch
record component
-
breakSound
Returns the value of thebreakSound
record component.- Returns:
- the value of the
breakSound
record component
-
hitSound
Returns the value of thehitSound
record component.- Returns:
- the value of the
hitSound
record component
-
fallSound
Returns the value of thefallSound
record component.- Returns:
- the value of the
fallSound
record component
-
placeSound
Returns the value of theplaceSound
record component.- Returns:
- the value of the
placeSound
record component
-
stepSound
Returns the value of thestepSound
record component.- Returns:
- the value of the
stepSound
record component
-