pocketmine\network\protocol\ContainerSetContentPacket::decode PHP Method

decode() public method

public decode ( )
    public function decode()
    {
        $this->windowid = $this->getByte();
        $count = $this->getShort();
        for ($s = 0; $s < $count and !$this->feof(); ++$s) {
            $this->slots[$s] = $this->getSlot();
        }
        if ($this->windowid === self::SPECIAL_INVENTORY) {
            $count = $this->getShort();
            for ($s = 0; $s < $count and !$this->feof(); ++$s) {
                $this->hotbar[$s] = $this->getInt();
            }
        }
    }
ContainerSetContentPacket