Function at 0x40c470
Capabilities:
Check if file exists
Link many functions at runtime

Disassembly:
sub esp, 0x804
mov eax, dword [esp + 0x818]
push ebx
push ebp
push esi
push edi
mov edi, ecx
xor ebp, ebp
mov dword [esp + 0x10], edi
lea esi, [edi + 0x154]
mov dword [edi + 0x148], eax
cmp dword [esi], ebp
jne 0x40c4ae
call fcn.00406030
cmp eax, ebp
je 0x40c4aa
mov ecx, dword [eax]
push eax
call dword [ecx + 0x54]
jmp 0x40c4ac
xor eax, eax
mov dword [esi], eax
mov ecx, dword [esi]
cmp ecx, ebp
je 0x40c4d6
mov eax, dword [esp + 0x824]
mov edx, dword [ecx]
push ebp
push eax
call dword [edx + 0xc]
test eax, eax
jne 0x40c4d6
call fcn.00406030
cmp eax, ebp
je 0x40c4d6
mov ecx, dword [eax]
push esi
push eax
call dword [ecx + 0x58]
mov eax, dword [edi + 0x128]
add edi, 0x128
cmp eax, ebp
jne 0x40c4fb
call fcn.00406030
cmp eax, ebp
je 0x40c4f7
mov edx, dword [eax]
push eax
call dword [edx + 0x54]
jmp 0x40c4f9
xor eax, eax
mov dword [edi], eax
mov ecx, dword [edi]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
cmp ecx, ebp
je 0x40c5db
mov edx, dword [esp + 0x818]
mov eax, dword [ecx]
push ebp
push edx
call dword [eax + 0xc]
test eax, eax
jne 0x40c5db
mov eax, dword [0x4730e0]
cmp eax, ebp
je 0x40c536
cmp dword [0x4730e4], ebp
jne 0x40c5ce
lea eax, [esp + 0x14]
push 0x400
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [esp + 0x14]
push ecx
call ebx
mov eax, dword [0x4730e8]
xor esi, esi
cmp eax, ebp
jle 0x40c56a
lea edx, [esp + 0x14]
push edx
call ebx
mov eax, dword [0x4730e8]
inc esi
cmp esi, eax
jl 0x40c559
lea eax, [esp + 0x14]
push str.MiniUI.dll
lea ecx, [esp + 0x18]
push eax
push ecx
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea edx, [esp + 0x14]
push edx
call fcn.00401560
add esp, 4
test eax, eax
je 0x40c59b
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp eax, ebp
mov dword [0x4730e4], eax
je 0x40c5db
push str.GetMiniUI
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebp
mov dword [0x4730e0], eax
jne 0x40c5ce
mov ecx, dword [0x4730e4]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x4730e4], ebp
jmp 0x40c5db
call eax
cmp eax, ebp
je 0x40c5db
mov edx, dword [eax]
push edi
push eax
call dword [edx + 0x58]
mov eax, dword [esp + 0x10]
lea edi, [eax + 0x12c]
mov eax, dword [eax + 0x12c]
cmp eax, ebp
jne 0x40c6a6
mov eax, dword [0x4730e0]
cmp eax, ebp
je 0x40c608
cmp dword [0x4730e4], ebp
jne 0x40c737
lea ecx, [esp + 0x14]
push 0x400
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea edx, [esp + 0x14]
push edx
call ebx
mov eax, dword [0x4730e8]
xor esi, esi
cmp eax, ebp
jle 0x40c63c
lea eax, [esp + 0x14]
push eax
call ebx
mov eax, dword [0x4730e8]
inc esi
cmp esi, eax
jl 0x40c62b
lea ecx, [esp + 0x14]
push str.MiniUI.dll
lea edx, [esp + 0x18]
push ecx
push edx
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [esp + 0x14]
push eax
call fcn.00401560
add esp, 4
test eax, eax
je 0x40c66d
lea ecx, [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp eax, ebp
mov dword [0x4730e4], eax
je 0x40c6a2
push str.GetMiniUI
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebp
mov dword [0x4730e0], eax
jne 0x40c737
mov edx, dword [0x4730e4]
push edx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x4730e4], ebp
xor eax, eax
mov dword [edi], eax
mov ecx, dword [edi]
cmp ecx, ebp
je 0x40c797
mov eax, dword [esp + 0x81c]
mov edx, dword [ecx]
push ebp
push eax
call dword [edx + 0xc]
test eax, eax
jne 0x40c797
mov eax, dword [0x4730e0]
cmp eax, ebp
je 0x40c6db
cmp dword [0x4730e4], ebp
jne 0x40c78a
lea ecx, [esp + 0x14]
push 0x400
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea edx, [esp + 0x14]
push edx
call ebx
mov eax, dword [0x4730e8]
xor esi, esi
cmp eax, ebp
jle 0x40c70f
lea eax, [esp + 0x14]
push eax
call ebx
mov eax, dword [0x4730e8]
inc esi
cmp esi, eax
jl 0x40c6fe
lea ecx, [esp + 0x14]
push str.MiniUI.dll
lea edx, [esp + 0x18]
push ecx
push edx
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [esp + 0x14]
push eax
call fcn.00401560
add esp, 4
test eax, eax
jne 0x40c74c
jmp 0x40c757
call eax
cmp eax, ebp
je 0x40c6a2
mov ecx, dword [eax]
push eax
call dword [ecx + 0x54]
jmp 0x40c6a4
lea ecx, [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp eax, ebp
mov dword [0x4730e4], eax
je 0x40c797
push str.GetMiniUI
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebp
mov dword [0x4730e0], eax
jne 0x40c78a
mov edx, dword [0x4730e4]
push edx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x4730e4], ebp
jmp 0x40c797
call eax
cmp eax, ebp
je 0x40c797
mov ecx, dword [eax]
push edi
push eax
call dword [ecx + 0x58]
mov edx, dword [esp + 0x10]
mov eax, dword [edx + 0x158]
lea edi, [edx + 0x158]
cmp eax, ebp
jne 0x40c862
mov eax, dword [0x4730e0]
cmp eax, ebp
je 0x40c7c4
cmp dword [0x4730e4], ebp
jne 0x40c91f
lea eax, [esp + 0x14]
push 0x400
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [esp + 0x14]
push ecx
call ebx
mov eax, dword [0x4730e8]
xor esi, esi
cmp eax, ebp
jle 0x40c7f8
lea edx, [esp + 0x14]
push edx
call ebx
mov eax, dword [0x4730e8]
inc esi
cmp esi, eax
jl 0x40c7e7
lea eax, [esp + 0x14]
push str.MiniUI.dll
lea ecx, [esp + 0x18]
push eax
push ecx
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea edx, [esp + 0x14]
push edx
call fcn.00401560
add esp, 4
test eax, eax
je 0x40c829
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp eax, ebp
mov dword [0x4730e4], eax
je 0x40c85e
push str.GetMiniUI
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebp
mov dword [0x4730e0], eax
jne 0x40c91f
mov ecx, dword [0x4730e4]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x4730e4], ebp
xor eax, eax
mov dword [edi], eax
mov ecx, dword [edi]
cmp ecx, ebp
je 0x40c98f
mov edx, dword [esp + 0x820]
mov eax, dword [ecx]
push ebp
push edx
call dword [eax + 0xc]
test eax, eax
jne 0x40c98f
mov eax, dword [0x4730e0]
cmp eax, ebp
je 0x40c897
cmp dword [0x4730e4], ebp
jne 0x40c982
lea eax, [esp + 0x14]
push 0x400
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [esp + 0x14]
push ecx
call ebx
mov eax, dword [0x4730e8]
xor esi, esi
cmp eax, ebp
jle 0x40c8cb
lea edx, [esp + 0x14]
push edx
call ebx
mov eax, dword [0x4730e8]
inc esi
cmp esi, eax
jl 0x40c8ba
lea eax, [esp + 0x14]
push str.MiniUI.dll
lea ecx, [esp + 0x18]
push eax
push ecx
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea edx, [esp + 0x14]
test edx, edx
je 0x40c91b
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40c934
lea ecx, [esp + 0x14]
push ecx
call fcn.00456ce0
add esp, 4
test eax, eax
jne 0x40c934
call fcn.00456be0
lea edx, [esp + 0x14]
push eax
push edx
call fcn.00456bf0
add esp, 8
xor eax, eax
jmp 0x40c93f
call eax
cmp eax, ebp
je 0x40c85e
mov edx, dword [eax]
push eax
call dword [edx + 0x54]
jmp 0x40c860
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp eax, ebp
mov dword [0x4730e4], eax
je 0x40c98f
push str.GetMiniUI
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebp
mov dword [0x4730e0], eax
jne 0x40c982
mov ecx, dword [0x4730e4]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
mov dword [0x4730e4], ebp
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x804
ret 0x14
call eax
cmp eax, ebp
je 0x40c98f
mov edx, dword [eax]
push edi
push eax
call dword [edx + 0x58]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x804
ret 0x14