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

Disassembly:
sub esp, 0x1c
push esi
mov esi, dword [esp + 0x24]
mov eax, dword [esi]
test eax, eax
je 0x408a97
cmp eax, 1
jne 0x408d32
cmp dword [esi + 0x74], 0
je 0x408d32
cmp dword [esi + 0x78], 0
je 0x408d32
push ebx
mov ebx, dword [esi + 0x60]
lea eax, [ebx - 1]
imul eax, ebx
cdq
sub eax, edx
sar eax, 1
add eax, eax
push ebp
add eax, eax
add eax, eax
push edi
push eax
mov dword [esp + 0x2c], ebx
call fcn.0040adf0
push eax
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x3c]
push eax
push esi
call fcn.004036c0
lea ecx, [ebx*4]
fstp st(0)
push ecx
call fcn.0040adf0
add esp, 0x14
mov edi, eax
xor esi, esi
mov dword [esp + 0x14], edi
test ebx, ebx
jle 0x408b12
lea ebp, [ebx*8]
push ebp
call fcn.0040adf0
mov dword [edi + esi*4], eax
inc esi
add esp, 4
cmp esi, ebx
jl 0x408b01
xor edx, edx
mov dword [esp + 0x10], edx
test ebx, ebx
jle 0x408c09
mov ecx, 1
mov eax, edi
xor ebp, ebp
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ebx
cmp ecx, ebx
jge 0x408bf0
lea esi, [eax + 4]
mov eax, dword [eax]
lea edi, [eax + ebp + 8]
sub ebx, ecx
jmp 0x408b50
mov ecx, dword [esp + 0x30]
mov eax, dword [ecx + 0x74]
mov ecx, dword [esp + 0x24]
fld qword [ecx + edx*8]
fmul qword [eax + edx*8]
mov eax, dword [esp + 0x30]
mov ecx, dword [eax + 0x78]
fadd qword [ecx + edx*8]
fldz
fcomp st(1)
fnstsw ax
test ah, 0x41
jp 0x408b89
fchs
call fcn.0040ad9c
fld st(0)
fld1
fadd st(1), st(0)
fxch st(2)
fdivrp st(1)
jmp 0x408b98
call fcn.0040ad9c
fld1
fadd st(1), st(0)
fld st(0)
fdivrp st(2)
fxch st(1)
fld qword [0x41b6a0]
fcom st(1)
fnstsw ax
test ah, 5
jp 0x408bbc
fstp st(0)
fld st(0)
fld qword [0x41b698]
fcom st(2)
fnstsw ax
fstp st(2)
test ah, 0x41
jne 0x408bc0
fstp st(1)
jmp 0x408bc2
fstp st(0)
mov edx, dword [esi]
fst qword [edi]
inc dword [esp + 0x10]
fsubp st(1)
add esi, 4
add edi, 8
dec ebx
fstp qword [edx + ebp]
mov edx, dword [esp + 0x10]
jne 0x408b50
mov ebx, dword [esp + 0x28]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x14]
inc ecx
add eax, 4
add ebp, 8
dec dword [esp + 0x20]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], eax
jne 0x408b35
mov ebp, dword [esp + 0x38]
push ebp
push edi
push ebx
call fcn.00407000
xor edi, edi
lea ecx, [edi + 1]
add esp, 0xc
cmp ebx, ecx
jle 0x408cee
lea eax, [ebx - 1]
cmp eax, 4
jl 0x408cc6
mov eax, 0xfffffff8
sub eax, ebp
mov dword [esp + 0x20], eax
mov eax, 8
sub eax, ebp
mov dword [esp + 0x1c], eax
mov eax, 0xfffffff0
xor esi, esi
sub eax, ebp
mov dword [esp + 0x10], 0x18
lea edx, [ebp + 0x18]
mov dword [esp + 0x28], eax
nop
fld qword [esi + ebp]
fcomp qword [edx - 0x10]
fnstsw ax
test ah, 5
jp 0x408c75
mov esi, dword [esp + 0x28]
mov edi, ecx
add esi, edx
fld qword [esi + ebp]
fcomp qword [edx - 8]
fnstsw ax
test ah, 5
jp 0x408c8b
mov esi, dword [esp + 0x20]
lea edi, [ecx + 1]
add esi, edx
fld qword [esi + ebp]
fcomp qword [edx]
fnstsw ax
test ah, 5
jp 0x408c9e
mov esi, dword [esp + 0x10]
lea edi, [ecx + 2]
fld qword [esi + ebp]
fcomp qword [edx + 8]
fnstsw ax
test ah, 5
jp 0x408cb4
mov esi, dword [esp + 0x1c]
lea edi, [ecx + 3]
add esi, edx
add dword [esp + 0x10], 0x20
add ecx, 4
lea eax, [ebx - 3]
add edx, 0x20
cmp ecx, eax
jl 0x408c60
cmp ecx, ebx
jge 0x408cee
lea esi, [edi*8]
fld qword [esi + ebp]
lea edx, [ecx*8]
fcomp qword [edx + ebp]
fnstsw ax
test ah, 5
jp 0x408ce9
mov edi, ecx
mov esi, edx
inc ecx
cmp ecx, ebx
jl 0x408cd1
xor esi, esi
test ebx, ebx
jle 0x408d09
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx + esi*4]
push edx
call fcn.004099d7
inc esi
add esp, 4
cmp esi, ebx
jl 0x408cf4
mov eax, dword [esp + 0x24]
push eax
call fcn.004099d7
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004099d7
mov edx, dword [esp + 0x38]
mov eax, dword [edx + 0x7c]
fild dword [eax + edi*4]
add esp, 8
pop edi
pop ebp
pop ebx
pop esi
add esp, 0x1c
ret
mov ecx, dword [esp + 0x28]
push ecx
push esi
call fcn.00403a70
add esp, 8
pop esi
add esp, 0x1c
ret