summaryrefslogtreecommitdiff
path: root/src/scriptapi_env.cpp
diff options
context:
space:
mode:
authorWeblate <42@minetest.ru>2013-04-18 20:00:16 +0200
committerWeblate <42@minetest.ru>2013-04-18 20:00:16 +0200
commit9e6376bd95ba9309365b39b878ab2f499776437a (patch)
treea354a250daedf036cc36e33d3d1ebb9fafc4ac27 /src/scriptapi_env.cpp
parente385af7cc01d156164b85d10b00a7047a5372e66 (diff)
parente60eb32050a44d344795e4a1515a56038bb97e02 (diff)
downloadminetest-9e6376bd95ba9309365b39b878ab2f499776437a.tar.gz
minetest-9e6376bd95ba9309365b39b878ab2f499776437a.tar.bz2
minetest-9e6376bd95ba9309365b39b878ab2f499776437a.zip
Merge remote branch 'origin/master'
Diffstat (limited to 'src/scriptapi_env.cpp')
-rw-r--r--src/scriptapi_env.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/scriptapi_env.cpp b/src/scriptapi_env.cpp
index 9bf7f0b55..efed58e66 100644
--- a/src/scriptapi_env.cpp
+++ b/src/scriptapi_env.cpp
@@ -662,9 +662,11 @@ int EnvRef::l_line_of_sight(lua_State *L) {
v3f pos2 = checkFloatPos(L, 2);
//read step size from lua
if(lua_isnumber(L, 3))
- stepsize = lua_tonumber(L, 3);
+ stepsize = lua_tonumber(L, 3);
- return (env->line_of_sight(pos1,pos2,stepsize));
+ lua_pushboolean(L, env->line_of_sight(pos1,pos2,stepsize));
+
+ return 1;
}
int EnvRef::l_find_path(lua_State *L)