59 $blockPosition = CommonTypes::getBlockPosition($in);
60 $this->x = $blockPosition->getX() / 8;
61 $this->y = $blockPosition->getY() / 8;
62 $this->z = $blockPosition->getZ() / 8;
63 $this->volume = LE::readFloat($in);
64 $this->pitch = LE::readFloat($in);
65 $this->serverSoundHandle = CommonTypes::readOptional($in, LE::readUnsignedLong(...));
70 CommonTypes::putBlockPosition($out,
new BlockPosition((
int) ($this->x * 8), (
int) ($this->y * 8), (
int) ($this->z * 8)));
71 LE::writeFloat($out, $this->volume);
72 LE::writeFloat($out, $this->pitch);
73 CommonTypes::writeOptional($out, $this->serverSoundHandle, LE::writeUnsignedLong(...));