diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mapgen.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mapgen.cpp b/src/mapgen.cpp index 6f3ea7cb0..b6e8c0fd1 100644 --- a/src/mapgen.cpp +++ b/src/mapgen.cpp @@ -1003,8 +1003,11 @@ void MapgenParams::readParams(const Settings *settings) } std::string mg_name; - if (settings->getNoEx("mg_name", mg_name)) - this->mgtype = Mapgen::getMapgenType(mg_name); + if (settings->getNoEx("mg_name", mg_name)) { + mgtype = Mapgen::getMapgenType(mg_name); + if (mgtype == MAPGEN_INVALID) + mgtype = MAPGEN_DEFAULT; + } settings->getS16NoEx("water_level", water_level); settings->getS16NoEx("mapgen_limit", mapgen_limit); |