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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
and dword [ebp - 0x1c], 0
push ebx
push esi
push edi
push 0x6c
call fcn.004355f2
mov edi, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0x24], eax
mov eax, dword [edi + 0x3c]
mov esi, dword [eax + edi + 0x78]
mov ecx, dword [eax + edi + 0x7c]
lea edx, [ecx + esi]
mov dword [ebp - 0x14], edx
cmp esi, ebx
jae 0x408c2e
lea eax, [esi + 0x28]
cmp eax, ebx
ja 0x408c2e
cmp ecx, ebx
ja 0x408c2e
cmp edx, ebx
ja 0x408c2e
mov eax, dword [esi + edi + 0x14]
mov edx, dword [esi + edi + 0x1c]
mov dword [ebp - 8], eax
mov eax, dword [esi + edi + 0x18]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp + 0x14]
add eax, edx
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0xc]
jb 0x408c2e
test eax, eax
je 0x408c2e
mov eax, dword [esi + edi + 0x20]
mov dword [ebp - 4], eax
cmp eax, esi
jb 0x408c2e
mov ebx, dword [ebp - 0xc]
lea eax, [eax + ebx*4]
cmp eax, dword [ebp - 0x14]
ja 0x408c2e
mov eax, ebx
shl eax, 2
cmp eax, ecx
jae 0x408c2e
mov eax, dword [esi + edi + 0x24]
mov dword [ebp - 0x20], eax
cmp eax, esi
jb 0x408c2e
mov edi, ebx
lea eax, [eax + edi*2]
mov edi, dword [ebp + 8]
cmp eax, dword [ebp - 0x14]
ja 0x408c2e
cmp edx, esi
jb 0x408c2e
mov eax, dword [ebp - 8]
shl eax, 2
add eax, edx
cmp eax, dword [ebp - 0x14]
ja 0x408c2e
mov eax, dword [ebp - 8]
mov ebx, dword [ebp + 0xc]
shl eax, 2
cmp eax, ecx
jae 0x408c2e
mov eax, dword [ebp - 4]
add edx, edi
add eax, edi
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x20]
add eax, edi
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x24]
cmp eax, 2
ja 0x408ade
push eax
push ebx
push edi
call fcn.0040a2a2
mov edx, dword [ebp - 0x18]
and dword [ebp - 4], 0
cmp dword [ebp - 8], 0
jbe 0x408c2e
mov ecx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x10]
add ecx, 8
sub eax, dword [ebp + 0x14]
sub edx, dword [ebp - 0x10]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp - 8]
mov dword [ebp + 0x18], ecx
cmp dword [ebp + 0x1c], 0x260
jb 0x408c1e
mov edi, dword [ebp - 0x18]
mov eax, dword [ebp - 0x10]
mov eax, dword [edi + eax]
mov edi, dword [ebp + 8]
mov dword [ebp - 0x2c], eax
cmp eax, ebx
jae 0x408c1b
cmp eax, esi
jb 0x408b3b
cmp eax, dword [ebp - 0x14]
jb 0x408c1b
mov edx, dword [ebp - 0x10]
mov edx, dword [edx]
mov dword [ebp - 0x30], edx
test edx, edx
je 0x408c18
cmp eax, edx
je 0x408c18
and dword [ebp + 0x14], 0
xor edx, edx
cmp dword [ebp - 0xc], edx
jbe 0x408b86
mov eax, dword [ebp - 0x20]
movzx eax, word [eax + edx*2]
cmp eax, dword [ebp - 4]
je 0x408b72
inc edx
cmp edx, dword [ebp - 0xc]
jb 0x408b5e
jmp 0x408b86
mov eax, dword [ebp - 0x28]
mov eax, dword [eax + edx*4]
cmp eax, esi
jb 0x408b86
cmp eax, dword [ebp - 0x14]
jae 0x408b86
add eax, edi
mov dword [ebp + 0x14], eax
mov eax, dword [ebp - 0x10]
add eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x30]
mov ebx, dword [ebp + 0xc]
mov dword [ecx - 8], eax
mov eax, dword [ebp - 0x2c]
mov dword [ecx - 4], eax
add eax, dword [ebp + 0x10]
mov dword [ecx + 4], eax
mov eax, dword [ebp + 0x10]
add eax, edx
mov dword [ecx], edx
mov edx, dword [ebp + 0x14]
mov dword [ecx + 8], eax
lea eax, [ecx + 0xc]
mov byte [eax], 0
test edx, edx
je 0x408bc8
push 0x40
push edx
push eax
call fcn.0047d6a8
mov ecx, dword [ebp + 0x18]
mov byte [ecx + 0x4b], 0
mov eax, dword [esi + edi + 0x10]
xor edx, edx
add eax, dword [ebp - 4]
mov dword [ecx + 0x4c], eax
lea eax, [ecx + 0x50]
mov word [eax], dx
push dword [ecx + 8]
mov dword [ebp + 0x14], eax
call fcn.0040a248
test eax, eax
je 0x408c05
push 0x104
push eax
push dword [ebp + 0x14]
call fcn.0047d8b0
mov ecx, dword [ebp + 0x18]
xor eax, eax
mov word [ecx + 0x256], ax
jmp 0x408c08
mov ecx, dword [ebp + 0x18]
mov eax, 0x260
sub dword [ebp + 0x1c], eax
add ecx, eax
inc dword [ebp - 0x1c]
mov dword [ebp + 0x18], ecx
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
add dword [ebp - 0x10], 4
inc eax
mov dword [ebp - 4], eax
cmp eax, edx
jb 0x408b0a
mov eax, dword [ebp - 0x1c]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18