mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2024-12-26 03:07:32 +01:00
Shorten code slightly
This commit is contained in:
parent
e17fab385b
commit
abdd5e11c0
@ -806,8 +806,6 @@ function mcl_core.get_grass_palette_index(pos)
|
|||||||
local reg_biome = mcl_util.get_registered_biome_from_pos(pos)
|
local reg_biome = mcl_util.get_registered_biome_from_pos(pos)
|
||||||
if reg_biome and reg_biome._mcl_grass_palette_index then
|
if reg_biome and reg_biome._mcl_grass_palette_index then
|
||||||
return reg_biome._mcl_grass_palette_index
|
return reg_biome._mcl_grass_palette_index
|
||||||
else
|
|
||||||
return index
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -820,8 +818,6 @@ function mcl_core.get_foliage_palette_index(pos)
|
|||||||
local reg_biome = mcl_util.get_registered_biome_from_pos(pos)
|
local reg_biome = mcl_util.get_registered_biome_from_pos(pos)
|
||||||
if reg_biome and reg_biome._mcl_foliage_palette_index then
|
if reg_biome and reg_biome._mcl_foliage_palette_index then
|
||||||
return reg_biome._mcl_foliage_palette_index
|
return reg_biome._mcl_foliage_palette_index
|
||||||
else
|
|
||||||
return index
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user