1
0
Fork 0

Adjust palette foliage check

The excessive 128 blocks high check has been changed to now check only up to 30 blocks, since the tallest 2x2 jungle tree I seemed to get was only 29 blocks tall.

I also discovered that the search area wasn't wide enough, so sometimes the most outer leaves avoided the check. I also adjusted that.
texture_conversion_wool
FossFanatic 2023-02-11 07:53:12 +00:00
parent 1fb300ef18
commit 81dbdaab94
1 changed files with 1 additions and 1 deletions

View File

@ -1110,7 +1110,7 @@ local grow_spruce = sapling_grow_action(SPRUCE_TREE_ID, 1, true, true, "mcl_core
local grow_birch = sapling_grow_action(BIRCH_TREE_ID, 1, true, false)
function mcl_core.update_sapling_foliage_colors(pos)
local pos1, pos2 = vector.offset(pos, -6, 0, -6), vector.offset(pos, 6, 128, 6)
local pos1, pos2 = vector.offset(pos, -8, 0, -8), vector.offset(pos, 8, 30, 8)
local fnode
local foliage = minetest.find_nodes_in_area(pos1, pos2, {"group:foliage_palette", "group:foliage_palette_wallmounted"})
for _, fpos in pairs(foliage) do