voxel / voxel-land

a terrain generator with grass, dirt, stone, and trees (addon for voxel-engine)
6 stars 2 forks source link

Ore generation #1

Closed deathcap closed 10 years ago

greenlion commented 10 years ago

Should ores be placed naturally?

Real coal occurs in seams, which can be deep, or long, or both. Some coal is found near the surface (anthracite) and other far below the surface (bituminous). Some seams run for tens of miles (these are what coal mines are dug out of). Obviously, kilometer long runs are probably not useful in a game, so at what scale should the ores spawn? I'm thinking that a coal seam shouldn't run more than two chunks long and probably 1/4 chunk high, but there can be multiple seams in an area that can be mined out.

I don't know that much about how other deposits occur. I think that gold and silver are embedded in other rocks, and usually distributed over a small to medium area (you get a low yield of gold or silver per square meter) where other minerals such as iron, tend to be occur in much higher density and over a wide area.

Gold is found in deep mines in some parts of the world, and can be close to the surface in others (this led to the california gold rush). Diamond should sometimes be found near coal, and should probably run in seams too, but be very rare and found deep.

What overall minerals are you planning to have? Minecraft doesn't have a lot of unusual ones, but I'd like to add things like uranium, copper and lead.

Also do you want hydrocarbons? You could collect oil for lamps, or to make gasoline in a special furnace.

deathcap commented 10 years ago

Yeah there's many possibilities here. I like the idea of large but rare ore seams, distinctive places in the world (perhaps biome-specific) you would keep returning to for mining (instead of mining randomly essentially anywhere, though that kind of ore distribution could be useful too). Ideally the ore generation would be modular enough for plugins to add their own (as a 'chunk populator?'), hooking into voxel-land, so we could have all different kinds of ore populators with different techniques.

A few resources for reference:

What overall minerals are you planning to have? Minecraft doesn't have a lot of unusual ones, but I'd like to add things like uranium, copper and lead.

Sounds good. Also tin, especially tin and copper could be useful for many different kind of machines, either by themselves or in the form of bronze or brass. Lead for wires or glass, uranium for nuclear reactors, etc. Unsure of the best way to do this, but I'm thinking the either the related ores would be grouped together in the same plugin, or each ore in its own plugin, so other plugins could using the ores could add them as a dependency.

Also do you want hydrocarbons? You could collect oil for lamps, or to make gasoline in a special furnace.

Definitely at least coal, and oil would also be pretty cool. In playing FTB I really enjoyed finding spouts of oil and pumping them out to refine into diesel, added by the MC mod BuildCraft: http://ftbwiki.org/Oil - oil generates randomly, a black liquid which flows similar to water. A mechanic adding to the exploration aesthetic, as once you find a large spout of oil it could be a good place to settle and use it to power your base. Coal could be refined into coal coke http://railcraft.info/wiki/fuel:coal_coke and creosote, another liquid. http://en.wikipedia.org/wiki/Fractional_distillation? But we would probably need liquids in voxel.js..

deathcap commented 10 years ago

Added a simple implementation of ore generation in the above commits, currently only for coal but intended to be extensible.

(Other references: http://www.minecraftforum.net/topic/1107057-146v2-custom-ore-generation-updated-jan-5th/ http://customoregen.shoutwiki.com/wiki/Category:Distributions http://www.minecraftforge.net/wiki/Tutorials/Ore_Generation)