1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-06 17:41:04 +00:00

Add minetest.bulk_swap_node (#15043)

Co-authored-by: sfan5 <sfan5@live.de>
This commit is contained in:
Elias Åström 2024-09-24 22:25:34 +02:00 committed by GitHub
parent d8f1daac25
commit f65fe80e81
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 67 additions and 0 deletions

View file

@ -6145,6 +6145,8 @@ Environment access
* `minetest.swap_node(pos, node)`
* Swap node at position with another.
* This keeps the metadata intact and will not run con-/destructor callbacks.
* `minetest.bulk_swap_node({pos1, pos2, pos3, ...}, node)`
* Equivalent to `minetest.swap_node` but in bulk.
* `minetest.remove_node(pos)`: Remove a node
* Equivalent to `minetest.set_node(pos, {name="air"})`, but a bit faster.
* `minetest.get_node(pos)`