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

Disassembly:
sub esp, 0xb48
push ebp
mov ebp, ecx
mov eax, dword [ebp + 0x24]
cmp eax, 1
push esi
jne 0x4206d2
mov ecx, dword [ebp + 4]
mov eax, dword [ecx + 0x20]
test eax, eax
jne 0x420691
call fcn.004232b0
mov ecx, dword [esp + 0xb64]
fld qword [esp + 0xb54]
mov edx, dword [esp + 0xb60]
mov esi, dword [ebp]
push eax
mov eax, dword [esp + 0xb6c]
push eax
mov eax, dword [esp + 0xb64]
push ecx
push edx
push eax
call fcn.004ae0e0
push eax
mov ecx, ebp
call dword [esi + 0x14]
pop esi
pop ebp
add esp, 0xb48
ret 0x1c
cmp eax, 2
jne 0x420e99
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
push ebx
push edi
mov edi, dword [ecx + 0x24]
lea eax, [esp + 0x44]
push eax
mov ecx, ebp
mov dword [esp + 0x40], edi
call dword [edx + 0x24]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x28], ebx
je 0x420e97
mov ecx, dword [ebp + 4]
mov eax, dword [ecx + 0x20]
test eax, eax
jne 0x420711
call fcn.004232b0
mov ecx, dword [ebx + 0x64]
mov esi, eax
test byte [ebx + 0x30], 4
je 0x420729
movzx edx, word [ebx + 0x2e]
mov eax, dword [esp + 0x44]
lea eax, [eax + edx*2]
jmp 0x420731
movzx eax, word [ebx + 0x2e]
add eax, dword [esp + 0x44]
mov edx, dword [ebp]
add eax, 6
add eax, ecx
mov ecx, dword [esp + 0xb68]
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0xb6c]
push eax
push ecx
mov ecx, ebp
call dword [edx + 0x28]
test eax, eax
mov dword [esp + 0x34], eax
je 0x420e97
cmp esi, 8
mov dword [esp + 0x2c], 0
jl 0x420783
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x30]
test al, al
je 0x420783
mov eax, dword [ebp]
mov ecx, ebp
call dword [eax + 0x2c]
mov dword [esp + 0x2c], eax
cmp esi, 8
mov dword [esp + 0x38], 0
jl 0x4207b3
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x34]
test eax, eax
je 0x4207b3
mov eax, dword [ebp]
push 0
mov ecx, ebp
call dword [eax + 0x34]
mov ecx, dword [ebp + 4]
push eax
call fcn.00424900
mov dword [esp + 0x38], eax
mov ecx, dword [edi + 0x18]
add ecx, 0x44
mov edx, dword [ecx]
mov dword [esp + 0x88], edx
mov eax, dword [ecx + 4]
mov dword [esp + 0x8c], eax
mov edx, dword [ecx + 8]
mov dword [esp + 0x90], edx
mov eax, dword [ecx + 0xc]
lea ecx, [esp + 0x88]
push ecx
push 0x28
mov dword [esp + 0x9c], eax
call fcn.00438d80
mov ecx, dword [ebp + 4]
lea edx, [esp + 0x90]
push edx
mov eax, edx
push eax
add ecx, 0xe8
push ecx
call fcn.00437a70
mov ecx, dword [ebp + 4]
mov eax, dword [ecx + 0x20]
add esp, 0x14
test eax, eax
jne 0x42081b
call fcn.004232b0
mov edx, dword [ebp]
push eax
mov ecx, ebp
call dword [edx + 0x20]
cmp esi, 7
jl 0x420834
test byte [ebx + 0x30], 0x20
mov byte [esp + 0x13], 1
jne 0x420839
mov byte [esp + 0x13], 0
mov eax, dword [ebp + 4]
mov ecx, dword [eax + 0x2c]
push ecx
lea edx, [esp + 0x54]
push edx
call fcn.004380a0
fld qword [esp + 0xb64]
mov al, byte [esp + 0x1b]
add esp, 8
test al, al
je 0x4208e0
call fcn.004ae0e0
mov ecx, eax
cdq
mov esi, 0x14
idiv esi
cmp edx, 0xa
jl 0x420894
add ecx, 0xa
mov eax, 0x66666667
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
lea eax, [eax + eax*4]
shl eax, 2
mov dword [esp + 0x60], eax
jmp 0x42089e
lea ecx, [eax + eax*4]
shl ecx, 2
mov dword [esp + 0x60], ecx
mov ecx, dword [esp + 0xb64]
mov eax, ecx
cdq
mov esi, 0x14
idiv esi
cmp edx, 0xa
jl 0x4208d4
add ecx, 0xa
mov eax, 0x66666667
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
lea edx, [eax + eax*4]
shl edx, 2
mov dword [esp + 0x64], edx
jmp 0x4208f4
lea eax, [eax + eax*4]
shl eax, 2
mov dword [esp + 0x64], eax
jmp 0x4208f4
call fcn.004ae0e0
mov ecx, dword [esp + 0xb64]
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], ecx
cmp byte [ebx + 0x6f], 0x4b
mov esi, 0x400
mov dword [esp + 0x30], esi
mov dword [esp + 0x20], 0x44800000
jne 0x42091c
mov esi, 0x5000
mov dword [esp + 0x30], esi
mov dword [esp + 0x20], 0x46a00000
mov eax, dword [ebp + 4]
test eax, eax
je 0x420973
mov eax, dword [eax + 0x2c]
test eax, eax
je 0x420973
mov ecx, eax
call fcn.00497d50
test al, al
je 0x420973
cmp dword [esp + 0x68], 1
je 0x420949
lea edx, [esp + 0x50]
push edx
call fcn.00437620
add esp, 4
mov eax, dword [ebp]
mov ecx, ebp
call dword [eax + 0x38]
test eax, eax
jge 0x420957
neg eax
fld dword [str..ssr]
mov dword [esp + 0x14], eax
fdiv dword [esp + 0x20]
fimul dword [esp + 0x14]
fst dword [esp + 0x5c]
fstp dword [esp + 0x50]
jmp 0x4209b2
cmp dword [esp + 0x68], 1
jne 0x420987
lea ecx, [esp + 0x50]
push ecx
call fcn.00437660
add esp, 4
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x38]
test eax, eax
jge 0x420995
neg eax
mov ecx, eax
mov eax, 0x10000
cdq
idiv esi
mov dword [esp + 0x68], 0
imul eax, ecx
mov dword [esp + 0x5c], eax
mov dword [esp + 0x50], eax
mov ebx, dword [esp + 0xb74]
mov edi, dword [esp + 0xb70]
xor esi, esi
test ebx, ebx
mov dword [esp + 0x48], esi
je 0x420a92
mov eax, dword [ebx + 4]
push eax
call fcn.004601e0
add esp, 4
test al, al
je 0x420a92
mov eax, dword [ebx + 4]
mov ecx, dword [eax + 0x18]
mov ecx, dword [ecx + 0x5c]
mov eax, dword [ecx + 0x1ac]
test eax, eax
jne 0x4209fa
call fcn.00486cc0
cmp eax, 8
jl 0x420a92
mov edx, dword [ebp + 4]
mov ecx, dword [edx + 0x24]
call fcn.004763b0
mov ecx, dword [eax + 0xfc]
test ecx, ecx
jne 0x420a92
mov eax, dword [esp + 0x28]
push eax
call fcn.0045ef70
mov esi, eax
mov eax, dword [ebp + 4]
lea ecx, [eax + 0x348]
mov dword [esp + 0x20], edi
mov eax, dword [ecx]
add esp, 4
test eax, eax
mov dword [esp + 0x48], esi
je 0x420a4f
push edi
lea edx, [esp + 0x28]
push edx
call fcn.00459a00
mov eax, dword [eax]
mov dword [esp + 0x1c], eax
mov al, byte [esp + 0x1f]
cmp al, 0xff
je 0x420a92
movzx ecx, byte [esp + 0x1c]
movzx eax, al
inc eax
imul ecx, eax
sar ecx, 8
mov byte [esp + 0x1c], cl
mov edx, dword [esp + 0x1c]
shr edx, 8
movzx edx, dl
imul edx, eax
sar edx, 8
mov byte [esp + 0x1d], dl
mov ecx, dword [esp + 0x1c]
shr ecx, 0x10
movzx ecx, cl
imul ecx, eax
sar ecx, 8
mov byte [esp + 0x1e], cl
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x38]
test eax, eax
jge 0x420aa0
neg eax
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 4]
mov ecx, dword [eax + 0x2c]
mov edx, dword [ecx + 0x3dc]
mov ebx, dword [edx]
mov ecx, dword [esp + 0xb6c]
xor eax, eax
test esi, esi
mov dword [esp + 0x14], ebx
je 0x420c5b
test ecx, ecx
fld qword [esp + 0xb5c]
fstp dword [esp + 0x3c]
mov dword [esp + 0x24], eax
fild dword [esp + 0xb64]
fstp dword [esp + 0x40]
jle 0x420e8a
mov edi, dword [esp + 0xb68]
mov ebx, dword [esp + 0xb74]
jmp 0x420b00
mov ecx, dword [esp + 0x34]
mov si, word [ecx + eax*2]
cmp si, 0xffff
je 0x420c3f
mov eax, dword [esp + 0x20]
push 0
lea edx, [esp + 0x40]
push edx
push eax
mov eax, dword [esp + 0x54]
xor edx, edx
mov dx, word [edi]
lea ecx, [esp + 0x28]
push ecx
mov ecx, dword [esp + 0x38]
push esi
push edx
push eax
push ecx
mov ecx, ebx
call fcn.00460c00
mov eax, dword [esp + 0x4c]
movzx edx, si
lea eax, [eax + edx*2]
movzx edx, byte [eax]
xor ecx, ecx
mov ch, byte [eax + 1]
mov eax, dword [esp + 0x2c]
or ecx, edx
test eax, eax
mov dword [esp + 0x18], ecx
fild dword [esp + 0x18]
fstp dword [esp + 0x14]
je 0x420ba0
movzx ecx, word [edi]
movzx edx, word [edi + 6]
shl ecx, 0x10
lea eax, [esp + 0x18]
or ecx, edx
push eax
push ecx
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x20], 0
call fcn.00439e90
test eax, eax
je 0x420ba0
movsx eax, word [esp + 0x18]
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fadd dword [esp + 0x14]
fstp dword [esp + 0x14]
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x38]
test eax, eax
jge 0x420bae
neg eax
test ebx, ebx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fmul dword [esp + 0x14]
fidiv dword [esp + 0x30]
fstp dword [esp + 0x14]
je 0x420c2b
mov ecx, dword [ebx + 4]
call fcn.0047ea70
mov ecx, eax
call fcn.0045ffa0
cmp eax, 1
jne 0x420c2b
cmp word [edi], 0x20
je 0x420c2b
lea eax, [ebx + 0x70]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x6c], ecx
mov ecx, dword [eax + 8]
mov dword [esp + 0x74], ecx
fld dword [esp + 0x74]
fdiv dword [esp + 0x6c]
mov dword [esp + 0x70], edx
mov edx, dword [eax + 0xc]
mov ecx, dword [eax + 0x10]
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x78], edx
mov edx, dword [eax + 0x14]
mov dword [esp + 0x80], edx
fmul dword [esp + 0x14]
fld dword [esp + 0x7c]
fmul dword [0x53e6f0]
faddp st(1)
fstp dword [esp + 0x14]
fild dword [esp + 0x38]
mov eax, dword [esp + 0x24]
fadd dword [esp + 0x14]
fadd dword [esp + 0x3c]
fstp dword [esp + 0x3c]
mov ecx, dword [esp + 0xb6c]
inc eax
add edi, 6
cmp eax, ecx
mov dword [esp + 0x24], eax
jl 0x420b00
jmp 0x420e8a
test ecx, ecx
mov dword [esp + 0x18], eax
jle 0x420e8a
mov ecx, dword [esp + 0xb68]
mov dword [esp + 0x20], ecx
mov edx, dword [esp + 0x34]
mov di, word [edx + eax*2]
cmp di, 0xffff
je 0x420e6b
mov ecx, dword [ebp + 4]
lea eax, [esp + 0x6c]
push eax
add ecx, 0xe8
push ecx
lea edx, [esp + 0x58]
push edx
call fcn.00437c90
mov al, byte [esp + 0x1f]
add esp, 0xc
test al, al
je 0x420cf2
cmp ebx, 1
jle 0x420cf2
mov esi, dword [esp + 0x7c]
mov eax, esi
cdq
idiv ebx
mov ecx, ebx
sar ecx, 1
cmp edx, ecx
jl 0x420cc5
lea eax, [ecx + esi]
cdq
idiv ebx
mov esi, dword [esp + 0x80]
imul eax, ebx
mov dword [esp + 0x7c], eax
mov eax, esi
cdq
idiv dword [esp + 0x14]
mov ebx, dword [esp + 0x14]
cmp edx, ecx
jl 0x420ce8
lea eax, [ecx + esi]
cdq
idiv ebx
imul eax, ebx
mov dword [esp + 0x80], eax
mov eax, dword [esp + 0x28]
test byte [eax + 0x30], 8
movzx esi, di
je 0x420d23
mov ecx, eax
mov eax, dword [ecx + 0x64]
movzx edx, byte [eax + esi*4 + 1]
xor ecx, ecx
mov ch, byte [eax + esi*4 + 3]
mov cl, byte [eax + esi*4 + 2]
shl ecx, 8
or ecx, edx
movzx edx, byte [eax + esi*4]
shl ecx, 8
or ecx, edx
jmp 0x420d33
mov eax, dword [esp + 0x28]
mov eax, dword [eax + 0x64]
xor ecx, ecx
mov ch, byte [eax + esi*2 + 1]
mov cl, byte [eax + esi*2]
mov edi, dword [esp + 0x3c]
lea edx, [esp + 0x6c]
push edx
push ecx
push eax
mov eax, dword [edi + 0x18]
mov ecx, dword [eax + 0x5c]
push ecx
lea ecx, [esp + 0xa8]
call fcn.0041f560
mov edx, dword [esp + 0x110]
mov dword [esp + 0xb54], edi
mov dword [esp + 0xb50], 1
mov dword [edx], 0
mov eax, dword [esp + 0x114]
mov edx, dword [esp + 0xb70]
mov dword [eax], 0
mov ecx, dword [esp + 0x114]
add edi, 0x48
push edi
mov word [ecx + 4], 0
push edx
mov ecx, ebp
call fcn.00420530
mov ecx, dword [esp + 0x110]
push 0
lea edx, [esp + 0x8c]
mov dword [ecx + 4], eax
push edx
push 0
lea ecx, [esp + 0xa4]
mov dword [esp + 0x118], 1
call fcn.00478f90
mov eax, dword [esp + 0x4c]
xor ecx, ecx
mov ch, byte [eax + esi*2 + 1]
mov cl, byte [eax + esi*2]
mov esi, ecx
mov ecx, dword [esp + 0x2c]
test ecx, ecx
je 0x420e0f
mov eax, dword [esp + 0x20]
lea edx, [esp + 0x24]
push edx
movzx edx, word [eax]
movzx eax, word [eax + 6]
shl edx, 0x10
or edx, eax
push edx
mov dword [esp + 0x2c], 0
call fcn.00439e90
test eax, eax
je 0x420e0f
movsx ecx, word [esp + 0x24]
add esi, ecx
mov edx, dword [ebp]
mov ecx, ebp
call dword [edx + 0x38]
test eax, eax
jge 0x420e1d
neg eax
imul eax, esi
cdq
idiv dword [esp + 0x30]
mov edx, dword [esp + 0x38]
mov cl, byte [esp + 0x13]
add eax, edx
test cl, cl
je 0x420e57
lea ecx, [eax + 0x13]
mov eax, 0x66666667
imul ecx
mov ecx, dword [esp + 0x60]
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
lea eax, [eax + eax*4]
lea edx, [ecx + eax*4]
mov dword [esp + 0x60], edx
jmp 0x420e5b
add dword [esp + 0x60], eax
lea ecx, [esp + 0x98]
call fcn.004846b0
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x20]
mov ecx, dword [esp + 0xb6c]
inc eax
add edx, 6
cmp eax, ecx
mov dword [esp + 0x18], eax
mov dword [esp + 0x20], edx
jl 0x420c72
mov eax, dword [esp + 0x34]
push eax
call fcn.00439d00
add esp, 4
pop edi
pop ebx
pop esi
pop ebp
add esp, 0xb48
ret 0x1c