summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorHybridDog <3192173+HybridDog@users.noreply.github.com>2020-01-04 15:44:48 +0100
committersfan5 <sfan5@live.de>2020-01-04 15:44:48 +0100
commitf9c7e46a347576c9327aaa0d9b6a5b4cd07c26e2 (patch)
tree0a1cffa49e854c2e808981383ce07ff2f8f17f5d /doc
parent3ad92baa9c1e1b4c7b23306b2be1fc4284dd4872 (diff)
downloadminetest-f9c7e46a347576c9327aaa0d9b6a5b4cd07c26e2.tar.gz
minetest-f9c7e46a347576c9327aaa0d9b6a5b4cd07c26e2.tar.bz2
minetest-f9c7e46a347576c9327aaa0d9b6a5b4cd07c26e2.zip
Add table.key_value_swap (#9248)
Diffstat (limited to 'doc')
-rw-r--r--doc/lua_api.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 35be95d51..374a774b1 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -2902,6 +2902,8 @@ Helper functions
* `table.insert_all(table, other_table)`:
* Appends all values in `other_table` to `table` - uses `#table + 1` to
find new indices.
+* `table.key_value_swap(t)`: returns a table with keys and values swapped
+ * If multiple keys in `t` map to the same value, the result is undefined.
* `minetest.pointed_thing_to_face_pos(placer, pointed_thing)`: returns a
position.
* returns the exact position on the surface of a pointed node