Package net.minecraft.world.server
Class ServerWorldLightManager
java.lang.Object
net.minecraft.world.lighting.WorldLightManager
net.minecraft.world.server.ServerWorldLightManager
- All Implemented Interfaces:
AutoCloseable
,ILightListener
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ChunkManager
private final it.unimi.dsi.fastutil.objects.ObjectList<com.mojang.datafixers.util.Pair<ServerWorldLightManager.Phase,
Runnable>> private static final org.apache.logging.log4j.Logger
private final AtomicBoolean
private final ITaskExecutor<ChunkTaskPriorityQueueSorter.FunctionEntry<Runnable>>
private final DelegatedTaskExecutor<Runnable>
private int
-
Constructor Summary
ConstructorDescriptionServerWorldLightManager
(IChunkLightProvider p_i50701_1_, ChunkManager p_i50701_2_, boolean p_i50701_3_, DelegatedTaskExecutor<Runnable> p_i50701_4_, ITaskExecutor<ChunkTaskPriorityQueueSorter.FunctionEntry<Runnable>> p_i50701_5_) -
Method Summary
Modifier and TypeMethodDescriptionprivate void
addTask
(int p_215600_1_, int p_215600_2_, IntSupplier p_215600_3_, ServerWorldLightManager.Phase p_215600_4_, Runnable p_215600_5_) private void
addTask
(int p_215586_1_, int p_215586_2_, ServerWorldLightManager.Phase p_215586_3_, Runnable p_215586_4_) void
checkBlock
(BlockPos p_215568_1_) void
close()
void
enableLightSources
(ChunkPos p_215571_1_, boolean p_215571_2_) lightChunk
(IChunk p_215593_1_, boolean p_215593_2_) void
onBlockEmissionIncrease
(BlockPos p_215573_1_, int p_215573_2_) void
queueSectionData
(LightType p_215574_1_, SectionPos p_215574_2_, NibbleArray p_215574_3_, boolean p_215574_4_) void
retainData
(ChunkPos p_223115_1_, boolean p_223115_2_) private void
int
runUpdates
(int p_215575_1_, boolean p_215575_2_, boolean p_215575_3_) void
setTaskPerBatch
(int p_215598_1_) void
protected void
updateChunkStatus
(ChunkPos p_215581_1_) void
updateSectionStatus
(SectionPos p_215566_1_, boolean p_215566_2_) Methods inherited from class net.minecraft.world.lighting.WorldLightManager
getDebugData, getLayerListener, getRawBrightness, hasLightWork
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.world.lighting.ILightListener
updateSectionStatus
-
Field Details
-
LOGGER
private static final org.apache.logging.log4j.Logger LOGGER -
taskMailbox
-
lightTasks
private final it.unimi.dsi.fastutil.objects.ObjectList<com.mojang.datafixers.util.Pair<ServerWorldLightManager.Phase,Runnable>> lightTasks -
chunkMap
-
sorterMailbox
-
taskPerBatch
private volatile int taskPerBatch -
scheduled
-
-
Constructor Details
-
ServerWorldLightManager
public ServerWorldLightManager(IChunkLightProvider p_i50701_1_, ChunkManager p_i50701_2_, boolean p_i50701_3_, DelegatedTaskExecutor<Runnable> p_i50701_4_, ITaskExecutor<ChunkTaskPriorityQueueSorter.FunctionEntry<Runnable>> p_i50701_5_)
-
-
Method Details
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-
runUpdates
public int runUpdates(int p_215575_1_, boolean p_215575_2_, boolean p_215575_3_) - Overrides:
runUpdates
in classWorldLightManager
-
onBlockEmissionIncrease
- Overrides:
onBlockEmissionIncrease
in classWorldLightManager
-
checkBlock
- Overrides:
checkBlock
in classWorldLightManager
-
updateChunkStatus
-
updateSectionStatus
- Specified by:
updateSectionStatus
in interfaceILightListener
- Overrides:
updateSectionStatus
in classWorldLightManager
-
enableLightSources
- Overrides:
enableLightSources
in classWorldLightManager
-
queueSectionData
public void queueSectionData(LightType p_215574_1_, SectionPos p_215574_2_, @Nullable NibbleArray p_215574_3_, boolean p_215574_4_) - Overrides:
queueSectionData
in classWorldLightManager
-
addTask
private void addTask(int p_215586_1_, int p_215586_2_, ServerWorldLightManager.Phase p_215586_3_, Runnable p_215586_4_) -
addTask
private void addTask(int p_215600_1_, int p_215600_2_, IntSupplier p_215600_3_, ServerWorldLightManager.Phase p_215600_4_, Runnable p_215600_5_) -
retainData
- Overrides:
retainData
in classWorldLightManager
-
lightChunk
-
tryScheduleUpdate
public void tryScheduleUpdate() -
runUpdate
private void runUpdate() -
setTaskPerBatch
public void setTaskPerBatch(int p_215598_1_)
-