Package net.minecraft.sound
Record Class SoundEvent
java.lang.Object
java.lang.Record
net.minecraft.sound.SoundEvent
- Record Components:
id-fixedRange-
- Mappings:
Namespace Name named net/minecraft/sound/SoundEventintermediary net/minecraft/class_3414official awxnamed idintermediary comp_3319official enamed fixedRangeintermediary comp_3320official f
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<SoundEvent> static final com.mojang.serialization.Codec<RegistryEntry<SoundEvent>> static final PacketCodec<RegistryByteBuf, RegistryEntry<SoundEvent>> The field for thefixedRangerecord component.private final IdentifierThe field for theidrecord component.static final PacketCodec<ByteBuf, SoundEvent> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of thefixedRangerecord component.floatgetDistanceToTravel(float volume) final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.static SoundEventof(Identifier id) static SoundEventof(Identifier id, float fixedRange) private static SoundEventof(Identifier id, Optional<Float> fixedRange) final StringtoString()Returns a string representation of this record class.
-
Field Details
-
id
The field for theidrecord component. -
fixedRange
The field for thefixedRangerecord component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/sound/SoundEvent;CODEC:Lcom/mojang/serialization/Codec;intermediary field_41698Lnet/minecraft/class_3414;field_41698:Lcom/mojang/serialization/Codec;official aLawx;a:Lcom/mojang/serialization/Codec;
-
ENTRY_CODEC
- Mappings:
Namespace Name Mixin selector named ENTRY_CODECLnet/minecraft/sound/SoundEvent;ENTRY_CODEC:Lcom/mojang/serialization/Codec;intermediary field_41699Lnet/minecraft/class_3414;field_41699:Lcom/mojang/serialization/Codec;official bLawx;b:Lcom/mojang/serialization/Codec;
-
PACKET_CODEC
- Mappings:
Namespace Name Mixin selector named PACKET_CODECLnet/minecraft/sound/SoundEvent;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;intermediary field_48278Lnet/minecraft/class_3414;field_48278:Lnet/minecraft/class_9139;official cLawx;c:Lze;
-
ENTRY_PACKET_CODEC
- Mappings:
Namespace Name Mixin selector named ENTRY_PACKET_CODECLnet/minecraft/sound/SoundEvent;ENTRY_PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;intermediary field_48279Lnet/minecraft/class_3414;field_48279:Lnet/minecraft/class_9139;official dLawx;d:Lze;
-
-
Constructor Details
-
SoundEvent
- Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/sound/SoundEvent;<init>(Lnet/minecraft/util/Identifier;Ljava/util/Optional;)Vintermediary <init>Lnet/minecraft/class_3414;<init>(Lnet/minecraft/class_2960;Ljava/util/Optional;)Vofficial <init>Lawx;<init>(Lalr;Ljava/util/Optional;)V
-
-
Method Details
-
of
- Mappings:
Namespace Name Mixin selector named ofLnet/minecraft/sound/SoundEvent;of(Lnet/minecraft/util/Identifier;Ljava/util/Optional;)Lnet/minecraft/sound/SoundEvent;intermediary method_47956Lnet/minecraft/class_3414;method_47956(Lnet/minecraft/class_2960;Ljava/util/Optional;)Lnet/minecraft/class_3414;official aLawx;a(Lalr;Ljava/util/Optional;)Lawx;
-
of
- Mappings:
Namespace Name Mixin selector named ofLnet/minecraft/sound/SoundEvent;of(Lnet/minecraft/util/Identifier;)Lnet/minecraft/sound/SoundEvent;intermediary method_47908Lnet/minecraft/class_3414;method_47908(Lnet/minecraft/class_2960;)Lnet/minecraft/class_3414;official aLawx;a(Lalr;)Lawx;
-
of
- Mappings:
Namespace Name Mixin selector named ofLnet/minecraft/sound/SoundEvent;of(Lnet/minecraft/util/Identifier;F)Lnet/minecraft/sound/SoundEvent;intermediary method_47909Lnet/minecraft/class_3414;method_47909(Lnet/minecraft/class_2960;F)Lnet/minecraft/class_3414;official aLawx;a(Lalr;F)Lawx;
-
getDistanceToTravel
public float getDistanceToTravel(float volume) - Mappings:
Namespace Name Mixin selector named getDistanceToTravelLnet/minecraft/sound/SoundEvent;getDistanceToTravel(F)Fintermediary method_43044Lnet/minecraft/class_3414;method_43044(F)Fofficial aLawx;a(F)F
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
fixedRange
Returns the value of thefixedRangerecord component.- Returns:
- the value of the
fixedRangerecord component
-