mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 10:53:05 +00:00
Improved batch handling
This commit is contained in:
@ -75,7 +75,7 @@ class ChunkRequestTask extends AsyncTask{
|
||||
|
||||
$batch = new BatchPacket();
|
||||
$batch->addPacket($pk);
|
||||
$batch->compress($this->compressionLevel);
|
||||
$batch->setCompressionLevel($this->compressionLevel);
|
||||
$batch->encode();
|
||||
|
||||
$this->setResult($batch->buffer, false);
|
||||
@ -87,7 +87,6 @@ class ChunkRequestTask extends AsyncTask{
|
||||
if($this->hasResult()){
|
||||
$batch = new BatchPacket($this->getResult());
|
||||
assert(strlen($batch->buffer) > 0);
|
||||
$batch->compressed = true;
|
||||
$batch->isEncoded = true;
|
||||
$level->chunkRequestCallback($this->chunkX, $this->chunkZ, $batch);
|
||||
}else{
|
||||
|
Reference in New Issue
Block a user