Vertical biome blend: Tune PRNG seed for finer detail (#7329)

This commit is contained in:
Paramat 2018-05-14 19:01:58 +01:00 committed by GitHub
parent 0cecc1d1a9
commit a01a9ca24c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -142,7 +142,7 @@ Biome *BiomeManager::getBiomeFromNoiseOriginal(float heat, float humidity, v3s16
} }
} }
mysrand(pos.Y + (heat + humidity) / 2); mysrand(pos.Y + (heat + humidity) * 0.9f);
if (biome_closest_blend && dist_min_blend <= dist_min && if (biome_closest_blend && dist_min_blend <= dist_min &&
myrand_range(0, biome_closest_blend->vertical_blend) >= myrand_range(0, biome_closest_blend->vertical_blend) >=
pos.Y - biome_closest_blend->max_pos.Y) pos.Y - biome_closest_blend->max_pos.Y)
@ -302,7 +302,7 @@ Biome *BiomeGenOriginal::calcBiomeFromNoise(float heat, float humidity, v3s16 po
// Carefully tune pseudorandom seed variation to avoid single node dither // Carefully tune pseudorandom seed variation to avoid single node dither
// and create larger scale blending patterns similar to horizontal biome // and create larger scale blending patterns similar to horizontal biome
// blend. // blend.
mysrand(pos.Y + (heat + humidity) / 2); mysrand(pos.Y + (heat + humidity) * 0.9f);
if (biome_closest_blend && dist_min_blend <= dist_min && if (biome_closest_blend && dist_min_blend <= dist_min &&
myrand_range(0, biome_closest_blend->vertical_blend) >= myrand_range(0, biome_closest_blend->vertical_blend) >=