mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-12 16:59:44 +00:00
Merge branch 'release/3.4'
This commit is contained in:
commit
507d47a6f5
@ -103,10 +103,10 @@ class SubChunk implements SubChunkInterface{
|
|||||||
$i >>= 1;
|
$i >>= 1;
|
||||||
|
|
||||||
$shift = ($y & 1) << 2;
|
$shift = ($y & 1) << 2;
|
||||||
$byte = ord($this->data{$i});
|
$oldPair = ord($this->data{$i});
|
||||||
$this->data{$i} = chr(($byte & ~(0xf << $shift)) | (($data & 0xf) << $shift));
|
$newPair = ($oldPair & ~(0xf << $shift)) | (($data & 0xf) << $shift);
|
||||||
|
if($newPair !== $oldPair){
|
||||||
if($this->data{$i} !== $byte){
|
$this->data{$i} = chr($newPair);
|
||||||
$changed = true;
|
$changed = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user