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

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x5c
mov esi, dword [esp + 0xac]
mov eax, dword [ecx + 0x48]
mov ebp, dword [eax + 4]
mov dword [esp + 0x58], ebp
test esi, esi
je 0x40671e
cmp dword [eax + 0x34], 0
jne 0x40671e
mov dword [ecx + 0x1c], 3
jmp 0x406bf6
mov dword [esp + 0x50], esi
mov dword [esp + 0x4c], edx
mov dword [esp + 0x54], eax
mov dword [esp], ecx
xor ecx, ecx
mov dword [esp + 0x40], ebp
add ebp, 0x2e
setb cl
movzx edi, word [esp + 0x70]
mov esi, ebp
xor esi, edi
mov edx, ebp
mov eax, edi
mov dword [esp + 0x3c], edi
and edx, edi
add edx, edx
movzx eax, word [esp + 0x78]
movzx ebx, ax
movzx edi, word [esp + 0x80]
mov eax, edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x38], ebx
add edi, ebx
xor eax, eax
add edi, dword [esp + 0xb8]
setb al
add edi, esi
adc eax, ecx
add edi, edx
adc eax, 0
cmp edi, 0xffffffff
sbb eax, 0
jb 0x406796
mov eax, dword [esp]
mov dword [eax + 0x1c], 0xf
jmp 0x406bf6
mov esi, dword [esp + 0x90]
mov eax, dword [esp + 0x88]
mov dword [esp + 0x48], eax
mov ebx, dword [esp + 0xb0]
mov dword [esp + 0xa], 0
mov dword [esp + 0xe], 0
mov dword [esp + 0x12], 0
mov dword [esp + 0x16], 0
mov dword [esp + 0x1a], 0
mov dword [esp + 0x1e], 0
mov dword [esp + 0x22], 0
mov dword [esp + 0x26], 0
mov word [esp + 0x2a], 0
mov dword [esp + 6], 0x2014b50
movzx edi, word [esp + 0x9c]
mov ecx, dword [esp + 0x94]
mov eax, dword [esp + 0xb8]
movzx edx, word [esp + 0x78]
add eax, edx
mov dword [esp + 0x44], eax
xor edx, edx
mov eax, 0
cmp word [esp + 0x98], 0
je 0x406833
mov al, 0x14
mov byte [esp + 0xc], al
mov eax, edi
mov byte [esp + 0xe], al
mov byte [esp + 0xf], ah
movzx eax, word [esp + 0x98]
mov byte [esp + 0x10], al
mov byte [esp + 0x11], ah
movzx eax, word [esp + 0xa0]
mov byte [esp + 0x12], al
mov byte [esp + 0x13], ah
movzx eax, word [esp + 0xa4]
mov byte [esp + 0x14], al
mov byte [esp + 0x15], ah
mov byte [esp + 0x16], cl
mov byte [esp + 0x17], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x18], al
shr ecx, 0x18
mov byte [esp + 0x19], cl
neg esi
mov ecx, 0
sbb ecx, ecx
or ecx, dword [esp + 0x8c]
mov byte [esp + 0x1a], cl
mov byte [esp + 0x1b], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x1c], al
shr ecx, 0x18
mov byte [esp + 0x1d], cl
neg dword [esp + 0x48]
mov ecx, 0
sbb ecx, ecx
or ecx, dword [esp + 0x84]
mov byte [esp + 0x1e], cl
mov byte [esp + 0x1f], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x20], al
shr ecx, 0x18
mov byte [esp + 0x21], cl
movzx eax, word [esp + 0x70]
mov byte [esp + 0x22], al
mov byte [esp + 0x23], ah
mov eax, dword [esp + 0x44]
mov byte [esp + 0x24], al
mov byte [esp + 0x25], ah
movzx eax, word [esp + 0x80]
mov byte [esp + 0x26], al
mov byte [esp + 0x27], ah
mov byte [esp + 0x2c], bl
mov byte [esp + 0x2d], bh
mov eax, ebx
shr eax, 0x10
mov byte [esp + 0x2e], al
shr ebx, 0x18
mov byte [esp + 0x2f], bl
neg dword [esp + 0x50]
sbb edx, edx
or edx, dword [esp + 0xa8]
mov byte [esp + 0x30], dl
mov byte [esp + 0x31], dh
mov eax, edx
shr eax, 0x10
mov byte [esp + 0x32], al
shr edx, 0x18
mov byte [esp + 0x33], dl
mov ebx, dword [esp + 0x54]
mov ecx, dword [ebx + 8]
cmp ecx, ebp
jae 0x40698a
mov eax, 1
test ecx, ecx
je 0x406960
mov eax, ecx
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, eax
add eax, eax
cmp esi, ebp
jb 0x406960
push esi
push dword [ebx + 0xc]
push dword [ebx]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx], eax
mov dword [ebx + 8], esi
jmp 0x40698c
mov eax, dword [ebx]
mov dword [ebx + 4], ebp
mov ecx, dword [ebx + 0xc]
imul edx, ecx, 0x2e
imul ecx, dword [esp + 0x40]
add ecx, eax
lea eax, [esp + 6]
push edx
push eax
push ecx
call fcn.00408d00
add esp, 0xc
mov esi, dword [ebx + 4]
mov ebp, dword [ebx + 8]
mov eax, dword [esp + 0x3c]
lea edi, [esi + eax]
cmp ebp, edi
jae 0x4069f8
mov eax, 1
test ebp, ebp
je 0x4069d0
mov eax, ebp
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ebp, eax
add eax, eax
cmp ebp, edi
jb 0x4069d0
push ebp
push dword [ebx + 0xc]
push dword [ebx]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx], eax
mov dword [ebx + 8], ebp
mov dword [ebx + 4], edi
cmp word [esp + 0x70], 0
je 0x406a26
mov eax, dword [ebx + 0xc]
imul esi, eax
add esi, dword [ebx]
mov ecx, dword [esp + 0x3c]
imul ecx, eax
push ecx
push dword [esp + 0x50]
push esi
call fcn.00408d00
add esp, 0xc
mov edi, dword [ebx + 4]
mov ebp, dword [ebx + 8]
mov eax, dword [esp + 0x38]
lea esi, [edi + eax]
cmp ebp, esi
jae 0x406a68
mov eax, 1
test ebp, ebp
je 0x406a40
mov eax, ebp
nop
nop
nop
nop
mov ebp, eax
add eax, eax
cmp ebp, esi
jb 0x406a40
push ebp
push dword [ebx + 0xc]
push dword [ebx]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx], eax
mov dword [ebx + 8], ebp
movzx eax, word [esp + 0x78]
mov dword [ebx + 4], esi
test ax, ax
je 0x406a98
mov eax, dword [ebx + 0xc]
imul edi, eax
add edi, dword [ebx]
mov ecx, dword [esp + 0x38]
imul ecx, eax
push ecx
push dword [esp + 0x78]
push edi
call fcn.00408d00
add esp, 0xc
mov esi, dword [ebx + 4]
mov ebp, dword [ebx + 8]
mov eax, dword [esp + 0xb8]
lea edi, [esi + eax]
cmp ebp, edi
jae 0x406ae8
mov eax, 1
test ebp, ebp
je 0x406ac0
mov eax, ebp
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ebp, eax
add eax, eax
cmp ebp, edi
jb 0x406ac0
push ebp
push dword [ebx + 0xc]
push dword [ebx]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx], eax
mov dword [ebx + 8], ebp
mov dword [ebx + 4], edi
mov ecx, dword [esp + 0xb8]
test ecx, ecx
je 0x406b18
mov eax, dword [ebx + 0xc]
imul esi, eax
add esi, dword [ebx]
imul ecx, eax
push ecx
push dword [esp + 0xb8]
push esi
call fcn.00408d00
add esp, 0xc
mov edi, dword [ebx + 4]
mov ebp, dword [ebx + 8]
mov eax, dword [esp + 0x34]
lea esi, [edi + eax]
cmp ebp, esi
jae 0x406b54
mov eax, 1
test ebp, ebp
je 0x406b30
mov eax, ebp
nop
nop
mov ebp, eax
add eax, eax
cmp ebp, esi
jb 0x406b30
push ebp
push dword [ebx + 0xc]
push dword [ebx]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx], eax
mov dword [ebx + 8], ebp
mov dword [ebx + 4], esi
cmp word [esp + 0x80], 0
je 0x406b82
mov eax, dword [ebx + 0xc]
imul edi, eax
add edi, dword [ebx]
mov ecx, dword [esp + 0x34]
imul ecx, eax
push ecx
push dword [esp + 0x80]
push edi
call fcn.00408d00
add esp, 0xc
mov esi, dword [ebx + 0x14]
mov ecx, dword [ebx + 0x18]
lea edi, [esi + 1]
cmp ecx, edi
jae 0x406c00
mov eax, 1
test ecx, ecx
je 0x406ba0
mov eax, ecx
nop
nop
nop
nop
nop
nop
mov ebp, eax
add eax, eax
cmp ebp, edi
jb 0x406ba0
push ebp
push dword [ebx + 0x1c]
push dword [ebx + 0x10]
mov eax, dword [esp + 0xc]
push dword [eax + 0x34]
call dword [eax + 0x30]
add esp, 0x10
test eax, eax
je 0x406bc8
mov dword [ebx + 0x10], eax
mov dword [ebx + 0x18], ebp
jmp 0x406c03
mov edi, dword [esp + 0x40]
cmp dword [ebx + 8], edi
mov esi, dword [esp]
jae 0x406bec
push edi
push dword [ebx + 0xc]
push dword [ebx]
push dword [esi + 0x34]
call dword [esi + 0x30]
add esp, 0x10
test eax, eax
je 0x406bef
mov dword [ebx], eax
mov dword [ebx + 8], edi
mov dword [ebx + 4], edi
mov dword [esi + 0x1c], 0x10
xor eax, eax
add esp, 0x5c
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [ebx + 0x10]
mov dword [ebx + 0x14], edi
mov ecx, dword [ebx + 0x1c]
imul esi, ecx
add esi, eax
lea eax, [esp + 0x58]
push ecx
push eax
push esi
call fcn.00408d00
add esp, 0xc
mov eax, 1
jmp 0x406bf8