Package net.minecraft.server.level
Class ChunkTracker
java.lang.Object
net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
net.minecraft.server.level.ChunkTracker
- Direct Known Subclasses:
DistanceManager.ChunkTicketTracker
,DistanceManager.FixedPlayerDistanceChunkTracker
,TickingTracker
-
Field Summary
Fields inherited from class net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
levelCount, SOURCE
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
ChunkTracker
(int firstQueuedLevel, int width, int height) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
checkNeighborsAfterUpdate
(long pos, int level, boolean isDecreasing) protected int
computeLevelFromNeighbor
(long startPos, long endPos, int startLevel) Returns level propagated from start position with specified level to the neighboring end position.protected int
getComputedLevel
(long pos, long excludedSourcePos, int level) Computes level propagated from neighbors of specified position with given existing level, excluding the given source position.protected abstract int
getLevelFromSource
(long pos) protected boolean
isSource
(long pos) void
update
(long pos, int level, boolean isDecreasing) Methods inherited from class net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
checkEdge, checkNeighbor, checkNode, getLevel, getQueueSize, hasWork, removeFromQueue, removeIf, runUpdates, setLevel
-
Constructor Details
-
ChunkTracker
protected ChunkTracker(int firstQueuedLevel, int width, int height)
-
-
Method Details
-
isSource
protected boolean isSource(long pos) - Overrides:
isSource
in classDynamicGraphMinFixedPoint
-
checkNeighborsAfterUpdate
protected void checkNeighborsAfterUpdate(long pos, int level, boolean isDecreasing) - Specified by:
checkNeighborsAfterUpdate
in classDynamicGraphMinFixedPoint
-
getComputedLevel
protected int getComputedLevel(long pos, long excludedSourcePos, int level) Computes level propagated from neighbors of specified position with given existing level, excluding the given source position.- Specified by:
getComputedLevel
in classDynamicGraphMinFixedPoint
-
computeLevelFromNeighbor
protected int computeLevelFromNeighbor(long startPos, long endPos, int startLevel) Returns level propagated from start position with specified level to the neighboring end position.- Specified by:
computeLevelFromNeighbor
in classDynamicGraphMinFixedPoint
-
getLevelFromSource
protected abstract int getLevelFromSource(long pos) -
update
public void update(long pos, int level, boolean isDecreasing)
-