summaryrefslogtreecommitdiff
path: root/plugins/MirLua/src/mlua.cpp
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2015-10-23 22:27:49 +0000
committerAlexander Lantsev <aunsane@gmail.com>2015-10-23 22:27:49 +0000
commitf4258bb6d37d16a673c268376e0dff1958c34f82 (patch)
tree071772b69092f7b095b5dc9e14e3a6ea18f85211 /plugins/MirLua/src/mlua.cpp
parentf9805e018525db5063d28692014e04dba47196db (diff)
MirLua:
- m_core is available as usual module - options page moved to Services/MirLua/Scripts - code cleaning - version bump git-svn-id: http://svn.miranda-ng.org/main/trunk@15602 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/MirLua/src/mlua.cpp')
-rw-r--r--plugins/MirLua/src/mlua.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/plugins/MirLua/src/mlua.cpp b/plugins/MirLua/src/mlua.cpp
index 15bd34fe2d..6a54f92592 100644
--- a/plugins/MirLua/src/mlua.cpp
+++ b/plugins/MirLua/src/mlua.cpp
@@ -34,16 +34,14 @@ void CMLua::Load()
lua_setfield(L, -2, "cpath");
lua_pop(L, 1);
- lua_getglobal(L, "_G");
lua_pushcclosure(L, luaM_print, 0);
- lua_setfield(L, -2, "print");
+ lua_setglobal(L, "print");
lua_pushcclosure(L, luaM_toansi, 0);
- lua_setfield(L, -2, "a");
+ lua_setglobal(L,"a");
lua_pushcclosure(L, luaM_toucs2, 0);
- lua_setfield(L, -2, "u");
+ lua_setglobal(L, "u");
lua_pushcclosure(L, luaM_totable, 0);
- lua_setfield(L, -2, "totable");
- lua_pop(L, 1);
+ lua_setglobal(L, "totable");
lua_atpanic(L, luaM_atpanic);