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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x42dfa0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x58
mov eax, dword [0x438f6c]
mov dword [esp + 0x50], eax
mov eax, dword [ebp + 0x14]
mov edx, dword [eax + 0x10]
test dh, 0x40
push ebx
push esi
push edi
mov dword [esp + 0x1c], ecx
jne 0x404839
movzx esi, byte [ebp + 0x1c]
mov edx, dword [ecx]
push esi
mov esi, dword [ebp + 0x18]
push esi
mov esi, dword [ebp + 8]
push eax
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 0xc]
push eax
push esi
call dword [edx + 0x1c]
jmp 0x404a02
lea ecx, [esp + 0x20]
push ecx
mov ecx, eax
call fcn.004011c0
push eax
mov dword [esp + 0x70], 0
call fcn.00404b40
mov esi, dword [esp + 0x24]
add esp, 4
test esi, esi
mov edi, eax
mov dword [esp + 0x6c], 0xffffffff
mov ebx, 1
je 0x4048a9
push 0
lea ecx, [esp + 0x10]
call fcn.0040cc0a
mov eax, dword [esi + 4]
test eax, eax
jbe 0x404888
cmp eax, 0xffffffff
jae 0x404888
dec eax
mov dword [esi + 4], eax
mov ecx, dword [esi + 4]
xor edx, edx
test ecx, ecx
setne dl
lea ecx, [esp + 0xc]
dec edx
and esi, edx
call fcn.0040cc2d
test esi, esi
je 0x4048a9
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax]
mov dword [esp + 0x58], 0xf
mov dword [esp + 0x54], 0
mov byte [esp + 0x44], 0
mov al, byte [ebp + 0x1c]
test al, al
mov dword [esp + 0x6c], ebx
je 0x4048fa
lea ecx, [esp + 0x24]
push ecx
mov ecx, edi
call fcn.00404b20
push 0xffffffffffffffff
push 0
push eax
lea ecx, [esp + 0x4c]
mov byte [esp + 0x78], 2
call fcn.00403d00
cmp dword [esp + 0x3c], 0x10
mov byte [esp + 0x6c], bl
jb 0x404931
mov edx, dword [esp + 0x28]
push edx
jmp 0x404929
lea eax, [esp + 0x24]
push eax
mov ecx, edi
call fcn.00404b00
push 0xffffffffffffffff
push 0
push eax
lea ecx, [esp + 0x4c]
mov byte [esp + 0x78], 3
call fcn.00403d00
cmp dword [esp + 0x3c], 0x10
mov byte [esp + 0x6c], bl
jb 0x404931
mov ecx, dword [esp + 0x28]
push ecx
call fcn.0041e36f
add esp, 4
mov ebx, dword [ebp + 0x14]
mov eax, dword [ebx + 0x18]
test eax, eax
mov edx, dword [esp + 0x54]
jle 0x404949
cmp eax, edx
jbe 0x404949
sub eax, edx
mov esi, eax
jmp 0x40494b
xor esi, esi
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp + 0xc]
and eax, 0x1c0
cmp eax, 0x40
mov eax, dword [ebp + 0x10]
je 0x40498e
test esi, esi
mov dword [esp + 0xc], ecx
mov dword [esp + 0x10], eax
jbe 0x404984
lea ebx, [ebx]
mov ecx, dword [ebp + 0x18]
push ecx
lea ecx, [esp + 0x10]
call fcn.00404a30
dec esi
jne 0x404970
mov edx, dword [esp + 0x54]
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x10]
xor esi, esi
cmp dword [esp + 0x58], 0x10
mov edi, dword [esp + 0x44]
jae 0x40499d
lea edi, [esp + 0x44]
test edx, edx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], eax
jbe 0x4049c5
mov ebx, edx
jmp 0x4049b0
xor edx, edx
mov dl, byte [edi]
lea ecx, [esp + 0x14]
push edx
call fcn.00404a30
inc edi
dec ebx
jne 0x4049b0
mov ebx, dword [ebp + 0x14]
mov eax, dword [ebp + 0x18]
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x14]
push esi
mov esi, dword [ebp + 8]
push eax
mov eax, dword [esp + 0x24]
push ecx
push edx
push esi
push eax
mov dword [ebx + 0x18], 0
call fcn.00404a90
mov eax, dword [esp + 0x70]
add esp, 0x18
cmp eax, 0x10
jb 0x404a02
mov ecx, dword [esp + 0x44]
push ecx
call fcn.0041e36f
add esp, 4
mov ecx, dword [esp + 0x64]
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x5c]
mov eax, esi
call fcn.0041ef4c
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18