summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Zenz <Robert.Zenz@bonsaimind.org>2015-09-07 18:51:45 +0200
committerest31 <MTest31@outlook.com>2015-09-08 21:14:56 +0200
commitfe6575b8d38b29026adb9bf3d6226b5b3ceb4cab (patch)
treea5300c6e07dd19208bdafc35670768a58b8bd526
parent0b875560481ca16782ace98b0bace9f02d18b22d (diff)
downloadminetest-fe6575b8d38b29026adb9bf3d6226b5b3ceb4cab.tar.gz
minetest-fe6575b8d38b29026adb9bf3d6226b5b3ceb4cab.tar.bz2
minetest-fe6575b8d38b29026adb9bf3d6226b5b3ceb4cab.zip
Add more information about how get_node_light works.
-rw-r--r--doc/lua_api.txt8
1 files changed, 6 insertions, 2 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 5372cb834..b07d046c4 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -1914,9 +1914,13 @@ and `minetest.auth_reload` call the authetification handler.
* Returns `{name="ignore", ...}` for unloaded area
* `minetest.get_node_or_nil(pos)`
* Returns `nil` for unloaded area
-* `minetest.get_node_light(pos, timeofday)` returns a number between `0` and `15` or `nil`
+* `minetest.get_node_light(pos, timeofday)`
+ * Gets the light value at the given position. Note that the light value
+ "inside" the node at the given position is returned, so you usually want
+ to get the light value of a neighbor.
+ * `pos`: The position where to measure the light.
* `timeofday`: `nil` for current time, `0` for night, `0.5` for day
-
+ * Returns a number between `0` and `15` or `nil`
* `minetest.place_node(pos, node)`
* Place node with the same effects that a player would cause
* `minetest.dig_node(pos)`