Convert Minecraft server world files into MCserver world files.
#10
OK, I've been going through this file and finally think I understand how the data is stored.

It's a binary file. I opened up a .pak file in a hex editor and saw this:

01 01 01 00
This means Pak V1, Chunk V1, and 1 chunk in file.

16* 01 = 16, next 16 entries are the single chunk's header.
AC 00 00 00 00 00 00 00 68 0A 00 00 00 40 01 00

The rest of the data is the COMPRESSED chunk data.


01 01 A5 02
This means Pak V1, Chunk V1, and 677 chunks in file?

16 * (A5 02) = Next 10,832 entries are the chunk headers.every 16 is one chunk header

The rest of the data is the COMPRESSED chunk data. The length of the data is stored in the header of each chunk. Let's say chunk header one says the first chunk is 10,000 long. The first 10,000 chars would then be the first chunk's COMPRESSED data. Let's say the second chunk header says the next chunk is 12,000 chars long, The next 12,000 after the last 10,000 which is after the file and chunk headers is the second chunk's COMPRESSED data.

Does that sound right?
Reply
Thanks given by:


Messages In This Thread
RE: Convert Minecraft server world files into MCserver world files. - by rs2k - 10-28-2011, 02:31 AM



Users browsing this thread: 2 Guest(s)