mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-26 04:43:45 +00:00
Player: don't re-request chunks unless they've already been sent
if they've been requested, the ChunkCache will take care of rebuilding the chunk packet before sending it.
This commit is contained in:
parent
129c638e29
commit
b4afa46fad
@ -2345,7 +2345,7 @@ class Player extends Human implements CommandSender, ChunkListener, IPlayer{
|
||||
|
||||
public function onChunkChanged(int $chunkX, int $chunkZ, Chunk $chunk) : void{
|
||||
$status = $this->usedChunks[$hash = World::chunkHash($chunkX, $chunkZ)] ?? null;
|
||||
if($status !== null && !$status->equals(UsedChunkStatus::NEEDED())){
|
||||
if($status !== null && $status->equals(UsedChunkStatus::SENT())){
|
||||
$this->usedChunks[$hash] = UsedChunkStatus::NEEDED();
|
||||
$this->nextChunkOrderRun = 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user