kahrl wrote:Can you try if the following change to minetest.find_path has any effect?Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
- Code: Select all
diff --git a/src/script/lua_api/l_env.cpp b/src/script/lua_api/l_env.cpp
index a287281..689ff53 100644
--- a/src/script/lua_api/l_env.cpp
+++ b/src/script/lua_api/l_env.cpp
@@ -572,7 +572,7 @@ int ModApiEnvMod::l_find_path(lua_State *L)
unsigned int max_jump = luaL_checkint(L, 4);
unsigned int max_drop = luaL_checkint(L, 5);
algorithm algo = A_PLAIN_NP;
- if(! lua_isnil(L, 6)) {
+ if(! lua_isnoneornil(L, 6)) {
std::string algorithm = luaL_checkstring(L,6);
if (algorithm == "A*")
Sorry, I don't understand. Where is the file minetest.find_path?