public function close() { if ($this->closed === false) { foreach ($this->getInventory()->getViewers() as $player) { $player->removeWindow($this->getInventory()); } parent::close(); } }
public function __construct(FullChunk $chunk, Compound $nbt) { if (!isset($nbt->item)) { $nbt->item = new Short("item", 0); } if (!isset($nbt->data)) { $nbt->data = new Int("data", 0); } parent::__construct($chunk, $nbt); }
public function saveNBT() { parent::saveNBT(); unset($this->namedtag->Creator); }