mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Schematic decorations: Add 'place_offset_y' placement parameter
For precise control of schematic vertical position relative to the 'place_on' node. Avoids workarounds that add empty nodes to a schematic and therefore reduce performance. Also remove long-unused decoration cutoff code.
This commit is contained in:
parent
557bbc6704
commit
51002b1629
4 changed files with 27 additions and 83 deletions
|
@ -1018,6 +1018,8 @@ bool read_deco_schematic(lua_State *L, SchematicManager *schemmgr, DecoSchematic
|
|||
deco->rotation = (Rotation)getenumfield(L, index, "rotation",
|
||||
ModApiMapgen::es_Rotation, ROTATE_0);
|
||||
|
||||
deco->place_offset_y = getintfield_default(L, index, "place_offset_y", 0);
|
||||
|
||||
StringMap replace_names;
|
||||
lua_getfield(L, index, "replacements");
|
||||
if (lua_istable(L, -1))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue