Record Class AmbientSounds
java.lang.Object
java.lang.Record
fr.fidorial.world.environment.AmbientSounds
- Record Components:
loop- sound continually looped while inside, ornullfor none — waseffects.ambient_soundmood- darkness ambience, ornullfor none — waseffects.mood_soundadditions- randomly played sound, ornullfor none — waseffects.additions_sound
-
Constructor Summary
ConstructorsConstructorDescriptionAmbientSounds(@Nullable Key loop, @Nullable MoodSound mood, @Nullable AdditionsSound additions) Creates an instance of aAmbientSoundsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theadditionsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.loop()Returns the value of thelooprecord component.static AmbientSoundsCreates an attribute carrying only a looping sound.mood()Returns the value of themoodrecord component.static AmbientSoundsCreates an attribute carrying only a mood sound.static AmbientSoundsCreates an attribute carrying a looping sound and a mood sound.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
AmbientSounds
-
-
Method Details
-
loop
Creates an attribute carrying only a looping sound.- Parameters:
loop- the sound event key- Returns:
- the ambient sounds
-
mood
Creates an attribute carrying only a mood sound.- Parameters:
mood- the mood sound- Returns:
- the ambient sounds
-
of
Creates an attribute carrying a looping sound and a mood sound.- Parameters:
loop- the sound event keymood- the mood sound- Returns:
- the ambient sounds
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
loop
-
mood
-
additions
-