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

Disassembly:
push 0xffffffffffffffff
push 0x478dd8
mov eax, dword fs:[0]
push eax
sub esp, 0x50
push ebx
push ebp
push esi
push edi
mov eax, dword [0x498550]
xor eax, esp
push eax
lea eax, [esp + 0x64]
mov dword fs:[0], eax
mov ecx, dword [esp + 0x7c]
mov eax, dword [esp + 0x78]
mov esi, dword [esp + 0x80]
xor ebx, ebx
mov dword [edx + 0x18], ecx
mov dword [esp + 0x38], ecx
mov dword [esp + 0x48], ecx
mov dword [esp + 0x50], ecx
mov ecx, dword [esp + 0x74]
mov dword [edx + 0x14], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x4c], eax
mov eax, dword [ecx + 0x14]
test al, 2
mov dword [esp + 0x2c], esi
mov esi, dword [esp + 0x84]
mov dword [esp + 0x28], ebx
mov dword [esp + 0x30], esi
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x54], ebx
mov dword [esp + 0x58], ebx
mov byte [esp + 0x5c], bl
mov byte [esp + 0x5d], bl
je 0x40a8ab
mov ecx, eax
and ecx, 0x80
cmp cl, 0x80
sete byte [esp + 0x80]
and eax, 0x40
cmp al, 0x40
sete byte [esp + 0x78]
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
lea edi, [edx + 4]
push edi
lea edx, [esp + 0x2c]
mov dword [esp + 0x70], ebx
mov eax, dword [esp + 0x78]
push edx
push eax
call fcn.0040aed0
add esp, 0xc
test al, al
je 0x40a832
jmp 0x40a750
cmp byte [esp + 0x78], 0
mov ebp, dword [esp + 0x28]
je 0x40a767
push ebp
lea esi, [esp + 0x1c]
call fcn.0040a970
jmp 0x40a7e6
cmp byte [esp + 0x80], 0
je 0x40a7bc
mov eax, dword [edi + 8]
cmp dword [edi + 4], eax
mov dword [esp + 0x14], eax
jbe 0x40a782
call fcn.0045d601
mov esi, dword [edi + 4]
cmp esi, dword [edi + 8]
jbe 0x40a78f
call fcn.0045d601
mov ebx, dword [esp + 0x20]
cmp dword [esp + 0x1c], ebx
jbe 0x40a79e
call fcn.0045d601
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x74]
push ecx
push edi
push esi
push edi
lea eax, [esp + 0x28]
push ebx
push eax
push edx
mov ecx, eax
call fcn.0040b5d0
xor ebx, ebx
jmp 0x40a7e6
mov ecx, dword [edi + 4]
mov eax, dword [esp + 0x1c]
mov dword [edi + 4], eax
mov eax, dword [esp + 0x20]
mov edx, dword [edi + 8]
mov dword [edi + 8], eax
mov eax, dword [esp + 0x24]
mov dword [esp + 0x1c], ecx
mov ecx, dword [edi + 0xc]
mov dword [esp + 0x20], edx
mov dword [esp + 0x24], ecx
mov dword [edi + 0xc], eax
mov edx, dword [ebp + 8]
mov dword [esp + 0x4c], edx
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x50], eax
mov eax, dword [ebp]
cmp eax, 0xfffffffe
je 0x40a80a
cmp eax, ebx
je 0x40a805
cmp eax, dword [ebp + 8]
je 0x40a80a
call fcn.0045d601
mov ecx, dword [ebp + 4]
cmp ecx, dword [ebp + 0xc]
mov ecx, dword [esp + 0x74]
push edi
lea eax, [esp + 0x2c]
push eax
sete dl
push ecx
mov byte [esp + 0x68], dl
call fcn.0040aed0
add esp, 0xc
test al, al
jne 0x40a750
mov ecx, dword [edi + 4]
mov edx, dword [esp + 0x1c]
mov dword [edi + 4], edx
mov eax, dword [edi + 8]
mov edx, dword [esp + 0x20]
mov dword [edi + 8], edx
mov edx, dword [esp + 0x24]
mov dword [esp + 0x20], eax
mov eax, dword [edi + 0xc]
mov dword [edi + 0xc], edx
mov dword [esp + 0x24], eax
mov eax, dword [edi + 4]
cmp eax, ebx
mov dword [esp + 0x1c], ecx
jne 0x40a867
xor eax, eax
jmp 0x40a87f
mov edi, dword [edi + 8]
sub edi, eax
mov eax, 0x88888889
imul edi
add edx, edi
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, ebx
setne byte [esp + 0x74]
cmp ecx, ebx
je 0x40a893
push ecx
call fcn.0043f84a
add esp, 4
mov al, byte [esp + 0x74]
mov ecx, dword [esp + 0x64]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x5c
ret
add edx, 4
push edx
lea eax, [esp + 0x2c]
push eax
push ecx
call fcn.0040aed0
add esp, 0xc
mov ecx, dword [esp + 0x64]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x5c
ret