mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-04 17:06:16 +00:00
Mark chunk to be saved when removing invalid entities/tiles
This commit is contained in:
@ -146,10 +146,12 @@ abstract class BaseFullChunk implements FullChunk{
|
||||
foreach($this->NBTtiles as $nbt){
|
||||
if($nbt instanceof Compound){
|
||||
if(!isset($nbt->id)){
|
||||
$this->setChanged();
|
||||
continue;
|
||||
}
|
||||
|
||||
if(($nbt["x"] >> 4) !== $this->x or ($nbt["z"] >> 4) !== $this->z){
|
||||
$this->setChanged();
|
||||
continue; //Fixes tiles allocated in wrong chunks.
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user