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

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x5c
mov edi, dword [esp + 0x74]
mov dword [esp], 0
test edi, edi
je 0x404928
mov edx, dword [esp + 0x78]
test edx, edx
jne 0x4047e5
mov edx, dword [edi + 0x10]
mov ebx, dword [esp + 0x70]
xor eax, eax
test edx, edx
je 0x4049b7
mov ecx, dword [edi + 0x14]
and ecx, 2
jne 0x4049b7
cmp byte [edx], 0
je 0x4049b7
mov eax, esp
lea ecx, [esp + 4]
push eax
push ecx
push edx
push ebx
mov ebp, edx
call fcn.004478d0
add esp, 0x10
mov esi, eax
test eax, eax
jne 0x40499f
mov dword [esp + 0xc], ebp
push dword [esp + 4]
push 1
push 0x6f
push 0xe9fc2a
call fcn.007de078
add esp, 0x10
push edi
call fcn.00405480
add esp, 4
mov dword [esp + 8], 0
test eax, eax
je 0x40493b
mov esi, eax
jmp 0x404890
cmp byte [edi + 0x14], 0
mov eax, 0xe9fcbe
mov ecx, 0xe9fcbc
cmovne eax, ecx
push 0xe9fcca
push dword [edi + 0x10]
push eax
push 0xe9fcbf
push ebx
call fcn.0040aef0
add esp, 0x14
test esi, esi
je 0x404933
push esi
call fcn.004054a0
add esp, 4
mov edi, eax
push esi
call fcn.004054b0
add esp, 4
mov esi, eax
mov eax, dword [edi + 0x18]
mov ecx, dword [edi + 0x1c]
mov edx, ecx
mov ebx, 0x7fffffff
xor edx, ebx
mov ebx, eax
mov ebp, 0xffffffff
xor ebx, ebp
or ebx, edx
mov ebx, dword [esp + 4]
je 0x404860
lea edx, [esp + 0x18]
push edx
push ecx
push eax
call fcn.00412c60
add esp, 0xc
test eax, eax
jne 0x40492f
cmp byte [edi + 0x14], 0
mov eax, 0xe9fcbe
mov ecx, 0xe9fcbc
cmovne eax, ecx
mov ecx, dword [esp + 0x2c]
mov edx, 0x76c
add ecx, edx
mov edx, dword [esp + 0x28]
inc edx
push dword [esp + 0x18]
push dword [esp + 0x20]
push dword [esp + 0x28]
push dword [esp + 0x30]
push edx
push ecx
push dword [edi + 0x10]
push eax
push 0xe9fc9a
push ebx
call fcn.0040aef0
add esp, 0x28
test esi, esi
jne 0x404890
jmp 0x404933
xor eax, eax
jmp 0x404af3
mov dword [esp + 8], eax
mov ebx, dword [esp + 0x70]
mov edi, dword [esp + 0x74]
push 0xe9fc08
push 0x182
push dword [esp + 0xc]
call fcn.00405d30
add esp, 0xc
mov ecx, dword [esp + 8]
test ecx, ecx
sete dl
mov eax, dword [esp]
test eax, eax
setne dh
and dh, dl
cmp dh, 1
jne 0x404983
push dword [esp + 0xc]
push eax
call fcn.00414700
add esp, 8
test eax, eax
mov ecx, 0x17
cmove ecx, eax
mov eax, dword [esp]
test ecx, ecx
setne dl
test eax, eax
setne dh
and dh, dl
mov esi, ecx
cmp dh, 1
jne 0x40499f
push eax
call fcn.007de200
add esp, 4
push 0xe9fc08
push 0x189
push dword [esp + 8]
call fcn.00405970
add esp, 0xc
mov eax, esi
cmp dword [ebx + 0x1c8], 0
je 0x404af3
push edi
mov esi, edi
mov edi, eax
call fcn.00405490
add esp, 4
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], 0
push esi
call fcn.00405480
add esp, 4
mov esi, eax
mov eax, edi
test esi, esi
je 0x404af3
nop word cs:[eax + eax]
push esi
call fcn.004054a0
add esp, 4
mov edi, eax
push esi
call fcn.004054b0
add esp, 4
mov esi, eax
mov eax, dword [edi + 0x10]
mov dword [esp + 0x3c], eax
push eax
call fcn.007ddf80
add esp, 4
mov dword [esp + 0x40], eax
movzx eax, byte [edi + 0x14]
mov dword [esp + 0x44], eax
mov eax, dword [edi + 0x18]
mov ecx, dword [edi + 0x1c]
mov edx, ecx
mov edi, 0x7fffffff
xor edx, edi
mov edi, eax
mov ebp, 0xffffffff
xor edi, ebp
or edi, edx
jne 0x404a70
lea eax, [esp + 0x48]
mov word [eax + 8], 0x64
mov dword [eax + 4], 0x6574696d
mov dword [eax], 0x696c6e75
jmp 0x404ab9
lea edx, [esp + 0x18]
push edx
push ecx
push eax
call fcn.00412c60
add esp, 0xc
test eax, eax
jne 0x404af3
mov eax, dword [esp + 0x2c]
mov ecx, 0x76c
add eax, ecx
mov ecx, dword [esp + 0x28]
inc ecx
push dword [esp + 0x18]
push dword [esp + 0x20]
push dword [esp + 0x28]
push dword [esp + 0x30]
push ecx
push eax
push 0xe9fcd4
push 0x12
lea eax, [esp + 0x68]
push eax
call fcn.0040ad30
add esp, 0x24
push dword [ebx + 0x1cc]
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x44]
push eax
push ebx
call dword [ebx + 0x1c8]
add esp, 0x10
cmp eax, 2
je 0x404aee
mov ecx, eax
xor eax, eax
test ecx, ecx
jne 0x404af3
inc dword [esp + 0x10]
test esi, esi
jne 0x404a00
jmp 0x404af3
mov eax, 0x2b
add esp, 0x5c
pop esi
pop edi
pop ebx
pop ebp
ret