"11. Ahawks This may be "confidential" information, but I have to ask: As a developer, I am amazed at the amazing world that's created dynamically. Towering mountains, twisting caves opening up to caverns, islands, precious ores sprinkled throughout, etc. Notch, could you explain at a high level how the world generation algorithm does this?
I'm not sure how to explain it without getting technical.. The complicated high level technical version is: First I generate a linearly interpolated 3d perlin noise offset along the y axis. I fill that in so that everything except the top x blocks is stone, then I do a second pass to add features like grass, trees, gravel, sand, caves and flowers. The world is generated in chunks of 16x16x128 blocks, based of pseudorandom seeds that are a mix of the level base seed and the chunk location in the world. This ensures that you always get the same terrain in an area regardless of what direction you traveled there from."
What an interesting application of perlin noise. Anybody aware of any other similar applications?
My master thesis was about "PRNGs in game programming", and I've done 2d side scroller shooter with unlimited world generated on the fly using 2d perlin noise.
If anyone is interested there it is - written in C++ with SDL, libparagui and a few other SDL_* libraries. Probably compiling it will be hard - I've used libparagui that was in gentoo at that time, then I've learned it is patched version, and on other systems older version was in the package managers.
I like to think that 'interesting decisions' are what make any game fun but that alone doesn't explain it... ludology?