Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Tall schematic decorations unnecessarily failing near chunk top #4401
^ Jungletrees missing at y = 126 and y = 127
Decoration placement is coded to fail if decoration height exceeds 16 nodes above the mapchunk top (exceeds the volume of the mapgen voxelmanip). placeDeco() looks up the height of simple decorations https://github.com/minetest/minetest/blob/master/src/mg_decoration.cpp#L148 but when it looks up the height of a schematic decoration https://github.com/minetest/minetest/blob/master/src/mg_decoration.cpp#L371 the height of the decoration is returned, but this doesn't take into account how schematics are placed sunk 1 node into the ground, or how 'place centre y' can place the schematic centre at ground level.
For jungletrees i was careful to keep their height within 16 nodes above mapchunk top, but they are sunk 1 node into the ground meaning their total height is 17 nodes
does not allow placement in this case. There is also an error, the comparison should be '>'.