mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Biomes: Add 'min_pos'/'max_pos' xyz biome limits
'y_min' and 'y_max' are still accepted for compatibility.
This commit is contained in:
parent
c7c03ad7a6
commit
cbb9301bea
4 changed files with 47 additions and 34 deletions
|
@ -693,7 +693,7 @@ void MapgenBasic::generateBiomes(MgStoneType *mgstone_type,
|
|||
|
||||
if (is_stone_surface || is_water_surface) {
|
||||
// (Re)calculate biome
|
||||
biome = biomegen->getBiomeAtIndex(index, y);
|
||||
biome = biomegen->getBiomeAtIndex(index, v3s16(x, y, z));
|
||||
|
||||
if (biomemap[index] == BIOME_NONE && is_stone_surface)
|
||||
biomemap[index] = biome->index;
|
||||
|
@ -704,7 +704,7 @@ void MapgenBasic::generateBiomes(MgStoneType *mgstone_type,
|
|||
noise_filler_depth->result[index], 0.0f);
|
||||
depth_water_top = biome->depth_water_top;
|
||||
depth_riverbed = biome->depth_riverbed;
|
||||
biome_y_min = biome->y_min;
|
||||
biome_y_min = biome->min_pos.Y;
|
||||
|
||||
// Detect stone type for dungeons during every biome calculation.
|
||||
// If none detected the last selected biome stone is chosen.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue