mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-16 18:01:40 +00:00
[CSM] Add get_node
and get_node_or_nil
This commit is contained in:
parent
073f5cf03d
commit
37df9cb7d7
6 changed files with 67 additions and 2 deletions
|
@ -717,7 +717,13 @@ Call these functions only at load time!
|
|||
* `minetest.after(time, func, ...)`
|
||||
* Call the function `func` after `time` seconds, may be fractional
|
||||
* Optional: Variable number of arguments that are passed to `func`
|
||||
|
||||
### Map
|
||||
* `minetest.get_node(pos)`
|
||||
* Returns the node at the given position as table in the format
|
||||
`{name="node_name", param1=0, param2=0}`, returns `{name="ignore", param1=0, param2=0}`
|
||||
for unloaded areas.
|
||||
* `minetest.get_node_or_nil(pos)`
|
||||
* Same as `get_node` but returns `nil` for unloaded areas.
|
||||
### Misc.
|
||||
* `minetest.parse_json(string[, nullvalue])`: returns something
|
||||
* Convert a string containing JSON data into the Lua equivalent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue