Also return the ObjectRef from minetest.spawn_falling_node() (#11184)

This commit is contained in:
benrob0329 2021-04-13 14:02:43 -04:00 committed by GitHub
parent bbe120308f
commit a106bfd456
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

@ -407,7 +407,7 @@ local function convert_to_falling_node(pos, node)
obj:get_luaentity():set_node(node, metatable) obj:get_luaentity():set_node(node, metatable)
core.remove_node(pos) core.remove_node(pos)
return true return true, obj
end end
function core.spawn_falling_node(pos) function core.spawn_falling_node(pos)

@ -4927,7 +4927,7 @@ Environment access
* Punch node with the same effects that a player would cause * Punch node with the same effects that a player would cause
* `minetest.spawn_falling_node(pos)` * `minetest.spawn_falling_node(pos)`
* Change node into falling node * Change node into falling node
* Returns `true` if successful, `false` on failure * Returns `true` and the ObjectRef of the spawned entity if successful, `false` on failure
* `minetest.find_nodes_with_meta(pos1, pos2)` * `minetest.find_nodes_with_meta(pos1, pos2)`
* Get a table of positions of nodes that have metadata within a region * Get a table of positions of nodes that have metadata within a region