Function at 0x4016c0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xd8
push ebx
mov ebx, dword [esp + 0xe4]
push ebp
mov ebp, dword [esp + 0xe4]
push esi
push edi
xor edi, edi
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], edi
mov dword [esp + 0x24], edi
mov dword [esp + 0x28], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x30], edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x38], edi
mov dword [esp + 0x3c], edi
mov dword [esp + 0x40], edi
mov dword [esp + 0x44], edi
mov dword [esp + 0x48], edi
mov dword [esp + 0x4c], edi
mov dword [esp + 0x50], edi
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x5c], edi
mov dword [esp + 0x60], edi
mov dword [esp + 0x64], edi
mov dword [esp + 0x14], edi
lea ebx, [ebx]
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x17]
push ecx
mov ecx, ebp
call fcn.00405040
movzx eax, byte [esp + 0x13]
add eax, 0xfffffffd
cmp eax, 4
ja case.default.0x40174e
jmp dword [eax*4 + 0x4019fc]
mov ecx, ebp
call fcn.00405370
jmp case.0x40174e.3
push edi
mov ecx, ebp
call fcn.004050b0
jmp case.0x40174e.3
lea edx, [esp + 0x18]
push edx
push edi
mov ecx, ebp
call fcn.00405390
jmp case.0x40174e.3
mov ecx, ebp
call fcn.00405090
mov esi, eax
lea eax, [esp + 0x1c]
push eax
mov ecx, ebp
call fcn.00405020
lea ecx, [esp + 0x18]
push ecx
mov edx, ecx
push edx
mov ecx, ebp
call fcn.00404fe0
push edi
push edi
mov ecx, ebp
call fcn.00405140
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x1c]
push ecx
lea ecx, [esp + 0xa0]
mov dword [esp + 0xa0], edi
mov dword [esp + 0xa4], 0
mov dword [esp + 0xa8], 0
mov dword [esp + 0xac], 0
mov dword [esp + 0xb0], 0
mov dword [esp + 0xb4], 0
mov dword [esp + 0xb8], 0
mov dword [esp + 0xbc], 0
mov dword [esp + 0xc0], 0
mov dword [esp + 0xc4], 0
mov dword [esp + 0xc8], 0
mov dword [esp + 0xcc], 0
mov dword [esp + 0xd0], 0
mov dword [esp + 0xd4], 0
mov dword [esp + 0xd8], 0
mov dword [esp + 0xdc], 0
mov dword [esp + 0xe0], 0
mov dword [esp + 0xe4], 0
mov dword [esp + 0xe8], 0
mov byte [esp + 0x74], 0
mov byte [esp + 0x75], 0
mov dword [esp + 0x78], 0
mov dword [esp + 0x7c], 0
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov byte [esp + 0x90], 0
mov dword [esp + 0x94], 0
mov dword [esp + 0x98], 0
mov dword [esp + 0x9c], 0
mov dword [esp + 0x6c], esi
mov dword [esp + 0x70], eax
call fcn.00401240
mov edx, dword [esp + 0x1c]
mov eax, edx
and eax, 1
mov byte [esp + 0x71], 0
lea ecx, [esp + 0x44]
jne 0x401915
lea ecx, [esp + 0x20]
test dl, 2
mov esi, dword [ecx]
mov dword [esp + 0x74], esi
mov esi, dword [ecx + 4]
mov ecx, dword [ecx + 8]
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x78], esi
lea ecx, [esp + 0x50]
jne 0x401936
lea ecx, [esp + 0x2c]
mov edx, dword [ecx]
mov dword [esp + 0x80], edx
mov edx, dword [ecx + 4]
mov ecx, dword [ecx + 8]
cmp eax, edi
mov dword [esp + 0x84], edx
mov dword [esp + 0x88], ecx
mov byte [esp + 0x8c], 0
lea eax, [esp + 0x44]
jne 0x401967
lea eax, [esp + 0x20]
mov edx, dword [eax]
mov ecx, dword [eax + 4]
mov esi, dword [ebx + 0xc]
mov dword [esp + 0x90], edx
mov edx, dword [eax + 8]
mov eax, dword [ebx + 4]
mov dword [esp + 0x94], ecx
lea ecx, [esi + 1]
cmp ecx, eax
mov dword [esp + 0x98], edx
jle 0x40199e
mov edx, esi
sub edx, eax
inc edx
push edx
mov ecx, ebx
call fcn.004014e0
mov eax, dword [ebx + 0xc]
mov ecx, dword [ebx]
inc eax
mov dword [ebx + 0xc], eax
sub eax, esi
dec eax
cmp eax, edi
mov dword [ebx + 0x10], ecx
jle 0x4019cc
mov edx, esi
shl edx, 7
shl eax, 7
add ecx, edx
push eax
push ecx
add ecx, 0x80
push ecx
call fcn.00407830
add esp, 0xc
mov eax, dword [ebx]
shl esi, 7
add esi, eax
mov eax, esi
je 0x401726
mov ecx, 0x20
lea esi, [esp + 0x68]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
xor edi, edi
jmp 0x401726
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xd8
ret