95        string $premiumWorldTemplateId,
 
  100        string $multiplayerCorrelationId,
 
  101        bool $enableNewInventorySystem,
 
  102        string $serverSoftwareVersion,
 
  103        UuidInterface $worldTemplateId,
 
  104        bool $enableClientSideChunkGeneration,
 
  105        bool $blockNetworkIdsAreHashes,
 
  106        bool $enableTickDeathSystems,
 
  112        $result->actorUniqueId = $actorUniqueId;
 
  113        $result->actorRuntimeId = $actorRuntimeId;
 
  114        $result->playerGamemode = $playerGamemode;
 
  115        $result->playerPosition = $playerPosition;
 
  116        $result->pitch = $pitch;
 
  119        $result->levelSettings = $levelSettings;
 
  120        $result->levelId = $levelId;
 
  121        $result->worldName = $worldName;
 
  122        $result->premiumWorldTemplateId = $premiumWorldTemplateId;
 
  123        $result->isTrial = $isTrial;
 
  124        $result->playerMovementSettings = $playerMovementSettings;
 
  125        $result->currentTick = $currentTick;
 
  126        $result->enchantmentSeed = $enchantmentSeed;
 
  127        $result->multiplayerCorrelationId = $multiplayerCorrelationId;
 
  128        $result->enableNewInventorySystem = $enableNewInventorySystem;
 
  129        $result->serverSoftwareVersion = $serverSoftwareVersion;
 
  130        $result->worldTemplateId = $worldTemplateId;
 
  131        $result->enableClientSideChunkGeneration = $enableClientSideChunkGeneration;
 
  132        $result->blockNetworkIdsAreHashes = $blockNetworkIdsAreHashes;
 
  133        $result->enableTickDeathSystems = $enableTickDeathSystems;
 
  134        $result->networkPermissions = $networkPermissions;
 
  135        $result->blockPalette = $blockPalette;
 
 
  141        $this->actorUniqueId = 
CommonTypes::getActorUniqueId($in);
 
  142        $this->actorRuntimeId = CommonTypes::getActorRuntimeId($in);
 
  143        $this->playerGamemode = VarInt::readSignedInt($in);
 
  145        $this->playerPosition = CommonTypes::getVector3($in);
 
  147        $this->pitch = LE::readFloat($in);
 
  148        $this->yaw = LE::readFloat($in);
 
  150        $this->levelSettings = LevelSettings::read($in);
 
  152        $this->levelId = CommonTypes::getString($in);
 
  153        $this->worldName = CommonTypes::getString($in);
 
  154        $this->premiumWorldTemplateId = CommonTypes::getString($in);
 
  155        $this->isTrial = CommonTypes::getBool($in);
 
  156        $this->playerMovementSettings = PlayerMovementSettings::read($in);
 
  157        $this->currentTick = LE::readUnsignedLong($in);
 
  159        $this->enchantmentSeed = VarInt::readSignedInt($in);
 
  161        $this->blockPalette = [];
 
  162        for($i = 0, $len = VarInt::readUnsignedInt($in); $i < $len; ++$i){
 
  163            $blockName = CommonTypes::getString($in);
 
  164            $state = CommonTypes::getNbtCompoundRoot($in);
 
  168        $this->multiplayerCorrelationId = CommonTypes::getString($in);
 
  169        $this->enableNewInventorySystem = CommonTypes::getBool($in);
 
  170        $this->serverSoftwareVersion = CommonTypes::getString($in);
 
  171        $this->playerActorProperties = 
new CacheableNbt(CommonTypes::getNbtCompoundRoot($in));
 
  172        $this->blockPaletteChecksum = LE::readUnsignedLong($in);
 
  173        $this->worldTemplateId = CommonTypes::getUUID($in);
 
  174        $this->enableClientSideChunkGeneration = CommonTypes::getBool($in);
 
  175        $this->blockNetworkIdsAreHashes = CommonTypes::getBool($in);
 
  176        $this->enableTickDeathSystems = CommonTypes::getBool($in);
 
  177        $this->networkPermissions = NetworkPermissions::decode($in);
 
 
  181        CommonTypes::putActorUniqueId($out, $this->actorUniqueId);
 
  182        CommonTypes::putActorRuntimeId($out, $this->actorRuntimeId);
 
  183        VarInt::writeSignedInt($out, $this->playerGamemode);
 
  185        CommonTypes::putVector3($out, $this->playerPosition);
 
  187        LE::writeFloat($out, $this->pitch);
 
  188        LE::writeFloat($out, $this->yaw);
 
  190        $this->levelSettings->write($out);
 
  192        CommonTypes::putString($out, $this->levelId);
 
  193        CommonTypes::putString($out, $this->worldName);
 
  194        CommonTypes::putString($out, $this->premiumWorldTemplateId);
 
  195        CommonTypes::putBool($out, $this->isTrial);
 
  196        $this->playerMovementSettings->write($out);
 
  197        LE::writeUnsignedLong($out, $this->currentTick);
 
  199        VarInt::writeSignedInt($out, $this->enchantmentSeed);
 
  201        VarInt::writeUnsignedInt($out, count($this->blockPalette));
 
  202        foreach($this->blockPalette as $entry){
 
  203            CommonTypes::putString($out, $entry->getName());
 
  204            $out->writeByteArray($entry->getStates()->getEncodedNbt());
 
  207        CommonTypes::putString($out, $this->multiplayerCorrelationId);
 
  208        CommonTypes::putBool($out, $this->enableNewInventorySystem);
 
  209        CommonTypes::putString($out, $this->serverSoftwareVersion);
 
  210        $out->writeByteArray($this->playerActorProperties->getEncodedNbt());
 
  211        LE::writeUnsignedLong($out, $this->blockPaletteChecksum);
 
  212        CommonTypes::putUUID($out, $this->worldTemplateId);
 
  213        CommonTypes::putBool($out, $this->enableClientSideChunkGeneration);
 
  214        CommonTypes::putBool($out, $this->blockNetworkIdsAreHashes);
 
  215        CommonTypes::putBool($out, $this->enableTickDeathSystems);
 
  216        $this->networkPermissions->encode($out);