Initialise 'seabed_height' to avoid compilation warning (#8715)
authorParamat <paramat@users.noreply.github.com>
Fri, 26 Jul 2019 16:51:53 +0000 (17:51 +0100)
committerGitHub <noreply@github.com>
Fri, 26 Jul 2019 16:51:53 +0000 (17:51 +0100)
src/mapgen/mapgen_fractal.cpp

index 933958587de27659ffbddf6e34ed068e7ad07d4b..091dbacfa28e9044e35d3a7a851d53a5833af657 100644 (file)
@@ -413,7 +413,7 @@ s16 MapgenFractal::generateTerrain()
                                if (vm->m_data[vi].getContent() != CONTENT_IGNORE)
                                        continue;
 
-                               s16 seabed_height;
+                               s16 seabed_height = -MAX_MAP_GENERATION_LIMIT;
                                if (noise_seabed)
                                        seabed_height = noise_seabed->result[index2d];