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

Disassembly:
sub esp, 0x94
push esi
push edi
mov edi, dword [esp + 0xa0]
xor esi, esi
cmp edi, esi
mov dword [esp + 0x10], esi
je 0x407a7c
push esi
call dword [0x40a04c]
cmp eax, esi
mov dword [esp + 0xc], eax
je 0x407a7c
push ebx
mov ebx, dword [0x40a058]
lea eax, [esp + 0x44]
push ebp
push eax
push 0x18
push edi
call ebx
mov ecx, dword [esp + 0x4c]
mov edx, dword [esp + 0x50]
push esi
lea eax, [esp + 0xa4]
mov dword [esp + 0x68], ecx
push esi
mov dword [esp + 0x70], edx
mov edx, dword [esp + 0x1c]
push eax
lea ecx, [esp + 0x6c]
push esi
mov ebp, 1
push ecx
push edx
mov dword [esp + 0x78], 0x28
mov word [esp + 0x84], bp
mov word [esp + 0x86], 0x20
mov dword [esp + 0x88], esi
mov dword [esp + 0x8c], esi
mov dword [esp + 0x90], esi
mov dword [esp + 0x94], esi
mov dword [esp + 0x98], esi
mov dword [esp + 0x9c], esi
call dword [0x40a02c]
mov esi, eax
test esi, esi
je 0x407a60
mov eax, dword [esp + 0x14]
push esi
push eax
call dword [0x40a030]
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x40], eax
push ecx
call dword [0x40a04c]
test eax, eax
mov dword [esp + 0x30], eax
je 0x407a49
lea edx, [esp + 0x88]
push edx
push 0x18
push esi
call ebx
mov eax, dword [esp + 0x94]
mov ecx, eax
and ecx, 0x80000003
jns 0x40772a
dec ecx
or ecx, 0xfffffffc
inc ecx
je 0x407745
inc eax
mov edx, eax
and edx, 0x80000003
jns 0x40773c
dec edx
or edx, 0xfffffffc
inc edx
jne 0x40772c
mov dword [esp + 0x94], eax
push edi
mov edi, dword [esp + 0x34]
push edi
call dword [0x40a030]
mov ecx, dword [esp + 0x4c]
mov edx, dword [esp + 0x14]
xor ebx, ebx
push 0xcc0020
mov dword [esp + 0x48], eax
mov eax, dword [esp + 0x54]
push ebx
push ebx
push edi
push eax
push ecx
push ebx
push ebx
push edx
call dword [0x40a034]
push 0x660
push 2
mov dword [esp + 0x24], 0x64
call dword [0x40a0e4]
push eax
mov dword [esp + 0x28], eax
call dword [0x40a0e8]
mov esi, eax
push ebx
push ebx
push 0x7fffffff
lea eax, [esi + 0x10]
push 0x7fffffff
push eax
mov dword [esi], 0x20
mov dword [esi + 4], ebp
mov dword [esi + 0xc], ebx
mov dword [esi + 8], ebx
call dword [0x40a444]
mov ebx, dword [esp + 0xac]
xor eax, eax
mov ecx, dword [esp + 0xb0]
mov al, bh
mov byte [esp + 0x3c], al
mov eax, ebx
shr eax, 0x10
mov byte [esp + 0x38], al
mov eax, ecx
mov edx, 0xff
and eax, edx
and ebx, edx
add eax, ebx
mov byte [esp + 0x12], dl
cmp eax, edx
jg 0x4077f5
mov byte [esp + 0x12], al
mov ebx, dword [esp + 0x3c]
xor eax, eax
mov al, ch
and ebx, edx
and eax, edx
mov byte [esp + 0x11], dl
add eax, ebx
cmp eax, edx
jg 0x40780f
mov byte [esp + 0x11], al
mov eax, dword [esp + 0x38]
mov byte [esp + 0x13], dl
shr ecx, 0x10
and ecx, edx
and eax, edx
add ecx, eax
cmp ecx, edx
jg 0x407828
mov byte [esp + 0x13], cl
mov ecx, dword [esp + 0x90]
mov edx, dword [esp + 0x9c]
dec ecx
mov eax, dword [esp + 0x50]
imul ecx, dword [esp + 0x94]
add ecx, edx
mov dword [esp + 0x20], 0
test eax, eax
mov dword [esp + 0x28], ecx
jle 0x4079f5
mov edi, dword [esp + 0x4c]
xor ebx, ebx
test edi, edi
jle 0x4079cf
mov edx, dword [esp + 0x1c]
lea eax, [edx + 2]
shl eax, 4
mov dword [esp + 0x2c], eax
cmp ebx, edi
mov dword [esp + 0x34], ebx
lea ecx, [ecx + ebx*4]
jge 0x4079c2
mov al, byte [ecx]
mov dl, byte [esp + 0xac]
cmp al, dl
jb 0x4078bd
cmp al, byte [esp + 0x12]
ja 0x4078bd
mov dl, byte [esp + 0x3c]
xor eax, eax
mov al, byte [ecx + 1]
cmp al, dl
jb 0x4078bd
cmp al, byte [esp + 0x11]
ja 0x4078bd
mov eax, dword [ecx]
mov dl, byte [esp + 0x38]
sar eax, 0x10
cmp al, dl
jb 0x4078bd
cmp al, byte [esp + 0x13]
jbe 0x4078c5
add ecx, 4
inc ebx
cmp ebx, edi
jl 0x407884
mov ebp, dword [esp + 0x34]
cmp ebx, ebp
jle 0x4079c2
mov eax, dword [esi + 8]
mov ecx, dword [esp + 0x1c]
cmp eax, ecx
jb 0x407916
mov esi, dword [esp + 0x24]
push esi
call dword [0x40a0dc]
mov eax, dword [esp + 0x2c]
mov edi, dword [esp + 0x1c]
add eax, 0x640
push 2
add edi, 0x64
push eax
push esi
mov dword [esp + 0x28], edi
mov dword [esp + 0x38], eax
call dword [0x40a0d8]
push eax
mov dword [esp + 0x28], eax
call dword [0x40a0e8]
mov esi, eax
mov eax, dword [esp + 0x20]
mov ecx, dword [esi + 8]
add ecx, 2
lea edi, [eax + 1]
push edi
push ebx
shl ecx, 4
push eax
add ecx, esi
push ebp
push ecx
call dword [0x40a444]
mov eax, dword [esp + 0x34]
mov ecx, dword [esi + 0x10]
lea ebp, [esi + 0x10]
cmp eax, ecx
jge 0x407944
mov dword [ebp], eax
mov eax, dword [esp + 0x20]
mov ecx, dword [esi + 0x14]
cmp eax, ecx
jge 0x407952
mov dword [esi + 0x14], eax
cmp ebx, dword [esi + 0x18]
jle 0x40795a
mov dword [esi + 0x18], ebx
cmp edi, dword [esi + 0x1c]
jle 0x407962
mov dword [esi + 0x1c], edi
mov ecx, dword [esi + 8]
inc ecx
mov eax, ecx
mov dword [esi + 8], ecx
cmp eax, 0x7d0
jne 0x4079be
mov edx, dword [esp + 0x2c]
push esi
push edx
push 0
call dword [0x40a038]
mov edi, eax
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40799e
push 2
push edi
push eax
push eax
call dword [0x40a03c]
push edi
call dword [0x40a040]
jmp 0x4079a2
mov dword [esp + 0x18], edi
push 0
push 0
push 0x7fffffff
push 0x7fffffff
push ebp
mov dword [esi + 8], 0
call dword [0x40a444]
mov edi, dword [esp + 0x4c]
mov ecx, dword [esp + 0x28]
inc ebx
cmp ebx, edi
jl 0x407875
mov ebp, dword [esp + 0x94]
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x50]
sub ecx, ebp
inc eax
mov dword [esp + 0x28], ecx
cmp eax, edx
mov dword [esp + 0x20], eax
jl 0x40785d
mov edi, dword [esp + 0x30]
mov eax, dword [esp + 0x1c]
push esi
add eax, 2
shl eax, 4
push eax
push 0
call dword [0x40a038]
mov esi, eax
mov eax, dword [esp + 0x18]
test eax, eax
je 0x407a27
push 2
push esi
push eax
push eax
call dword [0x40a03c]
push esi
call dword [0x40a040]
jmp 0x407a2b
mov dword [esp + 0x18], esi
mov ecx, dword [esp + 0x24]
push ecx
call dword [0x40a0d4]
mov edx, dword [esp + 0x44]
push edx
push edi
call dword [0x40a030]
push edi
call dword [0x40a044]
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x14]
push eax
push ecx
call dword [0x40a030]
push eax
call dword [0x40a040]
mov edx, dword [esp + 0x14]
push edx
call dword [0x40a044]
mov eax, dword [esp + 0x18]
pop ebp
pop ebx
pop edi
pop esi
add esp, 0x94
ret 0xc
mov eax, esi
pop edi
pop esi
add esp, 0x94
ret 0xc