Biome API: Make fallback biome stone and water, disable filler
authorparamat <mat.gregory@virginmedia.com>
Sun, 2 Aug 2015 00:35:05 +0000 (01:35 +0100)
committerparamat <mat.gregory@virginmedia.com>
Mon, 3 Aug 2015 01:34:32 +0000 (02:34 +0100)
src/mg_biome.cpp
src/script/lua_api/l_mapgen.cpp

index a21d99b171033bed4baee603708d3761e468e8e3..055ce01982c35e36af1ba2d7895bf2b2e0e8be6c 100644 (file)
@@ -43,15 +43,15 @@ BiomeManager::BiomeManager(IGameDef *gamedef) :
        b->name            = "Default";
        b->flags           = 0;
        b->depth_top       = 0;
-       b->depth_filler    = 0;
+       b->depth_filler    = -MAX_MAP_GENERATION_LIMIT;
        b->depth_water_top = 0;
        b->y_min           = -MAX_MAP_GENERATION_LIMIT;
        b->y_max           = MAX_MAP_GENERATION_LIMIT;
        b->heat_point      = 0.0;
        b->humidity_point  = 0.0;
 
-       b->m_nodenames.push_back("air");
-       b->m_nodenames.push_back("air");
+       b->m_nodenames.push_back("mapgen_stone");
+       b->m_nodenames.push_back("mapgen_stone");
        b->m_nodenames.push_back("mapgen_stone");
        b->m_nodenames.push_back("mapgen_water_source");
        b->m_nodenames.push_back("mapgen_water_source");
@@ -132,8 +132,8 @@ void BiomeManager::clear()
 
 void Biome::resolveNodeNames()
 {
-       getIdFromNrBacklog(&c_top,         "mapgen_dirt_with_grass",    CONTENT_AIR);
-       getIdFromNrBacklog(&c_filler,      "mapgen_dirt",               CONTENT_AIR);
+       getIdFromNrBacklog(&c_top,         "mapgen_stone",              CONTENT_AIR);
+       getIdFromNrBacklog(&c_filler,      "mapgen_stone",              CONTENT_AIR);
        getIdFromNrBacklog(&c_stone,       "mapgen_stone",              CONTENT_AIR);
        getIdFromNrBacklog(&c_water_top,   "mapgen_water_source",       CONTENT_AIR);
        getIdFromNrBacklog(&c_water,       "mapgen_water_source",       CONTENT_AIR);
index bf5e3631ebfc22b0ae27747d3c795ec117857fb8..d30b680548e1bd9522d4f9d8625b1f2796266942 100644 (file)
@@ -374,8 +374,8 @@ Biome *read_biome_def(lua_State *L, int index, INodeDefManager *ndef)
        Biome *b = BiomeManager::create(biometype);
 
        b->name            = getstringfield_default(L, index, "name", "");
-       b->depth_top       = getintfield_default(L,    index, "depth_top",       1);
-       b->depth_filler    = getintfield_default(L,    index, "depth_filler",    2);
+       b->depth_top       = getintfield_default(L,    index, "depth_top",       0);
+       b->depth_filler    = getintfield_default(L,    index, "depth_filler",    -31000);
        b->depth_water_top = getintfield_default(L,    index, "depth_water_top", 0);
        b->y_min           = getintfield_default(L,    index, "y_min",           -31000);
        b->y_max           = getintfield_default(L,    index, "y_max",           31000);