1
0

Noise3D: Fixed missing initialization.

This should fix terrain being at Y=0 or Y=255 for the spawn chunk.
Fixes #1433.
This commit is contained in:
Mattes D
2014-12-01 00:08:44 +01:00
parent e972c52e54
commit f0ad6221c3

View File

@@ -529,7 +529,9 @@ cBiomalNoise3DComposable::cBiomalNoise3DComposable(int a_Seed, cBiomeGenPtr a_Bi
m_DensityNoiseA(a_Seed + 1),
m_DensityNoiseB(a_Seed + 2),
m_BaseNoise(a_Seed + 3),
m_BiomeGen(a_BiomeGen)
m_BiomeGen(a_BiomeGen),
m_LastChunkX(0x7fffffff), // Set impossible coords for the chunk so that it's always considered stale
m_LastChunkZ(0x7fffffff)
{
// Generate the weight distribution for summing up neighboring biomes:
m_WeightSum = 0;