# HG changeset patch # User sheepluva # Date 1399495674 -7200 # Node ID ed8bab6e92baa095bf58623e92a2e25cd24d4f9a # Parent 7e20804db6a228bf4da5eaf2b320da5ef5dfffb8 rolling back the rest diff -r 7e20804db6a2 -r ed8bab6e92ba hedgewars/uScript.pas --- a/hedgewars/uScript.pas Wed May 07 19:26:05 2014 +0200 +++ b/hedgewars/uScript.pas Wed May 07 22:47:54 2014 +0200 @@ -2498,11 +2498,14 @@ cg : TCapGroup; begin // initialize lua -luaState:= luaL_newstate(); -TryDo(luaState <> nil, 'luaL_newstate() failed', true); +luaState:= lua_open; +TryDo(luaState <> nil, 'lua_open failed', true); // open internal libraries -luaL_openlibs(luaState); +luaopen_base(luaState); +luaopen_string(luaState); +luaopen_math(luaState); +luaopen_table(luaState); // import some variables ScriptSetString(_S'L', cLocale);