summaryrefslogtreecommitdiff
path: root/doc/lua_api.txt
diff options
context:
space:
mode:
authorCoderForTheBetter <marcumjp@gmail.com>2018-11-28 03:38:50 -0500
committerLoïc Blot <nerzhul@users.noreply.github.com>2018-11-28 09:38:50 +0100
commitfaa358e797128ab07bb5644ce305a832d59e5596 (patch)
treedcf05ef0611b839503c4845fd89ad9519ee1c4bb /doc/lua_api.txt
parent9519d57017cfa28eb4f2fbf3c780f826017bbb00 (diff)
downloadminetest-faa358e797128ab07bb5644ce305a832d59e5596.tar.gz
minetest-faa358e797128ab07bb5644ce305a832d59e5596.tar.bz2
minetest-faa358e797128ab07bb5644ce305a832d59e5596.zip
Add Lua methods 'set_rotation()' and 'get_rotation()' (#7395)
* Adds Lua methods 'set_rotation()' and 'get_rotation'. Also changed some method names to be more clear. Instead of an f32 being sent over network for yaw, now a v3f is sent for rotation on xyz axes. Perserved Lua method set_yaw/setyaw so that old mods still work, other wise to set yaw they would need to switch to set_rotation(0, yaw, 0).
Diffstat (limited to 'doc/lua_api.txt')
-rw-r--r--doc/lua_api.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 44902725d..a07356d00 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -5070,6 +5070,9 @@ This is basically a reference to a C++ `ServerActiveObject`
* `set_acceleration(acc)`
* `acc` is a vector
* `get_acceleration()`: returns the acceleration, a vector
+* `set_rotation(rot)`
+ * `rot` is a vector (radians)
+* `get_rotation()` : returns the rotation, a vector (radians)
* `set_yaw(radians)`
* `get_yaw()`: returns number in radians
* `set_texture_mod(mod)`