diff --git a/src/pocketmine/block/Block.php b/src/pocketmine/block/Block.php index 1cb51ff3c..201e10d53 100644 --- a/src/pocketmine/block/Block.php +++ b/src/pocketmine/block/Block.php @@ -987,6 +987,7 @@ class Block extends Position implements Metadatable{ $this->y = (int) $v->y; $this->z = (int) $v->z; $this->level = $v->level; + $this->boundingBox = null; } /** @@ -1067,7 +1068,7 @@ class Block extends Position implements Metadatable{ if($this->boundingBox !== null){ return $this->boundingBox; }else{ - return $this->boundingBox = $this->recalculateBoundingBox(); + return ($this->boundingBox = $this->recalculateBoundingBox()); } } diff --git a/src/pocketmine/item/Item.php b/src/pocketmine/item/Item.php index 8a5de9b75..301dd1e78 100644 --- a/src/pocketmine/item/Item.php +++ b/src/pocketmine/item/Item.php @@ -565,7 +565,7 @@ class Item{ public function getBlock(){ if($this->block instanceof Block){ - return $this->block; + return clone $this->block; }else{ return Block::get(self::AIR); }