Package net.minecraft.world.ticks
Record Class SavedTick<T>
java.lang.Object
java.lang.Record
net.minecraft.world.ticks.SavedTick<T>
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final intThe field for thedelayrecord component.private final BlockPosThe field for theposrecord component.private final TickPriorityThe field for thepriorityrecord component.private static final Stringprivate static final Stringprivate static final Stringprivate static final Stringprivate static final Stringprivate static final Stringprivate final TThe field for thetyperecord component.static final it.unimi.dsi.fastutil.Hash.Strategy<SavedTick<?>>
- 
Constructor SummaryConstructorsConstructorDescriptionSavedTick(T type, BlockPos pos, int delay, TickPriority priority) Creates an instance of aSavedTickrecord class.
- 
Method SummaryModifier and TypeMethodDescriptionintdelay()Returns the value of thedelayrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.loadTick(CompoundTag p_210670_, Function<String, Optional<T>> p_210671_) static <T> voidloadTickList(ListTag p_193351_, Function<String, Optional<T>> p_193352_, ChunkPos p_193353_, Consumer<SavedTick<T>> p_193354_) pos()Returns the value of theposrecord component.priority()Returns the value of thepriorityrecord component.static <T> SavedTick<T>private static CompoundTagsaveTick(String p_193339_, BlockPos p_193340_, int p_193341_, TickPriority p_193342_) static <T> CompoundTagsaveTick(ScheduledTick<T> p_193332_, Function<T, String> p_193333_, long p_193334_) final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.unpack(long p_193329_, long p_193330_) 
- 
Field Details- 
typeThe field for thetyperecord component.
- 
posThe field for theposrecord component.
- 
delayprivate final int delayThe field for thedelayrecord component.
- 
priorityThe field for thepriorityrecord component.
- 
TAG_ID- See Also:
 
- 
TAG_X- See Also:
 
- 
TAG_Y- See Also:
 
- 
TAG_Z- See Also:
 
- 
TAG_DELAY- See Also:
 
- 
TAG_PRIORITY- See Also:
 
- 
UNIQUE_TICK_HASH
 
- 
- 
Constructor Details- 
SavedTickCreates an instance of aSavedTickrecord class.- Parameters:
- type- the value for the- typerecord component
- pos- the value for the- posrecord component
- delay- the value for the- delayrecord component
- priority- the value for the- priorityrecord component
 
 
- 
- 
Method Details- 
loadTickList
- 
loadTick
- 
saveTickprivate static CompoundTag saveTick(String p_193339_, BlockPos p_193340_, int p_193341_, TickPriority p_193342_) 
- 
saveTickpublic static <T> CompoundTag saveTick(ScheduledTick<T> p_193332_, Function<T, String> p_193333_, long p_193334_) 
- 
save
- 
unpack
- 
probe
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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 withObjects::equals(Object,Object); primitive components are compared with '=='.
- 
typeReturns the value of thetyperecord component.- Returns:
- the value of the typerecord component
 
- 
posReturns the value of theposrecord component.- Returns:
- the value of the posrecord component
 
- 
delaypublic int delay()Returns the value of thedelayrecord component.- Returns:
- the value of the delayrecord component
 
- 
priorityReturns the value of thepriorityrecord component.- Returns:
- the value of the priorityrecord component
 
 
-