Function at 0x405a40
Capabilities:
Link many functions at runtime

Disassembly:
mov edx, dword [0x41d260]
sub esp, 0x434
test edx, edx
push ebx
push ebp
push esi
push edi
je 0x405dce
mov eax, dword [edx]
test eax, eax
je 0x405dce
mov ecx, dword [eax + 4]
test ecx, ecx
je 0x405a79
lea esp, [esp]
mov eax, ecx
mov ecx, dword [eax + 4]
test ecx, ecx
jne 0x405a70
cmp dword [eax], 0
je 0x405dce
call fcn.00407b40
mov ecx, dword [edx]
test ecx, ecx
je 0x405a9f
mov eax, dword [ecx + 4]
test eax, eax
je 0x405a9d
mov ecx, eax
mov eax, dword [ecx + 4]
test eax, eax
jne 0x405a94
mov ecx, dword [ecx]
mov eax, dword [ecx + 0x34]
xor edx, edx
xor esi, esi
test eax, eax
je 0x405aca
lea ebx, [ebx]
mov ecx, dword [eax + 0x10048]
add edx, ecx
mov ecx, dword [eax + 0x1004c]
mov eax, dword [eax + 0x10050]
adc esi, ecx
test eax, eax
jne 0x405ab0
push 0
push 0x64
push esi
push edx
call fcn.00409170
push 0
push 0x40000000
push edx
push eax
call fcn.004090c0
mov esi, eax
mov eax, dword [0x41d240]
test eax, eax
mov edi, edx
je 0x405b0f
cmp word [eax], 0
je 0x405b0f
mov eax, dword [0x41d28c]
lea edx, [esp + 0x18]
push edx
push 0x30
call fcn.00402950
mov ebp, eax
mov dword [esp + 0x2c], ebp
jmp 0x405b26
lea eax, [esp + 0x18]
push eax
mov eax, dword [0x41d28c]
push 0x2c
call fcn.00402950
mov dword [esp + 0x2c], eax
mov ebp, eax
test ebp, ebp
je 0x405dce
push 0
push 0x64
push edi
push esi
call fcn.00408fe0
push ebx
push ecx
mov ecx, dword [0x41b014]
push edx
push eax
push ecx
lea edx, [esp + 0x54]
push ebp
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x1c
lea eax, [esp + 0x40]
push eax
call fcn.00407b40
mov eax, dword [0x41d28c]
add esp, 4
lea ecx, [esp + 0x18]
xor ebx, ebx
push ecx
push 0x29
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x24], ebx
call fcn.00402950
lea edx, [esp + 0x18]
mov edi, eax
mov eax, dword [0x41d28c]
push edx
push 0x2a
mov dword [esp + 0x44], edi
call fcn.00402950
mov dword [esp + 0x38], eax
lea eax, [esp + 0x18]
push eax
mov eax, dword [0x41d28c]
push 0x2b
mov byte [esp + 0x1f], bl
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
call fcn.00402950
mov ebp, eax
cmp ebp, ebx
je 0x405cb8
mov ecx, dword [esp + 0x18]
push ecx
lea edx, [esp + 0x24]
push edx
call fcn.00403a10
mov esi, dword [esp + 0x24]
test esi, esi
je 0x405be6
cmp dword [esp + 0x20], ebx
jle 0x405be6
mov eax, dword [esi]
jmp 0x405be8
xor eax, eax
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x405ca4
test esi, esi
je 0x405c09
cmp dword [esp + 0x20], 1
jle 0x405c09
mov eax, dword [esi + 4]
jmp 0x405c0b
xor eax, eax
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
push edi
call ebx
test esi, esi
mov dword [esp + 0x34], eax
je 0x405c29
cmp dword [esp + 0x20], 2
jle 0x405c29
mov eax, dword [esi + 8]
jmp 0x405c2b
xor eax, eax
push eax
push edi
call ebx
test esi, esi
mov dword [esp + 0x28], eax
je 0x405c43
cmp dword [esp + 0x20], 3
jle 0x405c43
mov eax, dword [esi + 0xc]
jmp 0x405c45
xor eax, eax
push eax
push edi
call ebx
test esi, esi
mov dword [esp + 0x30], eax
je 0x405c5d
cmp dword [esp + 0x20], 4
jle 0x405c5d
mov eax, dword [esi + 0x10]
jmp 0x405c5f
xor eax, eax
push eax
push edi
call ebx
test esi, esi
mov dword [esp + 0x1c], eax
je 0x405c77
cmp dword [esp + 0x20], 5
jle 0x405c77
mov esi, dword [esi + 0x14]
jmp 0x405c79
xor esi, esi
push esi
push edi
call ebx
cmp dword [esp + 0x34], 0
mov ebx, eax
je 0x405ca4
cmp dword [esp + 0x28], 0
je 0x405ca4
cmp dword [esp + 0x30], 0
je 0x405ca4
cmp dword [esp + 0x1c], 0
je 0x405ca4
test ebx, ebx
je 0x405ca4
mov byte [esp + 0x17], 1
push ebp
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov edi, dword [esp + 0x3c]
lea esi, [esp + 0x20]
call fcn.00403ad0
test edi, edi
je 0x405dba
cmp dword [esp + 0x38], 0
je 0x405dba
cmp byte [esp + 0x17], 0
je 0x405dba
push 0
push 0
push 0
push 0
push 0x40a286
call dword [esp + 0x44]
mov ebp, eax
test ebp, ebp
je 0x405d9b
push 0
push 0
push 3
push 0
push 0
push 0x1bb
push edi
push ebp
call ebx
mov esi, eax
test esi, esi
je 0x405d85
mov ecx, dword [esp + 0x38]
push 0
push 0x80800000
push 0
lea eax, [esp + 0x4c]
push eax
push 0
push ecx
push 0
push esi
call dword [esp + 0x54]
mov edi, eax
test edi, edi
je 0x405d66
push 0
push 0
push 0
push 0
push edi
call dword [esp + 0x3c]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00407b40
add esp, 4
push edi
call dword [esp + 0x20]
push esi
call dword [esp + 0x20]
mov edi, dword [esp + 0x3c]
push ebp
call dword [esp + 0x20]
jmp 0x405daa
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00407b40
add esp, 4
push esi
call dword [esp + 0x20]
mov edi, dword [esp + 0x3c]
push ebp
call dword [esp + 0x20]
jmp 0x405daa
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00407b40
add esp, 4
push ebp
call dword [esp + 0x20]
jmp 0x405daa
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00407b40
add esp, 4
mov eax, edi
call fcn.00404d30
mov eax, dword [esp + 0x38]
call fcn.00404d30
mov edx, dword [esp + 0x2c]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x434
ret