diff --git a/src/pocketmine/entity/Human.php b/src/pocketmine/entity/Human.php index d9a26d1ee..e5c86b4b7 100644 --- a/src/pocketmine/entity/Human.php +++ b/src/pocketmine/entity/Human.php @@ -443,7 +443,9 @@ class Human extends Creature implements ProjectileSource, InventoryHolder{ $slotCount = $this->inventory->getSize() + $this->inventory->getHotbarSize(); for($slot = $this->inventory->getHotbarSize(); $slot < $slotCount; ++$slot){ $item = $this->inventory->getItem($slot - 9); - $this->namedtag->Inventory[$slot] = $item->nbtSerialize($slot); + if($item->getId() !== ItemItem::AIR){ + $this->namedtag->Inventory[$slot] = $item->nbtSerialize($slot); + } } //Armor