-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added PE 0.1.3 and below Level and Player format docs
- Loading branch information
1 parent
8c2dad8
commit 02aa41f
Showing
2 changed files
with
48 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Pocket Edition 0.1.3 and Below `level.dat` Format | ||
|
||
## Byte Order | ||
|
||
level.dat is stored in **Big Endian** byte order. | ||
|
||
## Parsing level.dat | ||
|
||
| Name | Size (in bytes) | Description | | ||
|------|-----------------|-------------| | ||
| Version | 4 | The version used to save the file. Always 1. | | ||
| Size | 4 | The size of the file subtracting the header(Version and Size). | | ||
| Spawn X | 4 | The X coordinate of the world spawn point | | ||
| Spawn Y | 4 | The Y coordinate of the world spawn point | | ||
| Spawn Z | 4 | The Z coordinate of the world spawn point | | ||
| Estimated World Size | 8 | The world size represented in bits | | ||
| Last Played | 4 | Unix timestamp indicating when the level was last saved.[\[1\]](#1) | | ||
| World Name Length | 2 | The length of the world name. | | ||
| World Name | Variable | A [CP437](https://en.wikipedia.org/wiki/Code_page_437) encoded string. | | ||
|
||
## Notes | ||
|
||
1. <a id="1"></a> Will overflow and become negative at **03:14:08 UTC on 19 January 2038** due to [the year 2038 problem](https://en.wikipedia.org/wiki/Year_2038_problem) and will overflow every ~136 years after that. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Pocket Edition 0.1.3 and Below `player.dat` Format | ||
|
||
## Byte Order | ||
|
||
level.dat is stored in **Little Endian** byte order. | ||
|
||
## Parsing level.dat | ||
|
||
| Name | Size (in bytes) | Description | | ||
|------|-----------------|-------------| | ||
| Version | 4 | The version used to save the file. Always 1. | | ||
| Size | 4 | The size of the file subtracting the header(Version and Size). Always 80. | | ||
| Pos X | 4 | The X coordinate of the players position. | | ||
| Pos Y | 4 | The Y coordinate of the players position. | | ||
| Pos Z | 4 | The Z coordinate of the players position. | | ||
| Motion X | 4 | The players motion in the X direction. | | ||
| Motion Y | 4 | The players motion in the Y direction. | | ||
| Motion Z | 4 | The players motion in the Z direction. | | ||
| Pitch | 4 | The players looking pitch. | | ||
| Yaw | 4 | The players looking yaw. | | ||
| Unknown | 4 | | | ||
| Fire | 2 | The number of ticks until the fire is put out. Negative values reflect how long the player can stand in fire before burning. Default -20. | | ||
| Air | 2 | How much air the player has, in ticks. Fills to a maximum of 300 in air. Decreases while underwater. | | ||
| Unknown | 4 | | | ||
| Hotbar | 36 | 9 slots that take up 4 bytes each, the first 2 bytes is the item ID, The next 2 bytes is the items data value. The last slot is always saved as `0xFF` for every byte. | |
02aa41f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
player format still refers to itself as level.dat
and i am not sure if the byte order is correct on the level format (arent all MCPE files LE order?)
02aa41f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I separated them since they are separate files in 0.1.0 - 0.1.3. (
level.dat
andplayer.dat
)I got the info for these from https://minecraft.wiki/w/Bedrock_Edition_level_format/v0.1.0_alpha
I am currently working on getting a 0.1.3 PE world to verify everything. if anything is wrong ill fix it once i verify it from the real files.