Closed MostAwesomeDude closed 13 years ago
http://archive.gamedev.net/community/forums/mod/journal/journal.asp?jn=259175 is a decent approach. Note that his "multiridged fractal" is just a folded noise map. The big problem with this is that it requires around 8 octaves of 3D noise for every occupied block in the chunk, which is an awful lot.
And considering that 3d noise is a bit sluggish in bravo, 8 layers of its seem a bit.. expensive. I was considering using cellular automata to make caves. Dig out an area, and branch off, moving in random directions. The upside to this is it's fairly easy, the downside is, its also fairly random. Heres the technique http://properundead.com/2009/03/cave-generator.html
Well, 3D noise is only slightly spendier than 2D noise, and in fact runs faster on most of my machines for some reason I don't understand. (Not a lot faster, but enough to confuse me.) The main cost is in doing it for every block (up to 32k per chunk) rather than every column (up to 256 per chunk).
Caves have been added, using a pair of noise fields per column to fake 3D regions fairly convincingly. Some fine-tuning probably still needs to take place, but the main code is there, so I'm closing this.
I have some code somewhere that I made that could take a list of coordinates and an offset, and split them into chunks... The aim was to make it easy for a generator to generate a large structure, send it to this splitter, and then modify the chunks.