Użytkownik:Frisk/brudnopis3: Różnice pomiędzy wersjami

Z Minecraft Wiki Polska
Przejdź do nawigacji Przejdź do wyszukiwania
d Test
d Anulowanie wersji 109089 autora Frisk (dyskusja) drugi test
 
(Nie pokazano 16 pośrednich wersji utworzonych przez tego samego użytkownika)
Linia 1: Linia 1:
{{about|the latest official PC version of Minecraft|the 2013 April Fools' day "Minecraft 2.0" version|Minecraft 2.0/Chunk format}}
Ostateczny test?
[[Chunk]]s store the terrain and entities within a 16×256×16 area. They also store precomputed lighting, heightmap data for Minecraft's performance, and other meta information.
Testów nigdy za wiele
 
== NBT structure ==
{{See also|Anvil file format#Further information|title1=Information from the Anvil format page}}
 
Chunks are stored in [[NBT Format|NBT]] format, with this structure (see [[#Block format|Block Format]] below for the ordering of the blocks within each array):
<div class="treeview">
* {{nbt|compound}} The root tag.
** {{nbt|int|DataVersion}}: Version of the chunk NBT structure.
** {{nbt|compound|Level}}: Chunk data.
*** {{nbt|int|xPos}}: X position of the chunk.
*** {{nbt|int|zPos}}: Z position of the chunk.
*** {{nbt|long|LastUpdate}}: Tick when the chunk was last saved.
*** {{nbt|byte|LightPopulated}}: 1 or 0 (true/false) - If true, the server/client has already calculated lighting values for this chunk after generation.
*** {{nbt|byte|TerrainPopulated}}: 1 or not present (true/false) indicate whether the terrain in this chunk was populated with special things. (Ores, special blocks, trees, dungeons, flowers, waterfalls, etc.) If set to zero then Minecraft will regenerate these features in the blocks that already exist.
*** {{nbt|byte|V}}: Currently always saved as 1 and not actually loaded by the game. Likely a chunk version tag.
*** {{nbt|long|InhabitedTime}}: The cumulative number of ticks players have been in this chunk. Note that this value increases faster when more players are in the chunk. Used for regional difficulty: increases the chances of mobs spawning with equipment, the chances of that equipment having enchantments, the chances of spiders having potion effects, the chances of mobs having the ability to pick up dropped items, and the chances of zombies having the ability to spawn other zombies when attacked. Note that at values 3600000 and above, regional difficulty is effectively maxed for this chunk. At values 0 and below, the difficulty is capped to a minimum (thus, if this is set to a negative number, it will behave identically to being set to 0, apart from taking time to build back up to the positives). See [[Difficulty#Regional difficulty|Regional Difficulty]] for more specifics.
*** {{nbt|byte-array|Biomes}}: May not exist. 256 bytes of biome data, one byte for each vertical column in the chunk. See [[Data Values#Biome IDs|Data Values]] for biome IDs. If this tag does not exist it will be created and filled by Minecraft when the chunk is loaded and saved. If any values in this array are -1, Minecraft will also set them to the correct biome.
*** {{nbt|int-array|HeightMap}}: 1024 bytes(256 TAG_Int) of heightmap data. 16 × 16. Each byte records the lowest level in each column where the light from the sky is at full strength. Speeds computing of the SkyLight.
*** {{nbt|list|Sections}}: List of Compound tags, each tag is a sub-chunk of sorts.
**** {{nbt|compound}} An individual Section.
***** {{nbt|byte|Y}}: The Y index (not coordinate) of this section. Range 0 to 15 (bottom to top), with no duplicates but some sections may be missing if empty.
***** {{nbt|byte-array|Blocks}}: 4096 bytes of [[Data values#Block IDs|block IDs]] defining the terrain. 8 bits per block, plus the bits from the below Add tag.
***** {{nbt|byte-array|Add}}: May not exist. 2048 bytes of additional block ID data. The value to add to (combine with) the above block ID to form the true block ID in the range 0 to 4095. 4 bits per block. Combining is done by shifting this value to the left 8 bits and then adding it to the block ID from above.
***** {{nbt|byte-array|Data}}: 2048 bytes of [[Data values#Data|block data]] additionally defining parts of the terrain. 4 bits per block.
***** {{nbt|byte-array|BlockLight}}: 2048 bytes recording the amount of block-emitted light in each block. Makes load times faster compared to recomputing at load time. 4 bits per block.
***** {{nbt|byte-array|SkyLight}}: 2048 bytes recording the amount of sunlight or moonlight hitting each block. 4 bits per block.
*** {{nbt|list|Entities}}: Each TAG_Compound in this list defines an entity in the chunk. See [[#Entity format|Entity Format]] below. If this list is empty it will be a list of Byte tags.
*** {{nbt|list|TileEntities}}: Each TAG_Compound in this list defines a block entity in the chunk. See [[#Block entity format|Block Entity Format]] below. If this list is empty it will be a list of Byte tags.
*** {{nbt|list|TileTicks}}: May not exist. Each TAG_Compound in this list is an "active" block in this chunk waiting to be updated. These are used to save the state of redstone machines, falling sand or water, and other activity. See [[#Tile tick format|Tile Tick Format]] below. This tag may not exist.
</div>
 
== Block format ==
In the Anvil format, block positions are ordered YZX for compression purposes.
 
The coordinate system is as follows:
* '''X''' increases East, decreases West
* '''Y''' increases upwards, decreases downwards
* '''Z''' increases South, decreases North
 
This also happens to yield the most natural scan direction, because all indices in the least significant dimension (i.e. X in this case) appear for each index in the next most significant dimension; so one reads an array ordered YZX as one would a book lying with its top northward, all letters (or X-indices) on a single line (or Z-index) at a time, and all lines on a single page (or Y-index) at a time. For the 2D arrays (i.e. "Biomes" and "HeightMap") the inapplicable Y dimension is simply omitted, as though the book is only one page thick.
 
Each section in a chunk is a 16x16x16-block area, with up to 16 sections in a chunk. Section 0 is the bottom section of the chunk, and section 15 is the top section of the chunk. To save space, completely empty sections are not saved. Within each section is a byte tag "Y" for the Y index of the section, 0 to 15, and then byte arrays for the blocks. The "Block" byte array has 4096 partial block IDs at 8 bits per block. Another byte array "Add" is used for block with IDs over 255, and is 2048 bytes of the other part of the 4096 block IDs at 4 bits per block. When both the "Block" and "Add" byte arrays exist, the partial ID from the "Add" array is shifted left 8 bits and added to the partial ID from the "Blocks" array to form the true Block ID. The "Data" byte array is also 2048 bytes for 4096 block data values at 4 bits per block. The "BlockLight" and "SkyLight" byte arrays are the same as the "Data" byte array but they are used for block light levels and sky light levels respectively. The "SkyLight" values represent how much sunlight or moonlight can potentially reach the block, independent of the current light level of the sky.
 
The endianness of the 2048-byte arrays (i.e. "Add," "Data," "BlockLight," & "SkyLight"), which give only 4 bits per block, seems to stand as the one anomalous exception to the otherwise consistent, format-wide standard of big-endian data storage. It also runs counter to the presumably natural human-readable printing direction. If the blocks begin at 0, they are grouped with even numbers preceding odd numbers (i.e. 0 & 1 share a byte, 2 & 3 share the next, etc.); under these designations Minecraft stores even-numbered blocks in the least significant half-byte, and odd-numbered blocks in the most significant half-byte. Thus block[0] is byte[0] at 0x0F, block[1] is byte[0] at 0xF0, block[2] is byte[1] at 0x0F, block[3] is byte[1] at 0xF0, etc. ...
 
The pseudo-code below shows how to access individual block information from a single section. Hover over text to see additional information or comments.
 
<pre<!---->>
<abbr title="Function to return the 4-bit nibble in a byte array at the given index"><span style="color:blue">byte</span> Nibble4(<span style="color:blue">byte</span>[] arr, <span style="color:blue">int</span> index)</abbr>{ <span style="color:blue">return</span> <abbr title="If index is even...">index%2 == 0 ?</abbr> <abbr title="...then return the low nibble...">arr[index/2]&0x0F</abbr> <abbr title="...else return the high nibble.">: (arr[index/2]>>4)&0x0F</abbr>; }
<span style="color:blue">int</span> '''<abbr title="The index the block is at in the arrays">BlockPos</abbr>''' = <abbr title="Careful! This is the Y coordinate relative to the section, not the whole chunk!">y</abbr>*<abbr title="Chunk/Section Width">16</abbr>*<abbr title="Section Height">16</abbr> + z*<abbr title="Chunk/Section Width">16</abbr> + x;
<span style="color:blue">byte</span> <abbr title="The first half of the block ID">BlockID_a</abbr> = <abbr title="The Block byte array, 8 bits per block">''Blocks''</abbr>[BlockPos];
<span style="color:blue">byte</span> <abbr title="The second half of the block ID">BlockID_b</abbr> = Nibble4(<abbr title="The Add byte array, 4 bits per block">''Add''</abbr>, BlockPos);
<span style="color:blue">short</span> <abbr title="The actual, real Block ID">'''BlockID'''</abbr> = <abbr title="Combine the separate parts of the block ID">BlockID_a + (BlockID_b << 8)</abbr>;
<span style="color:blue">byte</span> <abbr title="The data value for the block">'''BlockData'''</abbr> = Nibble4(<abbr title="The Data byte array, 4 bits per block">''Data''</abbr>, BlockPos);
<span style="color:blue">byte</span> <abbr title="The block light for the block">'''Blocklight'''</abbr> = Nibble4(<abbr title="The BlockLight byte array, 4 bits per block">''BlockLight''</abbr>, BlockPos);
<span style="color:blue">byte</span> <abbr title="The sky light for the block">'''Skylight'''</abbr> = Nibble4(<abbr title="The SkyLight byte array, 4 bits per block">''SkyLight''</abbr>, BlockPos);
</pre>
 
== Entity format ==
Every [[entity]] is an unnamed {{nbt|compound|TAG_Compound}} contained in the Entities list of a chunk file. The sole exception is the Player entity, stored in [[level.dat]], or in [[Player.dat Format|<player>.dat]] files on servers.
All entities share this base:
<div style="height:0;color:transparent;pointer-events:none;">
id Pos Motion Rotation FallDistance Fire Air OnGround Dimension Invulnerable PortalCooldown UUIDMost UUIDLeast UUID CustomName CustomNameVisible Silent Riding CommandStats SuccessCountObjective SuccessCountName AffectedBlocksObjective AffectedBlocksName AffectedEntitiesObjective AffectedEntitiesName AffectedItemsObjective AffectedItemsName QueryResultObjective QueryResultName
</div>
<div class="treeview">
* {{nbt|compound}} Entity data
{{:Chunk format/Entity}}
</div>
 
=== Mobs ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Mob Entities
|-
! Entity ID
! Name
|-
| Bat
| [[Bat]]
|-
| Blaze
| [[Blaze]]
|-
| CaveSpider
| [[Cave Spider]]
|-
| Chicken<ref name="breed" group="note">Can breed</ref>
| [[Chicken]]
|-
| Cow<ref name="breed" group="note" />
| [[Cow]]
|-
| Creeper
| [[Creeper]]
|-
| EnderDragon
| [[Ender Dragon]]
|-
| Enderman
| [[Enderman]]
|-
| Endermite
| [[Endermite]]
|-
| Ghast
| [[Ghast]]
|-
| Giant
| [[Giant]]
|-
| Guardian
| [[Guardian]]<br>[[Elder Guardian]]
|-
| EntityHorse<ref name="breed" group="note" /><!-- NOTE: Horses don't use the same "tameable" tags as other tameable mobs -->
| [[Horse]]
|-
| LavaSlime
| [[Magma Cube]]
|-
| MushroomCow<ref name="breed" group="note" />
| [[Mooshroom]]
|-
| Oz<!-- This is how it is spelled in the game code, as it is spelled in Swedish -->elot<ref name="breed" group="note" /><ref name="tame" group="note">Can be tamed</ref>
| [[Ocelot]]
|-
| Pig<ref name="breed" group="note" />
| [[Pig]]
|-
| PigZombie
| [[Zombie Pigman]]
|-
| Rabbit<ref name="breed" group="note" />
| [[Rabbit]]
|-
| Sheep<ref name="breed" group="note" />
| [[Sheep]]
|-
| Shulker
| [[Shulker]]
|-
| Silverfish
| [[Silverfish]]
|-
| Skeleton
| [[Skeleton]]<br>[[Wither Skeleton]]
|-
| Slime
| [[Slime]]
|-
| SnowMan
| [[Snow Golem]]
|-
| Spider
| [[Spider]]
|-
| Squid
| [[Squid]]
|-
| Villager<ref name="breed" group="note" />
| [[Villager]]
|-
| VillagerGolem
| [[Iron Golem]]
|-
| Witch
| [[Witch]]
|-
| WitherBoss
| [[Wither]]
|-
| Wolf<ref name="breed" group="note" /><ref name="tame" group="note" />
| [[Wolf]]
|-
| Zombie
| [[Zombie]]<br>[[Zombie Villager]]
|-
| colspan="2" | <references group="note" />
|}
Mobs are a subclass of Entity with additional tags to store their health, attacking/damaged state, potion effects, and more depending on the mob. [[Player.dat Format#NBT Structure|Player]]s are a subclass of Mob.
 
{{Data transclude|entity|Bat/ED|title=Bat}}
{{Data transclude|entity|Blaze/ED|title=Blaze}}
{{Data transclude|entity|Cave Spider/ED|title=CaveSpider|link=Cave Spider}}
{{Data transclude|entity|Chicken/ED|title=Chicken}}
{{Data transclude|entity|Cow/ED|title=Cow}}
{{Data transclude|entity|Creeper/ED|title=Creeper}}
{{Data transclude|entity|Ender Dragon/ED|title=EnderDragon|link=Ender Dragon}}
{{Data transclude|entity|Enderman/ED|title=Enderman}}
{{Data transclude|entity|Endermite/ED|title=Endermite}}
{{Data transclude|entity|Horse/ED|title=EntityHorse|link=Horse}}
{{Data transclude|entity|Ghast/ED|title=Ghast}}
{{Data transclude|entity|Giant/ED|title=Giant}}
{{Data transclude|entity|Guardian/ED|title=Guardian}}
{{Data transclude|entity|Magma Cube/ED|title=LavaSlime|link=Magma Cube}}
{{Data transclude|entity|Mooshroom/ED|title=MushroomCow|link=Mooshroom}}
{{Data transclude|entity|Ocelot/ED|title=Ozelot<!-- This is how it is spelled in the game code, as it is spelled in Swedish -->|link=Ocelot}}
{{Data transclude|entity|Pig/ED|title=Pig}}
{{Data transclude|entity|Zombie Pigman/ED|title=PigZombie|link=Zombie Pigman}}
{{Data transclude|entity|Rabbit/ED|title=Rabbit}}
{{Data transclude|entity|Sheep/ED|title=Sheep}}
{{Data transclude|entity|Shulker/ED|title=Shulker}}
{{Data transclude|entity|Silverfish/ED|title=Silverfish}}
{{Data transclude|entity|Skeleton/ED|title=Skeleton}}
{{Data transclude|entity|Slime/ED|title=Slime}}
{{Data transclude|entity|Snow Golem/ED|title=SnowMan|link=Snow Golem}}
{{Data transclude|entity|Spider/ED|title=Spider}}
{{Data transclude|entity|Squid/ED|title=Squid}}
{{Data transclude|entity|Villager/ED|title=Villager}}
{{Data transclude|entity|Iron Golem/ED|title=VillagerGolem|link=Iron Golem}}
{{Data transclude|entity|Witch/ED|title=Witch}}
{{Data transclude|entity|Wither/ED|title=WitherBoss|link=Wither}}
{{Data transclude|entity|Wolf/ED|title=Wolf}}
{{Data transclude|entity|Zombie/ED|title=Zombie}}
{{-}}
 
=== Projectiles ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Projectile Entities
|-
! Entity ID
! Name
|-
| Arrow
| [[Arrow]]
|-
| DragonFireball
| [[Ender Dragon]] Fireball
|-
| Fireball
| [[Ghast]] Fireball
|-
| SmallFireball
| [[Blaze]] Fireball/[[Fire Charge]]
|-
| Snowball
| [[Snowball]]
|-
| SpectralArrow
| [[Spectral Arrow]]
|-
| ThrownEgg
| [[Egg]]
|-
| ThrownEnderpearl
| [[Ender Pearl]]
|-
| ThrownExpBottle
| [[Bottle o' Enchanting]]
|-
| ThrownPotion
| [[Splash Potion]]
|-
| WitherSkull
| [[Wither#Wither Skull|Wither Skull]]
|}
Projectiles are a subclass of Entity and have very obscure tags such as X,Y,Z coordinate tags despite Entity Pos tag, inTile despite inGround, and shake despite most projectiles not being arrows. While all projectiles share tags, they are all independently implemented through <code>Throwable</code>, <code>ArrowBase</code>, and <code>FireballBase</code>.
 
{{Data transclude|entity|Arrow/ED|title=Arrow}}
{{Data transclude|entity|Ender Dragon/ED1|title=DragonFireball|link=Ender Dragon|icon=ender-acid-fire-charge}}
{{Data transclude|entity|Ghast/ED1|title=Fireball|link=Ghast|icon=fireball}}
{{Data transclude|entity|Fire Charge/ED|title=SmallFireball|link=Fire Charge|icon=fireball}}
{{Data transclude|entity|Snowball/ED|title=Snowball}}
{{Data transclude|entity|Arrow/ED1|title=SpectralArrow|link=Arrow}}
{{Data transclude|entity|Egg/ED|title=ThrownEgg|link=Egg}}
{{Data transclude|entity|Ender Pearl/ED|title=ThrownEnderpearl|link=Ender Pearl}}
{{Data transclude|entity|Bottle o' Enchanting/ED|title=ThrownExpBottle|link=Bottle o' Enchanting}}
{{Data transclude|entity|Splash Potion/ED|title=ThrownPotion|link=Splash Potion}}
{{Data transclude|entity|Wither/ED1|title=WitherSkull|link=Wither}}
{{-}}
 
=== Items and XPOrbs ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Item Entities
|-
! Entity ID
! Name
|-
| Item
| [[Dropped Item]]
|-
| XPOrb
| [[Experience|Experience Orb]]
|}
Items and XPOrbs are a subclass of Entity.
{{data transclude|env|Item (entity)/ED|title=Item|link=Item (entity)/ED|icon=item}}
{{data transclude|entity|Experience/ED|title=XPOrb|link=Experience|icon=experience-orb}}
{{-}}
 
=== Vehicles ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Vehicle Entities
|-
! Entity ID
! Name
|-
| Boat
| [[Boat]]
|-
| <s>Minecart</s> ''<small>(deprecated)</small>''
| [[Minecart]]<br>[[Minecart with Chest]]<br>[[Minecart with Furnace]]
|-
| MinecartRideable
| [[Minecart]]
|-
| MinecartChest
| [[Minecart with Chest]]
|-
| MinecartFurnace
| [[Minecart with Furnace]]
|-
| MinecartSpawner
| [[Minecart with Spawner]]
|-
| MinecartTNT
| [[Minecart with TNT]]
|-
| MinecartHopper
| [[Minecart with Hopper]]
|-
| MinecartCommandBlock
| [[Minecart with Command Block]]
|}
Vehicles are subclasses of Entity.
 
{{Data transclude|entity|Boat/ED|title=Boat}}
{{Data transclude|entity|Minecart/ED1|link=Boat|rawtitle={{EntityLink|Minecart|<s>Minecart</s>}} (deprecated since [[1.5]])}}
{{Data transclude|entity|Minecart/ED|link=Minecart|title=MinecartRideable}}
{{Data transclude|entity|Minecart with Chest/ED|link=Minecart with Chest|title=MinecartChest}}
{{Data transclude|entity|Minecart with Furnace/ED|link=Minecart with Furnace|title=MinecartFurnace}}
{{Data transclude|entity|Minecart with Spawner/ED|link=Minecart with Spawner|title=MinecartSpawner}}
{{Data transclude|entity|Minecart with TNT/ED|link=Minecart with TNT|title=MinecartTNT}}
{{Data transclude|entity|Minecart with Hopper/ED|link=Minecart with Hopper|title=MinecartHopper}}
{{Data transclude|entity|Minecart with Command Block/ED|link=Minecart with Command Block|title=MinecartCommandBlock}}
{{-}}
 
=== Dynamic tiles ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Dynamic Block Entities
|-
! Entity ID
! Name
|-
| PrimedTnt
| [[TNT]]
|-
| FallingSand
| Dynamic Tile
|}
Dynamic tiles are a subclass of Entity and are used to simulate realistically moving blocks.
 
{{Data transclude|entity|TNT/BE|link=TNT|title=PrimedTNT}}
{{Data transclude|entity|Sand/BE|rawtitle={{EntitySprite|falling-sand}} {{EntitySprite|falling-gravel}} {{EntitySprite|falling-dragon-egg}} {{EntitySprite|falling-anvil}} [[Sand|FallingSand]]}}
{{-}}
 
=== Other ===
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Other Entities
|-
! Entity ID
! Name
|-
| AreaEffectCloud
| Area Effect Cloud
|-
| ArmorStand
| [[Armor Stand]]
|-
| EnderCrystal
| [[Ender Crystal]]
|-
| EyeOfEnderSignal
| [[Eye of Ender]]
|-
| FireworksRocketEntity
| [[Firework Rocket]]
|-
| ItemFrame
| [[Item Frame]]
|-
| LeashKnot
| [[Lead]] Knot
|-
| Painting
| [[Painting]]
|-
| ShulkerBullet
| Shulker Bullet
|-
| <!-- this entity does not have a name and is not saved - its name IS NOT "unknown" -->
| [[Fishing Rod#Hooking entities|Fishing Rod Bobber]]
|}
Other entity types that are a subclass of Entity but do not fit into any of the above categories.
 
{{data transclude|effect|Lingering Potion/ED|title=AreaEffectCloud|link=Lingering Potion|icon=particle-absorption}}
{{data transclude|item|Armor Stand/ED|title=ArmorStand|link=Armor Stand}}
{{data transclude|entity|Ender Crystal/ED|title=EnderCrystal|link=Ender Crystal}}
{{data transclude|entity|Eye of Ender/ED|title=EyeOfEnderSignal|link=Eye of Ender}}
{{data transclude|item|Firework Rocket/ED|title=FireworksRocketEntity|link=Firework Rocket}}
{{data transclude|entity|Item Frame/ED|title=ItemFrame|link=Item Frame}}
{{data transclude|entity|Lead/ED|title=LeashKnot|link=Lead}}
{{data transclude|entity|Painting/ED|title=Painting}}
{{data transclude|entity|Shulker/ED1|title=ShulkerBullet|link=Shulker|icon=shulker-projectile}}
{{-}}
 
== {{anchor|Tile entity format}} Block entity format ==
 
{| class="wikitable" style="position:relative; z-index:1; float:right; margin-right:0"
|-
! colspan="2" | Block Entities
|-
! Block Entity ID
! Associated Block
|-
| Airportal
| [[End Portal (block)]]
|-
| Banner
| [[Banner]]
|-
| Beacon
| [[Beacon]]
|-
| <!--This is not a mistake, the game actually calls the block entity "Cauldron" for brewing stands!-->Cauldron
| [[Brewing Stand]]
|-
| Chest
| [[Chest]]<br>[[Trapped Chest]]
|-
| Comparator
| [[Redstone Comparator]]
|-
| Control
| [[Command Block]]
|-
| DLDetector
| [[Daylight Sensor]]
|-
| Dropper
| [[Dropper]]
|-
| EnchantTable
| [[Enchantment Table]]
|-
| EnderChest
| [[Ender Chest]]
|-
| EndGateway
| [[End Gateway (block)]]
|-
| FlowerPot
| [[Flower Pot]]
|-
| Furnace
| [[Furnace]]
|-
| Hopper
| [[Hopper]]
|-
| MobSpawner
| [[Monster Spawner]]
|-
| Music
| [[Note Block]]
|-
| Piston
| [[Piston#Piston extension|Piston Moving]]
|-
| RecordPlayer
| [[Jukebox]]
|-
| Sign
| [[Sign]]
|-
| Skull
| [[Mob head]]
|-
| Tr<!-- This is correct, the game code refers to dispensers this way -->ap
| [[Dispenser]]
|}
A [[block entity]] (not related to [[entity]]) is used by ''Minecraft'' to store information about a block that can't be stored in the four bits of block data the block has. Block entities were called "tile entities" until the 1.8 snapshots and that term is still used in some [[command]] usage.
 
{{Data transclude|blockentity|End Portal (block)/BE|sprite=block|icon=end-portal|link=End Portal (block)|title=AirPortal}}
{{Data transclude|blockentity|Banner/BE|sprite=block|title=Banner}}
{{Data transclude|blockentity|Beacon/BE|sprite=block|title=Beacon}}
{{Data transclude|blockentity|Brewing Stand/BE|sprite=block|link=Brewing Stand|title=Cauldron<!-- This is correct, the game code refers to brewing stands this way -->}}
{{Data transclude|blockentity|Chest/BE|sprite=block|title=Chest}}
{{Data transclude|blockentity|Redstone Comparator/BE|sprite=block|link=Redstone Comparator|title=Comparator}}
{{Data transclude|blockentity|Command Block/BE|sprite=block|link=Command Block|title=Control}}
{{Data transclude|blockentity|Daylight Sensor/BE|sprite=block|link=Daylight Sensor|title=DLDetector}}
{{Data transclude|blockentity|Dropper/BE|sprite=block|title=Dropper}}
{{Data transclude|blockentity|Enchantment Table/BE|sprite=block|link=Enchantment Table|title=EnchantTable}}
{{Data transclude|blockentity|Ender Chest/BE|sprite=block|link=Ender Chest|title=EnderChest}}
{{Data transclude|blockentity|End Gateway (block)/BE|sprite=block|icon=end-gateway|link=End Gateway (block)|title=EndGateway}}
{{Data transclude|blockentity|Flower Pot/BE|sprite=block|link=Flower Pot|title=FlowerPot}}
{{Data transclude|blockentity|Furnace/BE|sprite=block|title=Furnace}}
{{Data transclude|blockentity|Hopper/BE|sprite=block|title=Hopper}}
{{Data transclude|blockentity|Monster Spawner/BE|sprite=block|link=Monster Spawner|title=MobSpawner}}
{{Data transclude|blockentity|Note Block/BE|sprite=block|link=Note Block|title=Music}}
{{Data transclude|blockentity|Piston/BE|sprite=block|title=Piston}}
{{Data transclude|blockentity|Jukebox/BE|sprite=block|link=Jukebox|title=RecordPlayer}}
{{Data transclude|blockentity|Sign/BE|sprite=block|title=Sign}}
{{Data transclude|blockentity|Mob head/BE|sprite=block|link=Mob head|title=Skull}}
{{Data transclude|blockentity|Dispenser/BE|sprite=block|link=Dispenser|title=Trap<!-- This is correct, the game code refers to dispensers this way -->}}
{{-}}
 
== Tile tick format ==
Tile Ticks represent block updates that need to happen because they could not happen before the chunk was saved. Examples reasons for tile ticks include redstone circuits needing to continue updating, water and lava that should continue flowing, recently placed sand or gravel that should fall, etc. Tile ticks are not used for purposes such as leaf decay, where the decay information is stored in the leaf block data values and handled by Minecraft when the chunk loads. For map makers, tile ticks can be used to update blocks after a period of time has passed with the chunk loaded into memory.
 
<div class="treeview">
* {{nbt|compound}} A Tile Tick
** {{nbt|string|i}}: The ID of the block; used to activate the correct block update procedure.
** {{nbt|int|t}}: The number of ticks until processing should occur. May be negative when processing is overdue.
** {{nbt|int|p}}: If multiple tile ticks are scheduled for the same tick, tile ticks with lower p will be processed first. If they also have the same p, the order is unknown.
** {{nbt|int|x}}: X position
** {{nbt|int|y}}: Y position
** {{nbt|int|z}}: Z position
</div>
 
== History ==
 
Chunks were first introduced in Minecraft [[Infdev]]. Before the addition of the [[Region file format|MCRegion]] format in Beta 1.3, chunks were stored as individual chunk files ".dat" where the file names contained the chunk's position encoded in Base36 - this is known as the [[Alpha Level Format|Alpha level format]]. MCRegion changed this by storing groups of 32×32 chunks in individual ".mcr" files with the coordinates in Base10, with the goal being to reduce disk usage by cutting down on the number of file handles Minecraft had open at once. MCRegion's successor is the current format, [[Anvil file format|Anvil]], which only made changes to the '''chunk format'''. The region file technique is still used, but the region file extensions are ".mca" instead.
 
The major change from MCRegion to Anvil was the division of Chunks into Sections; each chunk has up to 16 individual 16×16×16 block Sections so that completely empty sections will not be saved at all. Preparation has also been made to support blocks with IDs in the range 0 to 4095, as compared to the previous 0 to 255 limitation. However, Minecraft is not fully prepared for such blocks to exist as items; many item IDs are already taken in the range 256 to 4095.
 
The Blocks, Data, BlockLight, and SkyLight arrays are now housed in individual chunk Sections. The Data, SkyLight, and BlockLight are arrays of 4-bit values, and the BlockLight and SkyLight arrays no longer house part of the block ID. The Blocks array is 8 bits per block, and the 4096-blocks support exists in the form of an optional Add byte array of 4-bits per block for additional block ID information. With the Anvil format, the [[NBT Format]] was changed from Notch's original specification to include an integer array tag similar to the existing byte array tag. It is currently only used for HeightMap information in chunks.
 
{{History|release}}
{{History||?|Removed <code>MaxExperience</code>, <code>RemainingExperience</code>, <code>ExperienceRegenTick</code>, <code>ExperienceRegenRate</code> and <code>ExperienceRegenAmount</code> from <code>MobSpawner</code>.}}
{{History||1.4.2|snap=12w34a|Added entity <code>WitherBoss</code>.}}
{{History||1.5|snap=13w02a|Added entity <code>MinecartTNT</code>.
|<code>Minecart</code> is now deprecated.}}
{{History|||snap=13w03a|Added entity <code>MinecartHopper</code>.}}
{{History|||snap=13w06a|Added entity <code>MinecartSpawner</code>.}}
{{History||1.6.1|snap=13w16a|Added entity <code>EntityHorse</code>.}}
{{History|||snap=13w21a|Removed <code>ArmorType</code> from <code>EntityHorse</code>.
|Removed <code>Saddle</code> from <code>EntityHorse</code>.}}
{{History|||snap=1.6.1-pre|Readded <code>Saddle</code> to <code>EntityHorse</code>.}}
{{History||1.7.2|snap=13w39a|Added entity <code>MinecartCommandBlock</code>.}}
{{History||1.8|snap=14w02a|Added <code>Lock</code> to containers.
|Item IDs are no longer used when specifying NBT data.
|Added <code>Block</code> to <code>FallingSand</code>, using the alphabetical ID format.}}
{{History|||snap=14w06a|Added <code>ShowParticles</code> to all mobs.
|Added <code>PickupDelay</code> to item entities.
|Setting <code>Age</code> to -32768 makes items which never expire.
|Removed <code>AttackTime</code> from mobs.}}
{{History|||snap=14w10a|Added <code>rewardExp</code> to <code>Villager</code>.
|Added <code>OwnerUUID</code> for mobs that can breed.
|Added <code>Owner</code> to <code>Skull</code>.
|Changes to item frames and paintings: added <code>Facing</code>, <code>TileX</code>, <code>TileY</code> and <code>TileZ</code> now represent the co-ordinates of the block the item is in rather than what it is placed on, deprecated <code>Direction</code> and <code>Dir</code>.}}
{{History|||snap=14w11a|Added entity <code>Endermite</code>.
|Added <code>EndermiteCount</code> to <code>Enderman</code>.}}
{{History|||snap=14w21a|<code>CustomName</code> and <code>CustomNameVisible</code> now work for all entities.}}
{{History|||snap=14w25a|Added entity <code>Guardian</code>.
|Added <code>Text1</code>, <code>Text2</code>, <code>Text3</code> and <code>Text4</code> to signs. The limit no longer depends on the amount of characters (16), it now depends on the width of the characters.}}
{{History|||snap=14w27a|Added entity <code>Rabbit</code>.
Added <code>CommandStats</code> to [[command block]]s and [[sign]]s.}}
{{History|||snap=14w28a|Removed <code>EndermiteCount</code> from <code>Enderman</code>.}}
{{History|||snap=14w30a|Added <code>Silent</code> for all entities.}}
{{History|||snap=14w32a|Added <code>NoAI</code> for all mobs.
|Added entity <code>ArmorStand</code>.}}
{{History|||snap=14w32c|Added <code>NoBasePlate</code> to <code>ArmorStand</code>.}}
{{History||1.9|snap=15w31a|Added tags <code>HandItems</code>, <code>ArmorItems</code>, <code>HandDropChances</code>, and <code>ArmorDropChances</code> to <code>Living</code>, which replace the <code>DropChances</code> and <code>Equipment</code> tags.
|Added <code>HandItems</code> and <code>ArmorItems</code> to <code>ArmorStand</code>.
|Added <code>Glowing</code> to <code>Entity</code>.
|Added <code>Team</code> to <code>LivingBase</code>.
|Added <code>DragonPhase</code> to <code>EnderDragon</code>
|Added entity <code>Shulker</code>, child of <code>SnowMan</code>.
|Added entity <code>ShulkerBullet</code>, child of <code>Entity</code>.
|Added entity <code>DragonFireball</code>, which extends <code>FireballBase</code> and has no unique tags.
|Added entities <code>TippedArrow</code> and <code>SpectralArrow</code>, children of <code>Arrow</code>.
|Added block <code>EndGateway</code>, child of <code>TileEntity</code>.
|Added block <code>Structure</code>, child of <code>TileEntity</code>.
|Added item tag <code>Potion</code>, child of <code>tag</code>.}}
{{History|||snap=15w32a|<code>Tags</code> and <code>DataVersion</code> tag can now be applied on [[entities]].
|Changed the <code>Fuse</code> tag's type for the </code>PrimedTnt</code> entity from "Byte" to "Short".}}
{{History|||snap=15w32c|Introduced a limit on the amount of tags an entity can have (1024 tags). When surpassed it displays an error saying: "Cannot add more than 1024 tags to an entity."}}
{{History|||snap=15w33a|Added entity <code>AreaEffectCloud</code>, child of <code>Entity</code>.
|Added <code>ExactTeleport</code> and renamed <code>Life</code> to <code>Age</code> for <code>EndGateway</code>.
|Added <code>Linger</code> to <code>ThrownPotion</code>.
|Removed <code>DataVersion</code> from <code>Entity</code>. It is now only applied to <code>Player</code> only, child of <code>LivingBase</code>.
|Removed <code>UUID</code> from <code>Entity</code>.
|<code>HealF</code> under <code>LivingBase</code> has become deprecated.
|<code>Health</code> under <code>LivingBase</code> has changed from type "Short" to "Float".
|<code>Equipment</code> removed from <code>ArmorStand</code> and <code>Living</code> entity, its usage replaced by <code>HandItems</code> and <code>ArmorItems</code> which were added earlier.}}
{{History|||snap=15w33c|Added <code>BeamTarget</code> to <code>EnderCrystal</code>.}}
{{History|||snap=15w34a|Added <code>powered</code> and <code>conditional</code> byte tags to <code>Control</code> tile entity for [[command block]]s.
|Added <code>life</code> and <code>power</code> to <code>FireballBase</code>.
|Added <code>id</code> inside <code>SpawnData</code> to <code>MobSpawner</code>.
|Added <code>powered</code> to the <code>Music</code> tile entity for [[note block]]s.}}
{{History|||snap=15w35a|Added <code>VillagerProfession</code> to <code>Zombie</code>.}}
{{History|||snap=15w37a|Added <code>Enabled</code> to <code>MinecartHopper</code>.}}
{{History|||snap=15w38a|Added <code>SkeletonTrap</code> and <code>SkeletonTrapTime</code> to <code>EntityHorse</code>.}}
{{History|||snap=15w41a|Replaced <code>Riding</code> with <code>Passengers</code> for all entities.
|Added <code>RootVehicle</code> for all passengers.
|Added <code>Type</code> to <code>Boat</code>.}}
{{History|||snap=15w42a|Added <code>Fuel</code> to <code>Cauldron</code> (brewing stands).}}
{{History|||snap=15w43a|Added <code>LootTable</code> and <code>LootTableSeed</code> to <code>Chest</code>, <code>Minecart</code> and <code>MinecartHopper</code>.
|Added <code>DeathLootTable</code> and <code>DeathLootTableSeed</code> to all mobs.
|Added <code>life</code> and <code>power</code> to all fireballs (<code>FireballBase</code>).}}
{{History|||snap=15w44a|Added <code>ShowBottom</code> to <code>EnderCrystal</code>.}}
{{History|||snap=15w44b|Added <code>Potion</code> and <code>CustomPotionEffects</code> to <code>Arrow</code>.
|Added <code>Potion</code> to <code>AreaEffectCloud</code>.}}
{{History|||snap=15w45a|Removed <code>Linger</code> from <code>ThrownPotion</code>. Instead, the potion will linger if the stored item has an ID of <code>minecraft:lingering_potion</code>.
|<code>ThrownPotion</code> will now render as its stored item even if the item is not a potion.}}
{{History|||snap=15w46a|<code>MoreCarrotTicks</code> from <code>Rabbit</code> is now set to 40 when rabbits eat a carrot crop, but is not used anyway.}}
{{History|||snap=15w47a|Added <code>PaymentItem</code> to <code>Beacon</code>.}}
{{History|||snap=15w49a|Removed <code>PaymentItem</code> from <code>Beacon</code>.
|In order for a sign to accept text, all 4 tags ("Text1", "Text2", "Text3", and "Text4") must exist.}}
{{History|||snap=15w51b|The original values of <code>DisabledSlots</code> in <code>ArmorStand</code> have changed in nature.}}
{{History|foot}}
 
 
{{Minecraft}}
[[Category:Development]]
[[Kategoria:Test bota]]
[[Kategoria:Test bota2]]
[[de:Chunk Format]]
[[fr:Format de fichier de tronçon]]
[[ko:청크 구성]]
[[nl:Segment formaat]]
[[zh:区块格式]]
[[Category:Tables without description]]

Aktualna wersja na dzień 14:41, 29 kwi 2018

Ostateczny test? Testów nigdy za wiele