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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x44
mov eax, dword [0x45b040]
xor eax, esp
mov dword [esp + 0x40], eax
push ebx
push esi
push edi
xor eax, eax
mov edi, ecx
xor ebx, ebx
mov word [esp + 0x10], ax
mov word [esp + 0xc], ax
test edi, edi
jne 0x405495
or ebx, 0xffffffff
jmp 0x405706
cmp dword [edi + 0x14], 1
je 0x4056e5
test byte [edi + 0x50], 0xf
je 0x405504
and dword [esp + 0x14], eax
mov edx, 0x450692
push 4
push ecx
push ecx
lea eax, [esp + 0x20]
push eax
lea ecx, [edi + 0xc8]
call fcn.004035bc
add esp, 0x10
cmp eax, 1
je 0x4054d6
test eax, eax
je 0x4054d6
push 0xfffffffffffffff4
pop ebx
jmp 0x4056e5
mov eax, dword [edi + 0xc0]
mov ecx, dword [edi + 0xc4]
mov dword [edi + 0x68], eax
mov eax, dword [edi + 0xb8]
push 8
mov dword [edi + 0x78], eax
mov dword [edi + 0x6c], ecx
mov ecx, dword [edi + 0xbc]
pop eax
mov dword [edi + 0x7c], ecx
mov word [edi + 0xa8], ax
mov ecx, dword [edi + 0x5c]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40550a
push dword [edi + 0x4e014]
sub ecx, edx
lea edx, [esp + 0x10]
push dword [edi + 0x4e010]
movzx eax, cx
lea ecx, [esp + 0x18]
mov dword [esp + 0x1c], eax
call fcn.0040398c
pop ecx
mov edx, dword [edi + 0x6c]
pop ecx
mov ecx, dword [edi + 0x70]
push 8
pop eax
mov byte [esp + 0x1b], al
mov eax, ecx
shr eax, 8
mov byte [esp + 0x1d], al
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x1e], al
mov byte [esp + 0x1c], cl
shr ecx, 0x18
mov byte [esp + 0x1f], cl
mov ecx, dword [edi + 0x68]
mov eax, ecx
shr eax, 8
mov byte [esp + 0x21], al
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x22], al
mov eax, edx
shr eax, 8
mov byte [esp + 0x25], al
mov eax, edx
shr eax, 0x10
mov byte [esp + 0x26], al
mov byte [esp + 0x20], cl
shr ecx, 0x18
mov byte [esp + 0x23], cl
mov ecx, dword [edi + 0x60]
mov eax, ecx
shr eax, 8
mov byte [esp + 0x29], al
mov eax, ecx
mov esi, dword [edi + 0x3c]
shr eax, 0x10
mov byte [esp + 0x24], dl
shr edx, 0x18
mov byte [esp + 0x2a], al
mov byte [esp + 0x27], dl
mov edx, dword [edi + 0x64]
mov eax, edx
shr eax, 8
mov byte [esp + 0x2d], al
mov eax, edx
shr eax, 0x10
push 0x18
mov byte [esp + 0x32], al
lea eax, [esp + 0x1c]
push eax
push dword [edi + 0x7c]
mov byte [esp + 0x34], cl
push dword [edi + 0x78]
shr ecx, 0x18
push dword [edi + 0x44]
mov byte [esp + 0x40], dl
mov byte [esp + 0x3f], cl
mov ecx, esi
shr edx, 0x18
mov word [esp + 0x2c], 0x4b50
mov byte [esp + 0x2e], 7
mov byte [esp + 0x43], dl
call dword [0x448184]
call esi
add esp, 0x14
cmp eax, 0x18
je 0x405614
push 0xfffffffffffffff2
jmp 0x4054d0
add dword [edi + 0x78], 0x18
lea eax, [edi + 0xa0]
push 0
pop esi
adc dword [edi + 0x7c], esi
cmp dword [eax + 4], esi
ja 0x405630
cmp dword [eax], 0xffffffff
jae 0x405630
mov eax, esi
lea ecx, [edi + 0x68]
cmp dword [ecx + 4], esi
ja 0x40563f
cmp dword [ecx], 0xffffffff
jae 0x40563f
mov ecx, esi
lea edx, [edi + 0x60]
cmp dword [edx + 4], esi
ja 0x40564e
cmp dword [edx], 0xffffffff
jae 0x40564e
mov edx, esi
push eax
push ecx
lea ecx, [esp + 0x38]
call fcn.00404539
mov edx, dword [esp + 0x1c]
mov esi, eax
pop ecx
pop ecx
test dx, dx
je 0x405682
mov eax, dword [edi + 0x5c]
movzx ecx, dx
cmp byte [eax + ecx - 1], 0x2f
jne 0x405682
mov eax, dword [edi + 0x60]
or eax, dword [edi + 0x64]
jne 0x405682
or dword [edi + 0x4e008], 0x10
push ecx
push ecx
push dword [edi + 0x4e008]
movzx eax, word [edi + 0xa8]
push dword [edi + 0xa4]
push dword [edi + 0xa0]
push dword [esp + 0x20]
push dword [esp + 0x28]
push ecx
push eax
push dword [edi + 0x70]
lea eax, [esp + 0x58]
push dword [edi + 0x6c]
push dword [edi + 0x68]
push dword [edi + 0x64]
push dword [edi + 0x60]
push ecx
push ecx
push esi
push eax
push edx
mov edx, dword [edi + 0x5c]
mov ecx, edi
call fcn.004047ce
add esp, 0x4c
test eax, eax
jne 0x4056d7
push 0xfffffffffffffff1
jmp 0x4054d0
inc dword [edi + 0x10]
mov eax, dword [edi + 0x78]
mov ecx, dword [edi + 0x7c]
mov dword [edi], eax
mov dword [edi + 4], ecx
and dword [edi + 0x4e010], 0
and dword [edi + 0x4e014], 0
cmp dword [edi + 0x5c], 0
je 0x405706
push dword [edi + 0x5c]
call fcn.00425247
and dword [edi + 0x5c], 0
pop ecx
mov ecx, dword [esp + 0x4c]
mov eax, ebx
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0041df18
mov esp, ebp
pop ebp
ret