1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Tune cave noise scales to 6. Fix blobs spflag, now enabled. Update conf.example

This commit is contained in:
paramat 2014-11-09 12:11:24 +00:00 committed by kwolekr
parent 18c583ee0b
commit 10a47b7fee
3 changed files with 25 additions and 20 deletions

View file

@ -42,7 +42,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
FlagDesc flagdesc_mapgen_v5[] = {
//{"blobs", MGV5_BLOBS},
{"blobs", MGV5_BLOBS},
{NULL, 0}
};
@ -70,6 +70,8 @@ MapgenV5::MapgenV5(int mapgenid, MapgenParams *params, EmergeManager *emerge_) {
MapgenV5Params *sp = (MapgenV5Params *)params->sparams;
this->spflags = sp->spflags;
// Terrain noise
noise_filler_depth = new Noise(&sp->np_filler_depth, seed, csize.X, csize.Z);
noise_factor = new Noise(&sp->np_factor, seed, csize.X, csize.Z);
@ -134,31 +136,32 @@ MapgenV5::~MapgenV5() {
MapgenV5Params::MapgenV5Params() {
//spflags = MGV5_BLOBS;
spflags = 0;
spflags = MGV5_BLOBS;
np_filler_depth = NoiseParams(0, 1, v3f(150, 150, 150), 261, 4, 0.7);
np_factor = NoiseParams(0, 1, v3f(250, 250, 250), 920381, 3, 0.45);
np_height = NoiseParams(0, 10, v3f(250, 250, 250), 84174, 4, 0.5);
np_cave1 = NoiseParams(0, 7.5, v3f(50, 50, 50), 52534, 4, 0.5);
np_cave2 = NoiseParams(0, 7.5, v3f(50, 50, 50), 10325, 4, 0.5);
np_ground = NoiseParams(0, 40, v3f(80, 80, 80), 983240, 4, 0.55);
np_crumble = NoiseParams(0, 1, v3f(20, 20, 20), 34413, 3, 1.3);
np_wetness = NoiseParams(0, 1, v3f(40, 40, 40), 32474, 4, 1.1);
np_filler_depth = NoiseParams(0, 1, v3f(150, 150, 150), 261, 4, 0.7);
np_factor = NoiseParams(0, 1, v3f(250, 250, 250), 920381, 3, 0.45);
np_height = NoiseParams(0, 10, v3f(250, 250, 250), 84174, 4, 0.5);
np_cave1 = NoiseParams(0, 6, v3f(50, 50, 50), 52534, 4, 0.5);
np_cave2 = NoiseParams(0, 6, v3f(50, 50, 50), 10325, 4, 0.5);
np_ground = NoiseParams(0, 40, v3f(80, 80, 80), 983240, 4, 0.55);
np_crumble = NoiseParams(0, 1, v3f(20, 20, 20), 34413, 3, 1.3);
np_wetness = NoiseParams(0, 1, v3f(40, 40, 40), 32474, 4, 1.1);
}
// Current caves noise scale default is 6 to compensate for new eased 3d noise amplitude
// Scaling the output of the noise function affects the overdrive of the
// contour function, which affects the shape of the output considerably.
//#define CAVE_NOISE_SCALE 12.0 < original default
//#define CAVE_NOISE_SCALE 10.0
//#define CAVE_NOISE_SCALE 7.5 < current default to compensate for new eased 3d noise
//#define CAVE_NOISE_SCALE 7.5
//#define CAVE_NOISE_SCALE 5.0
//#define CAVE_NOISE_SCALE 1.0
//#define CAVE_NOISE_THRESHOLD (2.5/CAVE_NOISE_SCALE)
//#define CAVE_NOISE_THRESHOLD (1.5/CAVE_NOISE_SCALE) < original and current default
//#define CAVE_NOISE_THRESHOLD (1.5/CAVE_NOISE_SCALE) < original and current code
void MapgenV5Params::readParams(Settings *settings) {
@ -222,9 +225,9 @@ void MapgenV5::makeChunk(BlockMakeData *data) {
updateHeightmap(node_min, node_max);
// Generate underground dirt, sand, gravel and lava blobs
//if (spflags & MGV5_BLOBS) {
if (spflags & MGV5_BLOBS) {
generateBlobs();
//}
}
// Calculate biomes
BiomeNoiseInput binput;
@ -290,10 +293,10 @@ void MapgenV5::calculateNoise() {
noise_ground->perlinMap3D(x, y, z, true);
noise_ground->transformNoiseMap();
//if (spflags & MGV5_BLOBS) {
if (spflags & MGV5_BLOBS) {
noise_crumble->perlinMap3D(x, y, z, true);
noise_wetness->perlinMap3D(x, y, z, false);
//}
}
noise_heat->perlinMap2D(x, z);
noise_humidity->perlinMap2D(x, z);