Tutorials/Mushroom farming

As of the Beta 1.6 update, mushrooms will slowly multiply to nearby opaque blocks, allowing for the creation of farms. However, the rate at which mushrooms spread is considerably slow; therefore, starting a farm is an ordeal without multiple mushrooms. Because mushrooms will "pop" out of the ground when light level is greater than 12, the farmer must consider carefully the placement of light sources. Mushrooms make this up by being placeable nearly everywhere, and not requiring water, sand or extra space like crops, cacti or saplings.

The main danger in basic mushroom farming is that they must be low-lit indoor rooms, often allowing monsters to spawn in the same area. This can be countered with making the farming area only 1 block high and coating any pathways with Slabs, since mobs cannot spawn on half-blocks. Using Redstone Torches instead of regular ones will also make keeping the light levels tolerable much easier.

Spread Mechanics
Every tick, every mushroom is given a 1/100 chance to do the following:


 * Choose a random block in the 3x3x3 cube centered on the mushroom (the mushroom itself, not the block it's on). This favors the mushroom's own level, the middle 3x3 square: upper and lower levels are given a 1/4 chance each whereas the mushroom's level is given 1/2. If a mushroom could be planted in the chosen block (empty, light <=12, lower block is opaque), do:


 * Choose another random block in the 3x3 square centered on the previously chosen block. If this block could support a mushroom as well, create one there.

Note that the first randomly chosen block can be the mushroom itself, the block it's sitting on, or the block above. The "can be planted" check will fail in all three cases, further reducing the overall spread chance.

The following can be deduced from the algorithm:


 * Mushrooms may spread to two blocks away, though only if a block on the way is free.
 * Mushrooms may spread diagonally in all three axes.