Record Class SoundFileEntry
java.lang.Object
java.lang.Record
de.luckymcdev.foundryengine.common.builder.sound.SoundFileEntry
public record SoundFileEntry(net.minecraft.resources.Identifier location, float volume, float pitch, int weight, boolean stream, int attenuationDistance, boolean preload)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionSoundFileEntry(net.minecraft.resources.Identifier location) SoundFileEntry(net.minecraft.resources.Identifier location, float volume, float pitch, int weight, boolean stream, int attenuationDistance, boolean preload) Creates an instance of aSoundFileEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of theattenuationDistancerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.minecraft.resources.Identifierlocation()Returns the value of thelocationrecord component.floatpitch()Returns the value of thepitchrecord component.booleanpreload()Returns the value of thepreloadrecord component.booleanstream()Returns the value of thestreamrecord component.final StringtoString()Returns a string representation of this record class.floatvolume()Returns the value of thevolumerecord component.intweight()Returns the value of theweightrecord component.
-
Constructor Details
-
SoundFileEntry
public SoundFileEntry(net.minecraft.resources.Identifier location) -
SoundFileEntry
public SoundFileEntry(net.minecraft.resources.Identifier location, float volume, float pitch, int weight, boolean stream, int attenuationDistance, boolean preload) Creates an instance of aSoundFileEntryrecord class.- Parameters:
location- the value for thelocationrecord componentvolume- the value for thevolumerecord componentpitch- the value for thepitchrecord componentweight- the value for theweightrecord componentstream- the value for thestreamrecord componentattenuationDistance- the value for theattenuationDistancerecord componentpreload- the value for thepreloadrecord component
-
-
Method Details
-
toString
-
hashCode
-
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 thecomparemethod from their corresponding wrapper classes. -
location
public net.minecraft.resources.Identifier location()Returns the value of thelocationrecord component.- Returns:
- the value of the
locationrecord component
-
volume
public float volume()Returns the value of thevolumerecord component.- Returns:
- the value of the
volumerecord component
-
pitch
public float pitch()Returns the value of thepitchrecord component.- Returns:
- the value of the
pitchrecord component
-
weight
public int weight()Returns the value of theweightrecord component.- Returns:
- the value of the
weightrecord component
-
stream
public boolean stream()Returns the value of thestreamrecord component.- Returns:
- the value of the
streamrecord component
-
attenuationDistance
public int attenuationDistance()Returns the value of theattenuationDistancerecord component.- Returns:
- the value of the
attenuationDistancerecord component
-
preload
public boolean preload()Returns the value of thepreloadrecord component.- Returns:
- the value of the
preloadrecord component
-