Minecraft:Bedrock Edition level format/v0.1.0 alpha: Difference between revisions
From SAS Gaming Wiki
More actions
imported>LPT5 m Changed location and description of facing values in accordance with disassmbled code from the APK https://gitlab.com/Monika-Trenholme/mcpe-level-save-disassembly/-/blob/main/code/a0.1.0_touch_proto.cpp?ref_type=heads |
Remove broken links to missing pages |
||
| Line 1: | Line 1: | ||
This is the specification for the [[Minecraft:Bedrock Edition level format|level format]] in [[Minecraft:Pocket Edition v0.1.0 alpha]] up to | This is the specification for the [[Minecraft:Bedrock Edition level format|level format]] in [[Minecraft:Pocket Edition v0.1.0 alpha]] up to Pocket Edition v0.2.0 alpha where the format was changed to NBT instead of raw binary. | ||
==level.dat== | ==level.dat== | ||
{| class="wikitable sortable" | {| class="wikitable sortable" | ||
| Line 32: | Line 32: | ||
| Last Played | | Last Played | ||
| 4 | | 4 | ||
| A big-endian 32 bit unix timestamp indicating when the level was last saved, will overflow and become negative at '''03:14:08 UTC on 19 January 2038''' due to | | A big-endian 32 bit unix timestamp indicating when the level was last saved, will overflow and become negative at '''03:14:08 UTC on 19 January 2038''' due to the year 2038 problem and will overflow every ~136 years after that. | ||
|- | |- | ||
| Length of World Name in Bytes | | Length of World Name in Bytes | ||
| Line 40: | Line 40: | ||
| World Name | | World Name | ||
| Variable | | Variable | ||
| A | | A CP437 encoded string<ref group="note">This is due to the font texture found in the assets folder of the apk, future versions may render non-ASCII characters differently</ref> | ||
|} | |} | ||
| Line 103: | Line 103: | ||
| Hotbar | | Hotbar | ||
| 36 | | 36 | ||
| 9 slots that take up 4 bytes each, the first two bytes is the item ID<ref group="note">Every items from Pocket Edition [[Minecraft:Pocket Edition v0.1.0 alpha|0.1.0]] to | | 9 slots that take up 4 bytes each, the first two bytes is the item ID<ref group="note">Every items from Pocket Edition [[Minecraft:Pocket Edition v0.1.0 alpha|0.1.0]] to 0.1.3 has an ID only takes up 1 byte with the exception of [[Minecraft:Camera]], which takes 2 bytes (c8 01).</ref>. The other two bytes have unknown use and are always 0x00. The last slot is always saved as 0xFF for every byte, it's known to be a hotbar slot as the <code>minecraftpe</code> library loops through 9 hotbar slots. | ||
|} | |} | ||
== Notes == | == Notes == | ||
{{notelist}} | {{notelist}} | ||
[[Category:Development]] | [[Category:Development]] | ||
pt:Formato de nível da Edição Bedrock/v0.1.0 alpha | |||
Revision as of 15:37, 9 April 2026
This is the specification for the level format in Minecraft:Pocket Edition v0.1.0 alpha up to Pocket Edition v0.2.0 alpha where the format was changed to NBT instead of raw binary.
level.dat
| Data | Length (Bytes) | Description |
|---|---|---|
| Header | 8 | A little-endian 32 bit integer used to identify the version of the tool used to save the file, always 1 followed by a little-endian 32 bit integer that marks the size of the file subtract the header. |
| Seed | 4 | A big-endian 32 bit signed integer |
| Spawn X | 4 | A big-endian 32 bit signed integer |
| Spawn Y | 4 | A big-endian 32 bit signed integer |
| Spawn Z | 4 | A big-endian 32 bit signed integer |
| Estimated world size | 8 | A big-endian 64 bit integer representing the world size in bitsTemplate:Verify |
| Last Played | 4 | A big-endian 32 bit unix timestamp indicating when the level was last saved, will overflow and become negative at 03:14:08 UTC on 19 January 2038 due to the year 2038 problem and will overflow every ~136 years after that. |
| Length of World Name in Bytes | 2 | A big-endian unsigned 16 bit integer |
| World Name | Variable | A CP437 encoded string<ref group="note">This is due to the font texture found in the assets folder of the apk, future versions may render non-ASCII characters differently</ref> |
player.dat
| Data | Length (Bytes) | Description |
|---|---|---|
| Header | 8 | A little-endian 32 bit integer used to identify the version of the tool used to save the file, always 1 followed by a little-endian 32 bit integer that marks the size of the file subtract the header, always 80. |
| Pos X | 4 | A little-endian 32 bit float |
| Pos Y | 4 | A little-endian 32 bit float |
| Pos Z | 4 | A little-endian 32 bit float |
| Motion X | 4 | A little-endian 32 bit float |
| Motion Y | 4 | A little-endian 32 bit float |
| Motion Z | 4 | A little-endian 32 bit float |
| Pitch | 4 | A little-endian 32 bit float, an error in the code causes this value to be read incorrectly |
| Yaw | 4 | A little-endian 32 bit float representing the player's yaw in degrees |
| Unknown | 4 | A little-endian 32 bit float |
| Fire | 2 | A little-endian signed short representing the number of ticks until the fire is put out. Negative values reflect how long the player can stand in fire before burning. Default value: -20 |
| Air | 2 | A little-endian signed short representing how much air the player has, in ticks. Fills to a maximum of 300 in air. Decreases while underwater.Template:Verify |
| Unknown | 4 | |
| Hotbar | 36 | 9 slots that take up 4 bytes each, the first two bytes is the item ID<ref group="note">Every items from Pocket Edition 0.1.0 to 0.1.3 has an ID only takes up 1 byte with the exception of Minecraft:Camera, which takes 2 bytes (c8 01).</ref>. The other two bytes have unknown use and are always 0x00. The last slot is always saved as 0xFF for every byte, it's known to be a hotbar slot as the minecraftpe library loops through 9 hotbar slots.
|
Notes
Template:Notelist pt:Formato de nível da Edição Bedrock/v0.1.0 alpha