Record Class Tick<T>

java.lang.Object
java.lang.Record
net.minecraft.world.tick.Tick<T>
Record Components:
type -
pos -
delay -
priority -

public record Tick<T>(T type, BlockPos pos, int delay, TickPriority priority) extends Record
Mappings:
Namespace Name
named net/minecraft/world/tick/Tick
intermediary net/minecraft/class_6759
official eym
named type
intermediary comp_248
official b
named pos
intermediary comp_249
official c
named delay
intermediary comp_250
official d
named priority
intermediary comp_251
official e
  • Field Details

    • type

      private final T type
      The field for the type record component.
    • pos

      private final BlockPos pos
      The field for the pos record component.
    • delay

      private final int delay
      The field for the delay record component.
    • priority

      private final TickPriority priority
      The field for the priority record component.
    • TYPE_NBT_KEY

      private static final String TYPE_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named TYPE_NBT_KEY Lnet/minecraft/world/tick/Tick;TYPE_NBT_KEY:Ljava/lang/String;
      intermediary field_35543 Lnet/minecraft/class_6759;field_35543:Ljava/lang/String;
      official f Leym;f:Ljava/lang/String;
    • X_NBT_KEY

      private static final String X_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named X_NBT_KEY Lnet/minecraft/world/tick/Tick;X_NBT_KEY:Ljava/lang/String;
      intermediary field_35544 Lnet/minecraft/class_6759;field_35544:Ljava/lang/String;
      official g Leym;g:Ljava/lang/String;
    • Y_NBT_KEY

      private static final String Y_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named Y_NBT_KEY Lnet/minecraft/world/tick/Tick;Y_NBT_KEY:Ljava/lang/String;
      intermediary field_35545 Lnet/minecraft/class_6759;field_35545:Ljava/lang/String;
      official h Leym;h:Ljava/lang/String;
    • Z_NBT_KEY

      private static final String Z_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named Z_NBT_KEY Lnet/minecraft/world/tick/Tick;Z_NBT_KEY:Ljava/lang/String;
      intermediary field_35546 Lnet/minecraft/class_6759;field_35546:Ljava/lang/String;
      official i Leym;i:Ljava/lang/String;
    • DELAY_NBT_KEY

      private static final String DELAY_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named DELAY_NBT_KEY Lnet/minecraft/world/tick/Tick;DELAY_NBT_KEY:Ljava/lang/String;
      intermediary field_35547 Lnet/minecraft/class_6759;field_35547:Ljava/lang/String;
      official j Leym;j:Ljava/lang/String;
    • PRIORITY_NBT_KEY

      private static final String PRIORITY_NBT_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named PRIORITY_NBT_KEY Lnet/minecraft/world/tick/Tick;PRIORITY_NBT_KEY:Ljava/lang/String;
      intermediary field_35548 Lnet/minecraft/class_6759;field_35548:Ljava/lang/String;
      official k Leym;k:Ljava/lang/String;
    • HASH_STRATEGY

      public static final Hash.Strategy<Tick<?>> HASH_STRATEGY
      Mappings:
      Namespace Name Mixin selector
      named HASH_STRATEGY Lnet/minecraft/world/tick/Tick;HASH_STRATEGY:Lit/unimi/dsi/fastutil/Hash$Strategy;
      intermediary field_35542 Lnet/minecraft/class_6759;field_35542:Lit/unimi/dsi/fastutil/Hash$Strategy;
      official a Leym;a:Lit/unimi/dsi/fastutil/Hash$Strategy;
  • Constructor Details

  • Method Details

    • tick

      public static <T> void tick(NbtList tickList, Function<String,Optional<T>> nameToTypeFunction, ChunkPos pos, Consumer<Tick<T>> tickConsumer)
      Mappings:
      Namespace Name Mixin selector
      named tick Lnet/minecraft/world/tick/Tick;tick(Lnet/minecraft/nbt/NbtList;Ljava/util/function/Function;Lnet/minecraft/util/math/ChunkPos;Ljava/util/function/Consumer;)V
      intermediary method_39406 Lnet/minecraft/class_6759;method_39406(Lnet/minecraft/class_2499;Ljava/util/function/Function;Lnet/minecraft/class_1923;Ljava/util/function/Consumer;)V
      official a Leym;a(Lug;Ljava/util/function/Function;Ldcb;Ljava/util/function/Consumer;)V
    • fromNbt

      public static <T> Optional<Tick<T>> fromNbt(NbtCompound nbt, Function<String,Optional<T>> nameToType)
      Mappings:
      Namespace Name Mixin selector
      named fromNbt Lnet/minecraft/world/tick/Tick;fromNbt(Lnet/minecraft/nbt/NbtCompound;Ljava/util/function/Function;)Ljava/util/Optional;
      intermediary method_40559 Lnet/minecraft/class_6759;method_40559(Lnet/minecraft/class_2487;Ljava/util/function/Function;)Ljava/util/Optional;
      official a Leym;a(Lua;Ljava/util/function/Function;)Ljava/util/Optional;
    • toNbt

      private static NbtCompound toNbt(String type, BlockPos pos, int delay, TickPriority priority)
      Mappings:
      Namespace Name Mixin selector
      named toNbt Lnet/minecraft/world/tick/Tick;toNbt(Ljava/lang/String;Lnet/minecraft/util/math/BlockPos;ILnet/minecraft/world/tick/TickPriority;)Lnet/minecraft/nbt/NbtCompound;
      intermediary method_39403 Lnet/minecraft/class_6759;method_39403(Ljava/lang/String;Lnet/minecraft/class_2338;ILnet/minecraft/class_1953;)Lnet/minecraft/class_2487;
      official a Leym;a(Ljava/lang/String;Ljd;ILeyr;)Lua;
    • orderedTickToNbt

      public static <T> NbtCompound orderedTickToNbt(OrderedTick<T> orderedTick, Function<T,String> typeToNameFunction, long delay)
      Mappings:
      Namespace Name Mixin selector
      named orderedTickToNbt Lnet/minecraft/world/tick/Tick;orderedTickToNbt(Lnet/minecraft/world/tick/OrderedTick;Ljava/util/function/Function;J)Lnet/minecraft/nbt/NbtCompound;
      intermediary method_39401 Lnet/minecraft/class_6759;method_39401(Lnet/minecraft/class_6760;Ljava/util/function/Function;J)Lnet/minecraft/class_2487;
      official a Leym;a(Leyn;Ljava/util/function/Function;J)Lua;
    • toNbt

      public NbtCompound toNbt(Function<T,String> typeToNameFunction)
      Mappings:
      Namespace Name Mixin selector
      named toNbt Lnet/minecraft/world/tick/Tick;toNbt(Ljava/util/function/Function;)Lnet/minecraft/nbt/NbtCompound;
      intermediary method_39404 Lnet/minecraft/class_6759;method_39404(Ljava/util/function/Function;)Lnet/minecraft/class_2487;
      official a Leym;a(Ljava/util/function/Function;)Lua;
    • createOrderedTick

      public OrderedTick<T> createOrderedTick(long time, long subTickOrder)
      Mappings:
      Namespace Name Mixin selector
      named createOrderedTick Lnet/minecraft/world/tick/Tick;createOrderedTick(JJ)Lnet/minecraft/world/tick/OrderedTick;
      intermediary method_39400 Lnet/minecraft/class_6759;method_39400(JJ)Lnet/minecraft/class_6760;
      official a Leym;a(JJ)Leyn;
    • create

      public static <T> Tick<T> create(T type, BlockPos pos)
      Mappings:
      Namespace Name Mixin selector
      named create Lnet/minecraft/world/tick/Tick;create(Ljava/lang/Object;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/world/tick/Tick;
      intermediary method_39402 Lnet/minecraft/class_6759;method_39402(Ljava/lang/Object;Lnet/minecraft/class_2338;)Lnet/minecraft/class_6759;
      official a Leym;a(Ljava/lang/Object;Ljd;)Leym;
    • 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 object)
      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 with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      object - the object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise.
    • type

      public T type()
      Returns the value of the type record component.
      Returns:
      the value of the type record component
    • pos

      public BlockPos pos()
      Returns the value of the pos record component.
      Returns:
      the value of the pos record component
    • delay

      public int delay()
      Returns the value of the delay record component.
      Returns:
      the value of the delay record component
    • priority

      public TickPriority priority()
      Returns the value of the priority record component.
      Returns:
      the value of the priority record component