aboutsummaryrefslogtreecommitdiff
path: root/doc/client_lua_api.txt
diff options
context:
space:
mode:
authorred-001 <red-001@outlook.ie>2017-01-31 13:18:52 +0000
committerLoïc Blot <nerzhul@users.noreply.github.com>2017-03-13 23:56:05 +0100
commit88df9fb5b6c78df9485e8bf3750e2608bd78e14c (patch)
treed823267e244592a7603dc3baffff49818765a853 /doc/client_lua_api.txt
parent44ca9c9cb2079fa97068adb8ee894c5ae13a9975 (diff)
downloadminetest-88df9fb5b6c78df9485e8bf3750e2608bd78e14c.tar.gz
minetest-88df9fb5b6c78df9485e8bf3750e2608bd78e14c.tar.bz2
minetest-88df9fb5b6c78df9485e8bf3750e2608bd78e14c.zip
Add `get_wielded_item`
Diffstat (limited to 'doc/client_lua_api.txt')
-rw-r--r--doc/client_lua_api.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/client_lua_api.txt b/doc/client_lua_api.txt
index 5ffffe938..7440c4014 100644
--- a/doc/client_lua_api.txt
+++ b/doc/client_lua_api.txt
@@ -721,6 +721,7 @@ 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
@@ -728,6 +729,11 @@ Call these functions only at load time!
for unloaded areas.
* `minetest.get_node_or_nil(pos)`
* Same as `get_node` but returns `nil` for unloaded areas.
+
+### Player
+* `minetest.get_wielded_item()`
+ * Returns the itemstack the local player is holding
+
### Misc.
* `minetest.parse_json(string[, nullvalue])`: returns something
* Convert a string containing JSON data into the Lua equivalent