Record Class CatSoundVariant.CatSoundSet

java.lang.Object
java.lang.Record
net.minecraft.world.entity.animal.feline.CatSoundVariant.CatSoundSet
Enclosing class:
CatSoundVariant

public static record CatSoundVariant.CatSoundSet(Holder<SoundEvent> ambientSound, Holder<SoundEvent> strayAmbientSound, Holder<SoundEvent> hissSound, Holder<SoundEvent> hurtSound, Holder<SoundEvent> deathSound, Holder<SoundEvent> eatSound, Holder<SoundEvent> begForFoodSound, Holder<SoundEvent> purrSound, Holder<SoundEvent> purreowSound) extends Record
  • Field Details

    • ambientSound

      private final Holder<SoundEvent> ambientSound
      The field for the ambientSound record component.
    • strayAmbientSound

      private final Holder<SoundEvent> strayAmbientSound
      The field for the strayAmbientSound record component.
    • hissSound

      private final Holder<SoundEvent> hissSound
      The field for the hissSound record component.
    • hurtSound

      private final Holder<SoundEvent> hurtSound
      The field for the hurtSound record component.
    • deathSound

      private final Holder<SoundEvent> deathSound
      The field for the deathSound record component.
    • eatSound

      private final Holder<SoundEvent> eatSound
      The field for the eatSound record component.
    • begForFoodSound

      private final Holder<SoundEvent> begForFoodSound
      The field for the begForFoodSound record component.
    • purrSound

      private final Holder<SoundEvent> purrSound
      The field for the purrSound record component.
    • purreowSound

      private final Holder<SoundEvent> purreowSound
      The field for the purreowSound record component.
    • CODEC

      private static com.mojang.serialization.Codec<CatSoundVariant.CatSoundSet> CODEC
  • Constructor Details

    • CatSoundSet

      public CatSoundSet(Holder<SoundEvent> ambientSound, Holder<SoundEvent> strayAmbientSound, Holder<SoundEvent> hissSound, Holder<SoundEvent> hurtSound, Holder<SoundEvent> deathSound, Holder<SoundEvent> eatSound, Holder<SoundEvent> begForFoodSound, Holder<SoundEvent> purrSound, Holder<SoundEvent> purreowSound)
      Creates an instance of a CatSoundSet record class.
      Parameters:
      ambientSound - the value for the ambientSound record component
      strayAmbientSound - the value for the strayAmbientSound record component
      hissSound - the value for the hissSound record component
      hurtSound - the value for the hurtSound record component
      deathSound - the value for the deathSound record component
      eatSound - the value for the eatSound record component
      begForFoodSound - the value for the begForFoodSound record component
      purrSound - the value for the purrSound record component
      purreowSound - the value for the purreowSound record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • ambientSound

      public Holder<SoundEvent> ambientSound()
      Returns the value of the ambientSound record component.
      Returns:
      the value of the ambientSound record component
    • strayAmbientSound

      public Holder<SoundEvent> strayAmbientSound()
      Returns the value of the strayAmbientSound record component.
      Returns:
      the value of the strayAmbientSound record component
    • hissSound

      public Holder<SoundEvent> hissSound()
      Returns the value of the hissSound record component.
      Returns:
      the value of the hissSound record component
    • hurtSound

      public Holder<SoundEvent> hurtSound()
      Returns the value of the hurtSound record component.
      Returns:
      the value of the hurtSound record component
    • deathSound

      public Holder<SoundEvent> deathSound()
      Returns the value of the deathSound record component.
      Returns:
      the value of the deathSound record component
    • eatSound

      public Holder<SoundEvent> eatSound()
      Returns the value of the eatSound record component.
      Returns:
      the value of the eatSound record component
    • begForFoodSound

      public Holder<SoundEvent> begForFoodSound()
      Returns the value of the begForFoodSound record component.
      Returns:
      the value of the begForFoodSound record component
    • purrSound

      public Holder<SoundEvent> purrSound()
      Returns the value of the purrSound record component.
      Returns:
      the value of the purrSound record component
    • purreowSound

      public Holder<SoundEvent> purreowSound()
      Returns the value of the purreowSound record component.
      Returns:
      the value of the purreowSound record component