Mineshaft



Abandoned mine shafts are naturally generated structures that generate in the Overworld. They were added in the adventure update, along with strongholds and NPC villages.

Structure
Abandoned mine shafts consist of:
 * A starting point - a large room with a flat dirt floor, an arched ceiling and up to four exits (one in each direction).
 * Corridors - 3×3 block corridors featuring supports made from fences and wooden planks (sometimes complementary with torches), broken rails, chests (containing resources) and cave spider spawners surrounded by cobwebs.
 * Crossings - intersections with wooden pillars, sometimes two floors tall.
 * Staircases - diagonal sections of tunnel.

The generator continues to add pieces onto an exit until it reaches a "depth" of 8 (eight pieces from an exit).

Abandoned mine shafts are generated before chunk features such as ores. As with other features, multiple abandoned mine shafts can generate near each other and intersect, producing larger complexes. They can also intersect with other cave systems, notably ravines. Corridors will generate a floor of wooden planks if they cross over empty space.

Obtainable items

 * Diamond
 * Coal
 * Lapis Lazuli
 * Redstone Dust
 * Iron Ingot
 * Gold Ingot
 * Melon Seeds
 * Pumpkin Seeds
 * Bread
 * Rails
 * Iron Pickaxe
 * Wooden Planks
 * Fences
 * String

Chest contents
Each chest contains 3-6 stacks of items, chosen from the following list. Chance listed is per stack, not for the chest as a whole.

Exploration
Mine shafts can be easily found in ravines or large caves, where it is likely that a mine shaft will intersect them. In ocean biomes it is possible to find the upper part of the shaft complex exposed to water at some of the sections.

Abandoned mine shafts may be large and be akin to mazes, making it difficult to keep bearings. The venomous Cave Spiders are common and make exploration dangerous unless prepared. However, due to automatically placed torches, the presence of other mobs is much lower, making areas aside from the Spider spawners safer than caves.

Gravel sometimes collapses into shafts, making them appear to be dead ends. Dig a few blocks past gravel walls to check if the shaft continues or not.

Using the large amount of resources found in abandoned mine shafts, the player may cut down cobwebs to collect string (then craft that into wool), take out wood and fence posts from the supports, and create a safe room with a bed within the shafts. (This lets you respawn nearer your death, making it much more likely to recover your possessions.) It's also a popular choice to include a crafting table and a furnace in the safe room. This makes exploration easier, although becoming lost means losing resources within the room and possibly death from the Cave Spiders or other hazards within the elaborate structure. One should put caution before anything else when exploring these locations. If the need of food arises, melon seeds and wheat are found in loot chests and water can be found in caves around the mine. It is also likely to find bread in the chests as well. Also, if you don't feel like enduring the monster encounters or worrying about hunger, you can always set to peaceful mode.

The minecart tracks can be repaired, and you can collect them by pickaxe, or pour a bucket of water on top of them. The mine shaft can be used for mining of your own, after it is cleaned up and rid of mob spawners.

How to explore
Abandoned mine shafts can be extremely difficult to explore, especially since some can be cut in half through ravines, though this is made easier by the bridges added in 1.2. The easiest ways to get the most out of an abandoned mine shaft without a ravine going through it is the following. Skip to the next part if you have found an abandoned mine shaft with a ravine cutting through it.

The first thing one should do when finding an abandoned mineshaft is to walk through the mine shaft, but make sure everywhere you go, the hall is well lit with torches. This helps locate all minerals present like iron ore, or coal, which may be embedded in the wall. Having multiple redundant sets of tools, weapons, and stacks of dirt/cobblestone (or any block not affected by gravity) is also beneficial. Valuable blocks and chests can often be found in difficult to access areas due to the mine's random generated nature. It is commonly required to build bridges or staircases to access all the areas within an abandoned mine shaft.

Because of the labyrinth-like characteristics of abandoned mine shafts, it is recommended to leave indication of where the exit routes are. (Such as a cobblestone or two adjacent torches.) Due to the repeating layouts and multiple floors, becoming lost and walking in circles is easier than in a cave. Another way to keep track of explored areas is to harvest the fence posts, so it is obvious which areas were cleared. You can then use the fence posts to block off unexplored regions so you don't end up with mobs coming from behind you. Still another way to mark your path is to pick up and reset the minecart tracks the shaft provides—with two or three (and sometimes as few as one) tile of track, you can indicate direction. Rails have an advantage over torches as breadcrumbs, in that they serve only one purpose, whereas torches provide necessary light, and may be left in places that could confuse your return path. Another option is to use redstone torches, as rails are generated naturally and will not be confused with normal torches. If Lapis Lazuli ore is present, you can use it on wool made from cobweb string. With bone meal from skeletons, you can also make light blue wool. Both are fairly distinctive and can be used for markers.

It is also somewhat common for mine shafts to intersect ravines, caves, and other underground structures, and therefore contact with lava is a potential hazard.

An easy way to explore these caverns is to block explored areas of the mineshaft, this way it is easier to not get lost. Also, you could use a few signs to remind yourself where you're going.

Bugs

 * If an abandoned mine shaft intersects with a dungeon, then it may destroy the dungeon's chests, causing the contents to fall to the ground.
 * When the mineshafts are being generated, there is likely to be a spot where two shafts are generated on top of each other, creating a very annoying obstacle if you are attempting to traverse the top shaft.
 * Sometimes, some of the randomly placed torches will not give off light but will still give off flame particles.
 * There may be flowers, grass blocks, and tall grass growing in the dirt room, even if it is nowhere near the surface.
 * Sometimes a chest generated in an abandoned mine shaft might be empty.
 * In extremely rare cases, a mineshaft might be generated above ground with a lighting glitch so that it appears that the shaft is underground. This will cause monsters to spawn even in daylight.

Trivia

 * Entrances to mine shafts can also appear underwater, causing the mine shaft to flood.
 * Sometimes torches may not be attached to blocks but still give off light.
 * A chest might be generated right next to another one, creating a naturally occurring large chest.
 * When Generated at bedrock layer Abandoned Mineshafts will cut through bedrock. It is currently unknown if it can cut through the last layer of bedrock.
 * Due to how deep the shafts can go, it is possible to find exposed veins of diamond ore in corridors.