24 public function __construct(
30 public function getContainerName() :
FullContainerName{
return $this->containerName; }
32 public function getSlotId() :
int{
return $this->slotId; }
34 public function getStackId() :
int{
return $this->stackId; }
36 public static function read(ByteBufferReader $in) :
self{
37 $containerName = FullContainerName::read($in);
38 $slotId = Byte::readUnsigned($in);
39 $stackId = CommonTypes::readItemStackNetIdVariant($in);
40 return new self($containerName, $slotId, $stackId);
43 public function write(ByteBufferWriter $out) :
void{
44 $this->containerName->write($out);
45 Byte::writeUnsigned($out, $this->slotId);
46 CommonTypes::writeItemStackNetIdVariant($out, $this->stackId);