diff --git a/changelogs/3.9.md b/changelogs/3.9.md index 2f35ab897..9e3e86b75 100644 --- a/changelogs/3.9.md +++ b/changelogs/3.9.md @@ -52,3 +52,8 @@ Plugin developers should **only** update their required API to this version if y - Fixed `Item->setCustomName()` with an empty string leaving behind an empty tag. - Fixed incorrect positioning of bucket empty sound. - Fixed some incorrect tag parsing in `/give` involving quoted numbers. + +# 3.9.3 +- Fixed a memory leak on async task removal in error conditions. +- Fixed scheduled block updates (for example liquid) triggering chunk reloading. This could cause a significant performance issue in some conditions. +- Fixed some minor cosmetic issues in documentation. diff --git a/src/pocketmine/VersionInfo.php b/src/pocketmine/VersionInfo.php index d7ae20990..25617f9eb 100644 --- a/src/pocketmine/VersionInfo.php +++ b/src/pocketmine/VersionInfo.php @@ -22,6 +22,6 @@ namespace pocketmine; const NAME = "PocketMine-MP"; -const BASE_VERSION = "3.9.3"; +const BASE_VERSION = "3.9.4"; const IS_DEVELOPMENT_BUILD = true; const BUILD_NUMBER = 0; diff --git a/src/pocketmine/level/Level.php b/src/pocketmine/level/Level.php index 3fb39dc30..9ca2e1af4 100644 --- a/src/pocketmine/level/Level.php +++ b/src/pocketmine/level/Level.php @@ -820,7 +820,12 @@ class Level implements ChunkManager, Metadatable{ //Delayed updates while($this->scheduledBlockUpdateQueue->count() > 0 and $this->scheduledBlockUpdateQueue->current()["priority"] <= $currentTick){ - $block = $this->getBlock($this->scheduledBlockUpdateQueue->extract()["data"]); + /** @var Vector3 $vec */ + $vec = $this->scheduledBlockUpdateQueue->extract()["data"]; + if(!$this->isInLoadedTerrain($vec)){ + continue; + } + $block = $this->getBlock($vec); unset($this->scheduledBlockUpdateQueueIndex[Level::blockHash($block->x, $block->y, $block->z)]); $block->onScheduledUpdate(); }