Class SkyLightEngine
java.lang.Object
net.minecraft.world.level.lighting.LightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
net.minecraft.world.level.lighting.SkyLightEngine
- All Implemented Interfaces:
LayerLightEventListener,LightEventListener
public final class SkyLightEngine
extends LightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.lighting.LightEngine
LightEngine.QueueEntryNested classes/interfaces inherited from interface net.minecraft.world.level.lighting.LayerLightEventListener
LayerLightEventListener.DummyLightLayerEventListener -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final longprivate final ChunkSkyLightSourcesprivate final BlockPos.MutableBlockPosprivate static final longprivate static final longFields inherited from class net.minecraft.world.level.lighting.LightEngine
chunkSource, MAX_LEVEL, MIN_OPACITY, PROPAGATION_DIRECTIONS, PULL_LIGHT_IN_ENTRY, storage -
Constructor Summary
ConstructorsModifierConstructorDescriptionSkyLightEngine(LightChunkGetter p_75843_) protectedSkyLightEngine(LightChunkGetter p_282215_, SkyLightSectionStorage p_282341_) -
Method Summary
Modifier and TypeMethodDescriptionprivate voidaddSourcesAbove(int p_285241_, int p_285212_, int p_284972_, int p_285134_) protected voidcheckNode(long p_75859_) private intcountEmptySectionsBelowIfAtBorder(long p_285356_) private static booleancrossedSectionEdge(Direction p_285014_, int p_284991_, int p_285468_) private ChunkSkyLightSourcesgetChunkSources(int p_285270_, int p_285307_) private intgetLowestSourceY(int p_285058_, int p_285191_, int p_285111_) private static booleanisSourceLevel(int p_285004_) protected voidpropagateDecrease(long p_285015_, long p_285395_) private voidpropagateFromEmptySections(long p_284965_, Direction p_285308_, int p_284977_, boolean p_285001_, int p_285052_) protected voidpropagateIncrease(long p_285341_, long p_285204_, int p_285003_) voidpropagateLightSources(ChunkPos p_285333_) private voidremoveSourcesBelow(int p_285475_, int p_285138_, int p_285130_, int p_285112_) voidsetLightEnabled(ChunkPos p_285459_, boolean p_285013_) private voidupdateSourcesInColumn(int p_285053_, int p_285140_, int p_285337_) Methods inherited from class net.minecraft.world.level.lighting.LightEngine
checkBlock, enqueueDecrease, enqueueIncrease, getChunk, getDataLayerData, getDebugData, getDebugSectionType, getLightBlockInto, getLightValue, getOcclusionShape, getOcclusionShape, getOpacity, getState, hasDifferentLightProperties, hasLightWork, isEmptyShape, queueSectionData, retainData, runLightUpdates, shapeOccludes, updateSectionStatusMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.world.level.lighting.LightEventListener
updateSectionStatus
-
Field Details
-
REMOVE_TOP_SKY_SOURCE_ENTRY
private static final long REMOVE_TOP_SKY_SOURCE_ENTRY -
REMOVE_SKY_SOURCE_ENTRY
private static final long REMOVE_SKY_SOURCE_ENTRY -
ADD_SKY_SOURCE_ENTRY
private static final long ADD_SKY_SOURCE_ENTRY -
mutablePos
-
emptyChunkSources
-
-
Constructor Details
-
SkyLightEngine
-
SkyLightEngine
@VisibleForTesting protected SkyLightEngine(LightChunkGetter p_282215_, SkyLightSectionStorage p_282341_)
-
-
Method Details
-
isSourceLevel
private static boolean isSourceLevel(int p_285004_) -
getLowestSourceY
private int getLowestSourceY(int p_285058_, int p_285191_, int p_285111_) -
getChunkSources
-
checkNode
protected void checkNode(long p_75859_) - Specified by:
checkNodein classLightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
-
updateSourcesInColumn
private void updateSourcesInColumn(int p_285053_, int p_285140_, int p_285337_) -
removeSourcesBelow
private void removeSourcesBelow(int p_285475_, int p_285138_, int p_285130_, int p_285112_) -
addSourcesAbove
private void addSourcesAbove(int p_285241_, int p_285212_, int p_284972_, int p_285134_) -
propagateIncrease
protected void propagateIncrease(long p_285341_, long p_285204_, int p_285003_) - Specified by:
propagateIncreasein classLightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
-
propagateDecrease
protected void propagateDecrease(long p_285015_, long p_285395_) - Specified by:
propagateDecreasein classLightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
-
countEmptySectionsBelowIfAtBorder
private int countEmptySectionsBelowIfAtBorder(long p_285356_) -
propagateFromEmptySections
private void propagateFromEmptySections(long p_284965_, Direction p_285308_, int p_284977_, boolean p_285001_, int p_285052_) -
crossedSectionEdge
-
setLightEnabled
- Specified by:
setLightEnabledin interfaceLightEventListener- Overrides:
setLightEnabledin classLightEngine<SkyLightSectionStorage.SkyDataLayerStorageMap,SkyLightSectionStorage>
-
propagateLightSources
-