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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
sub esp, 0x134
fldz
push ebx
fst qword [esp + 0xb8]
push esi
mov esi, dword [ebp + 8]
fst qword [esp + 0xc4]
fst qword [esp + 0xcc]
mov ebx, ecx
fst qword [esp + 0xd4]
push edi
fst qword [esp + 0xe0]
mov ecx, esi
fstp qword [esp + 0xe8]
call fcn.0051f0a0
fstp qword [esp + 0xf0]
test word [esi + 0x20], 0xfff9
mov edi, dword [ebp + 0x14]
fild dword [edi + 0x10]
lea eax, [esi + 0x1c]
mov dword [esp + 0x64], eax
fst qword [esp + 0x110]
fild dword [edi + 0x14]
fstp qword [esp + 0x118]
fild dword [edi + 0x18]
fstp qword [esp + 0x120]
fild dword [eax]
fst qword [esp + 0x58]
fdivp st(1)
jne 0x589f3e
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
fstp qword [esp + 0x90]
fstp qword [esp + 0x98]
fld qword [esp + 0x118]
fdiv qword [esp + 0x58]
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
fstp qword [esp + 0xa0]
fstp qword [esp + 0xa8]
fld qword [esp + 0x120]
fdiv qword [esp + 0x58]
jmp 0x589faa
fchs
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
fstp qword [esp + 0x90]
fstp qword [esp + 0x98]
fld qword [esp + 0x118]
fdiv qword [esp + 0x58]
fchs
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
fstp qword [esp + 0xa0]
fstp qword [esp + 0xa8]
fld qword [esp + 0x120]
fdiv qword [esp + 0x58]
fchs
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
movzx eax, byte [edi + 8]
fstp qword [esp + 0xb0]
and eax, 0xf
sub eax, 1
fstp qword [esp + 0xb8]
je 0x58a104
sub eax, 1
je 0x58a0b4
sub eax, 1
jne 0x58a10c
mov edi, dword [esp + 0xac]
fld qword [esp + 0x118]
mov eax, dword [esp + 0xa0]
fst qword [esp + 0x128]
fld qword [esp + 0x120]
mov ecx, dword [esp + 0xa4]
mov edx, dword [esp + 0xa8]
fstp qword [esp + 0x130]
mov dword [esp + 0xcc], edi
mov edi, dword [esp + 0xb0]
fstp qword [esp + 0x138]
mov dword [esp + 0xd0], edi
mov edi, dword [esp + 0xb4]
mov dword [esp + 0xd4], edi
mov edi, dword [esp + 0xb8]
mov dword [esp + 0xc0], eax
mov dword [esp + 0xd8], edi
mov edi, dword [esp + 0xbc]
mov dword [esp + 0xe0], eax
mov eax, dword [esp + 0xac]
mov dword [esp + 0xc4], ecx
mov dword [esp + 0xc8], edx
mov dword [esp + 0xdc], edi
mov dword [esp + 0xe4], ecx
mov dword [esp + 0xe8], edx
mov dword [esp + 0xec], eax
mov dword [esp + 0x60], 4
jmp 0x58a10c
mov ecx, dword [esp + 0xa0]
fld qword [esp + 0x118]
mov edx, dword [esp + 0xa4]
fstp qword [esp + 0x128]
mov eax, dword [esp + 0xa8]
mov dword [esp + 0xc0], ecx
mov ecx, dword [esp + 0xac]
mov dword [esp + 0xc4], edx
mov dword [esp + 0xc8], eax
mov dword [esp + 0xcc], ecx
mov dword [esp + 0x60], 2
jmp 0x58a10c
mov dword [esp + 0x60], 0
mov edx, dword [esi]
mov eax, dword [edx + 0x38]
mov ecx, esi
call eax
mov edi, dword [ebp + 0xc]
mov dword [esp + 0x28], eax
fild dword [esp + 0x28]
fcom qword [edi]
fnstsw ax
test ah, 0x41
jp 0x58a16a
fsubr qword [edi]
mov ecx, dword [ebp + 0x10]
fstp qword [edi]
test byte [ecx], 1
jne 0x58a69e
mov ecx, dword [0x686bbc]
push esi
call fcn.00583ab0
mov edx, dword [0x686bbc]
push 0
push 3
push edx
mov ecx, ebx
mov dword [0x686bcc], 3
call fcn.00548980
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
fsub qword [edi]
lea eax, [esp + 0xf8]
push eax
mov ecx, esi
fstp qword [esp + 0x6c]
fild dword [esi + 0x14]
fld qword [0x644828]
fmul st(1), st(0)
fxch st(1)
fchs
fst qword [esp + 0x74]
fild dword [esi + 0x18]
fmulp st(2)
fxch st(1)
fchs
fst qword [esp + 0x7c]
fstp qword [esp + 0x8c]
fstp qword [esp + 0x84]
call fcn.0051d930
lea ecx, [esp + 0x30]
call fcn.005f4550
lea ecx, [esp + 0x38]
call fcn.005f4550
fld qword [edi]
fdiv qword [esp + 0x58]
xor eax, eax
test word [esi + 0x20], 0xfff9
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
je 0x58a1d9
fchs
fst qword [esp + 0x28]
call sub.MSVCR90.dll__CIcos
fstp qword [esp + 0x48]
fld qword [esp + 0x28]
call sub.MSVCR90.dll__CIsin
fld qword [esp + 0x48]
fld st(0)
mov edi, dword [ebp + 0x10]
test byte [edi], 1
fld qword [esp + 0x70]
fmul st(1), st(0)
fld st(3)
fld qword [esp + 0x78]
fmul st(1), st(0)
fxch st(3)
fsubrp st(1)
fxch st(2)
fmulp st(3)
fmulp st(3)
fxch st(1)
faddp st(2)
fst qword [esp + 0x48]
fstp qword [esp + 0x70]
fst qword [esp + 0x50]
fstp qword [esp + 0x78]
fld qword [0x634650]
jne 0x58a352
fld qword [esp + 0x80]
fld st(0)
fld qword [esp + 0x58]
fmul st(1), st(0)
fxch st(1)
fadd qword [esp + 0xf8]
fldz
fcom st(1)
fnstsw ax
fxch st(1)
test ah, 0x41
jp 0x58a25c
fadd st(4)
jmp 0x58a25e
fsub st(4)
call fcn.005fbb60
fld qword [esp + 0x88]
fld st(0)
mov dword [esp + 0x40], eax
fmulp st(3)
fxch st(2)
fadd qword [esp + 0x100]
fcom st(1)
fnstsw ax
fstp st(1)
test ah, 1
jne 0x58a28a
faddp st(3)
jmp 0x58a28c
fsubrp st(3)
fxch st(2)
call fcn.005fbb60
fxch st(1)
sub esp, 0x10
fstp qword [esp + 8]
lea ecx, [esp + 0x38]
mov dword [esp + 0x54], eax
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x34]
call fcn.00522bf0
fld qword [esp + 0x78]
sub esp, 0x10
fstp qword [esp + 8]
lea ecx, [esp + 0x38]
fld qword [esp + 0x80]
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x3c]
call fcn.00522bf0
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
cmp eax, dword [esp + 0x38]
jne 0x58a2f2
cmp ecx, dword [esp + 0x3c]
je 0x58a354
mov edx, dword [esp + 0x64]
fld qword [esp + 0xf0]
neg ecx
mov dword [esp + 0x34], ecx
mov cx, word [esi + 0x20]
neg eax
and cx, 0xfff9
sub esp, 8
mov dword [esp + 0x38], eax
fstp qword [esp]
movzx eax, cx
mov ecx, dword [edx]
push eax
push ecx
lea eax, [esp + 0x48]
push eax
mov eax, dword [0x686bbc]
lea ecx, [esp + 0x44]
push ecx
lea edx, [esp + 0x58]
push edx
push eax
mov ecx, ebx
call fcn.00547c50
test eax, eax
je 0x58a354
mov ecx, dword [0x686bbc]
push 0
push 3
push ecx
mov ecx, ebx
call fcn.00548980
jmp 0x58a354
fstp st(0)
mov eax, dword [edi]
cmp eax, dword [esp + 0x60]
jle 0x58a360
xor eax, eax
jmp 0x58a361
inc eax
lea edx, [esp + 0x70]
push edx
lea ecx, [esp + 0x84]
mov dword [edi], eax
call fcn.005fef00
fld qword [esp + 0x68]
mov eax, dword [edi]
fsub qword [esp + eax*8 + 0x110]
fst qword [esp + 0x68]
fldz
fcom st(1)
fnstsw ax
test ah, 1
je 0x58a54a
mov eax, dword [edi]
fstp st(1)
mov ecx, eax
shl ecx, 4
fld qword [esp + ecx + 0x90]
lea ecx, [esp + ecx + 0x90]
fld qword [ecx + 8]
fld st(1)
fld qword [esp + 0x48]
fmul st(1), st(0)
fld qword [esp + 0x50]
fld st(0)
fmul st(4)
fsubp st(3)
fmulp st(4)
fmulp st(2)
fxch st(2)
faddp st(1)
fxch st(1)
fst qword [esp + 0x48]
fstp qword [esp + 0x70]
fst qword [esp + 0x50]
fstp qword [esp + 0x78]
test al, 1
jne 0x58a508
fld qword [esp + 0x80]
fld st(0)
fld qword [esp + 0x58]
fmul st(1), st(0)
fxch st(1)
fadd qword [esp + 0xf8]
fcom st(3)
fnstsw ax
fld qword [0x634650]
test ah, 1
jne 0x58a40d
fadd st(1), st(0)
jmp 0x58a40f
fsub st(1), st(0)
fxch st(1)
call fcn.005fbb60
fld qword [esp + 0x88]
fld st(0)
mov dword [esp + 0x40], eax
fmulp st(3)
fxch st(2)
fadd qword [esp + 0x100]
fcom st(4)
fnstsw ax
fstp st(4)
test ah, 1
jne 0x58a43d
faddp st(3)
jmp 0x58a43f
fsubp st(3)
fxch st(2)
call fcn.005fbb60
fxch st(1)
sub esp, 0x10
fstp qword [esp + 8]
lea ecx, [esp + 0x38]
mov dword [esp + 0x54], eax
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x34]
call fcn.00522bf0
fld qword [esp + 0x78]
sub esp, 0x10
fstp qword [esp + 8]
lea ecx, [esp + 0x118]
fld qword [esp + 0x80]
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x3c]
call fcn.00522bf0
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
cmp eax, dword [esp + 0x38]
jne 0x58a4a8
cmp ecx, dword [esp + 0x3c]
je 0x58a50a
mov dx, word [esi + 0x20]
fld qword [esp + 0xf0]
neg eax
neg ecx
sub esp, 8
and dx, 0xfff9
fstp qword [esp]
mov dword [esp + 0x38], eax
movzx eax, dx
mov dword [esp + 0x3c], ecx
mov ecx, dword [esp + 0x6c]
mov ecx, dword [ecx]
push eax
push ecx
lea edx, [esp + 0x48]
push edx
mov edx, dword [0x686bbc]
lea eax, [esp + 0x44]
push eax
lea ecx, [esp + 0x58]
push ecx
push edx
mov ecx, ebx
call fcn.00547c50
test eax, eax
je 0x58a50a
mov eax, dword [0x686bbc]
push 0
push 3
push eax
mov ecx, ebx
call fcn.00548980
jmp 0x58a50a
fstp st(0)
mov eax, dword [edi]
cmp eax, dword [esp + 0x60]
jle 0x58a516
xor eax, eax
jmp 0x58a517
inc eax
lea ecx, [esp + 0x70]
push ecx
lea ecx, [esp + 0x84]
mov dword [edi], eax
call fcn.005fef00
fld qword [esp + 0x68]
mov edx, dword [edi]
fsub qword [esp + edx*8 + 0x110]
fst qword [esp + 0x68]
fldz
fcom st(1)
fnstsw ax
test ah, 1
jne 0x58a394
test byte [edi], 1
jne 0x58a695
fstp st(1)
fld qword [esp + 0x80]
fld st(0)
fld qword [esp + 0x58]
fmul st(1), st(0)
fxch st(1)
fadd qword [esp + 0xf8]
fcom st(3)
fnstsw ax
fld qword [0x634650]
test ah, 1
jne 0x58a580
fadd st(1), st(0)
jmp 0x58a582
fsub st(1), st(0)
fxch st(1)
call fcn.005fbb60
fld qword [esp + 0x88]
fld st(0)
mov dword [esp + 0x40], eax
fmulp st(3)
fxch st(2)
fadd qword [esp + 0x100]
fcom st(4)
fnstsw ax
fstp st(4)
test ah, 1
jne 0x58a5b0
faddp st(3)
jmp 0x58a5b2
fsubp st(3)
fxch st(2)
call fcn.005fbb60
fxch st(1)
sub esp, 0x10
fstp qword [esp + 8]
lea ecx, [esp + 0x118]
mov dword [esp + 0x54], eax
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x34]
call fcn.00522bf0
mov ecx, esi
call fcn.0051c460
sub esp, 8
mov ecx, esi
fstp qword [esp]
call fcn.0051c430
sub esp, 8
lea ecx, [esp + 0x118]
fstp qword [esp]
call fcn.00522a00
push eax
lea ecx, [esp + 0x3c]
call fcn.00522bf0
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
cmp eax, dword [esp + 0x38]
jne 0x58a623
cmp ecx, dword [esp + 0x3c]
je 0x58a681
fld qword [esp + 0xf0]
neg eax
mov dword [esp + 0x30], eax
mov ax, word [esi + 0x20]
neg ecx
sub esp, 8
and ax, 0xfff9
fstp qword [esp]
mov dword [esp + 0x3c], ecx
mov ecx, dword [esp + 0x6c]
mov ecx, dword [ecx]
movzx eax, ax
push eax
push ecx
lea edx, [esp + 0x48]
push edx
mov edx, dword [0x686bbc]
lea eax, [esp + 0x44]
push eax
lea ecx, [esp + 0x58]
push ecx
push edx
mov ecx, ebx
call fcn.00547c50
test eax, eax
je 0x58a681
mov eax, dword [0x686bbc]
push 0
push 3
push eax
mov ecx, ebx
call fcn.00548980
fld qword [esp + 0x68]
mov ecx, dword [ebp + 0xc]
fchs
fstp qword [ecx]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov ecx, dword [ebp + 0xc]
fstp st(0)
fchs
fstp qword [ecx]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10