Schematics: Fix minetest.place_schematic() when defined by a Lua table
parent
60feb4ad25
commit
390c0cd691
|
@ -57,7 +57,7 @@ void Schematic::updateContentIds()
|
|||
|
||||
flags |= SCHEM_CIDS_UPDATED;
|
||||
|
||||
for (int i = 0; i != size.X * size.Y * size.Z; i++)
|
||||
for (size_t i = 0; i != size.X * size.Y * size.Z; i++)
|
||||
schemdata[i].setContent(c_nodes[schemdata[i].getContent()]);
|
||||
}
|
||||
|
||||
|
|
|
@ -1098,7 +1098,10 @@ bool read_schematic(lua_State *L, int index, Schematic *schem,
|
|||
}
|
||||
}
|
||||
|
||||
schem->flags = 0;
|
||||
// Here, we read the nodes directly from the INodeDefManager - there is no
|
||||
// need for pending node resolutions so we'll mark this schematic as updated
|
||||
schem->flags = SCHEM_CIDS_UPDATED;
|
||||
|
||||
schem->size = size;
|
||||
schem->schemdata = schemdata;
|
||||
schem->slice_probs = slice_probs;
|
||||
|
|
Loading…
Reference in New Issue