mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2024-11-28 13:53:45 +01:00
Make set palette safer
This commit is contained in:
parent
b77260253a
commit
ad25b0bc4b
@ -280,7 +280,7 @@ local function set_palette(minp,maxp,data2,area,biomemap,nodes)
|
|||||||
local bn = minetest.get_biome_name(biomemap[b_pos])
|
local bn = minetest.get_biome_name(biomemap[b_pos])
|
||||||
if bn then
|
if bn then
|
||||||
local biome = minetest.registered_biomes[bn]
|
local biome = minetest.registered_biomes[bn]
|
||||||
if biome and biome._mcl_biome_type then
|
if biome and biome._mcl_biome_type and biome._mcl_grass_palette_index then
|
||||||
data2[p_pos] = biome._mcl_grass_palette_index
|
data2[p_pos] = biome._mcl_grass_palette_index
|
||||||
lvm_used = true
|
lvm_used = true
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user