Light
Light (or lighting) in Minecraft affects visibility, mob spawning, and plant growth.
Περιεχόμενα
Brightness[επεξεργασία | επεξεργασία κώδικα]
There are 16 light levels, which are specified by an integer from 0 (the minimum) to 15 (the maximum). The game uses the light level of a block to compute the brightness of a given block.
The brightness of a block depends on both the level of light from other blocks and the level of sky light. Note "sky light" here is not reduced at night, instead the brightness curve itself changes based on the time. In this it matches the sky lighting value on the debug screen.
In general, lighting due to blocks results in a higher brightness, which is balanced by the fact that light due to blocks effectively starts at 14 (solid light-source blocks emit a level of 15, but that's for the light source block itself) while sky-light brightness is 15 outdoors. Light due to blocks also tends towards orange in the middle ranges, while sky light in the Overworld daytime is white.
In the Overworld with the "Moody" brightness setting, full daylight reaches 98% brightness,[luma 1] while at night brightness is reduced to about 17%[luma 1] and is shaded blue. Full darkness is about 5% brightness.[luma 1]
In the Nether, sky lighting doesn't play a role since there is no source of sky light (although if there were, it would reach about 99% brightness.[luma 1]) Full darkness with the "Moody" brightness setting is at about 25% brightness,[luma 1] which is only slightly darker than a block light level of 7 and no sky light in the Overworld, and is shaded orange like block light.
In the End, sky lighting wouldn't play a role even if there were a source of sky light; this can also be seen if lightning is summoned in the End, there is no flash of brightness like there is in other dimensions. Full darkness in the End with the "Moody" brightness setting is about 28% brightness,[luma 1] and is shaded towards a bluish-green rather than the orange of the Nether and of block lighting.
Spread[επεξεργασία | επεξεργασία κώδικα]
T | 13 | 12 | 11 | 10 | 9 | 8 | 9 | 10 | 11 | 12 | 13 | T |
13 | 12 | 11 | 10 | 9 | 8 | 9 | 8 | 9 | 10 | 11 | 12 | 13 |
12 | 11 | 10 | 9 | 8 | 9 | 10 | 9 | 8 | 9 | 10 | 11 | 12 |
11 | 10 | 9 | 8 | 9 | 10 | 11 | 10 | 9 | 8 | 9 | 10 | 11 |
10 | 9 | 8 | 9 | 10 | 11 | 12 | 11 | 10 | 9 | 8 | 9 | 10 |
9 | 8 | 9 | 10 | 11 | 12 | 13 | 12 | 11 | 10 | 9 | 8 | 9 |
8 | 9 | 10 | 11 | 12 | 13 | T | 13 | 12 | 11 | 10 | 9 | 8 |
The light from light-emitting blocks decreases by one light-level for each meter (block) of distance from the light source. Note that this applies to each of the 3 axes including N/S, E/W, and up/down. This fact is significant for preventing hostile mob spawning. If a torch (level 14) is placed on a wall two blocks up from the floor, the light level on the floor one block away from the wall will be 11 (e.g. 14 minus 2 down, minus 1 south). If the torch were placed on the floor at floor level, then the light level on the floor one block away from the wall will be 13 (e.g. 14 minus 0 down, minus 1 south).
Light decreases diagonally by "taxicab distance", or the sum of the distance along each axis. This means that if a torch (level 14) is placed on the floor, the light level on the adjacent floor blocks in all four direction will be 13 while the diagonal blocks in all four directions will have light level 12 (e.g. 14 minus 1 south, minus 1 east). Along a floor, this effect produces a diamond-shaped pattern of illumination around the light source. Remember, light decrease takes place in three dimensions. This means that if a torch (level 14) is placed on a wall one block up from the floor, then the block on the floor that is diagonally one block way will have a light level of 11 (e.g. 14 minus 1 south, minus 1 east, minus 1 down).
Sources of light[επεξεργασία | επεξεργασία κώδικα]

Blocks[επεξεργασία | επεξεργασία κώδικα]
The following values are the brightness of the block itself:
Icon | Block | Light Level |
---|---|---|
![]() |
Beacon | 15 |
![]() |
End Portal (block) | 15 |
![]() |
Fire | 15 |
![]() |
Glowstone | 15 |
25px | Jack o'Lantern | 15 |
![]() |
Lava | 15 |
25px | Redstone Lamp, when powered | 15 |
![]() |
Sea Lantern | 15 |
![]() |
End Rod | 14 |
![]() |
Torch | 14 |
25px | Furnace, when active | 13 |
![]() |
Glowing Obsidian | 12 |
25px | Nether Portal (block) | 11 |
![]() |
Redstone Ore, when touched | 9 |
![]() |
Ender Chest | 7 |
25px | Redstone Torch, when on | 7 |
![]() |
Magma Block | 3 |
![]() |
Brewing Stand | 1 |
![]() |
Brown Mushroom | 1 |
![]() |
Dragon Egg | 1 |
![]() |
End Portal Frame | 1 |
Other[επεξεργασία | επεξεργασία κώδικα]
Icon | Source | Light Level |
---|---|---|
Sunlight | 15 | |
Sunlight, during Rain or Snowfall | 12 | |
Sunlight, during a Thunderstorm | 10[storm 1] | |
Moonlight | 4 |
- ↑ During thunderstorms, hostile mobs are allowed to spawn as if the sky light level were actually 5.
Light-filtering blocks[επεξεργασία | επεξεργασία κώδικα]
Opaque blocks prevent the spread of light; a 21×21 square of opaque material is enough to spawn mobs in the shadow underneath. By contrast, some transparent blocks such as glass and portal interiors have no effect on light level. All other transparent blocks reduce the spread of light.
Leaves and cobwebs do not have any extra effect on block light, but they do diffuse sky light. The light level from sunlight or moonlight is the same in each block of air in the column of air above the highest obstruction in the column. When placed, leaves and cobwebs obstruct that light column so that the lowest air block above the leaves acts as other light sources do. As you descend below the leaves, the light level diminishes with distance like it would from other light sources such as torches. To control this effect, create an opaque 1×1 chimney with leaves at its opening above you.
The following values are the amount each block decreases the light value. The light emitted decreases by one for each block of distance from the light source, more depending on the block through which it passes.
Icon | Block | Amount of decrease |
---|---|---|
![]() |
Farmland | Full decrease as if opaque |
![]() |
Slab | |
![]() |
Stairs | |
![]() |
Ice | 2 |
![]() |
Water | |
25px | Cobweb | None, but diffuses sky light at the top-most block |
25px | Leaves |
Effects of light[επεξεργασία | επεξεργασία κώδικα]
Note: Keep in mind that light level is only one of the considerations that apply to mob spawning and plant growth.
Mobs[επεξεργασία | επεξεργασία κώδικα]
Level 0–3 | Level 4-7 | Level 8 | Level 9 | Level 10 | Level 11 | Level 12 | Level 13–15 | |
---|---|---|---|---|---|---|---|---|
Bats | Spawn at y: 0-62 | Spawn at y: 0-62 from October 20th to November 3rd | Do not spawn | |||||
Blazes | Spawn in Nether Fortresses | Hostile, do not spawn | ||||||
Wither skeletons | Spawn in Nether Fortresses | Hostile, do not spawn | ||||||
Silverfish[note 1] | Spawn in the Overworld | Hostile, do not spawn | ||||||
Slimes | Spawn in swamp biomes at y: 51–69 | Spawn in certain chunks in most biomes (except mushroom island, the Nether, the End, and the Void) at y: 0–40 | ||||||
Zombies Skeletons |
Spawn in the Overworld | Hostile, do not spawn | Hostile, burns in sunlight | |||||
Creepers Witches |
Spawn in the Overworld | Hostile, do not spawn | ||||||
Spiders Cave spiders |
Spawn in the Overworld | Hostile, do not spawn | Do not spawn, neutral unless provoked | |||||
Endermen | Spawn in the Overworld, the Nether and the End | Do not spawn, neutral unless provoked | Do not spawn, teleports randomly and often ignores players when in sunlight |
- ↑ These restrictions only apply when spawning from a monster spawner, and not from a Silverfish block.
Blocks[επεξεργασία | επεξεργασία κώδικα]
Level 0–3 | Level 4-7 | Level 8 | Level 9 | Level 10 | Level 11 | Level 12 | Level 13–15 | |
---|---|---|---|---|---|---|---|---|
Snow layers Ice[note 1] |
Forms, does not melt | Forms and melts | Melts | |||||
Mushrooms | Spread | Uproot unless on mycelium or podzol | ||||||
Saplings Pumpkin or Melon stems [note 2] |
Does not grow | Grows | ||||||
Wheat Carrots Potatoes Beetroots[note 3] |
Uproot | Does not grow | Grows | |||||
Grass Block Mycelium[note 4] |
Becomes dirt if opaque block or partially transparent block on top | Does not spread | Spreads to nearby dirt (see below) | |||||
Dirt[note 4] | Does not accept spread | Accepts spread if no opaque or partially transparent block on top |
- ↑ Sunlight does not affect snow and ice. The relevant light level is what would be in the block if it were air.
- ↑ For growth, the relevant light level is that in the block above the plant. The growth of pumpkins or melons from a stem checks the light above the stem, not the block where the pumpkin or melon grows.
- ↑ For growth, the relevant light level is that in the block above the plant. For uprooting, the relevant light level is the plant block itself.
- ↑ a b The relevant light level is that in the air block above it. "Partially transparent" blocks are those that reduce light by at least 3 levels (2 in addition to the normal propagation reduction), such as water or ice.
Other[επεξεργασία | επεξεργασία κώδικα]
Level 0–3 | Level 4-7 | Level 8 | Level 9 | Level 10 | Level 11 | Level 12 | Level 13–15 | |
---|---|---|---|---|---|---|---|---|
Ambience | On | Off |
Smooth lighting[επεξεργασία | επεξεργασία κώδικα]
Smooth lighting (which includes ambient occlusion as well as interpolating lighting across block faces) is a lighting engine that blends light levels and darkens corners to add semi-realistic shadows and glowing from light sources.
This lighting engine is set on by default, and can be set to minimum, maximum, or off by accessing Video Options from the Options menu.
Video[επεξεργασία | επεξεργασία κώδικα]
History[επεξεργασία | επεξεργασία κώδικα]
Classic | ||||
---|---|---|---|---|
? | The lighting engine in Classic was very simple, since there were only two light levels, bright and dark. "Sunlight" is emitted by the top edge of the map and will hit any block that is under it, regardless of distance. It will pass through transparent blocks to light blocks underneath. Blocks that do not receive light are in a dim shadow that remains at the same level of brightness no matter how far they are from a light source. | |||
Indev | ||||
0.31 | Added 16 degrees of brightness, with a maximum of 15 for full daylight and a minimum of 0 for almost complete darkness. Brightness is a linear scale and represents its value divided by 15; for example 15 is 100% (15⁄15) and 13 is 86.67% (13⁄15). | |||
Sunlight now has a maximum light value of 15, and steadily decreases from dusk, until it reaches a night-time minimum value of 4, representing moonlight. | ||||
Alpha | ||||
? | Lighting is no longer linear. | |||
Each brightness value below 15 is 80% as bright as the one above it. For example, 14 is 80% as bright as 15, and 13 is 64% as bright as 15. | ||||
Sunlight now has its own light array and optimizations to make dawn and dusk smoother. During dusk, nighttime, and dawn, a "darkness" value is subtracted from the sky to create the effects of different times of day. | ||||
1.2.0 | Halloween Update | Added the Nether, where light decreases by 10% each level, rather than the normal 20%. | ||
Hostile mobs could spawn in higher light levels at lower depths, using the formula 16 − (Layer / 8). At level 8 and below, mobs could spawn even in sunlight. | ||||
1.2.1 | Notch reverted mob spawning to the original method, saying, "It was way too annoying. I have plans on what to do with this." | |||
Beta | ||||
1.3 | Smooth lighting engine added with the help of MrMessiah.[1] | |||
1.8 | Implemented a new lighting engine. The lighting on a block is given a tint based on the most prominent source of light. | |||
Day/night cycles no longer require chunk updates and is a smooth transition. | ||||
Artificial light now gives a very subtle "flicker." | ||||
Added void fog, which increases darkness at extreme depths. | ||||
Official release | ||||
1.4.2 | 12w39a | Dinnerbone fixed black patches in world generation,[2] and began overhauling the lighting systems such as changing the lighting of blocks to allow for directional lighting.[3][4] | ||
1.5 | 13w05a | Improved lighting interaction with stairs. | ||
13w06a | Several lighting optimizations. | |||
13w09a | Added three different levels of smooth lighting: Off, Minimum, and Maximum. Minimum uses the old Smooth Lighting, and Maximum fixes a bug with stairs. | |||
1.7.2 | Black patches in world generation and structure generation were made a lot less common.[5] | |||
1.8 | 14w30a | The lighting engine was significantly improved, removing most black spots present in world generation. | ||
14w34c | The void fog and particles were removed in order to improve performance. | |||
Redstone repeaters no longer emit light. |
Issues[επεξεργασία | επεξεργασία κώδικα]
Issues relating to “Light” are maintained on the issue tracker. Report issues there.
Trivia[επεξεργασία | επεξεργασία κώδικα]
- In Minecraft's source code, the luminescences are defined using the floating point values in the third column. In a weird quirk, these floating point numbers are fractions of 16, but are multiplied by 15 to get the integer light value.
- This means that both 0/16 and 1/16 (0.0 and 0.0625) correspond to the integer light value 0.
Gallery[επεξεργασία | επεξεργασία κώδικα]
- 2012-03-11 15.00.48.png
Lighting, the wool block is exposed to sunlight ("Moody" brightness setting).
- 2012-03-11 15.00.53.png
Lighting, the wool block is exposed to sunlight ("Bright" brightness setting).
References[επεξεργασία | επεξεργασία κώδικα]
- ↑ http://notch.tumblr.com/post/3446675806/minecraft-beta-1-3
- ↑ https://twitter.com/Dinnerbone/status/250952827608915969
- ↑ https://twitter.com/Dinnerbone/status/250904989885661184
- ↑ http://www.reddit.com/r/Minecraft/comments/10g4mi/dinnerbone_at_this_point_i_think_its_almost/
- ↑ https://twitter.com/jeb_/status/362559336033165312