Minecraft:World generation
More actions
World generation (sometimes abbreviated as worldgen) is the Template:W process Minecraft uses to algorithmically generate terrain, Minecraft:biomes, Minecraft:features, and thus ultimately decides which Minecraft:blocks are placed where. Minecraft worlds are made of 16×16 blocks wide chunks stretching the full height of the Minecraft:dimension. Because there are more than 18 quintillion (18×1018, or Template:Abbr) possible worlds, the game generates them using randomness, algorithms, and some manually built decorations. The benefits of procedural world generation include smaller game file size and practically infinite possibilities of gameplay.
Randomness
In order to generate a different world every time, the game uses random numbers generated from a seed. However, pure randomness makes terrain and biomes too chaotic with no continuity.<ref>Template:YouTube link</ref>
To solve this problem, the game makes use of gradient noise algorithms, like Template:W.<ref>Template:Citation</ref> This makes sure blocks and chunks fit with their neighbors and gives the world both continuity and randomness.
Even though noise looks random and continuous, using it to generate terrain still lacks variation like hills and valleys that stand out and have a large height difference. To solve this, multiple noise functions are generated with different frequencies and amplitudes and then added up, which gives a more natural result. These noise functions are called octaves.
-
Pure randomness (also known as white noise) is too chaotic.
-
Perlin noise makes it random and continuous.
-
Multiple octaves are combined to create variation.
Steps
World generation happens in multiple steps. The game may freeze some chunks that are far from players at an early generation step for better performance, as shown on the graph. As the player approaches these chunks, the chunks advance through the generation steps again until they finish generating. Incomplete chunks that are temporarily frozen at a step are called proto-chunks, while chunks that are ready and accessible to players are called level chunks. Template:IN, the steps of world generation are sorted into:
- Template:Colorempty: The chunk is not yet loaded or generated.
- Template:Colorstructures_starts: This step calculates the starting points for structure pieces. For structures that start in this chunk, the position of all pieces are generated and stored.
- Template:Colorstructures_references: A reference to nearby chunks that have a structures' starting point are stored.
- Template:Colorbiomes: Biomes are determined and stored. No terrain is generated at this stage.
- Template:Colornoise: The base terrain shape and liquid bodies are placed.
- Template:Colorsurface: The surface of the terrain is replaced with biome-dependent blocks.
- Template:Colorcarvers: Carvers carve certain parts of the terrain and replace solid blocks with air.
- Template:Colorfeatures: Features and structure pieces are placed and heightmaps are generated.
- Template:Colorinitialize_light: The lighting engine is initialized and light sources are identified.
- Template:Colorlight: The lighting engine calculates the light level for blocks.
- Template:Colorspawn: Mobs are spawned.
- Template:Colorfull: Generation is done and a chunk can now be loaded. The proto-chunk is now converted to a level chunk and all block updates deferred in the above steps are executed.
Biomes
Overworld
Minecraft:Biome generation in the Minecraft:Overworld is based on 6 parameters: temperature, humidity (aka. vegetation), continentalness (aka. continents), erosion, weirdness (aka. ridges), and depth. Except for "depth", the other 5 parameters are based only on horizontal coordinates.
They can be thought of as a six-dimensional (6D) space, where multiple intervals are defined for each biome, as described below. If the 6 parameters at a location fall outside all the defined biome intervals, the game uses the closest biome interval in the 6D space.
Temperature is a noise parameter used only in biome generation and does not affect terrain generation. Temperature values are divided into 5 levels. The corresponding ranges from level 0 to level 4 are: -1.0~-0.45, -0.45~-0.15, -0.15~0.2, 0.2~0.55, 0.55~1.0.
Note that the temperature parameter is not the same as the temperature property of a biome, but they roughly correspond each other, e.g. if a location's temperature parameter is level 0, the base temperature of the biome here is usually low enough or the terrain is high enough, that the surface is covered in snow and ice.
Humidity (also known as vegetation) is a noise parameter used only in biome generation and does not affect terrain generation. Humidity values are also divided into 5 levels. The corresponding ranges from level 0 to level 4 are: -1.0~-0.35, -0.35~-0.1, -0.1~0.1, 0.1~0.3, 0.3~1.0.
Continentalness (also known as continents) is used to decide between ocean/beach/land biomes. Higher values correspond to more inland biomes.
- If -1.2~-1.05: Mushroom fields
- If -1.05~-0.455: Deep ocean
- If -0.455~-0.19: Ocean
- If -0.19~-0.11: Coast
- If -0.11~0.03: Near-inland
- If 0.03~0.3: Mid-inland
- If 0.3~1.0: Far-inland
Erosion is used to decide between flat and mountainous terrain. When erosion is high the landscape is generally flat, and where erosion is low the landscape is hilly. Areas with low erosion also tend to generate meadows, snowy slopes, stony peaks, jagged peaks, and frozen peaks. Erosion values are divided into 7 levels. The corresponding ranges from level 0 to level 6 are: -1.0~-0.78, -0.78~-0.375, -0.375~-0.2225, -0.2225~0.05, 0.05~0.45, 0.45~0.55, 0.55~1.0.
Weirdness (also known as ridges) affects whether to generate a biome variant or not, as well as whether or not terrain generates shattered. If the weirdness value is greater than 0, the generated biome becomes weirder. For example, weirdness could cause a jungle biome to become a bamboo jungle instead, or could cause a taiga to generate with more shattered terrain akin to a windswept savanna. A biome and its variant often do not appear on the same bank of a river.
The PV (peaks and valleys, aka. ridges folded) value is calculated through the formula <math>1-\vert (3 \vert weirdness \vert) - 2 \vert</math>.
- If -1.0~-0.85: Valleys
- If -0.85~-0.2: Low
- If -0.2~0.2: Mid
- If 0.2~0.7: High
- If 0.7~1.0: Peaks
Depth is a parameter not based directly on noise, instead it corresponds approximately to the terrain height. It is roughly 0 at the surface and increases by Template:Frac (0.0078125) for every 1 block down. The depth parameter affects whether a surface biome or a cave biome is placed.
The table below lists the defined depth values for Overworld biomes, and any additional noise values required for cave biomes to generate. Any other values result in the closest biome interval being used instead. Note that regions of lush caves and dripstone caves overlap.<ref>Template:Bug</ref>
| Depth | Additional requirement | Biomes |
|---|---|---|
| D=0.0 | N/A | Surface biomes |
| D=0.2~0.9 | Continentalness=0.8~1.0 | Template:BiomeLink |
| D=0.2~0.9 | Humidity=0.7~1.0 | Template:BiomeLink |
| D=0.2~0.9 | Weirdness=-1.1~-0.95 | Template:BiomeLinkTemplate:Upcoming |
| D=1.0 | N/A | Surface biomes |
| D=1.1 | Erosion=-1.0~-0.375 | Template:BiomeLink |
The generation of non-inland biomes is not based on humidity, erosion, or weirdness. The following table lists the relation between non-inland surface biomes and continentalness and temperature.
The following table lists the relation between inland surface biomes and continentalness, erosion and PV.
| Erosion | PV | Coast | Near-inland | Mid-inland | Far-inland |
|---|---|---|---|---|---|
| E=0 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) |
Middle biomes<ref group="bo" name="always-w-gt-0">Always generates as if W>0</ref>(T<4) Badland biomes<ref group="bo" name="always-w-gt-0">Always generates as if W>0</ref>(T=4) | ||
| Low | Template:BiomeLink | Middle biomes(T<4) Badland biomes(T=4) |
Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Middle biomes(0<T<4) Badland biomes(T=4) | ||
| Mid | Template:BiomeLink(T<3; H=0,1) Template:BiomeLink(T<3; H=2,3,4) Plateau biomes(T=3,4) | ||||
| High | Middle biomes | Template:BiomeLink(T<3; H=0,1) Template:BiomeLink(T<3; H=2,3,4) Plateau biomes(T=3,4) |
Template:BiomeLink(T=0,1,2; W<0) Template:BiomeLink(T=0,1,2; W>0) Template:BiomeLink(T=3) Badland biomes(T=4) | ||
| Peaks | Template:BiomeLink(T=0,1,2; W<0) Template:BiomeLink(T=0,1,2; W>0) Template:BiomeLink(T=3) Badland biomes(T=4) | ||||
| E=1 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) |
Middle biomes<ref group="bo" name="always-w-gt-0">Always generates as if W>0</ref>(T<4) Badland biomes<ref group="bo" name="always-w-gt-0">Always generates as if W>0</ref>(T=4) | ||
| Low | Template:BiomeLink | Middle biomes(T<4) Badland biomes(T=4) |
Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Middle biomes(0<T<4) Badland biomes(T=4) | ||
| Mid | Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Middle biomes(0<T<4) Badland biomes(T=4) |
Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Plateau biomes(T>0) | |||
| High | Middle biomes | Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Middle biomes(0<T<4) Badland biomes(T=4) |
Template:BiomeLink(T<3; H=0,1) Template:BiomeLink(T<3; H=2,3,4) Plateau biomes(T=3,4) | ||
| Peaks | Template:BiomeLink(T=0; H=0,1) Template:BiomeLink(T=0; H=2,3,4) Middle biomes(0<T<4) Badland biomes(T=4) |
Template:BiomeLink(T=0,1,2; W<0) Template:BiomeLink(T=0,1,2; W>0) Template:BiomeLink(T=3) Badland biomes(T=4) | |||
| E=2 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) | |||
| Low | Template:BiomeLink | Middle biomes | Middle biomes(T<4) Badland biomes(T=4) | ||
| Mid | Middle biomes (T<4) Badland biomes (T=4) |
Plateau biomes | |||
| High~Peaks | Middle biomes | Plateau biomes | |||
| E=3 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) | |||
| Low | Beach biomes | Middle biomes | Middle biomes(T<4) Badland biomes(T=4) | ||
| Mid | Middle biomes | ||||
| High~Peaks | Middle biomes (T<4) Badland biomes (T=4) |
Plateau biomes | |||
| E=4 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) | |||
| Low | Beach biomes | Middle biomes | |||
| Mid | Beach biomes(W<0) Middle biomes(W>0) | ||||
| High~Peaks | Middle biomes | ||||
| E=5 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink(T>0) | |||
| Low | Beach biomes(W<0) Middle biomes(W>0; T=0,1 OR H=4) Template:BiomeLink(W>0; T=2,3,4; H=0,1,2,3) |
Middle biomes(W<0 OR T=0,1 OR H=4) Template:BiomeLink(W>0; T=2,3,4; H=0,1,2,3) |
Middle biomes | ||
| Mid | Shattered biomes | ||||
| High | Middle biomes(W<0 OR T=0,1 OR H=4) Template:BiomeLink(W>0; T=2,3,4; H=0,1,2,3) | ||||
| Peaks | Shattered biomes (W<0 OR T=0,1 OR H=4) Template:BiomeLink (W>0; T=2,3,4; H=0,1,2,3) | ||||
| E=6 | Valleys | Template:BiomeLink(T=0) Template:BiomeLink (T>0) |
Template:BiomeLink(T=0) Template:BiomeLink(T=1,2) Template:BiomeLink(T=3,4) | ||
| Low | Beach biomes | Middle biomes(T=0) Template:BiomeLink(T=1,2) Template:BiomeLink(T=3,4) | |||
| Mid | Beach biomes(W<0) Middle biomes(W>0) | ||||
| High~Peaks | Middle biomes | ||||
In which, the specific biome generation of beach biomes, badland biomes, middle biomes, plateau biomes, and shattered biomes is determined by the temperature, humidity, and weirdness values.
Beach biomes generate in low lying terrain along the coast, and the specific biome generation is related only to the temperature value.
| Temperature | Biomes |
|---|---|
| T=0 | Template:BiomeLink |
| T=1,2,3 | Template:BiomeLink |
| T=4 | Template:BiomeLink |
Badland biomes usually generate inland with low erosion value, and can also generate along the coast with high terrain and low erosion. The specific biome generation is related to humidity and weirdness.
| Humidity | Biomes |
|---|---|
| H=0,1 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
| H=2 | Template:BiomeLink |
| H=3,4 | Template:BiomeLink |
Middle biomes are the most extensive biomes inland. The specific biome generation depends on temperature, humidity, and weirdness.
| Template:Diagonal split header | T=0 | T=1 | T=2 | T=3 | T=4 |
|---|---|---|---|---|---|
| H=0 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink |
| H=1 | Template:BiomeLink | Template:BiomeLink | |||
| H=2 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) | ||
| H=3 | Template:BiomeLink | Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink(W<0) Template:BiomeLink(W>0) | |
| H=4 | Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) | |
Plateau biomes generate at inland high terrain with moderate erosion, which results in biomes like meadows and savanna plateaus. The specific biome generation depends on temperature, humidity, and weirdness.
| Template:Diagonal split header | T=0 | T=1 | T=2 | T=3 | T=4 |
|---|---|---|---|---|---|
| H=0 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
| H=1 | Template:BiomeLink | Template:BiomeLink | |||
| H=2 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | Template:BiomeLink | |
| H=3 | Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink | |
| H=4 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) |
Template:BiomeLink (W<0)
Template:BiomeLink (W>0) |
Template:BiomeLink |
Shattered biomes are generated at inland places with high erosion. The specific biome generation depends on temperature, humidity, and weirdness.
| Template:Diagonal split header | T=0~1 | T=2 | T=3 | T=4 |
|---|---|---|---|---|
| H=0~1 | Template:BiomeLink | Template:BiomeLink | Template:BiomeLink | Template:BiomeLink |
| H=2 | Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) | ||
| H=3 | Template:BiomeLink | Template:BiomeLink(W<0) Template:BiomeLink(W>0) | ||
| H=4 | Template:BiomeLink(W<0) Template:BiomeLink(W>0) | |||
The Nether
Minecraft:The Nether uses 3 parameters to generate biomes: temperature, humidity and offset. Unlike the Overworld, the Nether specifies biomes with a single point.
The offset parameter is not based off of noise, it is always 0 at any location in a world. This means that the parameter point of a location is always in the temperature-humidity-plane. The closer the offset (of a biome point) is to 0, the closer the point is to the T-H-plane and the greater the advantage it has during biome generation.
| Biomes | Temperature | Humidity | Offset |
|---|---|---|---|
| Template:BiomeLink | -0.5 | 0 | 0.175 |
| Template:BiomeLink | 0.4 | 0 | 0 |
| Template:BiomeLink | 0 | 0 | 0 |
| Template:BiomeLink | 0 | -0.5 | 0 |
| Template:BiomeLink | 0 | 0.5 | 0.375 |
The End
Template:IN, Minecraft:the End uses only one noise parameter: erosion. If the horizontal distance from the chunk origin of a chunk to the world origin is less than 1024, the blocks in the chunk are in the End. Otherwise, the biome is determined by erosion.
| Biome | Erosion | Distance |
|---|---|---|
| Template:BiomeLink | -1~-0.21875 | >1024 |
| -0.21875~-0.0625 | ||
| Template:BiomeLink | -0.0625~0.25 | |
| Template:BiomeLink | 0.25~1 | |
| Template:BiomeLink | N/A | <1024 |
Template:IN, the End has only one biome: The End.
Terrain
Terrain shaping determines which blocks should be solid and which blocks should be filled with air.
3D noise
Template:For If the noise is in two dimensions, it controls only surface height and it is impossible to add terrain above the surface. To add overhangs and 3D shapes, the game uses 3D Perlin noise function that gives an output called density for every single block. A density > 0 means it is filled with solid block, otherwise it is filled with air.
Density is then given a height bias and a base height. Height bias "squeezes" the blocks. Base height is the base of the squeezing process where the density is left unchanged. Changing base height moves the ground up and down.
- In the Overworld, there is a single pair of height bias and base height, meaning the higher the block is, the less density it has and vice versa. Height bias and base height are both configured by a couple of different noises. Notably, amplified worlds are generated by tuning height bias to be lower than default, so that terrain stretch in the vertical direction more.
- In the Nether, there are two pairs of base heights that create the thick, solid ceiling and ground, and the hollow space between them.
- In the End, these parameters are configured to squeeze the map into a big island located relatively at the bottom of the dimension.
-
The side view of a world using a single noise
-
The side view of a world using 3D noise, creating overhangs
Splines
To give the world some dramatic terrain shapes like cliffs, fjords and plateaus, the game uses three 2D noise maps. These noises are mapped using splines to calculate the height offset and a vertical stretch factor. The same noises are also used in biome generation, which creates a soft link between biome and terrain. For example, a mountainous area generates mountainous biome and plains biomes are generally flatter.
The larger the continentalness, the higher the average terrain height. Continentalness is used mainly for differentiating ocean and land.
The erosion parameter affects inland terrain during terrain generation. Erosion is mainly used to create large areas of flat ground. The higher the erosion at a location, the lower the terrain height and the flatter the terrain.
The peaks and valleys (PV) value is calculated from weirdness. As the name suggests, it is mainly used for generating better peaks and valleys. The higher the PV value, the higher the terrain. Usually, at places with low continentalness or high erosion, when the PV level is "Valleys", the terrain is low enough to generate rivers. At high terrain, negative weirdness values lead to taller and more jagged and point peaks. When the erosion level is approximately 5, positive weirdness values result in weird inland terrain that is shattered and extremely precipitous and craggy.
-
Continentalness creates distinction between land and ocean
-
Large area of flat plains is created by high erosion.
-
PV creates peaks and valleys like this fjord.
Noise caves
Noise caves are part of the base terrain generation and are generated using 3D Perlin noises. They come in the form of cheese caves, spaghetti caves, and noodle caves. Three noise maps, frequency, hollowness, and thickness, are parameters that control this process. Frequency controls the frequency of the cave generation.
- Cheese caves are pocket areas of the underground that come in various sizes. They are generated by taking the white area in a Perlin noise map. Hollowness controls the size of cheese caves.
- Spaghetti caves are long, narrow caves that wind their way through the underground. When generating, the edge of black and white part of noise image becomes air, making it look like long and wide spaghetti. Thickness controls the thickness of spaghetti caves.
- Noodle caves are a thinner and squigglier variant of spaghetti caves. They consist of tunnels usually 1 to 5 blocks in width. Its generating mechanism is similar to that of spaghetti caves. Thickness controls the thickness of noodle caves.
Additionally, noise pillars generate inside big cheese cave chambers. Frequency controls the frequency of the pillar generation while thickness control the thickness of them.
-
Inside of a cheese cave.
-
Inside of a spaghetti cave.
-
Inside of a noodle cave.
Aquifers
Aquifers are liquid systems used in the Minecraft:Overworld to determine the fluid in all empty areas. Without aquifers all empty areas between sea-level and Y=-54 would be filled with Minecraft:water. Areas below Y=-55 are always filled with Minecraft:lava. To avoid all caves being flooded, aquifers are used to determine the fluid state of each position instead. Aquifers don't change the lava below Y=-55. An aquifer can be in 3 different states, with a state selected for each position:
- Empty: Always filled with air
- Flooded: As if aquifers didn't exist: filled with air above the sea-level and a fluid below.
- Local fluid level: Picks a local liquid level and fills areas below with a liquid and areas above with air.
For positions above the preliminary surface, the aquifer state is "Flooded". In areas of erosion less than -0.22 and depth greater than 0.9 (only the deep dark in vanilla), the state is always "Empty". Otherwise the state is determined bases on a noise. Values below 0.4 are "Empty", values above 0.8 are "Flooded", otherwise a local fluid level is used.
In positions near areas where the preliminary surface is below the sea-level the area of the "Flooded" aquifer state reaches slightly below the preliminary surface. In these areas the cutoff values for the noise are linearly decreased from 64 blocks below the preliminary surface upward. At the surface they are below -0.8 for "Empty" and above -0.3 for "Flooded". This causes the "Flooded" state to be much more common directly below rivers and oceans.
The local water level is determined in cells of size 16x40x16 blocks using a different noise. Whether to place water or lava is determined in cells of 64x40x64 blocks based on a third noise. Areas above Y=-10 always use water.
Barriers are used to separate areas of different liquids and to separate liquids from air. The height of the barriers is dependent on a fourth noise, causing water or lava to sometimes spill over the barrier.
Ore veins
Ore veins generate only in the Overworld. Three noises are used for vein generation: toggle, ridge, and gap.
Toggle is always 0 outside Y=-60 to Y=51 and can be negative or positive inside the range. The game attempts to generate an iron or a copper vein depending on whether toggle is < 0 or > 0. The attempts might fail because veins have a configured generating height.
Ridge is always -0.08 if Y level is outside the range. If ridge is > 0, the game skips the block.
Gap determines the ratio of ore-to-filler material, between 10% and 30% for any given vein. For non-filler blocks, 98% generate as normal ore blocks, while 2% are generated as raw ore blocks (Minecraft:Block of Raw Copper and Minecraft:Block of Raw Iron, respectively).
The blocks used in vein generation are Template:W, though their size can be changed with datapacks.
Surface
After the base terrain is generated, the game replaces some blocks with grass blocks, sand, dirt, etc., depending on the biome and other conditions.
Overworld
| Conditions | Result block | ||||
|---|---|---|---|---|---|
| Gradient Y=-64 → Y=-59 | Template:BlockLink | ||||
| Surface<ref group="s">Above preliminary surface (aka. not in noise caves)</ref> | Floor<ref group="s" name="floor-0">Only the top layer of the floor surface</ref> | Template:BiomeLink | Above Y=97 | Noise<ref group="s" name="surface-noise-1">Surface noise within -0.909~-0.5454, -0.1818~0.1818, or 0.5454~0.909</ref> | Template:BlockLink |
| No water above | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | At Y=63 | Noise<ref group="s">Swamp surface noise ≥ 0</ref> | Template:BlockLink | ||
| Template:BiomeLink | Between Y=61 and Y=63 | ||||
| Template:BiomeLink Template:BiomeLink Template:BiomeLink |
Floor<ref group="s" name="floor-0" /> | Above Y=256 | Template:BlockLink | ||
| Above Y=74 | Noise<ref group="s" name="surface-noise-1" /> | Template:BlockLink | |||
| Otherwise | Template:EnvLink<ref group="s" name="hoodoo">Special hardcoded rule that places the bands of terracotta</ref> | ||||
| Water no deeper than 1 | Ceiling<ref group="s" name="ceiling-0">Only the top layer of the ceiling surface</ref> | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Erosion<ref group="s" name="hole">A hole in the terrain, where the surface noise is 0</ref> | Template:BlockLink | ||||
| WaterTemplate:Info needed | Template:BlockLink | ||||
| Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Surface is above Y=63 | Above Y=63 and surface is below Y=74 | Template:BlockLink | |||
| Otherwise | Template:EnvLink<ref group="s" name="hoodoo" /> | ||||
| Floor<ref group="s" name="floor-0" /> | Water no deeper than 6 blocks | Template:BlockLink | |||
| Floor<ref group="s" name="floor-0" /> and water no deeper than 1 |
Template:BiomeLink Template:BiomeLink |
Erosion<ref group="s" name="hole" /> | No water above | Template:BlockLink | |
| Cold<ref group="s">Whether it is cold enough to snow here</ref> | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Steep face<ref group="s" name="steep">The vertical gradient of the north and south side is greater than 2</ref> or noise<ref group="s">Packed ice noise within 0~0.2</ref> | Template:BlockLink | |||
| Ice noise within 0~0.025 | Template:BlockLink | ||||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Steep face<ref group="s" name="steep" /> | Template:BlockLink | |||
| Noise<ref group="s" name="powder-snow-noise">Powder snow noise within 0.35~0.6</ref> | No water above | Template:BlockLink | |||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Steep face<ref group="s" name="steep" /> | Template:BlockLink | |||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Noise<ref group="s" name="powder-snow-noise" /> | No water above | Template:BlockLink | ||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Calcite noise within -0.0125~0.0125 | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Noise<ref group="s" name="gravel-noise">Gravel noise within -0.05~0.05</ref> | Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Surface noise ≥ 4/33 | Template:BlockLink | |||
| Template:BiomeLink Template:BiomeLink Template:BiomeLink Template:BiomeLink |
Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Template:BlockLink | ||||
| Template:BiomeLink | Surface noise ≥ 7/33 | Template:BlockLink | |||
| Surface noise ≥ -2/33 | Template:BlockLink | ||||
| Template:BiomeLink | Surface noise ≥ 8/33 | Ceiling | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Surface noise ≥ 4/33 | Template:BlockLink | ||||
| Surface noise ≥ -4/33 | No water above | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Ceiling | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink Template:BiomeLink |
Surface noise ≥ 7/33 | Template:BlockLink | |||
| Surface noise ≥ 19/165 | Template:BlockLink | ||||
| Template:BiomeLink | No water above | Template:BlockLink | |||
| Template:BiomeLink | Template:BlockLink | ||||
| Template:BiomeLink | Template:BlockLink | ||||
| No water above | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Floor<ref group="s" name="floor-0" /> and water no deeper than 6 |
Template:BiomeLink Template:BiomeLink |
Erosion<ref group="s" name="hole" /> | Template:BlockLink | ||
| Floor with depth<ref group="s" name="floor-depth">The top few layers of the floor surface</ref> and water no deeper than 6 |
Template:BiomeLink | Steep face<ref group="s" name="steep" /> or noise<ref group="s">Packed ice noise within -0.5~0.2</ref> | Template:BlockLink | ||
| Ice noise within -0.0625~0.025 | Template:BlockLink | ||||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Steep face<ref group="s" name="steep" /> | Template:BlockLink | |||
| Noise<ref group="s" name="powder-snow-noise-2">Powder snow noise within 0.45~0.58</ref> | No water above | Template:BlockLink | |||
| No water above | Template:BlockLink | ||||
| Template:BiomeLink | Template:BlockLink | ||||
| Template:BiomeLink | Noise<ref group="s" name="powder-snow-noise-2" /> | Above water | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Calcite noise within -0.0125~0.0125 | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Noise<ref group="s" name="gravel-noise">Gravel noise within -0.05~0.05</ref> | Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Surface noise ≥ 4/33 | Template:BlockLink | |||
| Template:BiomeLink Template:BiomeLink Template:BiomeLink Template:BiomeLink |
Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Template:BlockLink | ||||
| Template:BiomeLink | Surface noise ≥ 7/33 | Template:BlockLink | |||
| Template:BiomeLink | Surface noise ≥ 8/33 | Ceiling | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Surface noise ≥ 4/33 | Template:BlockLink | ||||
| Surface noise ≥ -4/33 | Template:BlockLink | ||||
| Ceiling | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink Template:BiomeLink Template:BiomeLink |
Floor with depth and secondary depth 6 | Template:BlockLink | |||
| Template:BiomeLink | Floor with depth and secondary depth 30 | ||||
| Floor<ref name="floor-0" group="s" /> | Template:BiomeLink Template:BiomeLink |
Template:BlockLink | |||
| Template:BiomeLink Template:BiomeLink Template:BiomeLink |
Ceiling | Template:BlockLink | |||
| Otherwise | Template:BlockLink | ||||
| Ceiling | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Below Y=0 and gradient Y=0 → Y=8 | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
The Nether
| Conditions | Result block | ||||
|---|---|---|---|---|---|
| Gradient Y=0 → Y=5 | Template:BlockLink | ||||
| Gradient Y=127 → Y=122 | |||||
| Above Y=122 | Template:BlockLink | ||||
| Template:BiomeLink | Ceiling<ref group="s" name="ceiling-0" /> | Template:BlockLink | |||
| Floor<ref group="s" name="floor-0" /> | Patch noise ≥ -0.012 | Surface between Y=30 and Y=35 | Template:BlockLink | ||
| Nether noise ≥ 0 | |||||
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Ceiling<ref group="s" name="ceiling-0" /> | Nether noise ≥ 0 | Template:BlockLink | ||
| Otherwise | Template:BlockLink | ||||
| Floor<ref group="s" name="floor-0" /> | Patch noise ≥ -0.012 | Surface between Y=30 and Y=35 | Template:BlockLink | ||
| Nether noise ≥ 0 | Template:BlockLink | ||||
| Otherwise | Template:BlockLink | ||||
| Floor<ref group="s" name="floor-0" /> | Below Y=33 | Erosion<ref group="s" name="hole" /> | Template:BlockLink | ||
| Template:BiomeLink | Netherack noise ≥ 0.54 | Above Y=31 | Nether wart noise ≥ 1.17 | Template:BlockLink | |
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Netherack noise ≥ 0.54 | Above Y=31 | Nether wart noise ≥ 1.17 | Template:BlockLink | |
| Otherwise | Template:BlockLink | ||||
| Template:BiomeLink | Floor with depth<ref group="s" name="floor-depth" /> | Soul sand noise ≥ -0.012 | Not erosion<ref group="s" name="hole" /> | Surface between Y=30 and Y=35 | Template:BlockLink |
| Otherwise | Template:BlockLink | ||||
| Floor<ref group="s" name="floor-0" /> | Above Y=31 and surface below Y=35 |
Gravel layer noise ≥ -0.012 | Above Y=32 | Template:BlockLink | |
| Not erosion<ref group="s" name="hole" /> | |||||
| Otherwise | Template:BlockLink | ||||
The End
| Conditions | Result block | ||||
|---|---|---|---|---|---|
| Always | Template:BlockLink | ||||
Carvers
Carvers include carver caves and carver canyons. As the name suggest, they "carve" through the ground.
Carver caves and carver canyons are configured to have different probability to be generated in each chunk. If the carver generates, it carves through the ground in random directions starting at the configured start Y level:
- Carver caves generate from Y=-56 to Y=180. The probability of cave generation is higher at Y=-56 to Y=47. Carver caves sometimes include a main room and can have branches.
- Nether carver caves generate Y=0 to Y=126.
- Canyons can start at levels 10 to 72.
-
A carver cave in the Overworld with a main room.
-
Template:BiomeLink with a Nether carver cave.
-
A canyon in the Overworld.
Structures
Structures are grouped into structure sets. A structure set determines the placement positions of the structures and places a structure at these positions based on the biome. If no structure matches the biome, then no structure is placed at a given position. The structure positions are usually calculated based on the spacing, separation, and frequency parameters of the structure set. Spacing determines the average distance between structure placement position in chunks, and separation determines the minimum distance. Frequency controls the probability that a determined position is used. If the biome at the placement attempt does not match the requirement, the structure is not placed. An exception are strongholds Template:In, which are placed as concentric rings, see Stronghold.
In the structures_starts generation step, the game determines if the chunk is suitable for a structure. If a structure is selected, the starting point of the structure and layout of the pieces is determined. In the structures_references generation step, every chunk near a chunk with a structure start stores a reference to that chunk. This allows finding the structure pieces that are inside each chunk. When a chunk is generating its decoration in the features step, the chunk is checked for a structure reference. If a structure reference is found, the stored pieces are placed in the world. (see #Features).
The following table gives the placement parameters for each structure set, as they are Template:In.
Features
The generation of features and placement of structure pieces (see #Structures) happens in the same step and are called decorations collectively. Each biome has a list of allowed features and structures that are possible to generate in them.
Decoration steps
Features and structures generate in 11 steps after each other called decoration steps.
- Template:Cd: Small end islands
- Template:Cd: Lava lakes
- Template:Cd: Amethyst geodes and icebergs
- Template:Cd: Trial chambers, buried treasure, mineshafts, trail ruins, monster rooms and Minecraft:fossils
- Template:Cd: All other structures, desert wells and blue ice patches
- Template:Cd: Unused, strongholds use the Template:Cd step
- Template:Cd: Ore blobs and sand/gravel/clay disks
- Template:Cd: Infested block blobs, nether gravel and blackstone blobs, and all nether ore blobs
- Template:Cd: Water and lava springs
- Template:Cd: Trees, bamboo, cacti, kelp, and other ground and ocean vegetation
- Template:Cd: Freeze top layer feature
Generation
To generate features in a chunk, the game first determines a list of Minecraft:biomes that appear in that chunk or the 8 surrounding chunks. Using that biome list the game constructs a list of features that are possible to generate in those biomes. For each decoration step, first the matching structure pieces are placed, followed by the features. When a structure piece crosses a chunk border, only the part in the current chunk is placed. Each feature has its own placement rules including the number of placement attempts and where in the chunk should the feature try to be placed. The game follows the rules to select a block in the chunk then checks if the biome, block and its surroundings at the current position allows that feature to spawn, and if so places the feature. Features can place block outside the current chunk's boundaries but are limited in the nearby 3×3 area.
When features are generated, they can spill over into neighboring chunks that have already had their features generated. Thus, the feature order specified above is not always adhered to. It is therefore also possible for two worlds generated with the same seed, from the same version of Minecraft, to differ slightly depending on the players' travel routes, because the chunk generation order may determine which of two conflicting features overwrite or suppress the other.<ref>Template:Bug</ref>
Lighting
As one of the last steps of chunk generation, the light levels for each block are calculated. Before this step, no block placement updates light, and light updates are instead deferred to this step.
Mob spawning
Template:IN many animals generate upon initial chunk creation. One in ten newly-generated chunks attempts to generate animal Minecraft:mobs, usually in packs of up to 4 of the same species.
Template:IN animals do not spawn during chunk generation, but they continually attempt to spawn as part of the environmental spawning algorithm.
Notably, mobs that spawn with a structure (e.g. elder guardian in ocean monuments) are immediately spawned when the structure is placed and are not spawned in this step.
Heightmaps
Template:IN, heightmaps are technically calculated at every step of world generation. Before features are placed, there are only 2 heightmaps – OCEAN_FLOOR_WG and WORLD_SURFACE_WG. After feature placement, OCEAN_FLOOR, WORLD_SURFACE, MOTION_BLOCKING and MOTION_BLOCKING_NO_LEAVES are calculated.
Videos
Videos by Henrik Kniberg: Template:Yt Template:Yt
History
A world generation algorithm has been included in the game since its very inception. World generation was often changed significantly before the release of Java Edition. Notably, after its release, world generation has changed greatly in Java Edition 1.7.2 and Java Edition 1.18. For Minecraft:Bedrock Edition, significant changes were made in Pocket Edition v0.9.0 alpha and Minecraft:Bedrock Edition 1.18.0.
Issues
References
External links
- More information on xoroshiro128++, the PRNG algorithm Minecraft uses for Overworld generation by University of Milan
- More information on Perlin noise by Raouf Touti
de:Weltgenerierung fr:Génération du monde pt:Geração de mundo ru:Генерация мира uk:Генерація світу zh:世界生成