Register new chunks' ticks before post-processing them
postprocess_chunks ran before tick_blocks registered the chunks that arrived since the last tick, so the fluid and block ticks their marks schedule went to chunks the scheduler did not know and were dropped. Vanilla registers a chunk's tick containers before postProcessGeneration.
This commit is contained in:
@@ -27,6 +27,11 @@ impl Game<'_> {
|
||||
if ready.is_empty() {
|
||||
return Ok(());
|
||||
}
|
||||
// The ticks the marks schedule go to the chunks' containers, which a
|
||||
// chunk that arrived since the last tick doesn't have yet
|
||||
// (`LevelChunk.registerTickContainerInLevel` comes before
|
||||
// `postProcessGeneration`).
|
||||
self.sync_tick_chunks();
|
||||
for key in ready {
|
||||
let Some(chunk) = self.world.chunks.get_mut(&key) else {
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user