Function at 0x10049f70
Capabilities:
Query environment variable

Disassembly:
push ebp
push esi
mov esi, dword [esp + 0xc]
push edi
push str._LOADLIB
push esi
call sym.lua51.dll_luaL_newmetatable
push 0
push 0x100495c0
push esi
call sym.lua51.dll_lua_pushcclosure
mov eax, dword [esi + 0x14]
mov eax, dword [eax - 8]
mov byte [eax + 6], 1
mov ecx, dword [esi + 8]
push str.__gc
add ecx, 0xd0
push 0xfffffffffffffffe
push esi
mov dword [eax + 0x10], ecx
call sym.lua51.dll_lua_setfield
push 0x1005244c
push str.package
push esi
call sym.lua51.dll_luaL_register
push 0xffffffffffffffff
push esi
call sym.lua51.dll_lua_pushvalue
push 0xffffd8ef
push esi
call sym.lua51.dll_lua_replace
push 0
push 4
push esi
call sym.lua51.dll_lua_createtable
mov eax, dword [0x10052484]
add esp, 0x48
xor edi, edi
test eax, eax
je 0x1004a027
lea ecx, [ecx]
push 0
push eax
push esi
call sym.lua51.dll_lua_pushcclosure
mov edx, dword [esi + 0x14]
mov eax, dword [edx - 8]
inc edi
mov byte [eax + 6], 1
mov ecx, dword [esi + 8]
push edi
add ecx, 0xd0
push 0xfffffffffffffffe
push esi
mov dword [eax + 0x10], ecx
call sym.lua51.dll_lua_rawseti
mov eax, dword [edi*4 + 0x10052484]
add esp, 0x18
test eax, eax
jne 0x10049ff0
push str.loaders
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
push str.LUA_NOENV
push 0xffffd8f0
push esi
call sym.lua51.dll_lua_getfield
push 0xffffffffffffffff
push esi
call sym.lua51.dll_lua_toboolean
push 0xfffffffffffffffe
push esi
mov ebp, eax
call sym.lua51.dll_lua_settop
mov edi, dword [sym.imp.MSVCR100.dll_getenv]
push str.LUA_PATH
call edi
add esp, 0x2c
test eax, eax
je 0x1004a09d
test ebp, ebp
jne 0x1004a09d
push 0x100526c8
push 0x100526c4
push eax
push esi
call sym.lua51.dll_luaL_gsub
push str.._.lua__lua_.lua__lua_init.lua_
push 0x100526c0
push eax
push esi
call sym.lua51.dll_luaL_gsub
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_remove
add esp, 0x28
jmp 0x1004a0ab
push str.._.lua__lua_.lua__lua_init.lua_
push esi
call sym.lua51.dll_lua_pushstring
add esp, 8
call fcn.10049180
push str.path
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
push str.LUA_CPATH
call edi
add esp, 0x10
test eax, eax
je 0x1004a0fe
test ebp, ebp
jne 0x1004a0fe
push 0x100526c8
push 0x100526c4
push eax
push esi
call sym.lua51.dll_luaL_gsub
push str.._.dll___.dll__loadall.dll
push 0x100526c0
push eax
push esi
call sym.lua51.dll_luaL_gsub
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_remove
add esp, 0x28
jmp 0x1004a10c
push str.._.dll___.dll__loadall.dll
push esi
call sym.lua51.dll_lua_pushstring
add esp, 8
call fcn.10049180
push str.cpath
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
push 9
push str._n__n__n__n_
push esi
call sym.lua51.dll_lua_pushlstring
push str.config
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
push 0x10
push str._LOADED
push 0xffffd8f0
push esi
call sym.lua51.dll_luaL_findtable
push str.loaded
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
add esp, 0x40
push 4
push str._PRELOAD
push 0xffffd8f0
push esi
call sym.lua51.dll_luaL_findtable
push str.preload
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_setfield
push 0xffffd8ee
push esi
call sym.lua51.dll_lua_pushvalue
push 0x1005246c
push 0
push esi
call sym.lua51.dll_luaL_register
push 0xfffffffffffffffe
push esi
call sym.lua51.dll_lua_settop
add esp, 0x38
pop edi
pop esi
mov eax, 1
pop ebp
ret