Record Class TimelineEntry<Value,Argument>
java.lang.Object
java.lang.Record
net.minecraft.world.attribute.timeline.TimelineEntry<Value,Argument>
- Record Components:
modifier-argumentTrack-
public record TimelineEntry<Value,Argument> (EnvironmentAttributeModifier<Value,Argument> modifier, Track<Argument> argumentTrack)
extends Record
- Mappings:
Namespace Name named net/minecraft/world/attribute/timeline/TimelineEntryintermediary net/minecraft/class_12327official fudnamed modifierintermediary comp_5223official anamed argumentTrackintermediary comp_5224official b
-
Field Summary
FieldsModifier and TypeFieldDescriptionThe field for theargumentTrackrecord component.private final EnvironmentAttributeModifier<Value, Argument> The field for themodifierrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionTimelineEntry(EnvironmentAttributeModifier<Value, Argument> modifier, Track<Argument> argumentTrack) Creates an instance of aTimelineEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theargumentTrackrecord component.static <Value> com.mojang.serialization.Codec<TimelineEntry<Value, ?>> createCodec(EnvironmentAttribute<Value> attribute) private static <Value,Argument>
com.mojang.serialization.MapCodec<TimelineEntry<Value, Argument>> createMapCodec(EnvironmentAttribute<Value> attribute, EnvironmentAttributeModifier<Value, Argument> modifier) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.modifier()Returns the value of themodifierrecord component.toModification(EnvironmentAttribute<Value> attribute, Optional<Integer> period, LongSupplier timeSupplier) final StringtoString()Returns a string representation of this record class.static com.mojang.serialization.DataResult<TimelineEntry<?, ?>> validateKeyframesInPeriod(TimelineEntry<?, ?> entry, int period)
-
Field Details
-
modifier
The field for themodifierrecord component. -
argumentTrack
The field for theargumentTrackrecord component.
-
-
Constructor Details
-
TimelineEntry
public TimelineEntry(EnvironmentAttributeModifier<Value, Argument> modifier, Track<Argument> argumentTrack) Creates an instance of aTimelineEntryrecord class.- Parameters:
modifier- the value for themodifierrecord componentargumentTrack- the value for theargumentTrackrecord component
-
-
Method Details
-
createCodec
public static <Value> com.mojang.serialization.Codec<TimelineEntry<Value,?>> createCodec(EnvironmentAttribute<Value> attribute) - Mappings:
Namespace Name Mixin selector named createCodecLnet/minecraft/world/attribute/timeline/TimelineEntry;createCodec(Lnet/minecraft/world/attribute/EnvironmentAttribute;)Lcom/mojang/serialization/Codec;intermediary method_76471Lnet/minecraft/class_12327;method_76471(Lnet/minecraft/class_12197;)Lcom/mojang/serialization/Codec;official aLfud;a(Lcdy;)Lcom/mojang/serialization/Codec;
-
createMapCodec
private static <Value,Argument> com.mojang.serialization.MapCodec<TimelineEntry<Value,Argument>> createMapCodec(EnvironmentAttribute<Value> attribute, EnvironmentAttributeModifier<Value, Argument> modifier) - Mappings:
Namespace Name Mixin selector named createMapCodecLnet/minecraft/world/attribute/timeline/TimelineEntry;createMapCodec(Lnet/minecraft/world/attribute/EnvironmentAttribute;Lnet/minecraft/world/attribute/EnvironmentAttributeModifier;)Lcom/mojang/serialization/MapCodec;intermediary method_76472Lnet/minecraft/class_12327;method_76472(Lnet/minecraft/class_12197;Lnet/minecraft/class_12212;)Lcom/mojang/serialization/MapCodec;official aLfud;a(Lcdy;Lcej;)Lcom/mojang/serialization/MapCodec;
-
toModification
public TrackAttributeModification<Value,Argument> toModification(EnvironmentAttribute<Value> attribute, Optional<Integer> period, LongSupplier timeSupplier) - Mappings:
Namespace Name Mixin selector named toModificationLnet/minecraft/world/attribute/timeline/TimelineEntry;toModification(Lnet/minecraft/world/attribute/EnvironmentAttribute;Ljava/util/Optional;Ljava/util/function/LongSupplier;)Lnet/minecraft/world/attribute/timeline/TrackAttributeModification;intermediary method_76473Lnet/minecraft/class_12327;method_76473(Lnet/minecraft/class_12197;Ljava/util/Optional;Ljava/util/function/LongSupplier;)Lnet/minecraft/class_12328;official aLfud;a(Lcdy;Ljava/util/Optional;Ljava/util/function/LongSupplier;)Lfue;
-
validateKeyframesInPeriod
public static com.mojang.serialization.DataResult<TimelineEntry<?,?>> validateKeyframesInPeriod(TimelineEntry<?, ?> entry, int period) - Mappings:
Namespace Name Mixin selector named validateKeyframesInPeriodLnet/minecraft/world/attribute/timeline/TimelineEntry;validateKeyframesInPeriod(Lnet/minecraft/world/attribute/timeline/TimelineEntry;I)Lcom/mojang/serialization/DataResult;intermediary method_76475Lnet/minecraft/class_12327;method_76475(Lnet/minecraft/class_12327;I)Lcom/mojang/serialization/DataResult;official aLfud;a(Lfud;I)Lcom/mojang/serialization/DataResult;
-
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). -
modifier
Returns the value of themodifierrecord component.- Returns:
- the value of the
modifierrecord component
-
argumentTrack
Returns the value of theargumentTrackrecord component.- Returns:
- the value of the
argumentTrackrecord component
-