mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-03 08:39:53 +00:00
World: Fixed inverted completion callbacks for chunk population
this would have caused any chunk populated by a plugin to remain loaded forever.
This commit is contained in:
parent
f9bfc0df73
commit
998a583815
@ -2706,8 +2706,8 @@ class World implements ChunkManager{
|
|||||||
$temporaryLoader = new class implements ChunkLoader{};
|
$temporaryLoader = new class implements ChunkLoader{};
|
||||||
$this->registerChunkLoader($temporaryLoader, $chunkX, $chunkZ);
|
$this->registerChunkLoader($temporaryLoader, $chunkX, $chunkZ);
|
||||||
$promise->onCompletion(
|
$promise->onCompletion(
|
||||||
static function() : void{},
|
fn() => $this->unregisterChunkLoader($temporaryLoader, $chunkX, $chunkZ),
|
||||||
fn() => $this->unregisterChunkLoader($temporaryLoader, $chunkX, $chunkZ)
|
static function() : void{}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
return $promise;
|
return $promise;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user