Skip to content

Commit

Permalink
Fix level loading screen showing 0% until in-game
Browse files Browse the repository at this point in the history
  • Loading branch information
jpenilla committed Aug 23, 2024
1 parent dff8c59 commit bce1f95
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1363,6 +1363,9 @@ private void completeStatusConsumers0(final ChunkStatus status, final ChunkAcces
final List<Consumer<ChunkAccess>> consumers;
consumers = this.statusWaiters.remove(status);

// Update progress listener for LevelLoadingScreen
this.world.getChunkSource().chunkMap.progressListener.onStatusChange(chunk.getPos(), status);

if (consumers == null) {
return;
}
Expand Down
1 change: 1 addition & 0 deletions src/main/resources/moonrise.accesswidener
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ accessible method net/minecraft/server/level/ChunkMap setServerViewDistance (I)V
accessible method net/minecraft/server/level/ChunkMap upgradeChunkTag (Lnet/minecraft/nbt/CompoundTag;)Lnet/minecraft/nbt/CompoundTag;
accessible field net/minecraft/server/level/ChunkMap worldGenContext Lnet/minecraft/world/level/chunk/status/WorldGenContext;
accessible field net/minecraft/server/level/ChunkMap tickingGenerated Ljava/util/concurrent/atomic/AtomicInteger;
accessible field net/minecraft/server/level/ChunkMap progressListener Lnet/minecraft/server/level/progress/ChunkProgressListener;

# ChunkLevel
accessible field net/minecraft/server/level/ChunkLevel FULL_CHUNK_LEVEL I
Expand Down

0 comments on commit bce1f95

Please sign in to comment.