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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x74
cmp dword [ebp + 0x14], 0
push ebx
push esi
push edi
mov dword [esp + 0xc], 0
jle 0x40fa30
mov esi, dword [ebp + 8]
fld qword [0x44a808]
mov ebx, dword [ebp + 0xc]
fldz
add esi, 0x630
add ebx, 0x14
mov dword [esp + 0x2c], esi
mov dword [esp + 0x28], ebx
cmp dword [ebx - 0x10], 0
je 0x40fa06
cmp dword [ebx], 0
je 0x40fa06
cmp dword [ebx - 0xc], 0
je 0x40fa06
mov edx, dword [ebx - 8]
mov edi, dword [ebp + 0xc]
mov eax, edx
imul eax, eax, 0x224
mov dword [esp + 0x14], edx
imul edx, edx, 0x2b430
lea eax, [eax + edi + 0x20]
mov edi, dword [ebp + 8]
lea ecx, [ebx + 0xc]
mov dword [ecx], 0
mov dword [eax], 0
add edx, edi
mov edi, dword [esi - 0x628]
cmp edi, dword [edx + 8]
jne 0x40fa06
cmp dword [ebp + 0x18], 0
je 0x40fa06
mov edi, dword [esi - 0x3f4]
mov dword [ebx - 4], 1
mov dword [ecx], 1
mov dword [eax], 1
fld qword [esi]
fadd qword [edx + 0x630]
fmul st(2)
fst qword [edx + 0x630]
fstp qword [esi]
test edi, edi
jle 0x40fa06
add esi, 0xfffffc14
lea edx, [eax + 4]
sub ecx, eax
mov dword [esp + 0x1c], edx
mov dword [esp + 0x18], esi
mov dword [esp + 0x38], ecx
mov dword [esp + 0x24], edi
jmp 0x40f457
mov esi, dword [esp + 0x18]
mov ebx, dword [esi]
fld st(0)
mov edx, dword [esi - 4]
fst qword [esp + 0x50]
mov esi, dword [ebp + 0x10]
fld st(1)
fst qword [esp + 0x60]
mov ecx, ebx
fxch st(2)
sub ecx, edx
fst qword [esp + 0x40]
xor edi, edi
cmp ecx, 4
fld st(0)
fld st(1)
mov dword [esp + 0x20], edi
fst qword [esp + 0x58]
mov eax, edx
fld st(2)
mov dword [esp + 0x3c], ecx
fst qword [esp + 0x68]
fxch st(3)
fst qword [esp + 0x48]
fst qword [esp + 0x70]
jl 0x40f78f
mov eax, dword [esp + 0xc]
fstp st(0)
mov eax, dword [esi + eax*4]
fstp st(2)
mov ecx, dword [esp + 0x14]
fstp st(1)
mov ecx, dword [esi + ecx*4]
fstp st(1)
lea edi, [eax + edx*8 + 0x18]
sub eax, ecx
mov dword [esp + 0x10], edi
lea edi, [ecx + edx*8 + 8]
mov ecx, ebx
sub ecx, edx
sub ecx, 4
shr ecx, 2
inc ecx
mov dword [esp + 0x30], eax
lea eax, [edx + ecx*4]
mov dword [esp + 0x34], eax
jmp 0x40f4e4
fstp st(4)
fstp st(3)
fstp st(0)
mov eax, dword [esp + 0x10]
fld qword [eax - 0x18]
fld qword [edi - 8]
fld st(0)
fadd st(2)
fmul st(5)
fld st(2)
fsub st(2)
fmul st(6)
fld st(1)
fmul st(2)
faddp st(5)
fxch st(4)
fstp qword [esp + 0x78]
fabs
fld qword [esp + 0x70]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f51d
fstp st(0)
fst qword [esp + 0x70]
jmp 0x40f51f
fstp st(1)
fld st(3)
fmul st(4)
fadd qword [esp + 0x40]
fstp qword [esp + 0x40]
fxch st(3)
fabs
fcom qword [esp + 0x48]
fnstsw ax
test ah, 5
jnp 0x40f540
fstp qword [esp + 0x48]
jmp 0x40f542
fstp st(0)
fld st(1)
fmul st(2)
faddp st(4)
fxch st(3)
fstp qword [esp + 0x60]
fld st(2)
fmul st(3)
fadd qword [esp + 0x50]
fstp qword [esp + 0x50]
fabs
fld qword [esp + 0x68]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f571
fstp st(0)
fst qword [esp + 0x68]
jmp 0x40f573
fstp st(1)
fxch st(2)
fabs
fcom qword [esp + 0x58]
fnstsw ax
test ah, 5
jnp 0x40f588
fstp qword [esp + 0x58]
jmp 0x40f58a
fstp st(0)
mov eax, dword [esp + 0x30]
fld qword [eax + edi]
fld qword [edi]
fld st(0)
fadd st(2)
fmul st(5)
fld st(2)
fsub st(2)
fmul st(6)
fld st(1)
fmul st(2)
fadd qword [esp + 0x78]
fstp qword [esp + 0x78]
fxch st(1)
fabs
fcom st(4)
fnstsw ax
test ah, 5
jnp 0x40f5e1
fstp st(4)
fxch st(3)
fst qword [esp + 0x70]
fxch st(3)
fld st(0)
fmul st(1)
fadd qword [esp + 0x40]
fstp qword [esp + 0x40]
fabs
fcom qword [esp + 0x48]
fnstsw ax
test ah, 5
jnp 0x40f5e5
fstp qword [esp + 0x48]
jmp 0x40f5e7
fstp st(0)
jmp 0x40f5c2
fstp st(0)
fld st(1)
fmul st(2)
fadd qword [esp + 0x60]
fstp qword [esp + 0x60]
fld st(0)
fmul st(1)
fadd qword [esp + 0x50]
fstp qword [esp + 0x50]
fxch st(1)
fabs
fcom st(3)
fnstsw ax
fstp st(3)
test ah, 5
jnp 0x40f616
fxch st(2)
fstp qword [esp + 0x68]
jmp 0x40f618
fstp st(2)
fxch st(1)
fabs
fcom qword [esp + 0x58]
fnstsw ax
test ah, 5
jnp 0x40f62d
fstp qword [esp + 0x58]
jmp 0x40f62f
fstp st(0)
mov eax, dword [esp + 0x10]
fld qword [eax - 8]
fld qword [edi + 8]
fld st(0)
fadd st(2)
fmul st(4)
fld st(2)
fsub st(2)
fmul st(5)
fld st(1)
fmul st(2)
fadd qword [esp + 0x78]
fxch st(2)
fabs
fcom st(5)
fnstsw ax
test ah, 5
jnp 0x40f683
fstp st(5)
fxch st(4)
fst qword [esp + 0x70]
fxch st(4)
fld st(0)
fmul st(1)
fadd qword [esp + 0x40]
fstp qword [esp + 0x40]
fabs
fcom qword [esp + 0x48]
fnstsw ax
test ah, 5
jnp 0x40f687
fstp qword [esp + 0x48]
jmp 0x40f689
fstp st(0)
jmp 0x40f664
fstp st(0)
fld st(2)
fmul st(3)
fadd qword [esp + 0x60]
fstp qword [esp + 0x60]
fld st(1)
fmul st(2)
fadd qword [esp + 0x50]
fstp qword [esp + 0x50]
fxch st(2)
fabs
fcom qword [esp + 0x68]
fnstsw ax
test ah, 5
jnp 0x40f6b6
fstp qword [esp + 0x68]
jmp 0x40f6b8
fstp st(0)
fabs
fcom qword [esp + 0x58]
fnstsw ax
test ah, 5
jnp 0x40f6cb
fstp qword [esp + 0x58]
jmp 0x40f6cd
fstp st(0)
mov eax, dword [esp + 0x10]
fld qword [eax]
fld qword [edi + 0x10]
fld st(0)
fadd st(2)
fmul st(5)
fld st(2)
fsub st(2)
fmul st(6)
fld st(1)
fmul st(2)
faddp st(5)
fxch st(1)
fabs
fcom st(5)
fnstsw ax
fstp st(5)
test ah, 5
jnp 0x40f6ff
fxch st(4)
fstp qword [esp + 0x70]
jmp 0x40f701
fstp st(4)
fld st(3)
fmul st(4)
fadd qword [esp + 0x40]
fstp qword [esp + 0x40]
fxch st(3)
fabs
fcom qword [esp + 0x48]
fnstsw ax
test ah, 5
jnp 0x40f722
fstp qword [esp + 0x48]
jmp 0x40f724
fstp st(0)
fld st(0)
fmul st(1)
fadd qword [esp + 0x60]
fst qword [esp + 0x60]
fld st(3)
fmul st(4)
fadd qword [esp + 0x50]
fst qword [esp + 0x50]
fxch st(2)
fabs
fld qword [esp + 0x68]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f755
fstp st(0)
fst qword [esp + 0x68]
jmp 0x40f757
fstp st(1)
fxch st(4)
fabs
fld qword [esp + 0x58]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f770
fstp st(0)
fst qword [esp + 0x58]
jmp 0x40f772
fstp st(1)
add dword [esp + 0x10], 0x20
add edi, 0x20
sub ecx, 1
jne 0x40f4de
fldz
mov eax, dword [esp + 0x34]
mov edi, dword [esp + 0x20]
jmp 0x40f799
fxch st(3)
fxch st(5)
fxch st(2)
fxch st(4)
fxch st(3)
cmp eax, ebx
jge 0x40f88d
mov ecx, dword [esp + 0x14]
fstp st(0)
mov ecx, dword [esi + ecx*4]
fstp st(4)
lea edi, [ecx + eax*8]
fstp st(3)
mov dword [esp + 0x10], edi
fstp st(0)
mov edi, dword [esp + 0xc]
fstp st(1)
mov edi, dword [esi + edi*4]
sub edi, ecx
mov ecx, ebx
sub ecx, eax
jmp 0x40f7d0
fstp st(2)
fstp st(1)
fstp st(1)
fstp st(0)
mov eax, dword [esp + 0x10]
fld qword [eax + edi]
fld qword [eax]
fld st(0)
fadd st(2)
fmul st(4)
fld st(2)
fsub st(2)
fmul st(5)
fld st(1)
fmul st(2)
faddp st(5)
fxch st(1)
fabs
fcom qword [esp + 0x70]
fnstsw ax
test ah, 5
jnp 0x40f800
fstp qword [esp + 0x70]
jmp 0x40f802
fstp st(0)
fld st(0)
fmul st(1)
fadd qword [esp + 0x40]
fstp qword [esp + 0x40]
fabs
fcom qword [esp + 0x48]
fnstsw ax
test ah, 5
jnp 0x40f821
fstp qword [esp + 0x48]
jmp 0x40f823
fstp st(0)
fld st(1)
fmul st(2)
fadd qword [esp + 0x60]
fst qword [esp + 0x60]
fld st(1)
fmul st(2)
fadd qword [esp + 0x50]
fst qword [esp + 0x50]
fxch st(3)
fabs
fld qword [esp + 0x68]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f854
fstp st(0)
fst qword [esp + 0x68]
jmp 0x40f856
fstp st(1)
fxch st(2)
fabs
fld qword [esp + 0x58]
fcom st(1)
fnstsw ax
test ah, 0x41
je 0x40f86f
fstp st(0)
fst qword [esp + 0x58]
jmp 0x40f871
fstp st(1)
add dword [esp + 0x10], 8
sub ecx, 1
jne 0x40f7c8
fldz
mov edi, dword [esp + 0x20]
fxch st(3)
fxch st(5)
fxch st(4)
fxch st(3)
fld qword [esp + 0x40]
fcomp st(5)
fnstsw ax
test ah, 0x41
je 0x40f8a2
fstp st(4)
fld qword [esp + 0x40]
fxch st(4)
fxch st(2)
fcom st(3)
fnstsw ax
test ah, 5
jp 0x40f8b1
fstp st(3)
jmp 0x40f8b3
fstp st(0)
fxch st(3)
fcomp st(2)
fnstsw ax
fstp st(1)
test ah, 5
jp 0x40f8fa
fld qword [esp + 0x48]
fld qword [esp + 0x70]
fcom st(1)
fnstsw ax
test ah, 5
jp 0x40f8d5
fstp st(1)
jmp 0x40f8d7
fstp st(0)
fxch st(3)
fcom st(2)
fnstsw ax
test ah, 5
jp 0x40f8e6
fstp st(2)
jmp 0x40f8e8
fstp st(0)
fxch st(2)
fcompp
fnstsw ax
test ah, 5
jp 0x40f8fe
mov edi, 1
jmp 0x40f8fe
fstp st(2)
fstp st(0)
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x38]
mov dword [ecx + eax], edi
mov dword [eax], edi
test edi, edi
je 0x40f9e6
cmp dword [esp + 0x3c], 4
jl 0x40f9ad
mov eax, dword [esp + 0xc]
mov edi, dword [esi + eax*4]
mov ecx, dword [esp + 0x14]
mov esi, dword [esi + ecx*4]
lea eax, [esi + edx*8 + 8]
lea ecx, [edi + edx*8 + 0x18]
sub edi, esi
mov esi, ebx
sub esi, edx
sub esi, 4
shr esi, 2
inc esi
lea edx, [edx + esi*4]
fld qword [ecx - 0x18]
add eax, 0x20
fsub qword [eax - 0x28]
add ecx, 0x20
sub esi, 1
fld qword [eax - 0x28]
fadd qword [ecx - 0x38]
fmul st(3)
fstp qword [ecx - 0x38]
fmul st(2)
fstp qword [eax - 0x28]
fld qword [edi + eax - 0x20]
fsub qword [eax - 0x20]
fld qword [eax - 0x20]
fadd qword [edi + eax - 0x20]
fmul st(3)
fstp qword [edi + eax - 0x20]
fmul st(2)
fstp qword [eax - 0x20]
fld qword [ecx - 0x28]
fsub qword [eax - 0x18]
fld qword [eax - 0x18]
fadd qword [ecx - 0x28]
fmul st(3)
fstp qword [ecx - 0x28]
fmul st(2)
fstp qword [eax - 0x18]
fld qword [ecx - 0x20]
fsub qword [eax - 0x10]
fld qword [eax - 0x10]
fadd qword [ecx - 0x20]
fmul st(3)
fstp qword [ecx - 0x20]
fmul st(2)
fstp qword [eax - 0x10]
jne 0x40f944
mov esi, dword [ebp + 0x10]
cmp edx, ebx
jge 0x40f9e6
mov eax, dword [esp + 0x14]
mov ecx, dword [esi + eax*4]
mov edi, dword [esp + 0xc]
mov esi, dword [esi + edi*4]
sub esi, ecx
lea eax, [ecx + edx*8]
sub ebx, edx
fld qword [esi + eax]
add eax, 8
sub ebx, 1
fsub qword [eax - 8]
fld qword [eax - 8]
fadd qword [esi + eax - 8]
fmul st(3)
fstp qword [esi + eax - 8]
fmul st(2)
fstp qword [eax - 8]
jne 0x40f9c6
mov eax, 4
add dword [esp + 0x18], eax
add dword [esp + 0x1c], eax
sub dword [esp + 0x24], 1
jne 0x40f453
mov ebx, dword [esp + 0x28]
mov esi, dword [esp + 0x2c]
mov eax, dword [esp + 0xc]
inc eax
add ebx, 0x224
add esi, 0x2b430
cmp eax, dword [ebp + 0x14]
mov dword [esp + 0xc], eax
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], esi
jl 0x40f39d
fstp st(0)
fstp st(0)
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret