13declare(strict_types=1);
15namespace pocketmine\network\mcpe\protocol;
21 public const NETWORK_ID = ProtocolInfo::INVENTORY_SLOT_PACKET;
24 public int $inventorySlot;
32 $result->windowId = $windowId;
33 $result->inventorySlot = $inventorySlot;
34 $result->item = $item;
39 $this->windowId = $in->getUnsignedVarInt();
41 $this->item = $in->getItemStackWrapper();
45 $out->putUnsignedVarInt($this->windowId);
47 $out->putItemStackWrapper($this->item);
51 return $handler->handleInventorySlot($this);
static create(int $windowId, int $inventorySlot, ItemStackWrapper $item)
decodePayload(PacketSerializer $in)
encodePayload(PacketSerializer $out)
handle(PacketHandlerInterface $handler)
putUnsignedVarInt(int $v)