Fix swamp trees.
parent
da5af62f87
commit
0734ca73d8
|
@ -33,7 +33,6 @@ do
|
||||||
tree_biomes["taiga"] = {"conifer_trees"}
|
tree_biomes["taiga"] = {"conifer_trees"}
|
||||||
tree_biomes["rainforest"] = {"jungle_trees"}
|
tree_biomes["rainforest"] = {"jungle_trees"}
|
||||||
tree_biomes["rainforest_swamp"] = {"jungle_trees"}
|
tree_biomes["rainforest_swamp"] = {"jungle_trees"}
|
||||||
tree_biomes["deciduous_forest_swamp"] = {"deciduous_trees"}
|
|
||||||
tree_biomes["coniferous_forest"] = {"conifer_trees"}
|
tree_biomes["coniferous_forest"] = {"conifer_trees"}
|
||||||
|
|
||||||
for i, obiome in pairs(minetest.registered_biomes) do
|
for i, obiome in pairs(minetest.registered_biomes) do
|
||||||
|
@ -361,7 +360,7 @@ function loud_walking.generate(p_minp, p_maxp, seed)
|
||||||
local y = minp.y + get_height(x - minp.x, z - minp.z, biomes[biome].terrain_scale, ocean) + ground
|
local y = minp.y + get_height(x - minp.x, z - minp.z, biomes[biome].terrain_scale, ocean) + ground
|
||||||
|
|
||||||
local ivm = a:index(x, y, z)
|
local ivm = a:index(x, y, z)
|
||||||
if data[ivm + a.ystride] == node("air") and (data[ivm] == node("default:dirt") or data[ivm] == node("default:dirt_with_grass") or data[ivm] == node("default:dirt_with_snow")) then
|
if (data[ivm + a.ystride] == node("air") or (swamp and data[ivm + a.ystride] == node("default:water_source"))) and (data[ivm] == node("default:dirt") or data[ivm] == node("default:dirt_with_grass") or data[ivm] == node("default:dirt_with_snow")) then
|
||||||
if biomes[biome].special_trees then
|
if biomes[biome].special_trees then
|
||||||
--print(dump(biomes[biome].special_trees))
|
--print(dump(biomes[biome].special_trees))
|
||||||
local tree_type = biomes[biome].special_trees[math.random(#biomes[biome].special_trees)]
|
local tree_type = biomes[biome].special_trees[math.random(#biomes[biome].special_trees)]
|
||||||
|
|
Loading…
Reference in New Issue