Package net.minecraft.server.level
Class SectionTracker
java.lang.Object
net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
net.minecraft.server.level.SectionTracker
- Direct Known Subclasses:
PoiManager.DistanceTracker
-
Field Summary
Fields inherited from class net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
levelCount, SOURCE
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
SectionTracker
(int pFirstQueuedLevel, int pWidth, int pHeight) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
checkNeighborsAfterUpdate
(long pPos, int pLevel, boolean pIsDecreasing) protected int
computeLevelFromNeighbor
(long pStartPos, long pEndPos, int pStartLevel) Returns level propagated from start position with specified level to the neighboring end position.protected int
getComputedLevel
(long pPos, long pExcludedSourcePos, int pLevel) Computes level propagated from neighbors of specified position with given existing level, excluding the given source position.protected abstract int
getLevelFromSource
(long pPos) void
update
(long pPos, int pLevel, boolean pIsDecreasing) Methods inherited from class net.minecraft.world.level.lighting.DynamicGraphMinFixedPoint
checkEdge, checkNeighbor, checkNode, getLevel, getQueueSize, hasWork, isSource, removeFromQueue, removeIf, runUpdates, setLevel
-
Constructor Details
-
SectionTracker
protected SectionTracker(int pFirstQueuedLevel, int pWidth, int pHeight)
-
-
Method Details
-
checkNeighborsAfterUpdate
protected void checkNeighborsAfterUpdate(long pPos, int pLevel, boolean pIsDecreasing) - Specified by:
checkNeighborsAfterUpdate
in classDynamicGraphMinFixedPoint
-
getComputedLevel
protected int getComputedLevel(long pPos, long pExcludedSourcePos, int pLevel) 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 pStartPos, long pEndPos, int pStartLevel) 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 pPos) -
update
public void update(long pPos, int pLevel, boolean pIsDecreasing)
-