This text is translated for Japanese developers.
If it has any problems, please tell me.
Translator: beito (Twitter: https://twitter.com/bei_203)
Original(by Tomcc): https://gist.github.com/Tomcc/a96af509e275b1af483b25c543cfbf37
Thank you :)
| <?php | |
| use \parallel\{Runtime, Channel}; | |
| class ExecutorService { | |
| public function __construct(int $workers, string $channel = __CLASS__, int $backlog = Channel::Infinite) { | |
| if ($backlog == 0) { | |
| /* | |
| * execute() will block until a worker is ready | |
| */ |
| leveldbのブロックの解凍処理の箇所: | |
| https://github.com/Mojang/leveldb-mcpe/blob/aac9314ae2800a203e1be5102fa00ca972f3449c/table/format.cc#L106 | |
| mcpeワールド用のleveldbの設定(一部): | |
| https://github.com/Mojang/leveldb-mcpe/blob/8fb685effc48819cb54b2f353871fbc80b8c67ed/mcpe_sample_setup.cpp | |
| leveldb用のzlib圧縮のヘッダー: | |
| https://github.com/Mojang/leveldb-mcpe/blob/8fb685effc48819cb54b2f353871fbc80b8c67ed/include/leveldb/zlib_compressor.h#L48 | |
| leveldb用のzlib圧縮の実装部分: |
Paletted chunks & removing BlockIDs brings a few big changes to how blocks are represented. In Bedrock, Blocks used to be represented by their 8 bit ID and 4 bit data; this means that we can only represent 256 blocks and 16 variants for each block. As it happens we ran out of IDs in Update Aquatic, so we had to do something about it :)
After this change, we can represent infinite types of Blocks and infinite BlockStates, just like in Java. BlockStates are what is sent over the network as they are roughly equivalent to the old ID+data information, eg. they're all the information attached to a block.
BlockStates are serialized in two ways:
PersistentID: a PersistentID is a NBT tag containing the BlockState name and its variant number; for example
| <?php | |
| /** | |
| * Minecraft: Pocket Edition header extractor | |
| * | |
| * This tool needs objdump (and objdump-multiarch + arm variants) installed on the current system | |
| * | |
| */ | |
| const VERSION = "0.0.1"; |
| 更新: | 2026-02-12 |
|---|---|
| 作者: | @voluntas |
| バージョン: | 2026.2 |
| url: | https://voluntas.github.io/ |
概要
| <?php | |
| define("COMPARATOR_VERSION", "0.1"); | |
| ini_set("memory_limit", "512M"); | |
| $node1 = json_decode(@file_get_contents($argv[1]), true); | |
| if($node1 == ""){ | |
| echo "Provide a valid json file produced by the Extractor".PHP_EOL; | |
| exit(1); | |
| } | |
| $node2 = json_decode(@file_get_contents($argv[2]), true); |