diff options
author | ShadowNinja <shadowninja@minetest.net> | 2015-05-16 19:09:53 -0400 |
---|---|---|
committer | ShadowNinja <shadowninja@minetest.net> | 2015-05-16 21:12:03 -0400 |
commit | c00b6812b116c7e08eaf00c52504aa7b93a936a1 (patch) | |
tree | 163145ae9b30bdedade2d0319da7bafa829217f4 /src | |
parent | 11a96e4901ce54c4646e47866f7a66cd9034c16b (diff) | |
download | minetest-c00b6812b116c7e08eaf00c52504aa7b93a936a1.tar.gz minetest-c00b6812b116c7e08eaf00c52504aa7b93a936a1.tar.bz2 minetest-c00b6812b116c7e08eaf00c52504aa7b93a936a1.zip |
Fix current mod name change missed during rebase
Diffstat (limited to 'src')
-rw-r--r-- | src/script/lua_api/l_base.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/script/lua_api/l_base.cpp b/src/script/lua_api/l_base.cpp index 136fcc507..6ad3e4ba2 100644 --- a/src/script/lua_api/l_base.cpp +++ b/src/script/lua_api/l_base.cpp @@ -49,12 +49,12 @@ GUIEngine *ModApiBase::getGuiEngine(lua_State *L) std::string ModApiBase::getCurrentModPath(lua_State *L) { - lua_getfield(L, LUA_REGISTRYINDEX, "current_modname"); - const char *current_modname = lua_tostring(L, -1); - if (!current_modname) + lua_getfield(L, LUA_REGISTRYINDEX, SCRIPT_MOD_NAME_FIELD); + const char *current_mod_name = lua_tostring(L, -1); + if (!current_mod_name) return "."; - const ModSpec *mod = getServer(L)->getModSpec(current_modname); + const ModSpec *mod = getServer(L)->getModSpec(current_mod_name); if (!mod) return "."; |