mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 01:46:04 +00:00
Level: fixed autosave not kicking in when entities are updated in a chunk (e.g. moving, dying, spawning)
This commit is contained in:
@ -1068,7 +1068,7 @@ class Level implements ChunkManager, Metadatable{
|
||||
|
||||
public function saveChunks(){
|
||||
foreach($this->chunks as $chunk){
|
||||
if($chunk->hasChanged() and $chunk->isGenerated()){
|
||||
if(($chunk->hasChanged() or count($chunk->getTiles()) > 0 or count($chunk->getSavableEntities()) > 0) and $chunk->isGenerated()){
|
||||
$this->provider->saveChunk($chunk);
|
||||
$chunk->setChanged(false);
|
||||
}
|
||||
|
Reference in New Issue
Block a user