mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add minetest.bulk_set_node call + optimize Environment::set_node call (#6958)
* Add minetest.bulk_set_node call + experimental mod unittest * Optimize set_node function to prevent triple lookup on contentfeatures Do only one lookup for old, and try to merge old and new lookup if node is same than previous node * Add benchmark function + optimize vector population to have real results
This commit is contained in:
parent
3b4df956b1
commit
584d00a01c
5 changed files with 124 additions and 3 deletions
|
@ -29,6 +29,10 @@ private:
|
|||
// pos = {x=num, y=num, z=num}
|
||||
static int l_set_node(lua_State *L);
|
||||
|
||||
// bulk_set_node([pos1, pos2, ...], node)
|
||||
// pos = {x=num, y=num, z=num}
|
||||
static int l_bulk_set_node(lua_State *L);
|
||||
|
||||
static int l_add_node(lua_State *L);
|
||||
|
||||
// remove_node(pos)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue