Template:Nbt/doc

This template is used to more clearly illustrate NBT tags and JSON fields.

When showing the structure of an NBT file, this template is best coupled with a unordered list, wrapped in a treeview class.

Usage


Available tags
Note: NBT does not use the boolean type (true/false attributes are usually of byte type), so this type should only be used for JSON.

JSON has no concept of numeric types other than double, nor of arrays that specify their elements' type, so the byte, short, int, long, float, byte array and int array tags should only be used to indicate what type Minecraft will convert a JSON field to after reading it.

Usage with treeview list

 *   World data.
 *  : Whether in survival (0) or in creative (1) mode.
 *  : Stores the Unix time stamp (in seconds) when the player saved the game.
 *  : Specifies the name of the level.
 *  : Seems to store the platform that the level is created on. Currently observed value is 2.
 *  : Player entity information. See Entity Format and Mob Entity Format for details. It is missing the id tag and has additional elements:
 *  : The dimension the player is in. 0 is the Overworld.
 *  : Each TAG_Compound in this list defines an item the player is carrying or holding.
 *   Inventory item data
 *  : Indicates which inventory slot this item is in.
 *  : Item or Block ID.
 *  : Number of items stacked in this inventory slot. Any item can be stacked, including tools. Range is 1-255. Values above 127 and below -128 are not displayed in-game.
 *  : For tools, the amount of wear they have suffered. The maximum durability of the tool (for example, 33 for golden tools) means undamaged. When the Damage reaches 0, it breaks and disappears.
 *  : The score of the player.
 *  : Random number providing the Random Seed for the terrain.
 *  : Estimated size of the entire world in bytes.
 *  : X coordinate of the player's spawn position. Default is 0.
 *  : Y coordinate of the player's spawn position. Default is 64.
 *  : Z coordinate of the player's spawn position. Default is 0.
 *  : Current version of Pocket Edition NBT. Currently 3.
 *  : Stores the current "time of day" in ticks. There are 20 ticks per real-life second, and 14400 ticks per Minecraft day/night cycle, making the full cycle length 12 minutes—8 minutes shorter than the standard 20 minute day/night cycle. 0 is the start of daytime, 7200 is the start of sunset, 8280 is the start of nighttime, 13320 is the start of sunrise, and 14400 is daytime again. The value stored in level.dat is always increasing and can be larger than 14400, but the "time of day" is always modulo 14400 of the "Time" field value.


 * World data.
 * : Whether in survival (0) or in creative (1) mode.
 * : Stores the Unix time stamp (in seconds) when the player saved the game.
 * : Specifies the name of the level.
 * : Seems to store the platform that the level is created on. Currently observed value is 2.
 * : Player entity information. See Entity Format and Mob Entity Format for details. It is missing the id tag and has additional elements:
 * : The dimension the player is in. 0 is the Overworld.
 * : Each TAG_Compound in this list defines an item the player is carrying or holding.
 * Inventory item data
 * : Indicates which inventory slot this item is in.
 * : Item or Block ID.
 * : Number of items stacked in this inventory slot. Any item can be stacked, including tools. Range is 1-255. Values above 127 and below -128 are not displayed in-game.
 * : For tools, the amount of wear they have suffered. The maximum durability of the tool (for example, 33 for golden tools) means undamaged. When the Damage reaches 0, it breaks and disappears.
 * : The score of the player.
 * : Random number providing the Random Seed for the terrain.
 * : Estimated size of the entire world in bytes.
 * : X coordinate of the player's spawn position. Default is 0.
 * : Y coordinate of the player's spawn position. Default is 64.
 * : Z coordinate of the player's spawn position. Default is 0.
 * : Current version of Pocket Edition NBT. Currently 3.
 * : Stores the current "time of day" in ticks. There are 20 ticks per real-life second, and 14400 ticks per Minecraft day/night cycle, making the full cycle length 12 minutes—8 minutes shorter than the standard 20 minute day/night cycle. 0 is the start of daytime, 7200 is the start of sunset, 8280 is the start of nighttime, 13320 is the start of sunrise, and 14400 is daytime again. The value stored in level.dat is always increasing and can be larger than 14400, but the "time of day" is always modulo 14400 of the "Time" field value.