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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x6296de
mov eax, dword fs:[0]
push eax
sub esp, 0x1c0
mov eax, dword [0x685e38]
xor eax, esp
mov dword [esp + 0x1b8], eax
push ebx
push esi
push edi
mov eax, dword [0x685e38]
xor eax, esp
push eax
lea eax, [esp + 0x1d0]
mov dword fs:[0], eax
mov ebx, dword [ebp + 8]
mov esi, ecx
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 4]
mov edx, dword [esi + 8]
add eax, eax
push eax
push eax
lea eax, [esp + 0xa4]
mov dword [esp + 0xa4], ecx
push eax
lea ecx, [esp + 0x40]
mov dword [esp + 0x24], ebx
mov dword [esp + 0xac], edx
call fcn.00517b80
mov eax, dword [esi + 0x10]
mov ecx, dword [esi + 4]
mov edx, dword [esi + 8]
add eax, eax
push eax
push eax
lea eax, [esp + 0xac]
xor edi, edi
mov dword [esp + 0xac], ecx
push eax
lea ecx, [esp + 0x54]
mov dword [esp + 0x1e4], edi
mov dword [esp + 0xb4], edx
call fcn.00517b80
mov byte [esp + 0x1d8], 1
lea eax, [esp + 0xac]
mov ecx, 0x13
mov edi, edi
mov dword [eax], edi
mov dword [eax + 4], edi
add eax, 8
sub ecx, 1
jns 0x587be0
mov cx, word [esi + 0x14]
imul cx, cx, 0x2d
cmp word [esi + 0x16], 2
mov dword [esp + 0x14c], edi
mov dword [esp + 0x150], edi
mov dword [esp + 0x154], edi
mov dword [esp + 0x158], edi
mov dword [esp + 0x15c], edi
mov dword [esp + 0x160], edi
mov dword [esp + 0x164], edi
mov dword [esp + 0x168], edi
mov dword [esp + 0x16c], edi
mov dword [esp + 0x170], edi
mov dword [esp + 0x174], edi
mov dword [esp + 0x178], edi
mov dword [esp + 0x17c], edi
mov dword [esp + 0x180], edi
mov dword [esp + 0x184], edi
mov dword [esp + 0x188], edi
mov dword [esp + 0x18c], edi
mov dword [esp + 0x190], edi
mov dword [esp + 0x194], edi
mov dword [esp + 0x198], edi
jge 0x58800a
movsx eax, cx
fild dword [esi + 0x18]
cdq
mov ecx, 0x5a
idiv ecx
test edx, edx
je 0x587e12
fdiv qword [0x644fa8]
mov edx, dword [esi + 0xc]
add edx, edx
mov dword [esp + 0x14], edx
fild dword [esp + 0x14]
fcomp st(1)
fnstsw ax
test ah, 5
jnp 0x587e28
fldz
fcom st(1)
fnstsw ax
fld st(1)
fld qword [0x634650]
test ah, 0x41
jp 0x587cd9
fadd st(1), st(0)
jmp 0x587cdb
fsub st(1), st(0)
fxch st(1)
call fcn.005fbb60
fxch st(2)
mov ebx, dword [esp + 0x54]
fcom st(1)
mov edi, dword [esp + 0x58]
mov ecx, ebx
sub ecx, eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0xb4], eax
mov dword [esp + 0xbc], eax
mov eax, dword [esp + 0x50]
mov dword [esp + 0xc0], eax
mov dword [esp + 0xc8], eax
fnstsw ax
mov dword [esp + 0xac], ecx
fld st(0)
mov dword [esp + 0xb0], edi
mov dword [esp + 0xb8], edi
mov dword [esp + 0xc4], ebx
test ah, 1
jne 0x587d3f
fadd st(3)
jmp 0x587d41
fsub st(3)
call fcn.005fbb60
fcom st(1)
sub edi, eax
mov dword [esp + 0xcc], ebx
mov dword [esp + 0xd0], edi
fnstsw ax
fld st(0)
test ah, 1
jne 0x587d65
fadd st(3)
jmp 0x587d67
fsub st(3)
call fcn.005fbb60
fcom st(1)
mov ebx, dword [esp + 0x44]
mov edi, dword [esp + 0x40]
mov ecx, ebx
sub ecx, eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0xe0], eax
mov dword [esp + 0xe8], eax
fnstsw ax
mov dword [esp + 0xd8], ecx
fstp st(1)
mov ecx, dword [esp + 0x38]
mov dword [esp + 0xd4], edi
mov dword [esp + 0xdc], edi
mov dword [esp + 0xe4], ecx
mov dword [esp + 0xec], ecx
mov dword [esp + 0xf0], ebx
test ah, 1
jne 0x587dc7
faddp st(1)
jmp 0x587dc9
fsubrp st(1)
call fcn.005fbb60
sub edi, eax
push 0x14
mov dword [esp + 0xf8], edi
mov dword [esp + 0xfc], ebx
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x1c], eax
mov byte [esp + 0x1d8], 2
test eax, eax
je 0x587f8d
push 0xa
lea edx, [esp + 0xb0]
push edx
mov ecx, eax
call fcn.00552290
jmp 0x587f8f
fld qword [0x634650]
fmul st(1), st(0)
fild dword [esi + 0xc]
fcomp st(2)
fnstsw ax
test ah, 5
jp 0x587e31
fstp st(1)
fstp st(0)
mov dword [ebx], edi
jmp 0x58831e
fldz
fcom st(2)
fnstsw ax
fld st(2)
test ah, 0x41
jp 0x587e42
fadd st(2)
jmp 0x587e44
fsub st(2)
mov edi, dword [esi + 8]
call fcn.005fbb60
fcom st(2)
mov ebx, dword [esp + 0x54]
mov ecx, dword [esp + 0x4c]
add eax, edi
mov dword [esp + 0xb0], eax
mov eax, dword [esp + 0x58]
mov dword [esp + 0xb8], eax
mov dword [esp + 0xc0], eax
mov eax, dword [esp + 0x50]
mov dword [esp + 0xc8], eax
mov dword [esp + 0xd0], eax
fnstsw ax
mov dword [esp + 0xac], ebx
fld st(2)
mov dword [esp + 0xb4], ebx
mov dword [esp + 0xbc], ecx
mov dword [esp + 0xc4], ecx
mov dword [esp + 0xcc], ebx
test ah, 0x41
jp 0x587eb3
fadd st(2)
jmp 0x587eb5
fsub st(2)
call fcn.005fbb60
fcom st(2)
mov ecx, edi
sub ecx, eax
mov dword [esp + 0xd4], ebx
fnstsw ax
mov dword [esp + 0xd8], ecx
fld st(2)
test ah, 0x41
jp 0x587edb
fadd st(2)
jmp 0x587edd
fsub st(2)
call fcn.005fbb60
fcomp st(2)
mov ebx, dword [esp + 0x40]
mov ecx, edi
sub ecx, eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0xe8], eax
mov dword [esp + 0xf0], eax
mov eax, dword [esp + 0x44]
mov dword [esp + 0xf8], eax
mov dword [esp + 0x100], eax
fnstsw ax
mov dword [esp + 0xe0], ecx
mov ecx, dword [esp + 0x38]
mov dword [esp + 0xdc], ebx
mov dword [esp + 0xe4], ebx
mov dword [esp + 0xec], ecx
mov dword [esp + 0xf4], ecx
mov dword [esp + 0xfc], ebx
test ah, 0x41
jp 0x587f49
faddp st(1)
jmp 0x587f4b
fsubp st(1)
call fcn.005fbb60
add eax, edi
push 0x14
mov dword [esp + 0x108], ebx
mov dword [esp + 0x10c], eax
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x1c], eax
mov byte [esp + 0x1d8], 3
test eax, eax
je 0x587f8d
push 0xc
lea edx, [esp + 0xb0]
push edx
mov ecx, eax
call fcn.00552290
jmp 0x587f8f
xor eax, eax
mov ecx, dword [esp + 0x18]
mov dword [ecx], eax
mov dx, word [esi + 0x14]
imul dx, dx, 0x2d
movsx ecx, dx
mov eax, ecx
cdq
mov edi, 0x5a
idiv edi
mov byte [esp + 0x1d8], 1
sub ecx, edx
mov dword [esp + 0x14], ecx
fild dword [esp + 0x14]
fmul qword [0x6345e0]
fdiv qword [0x6345d8]
fldz
fucomp st(1)
fnstsw ax
test ah, 0x44
jnp 0x588003
mov eax, dword [esi + 4]
mov ecx, dword [esi + 8]
lea edx, [esp + 0x24]
mov dword [esp + 0x24], eax
push edx
sub esp, 8
mov dword [esp + 0x34], ecx
mov eax, esp
fstp qword [eax]
mov eax, dword [esp + 0x24]
mov ecx, dword [eax]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
mov dword [esp + 0x28], esp
call eax
jmp 0x58831e
fstp st(0)
jmp 0x58831e
movsx edx, cx
mov dword [esp + 0x14], edx
lea eax, [esp + 0x5c]
fild dword [esp + 0x14]
push eax
mov ecx, esi
fmul qword [0x6345e0]
fdiv qword [0x6345d8]
fstp qword [esp + 0x30]
call fcn.00586720
fstp qword [esp + 0x24]
fld qword [esp + 0x5c]
mov ebx, dword [esi + 8]
fld st(0)
mov dword [esp + 0x14], ebx
fadd st(1)
fstp qword [esp + 0x5c]
fadd qword [esp + 0x2c]
fst qword [esp + 0x94]
call sub.MSVCR90.dll__CIsin
fmul qword [esp + 0x24]
fild dword [esp + 0x14]
mov dword [esp + 0x14], ebx
fadd st(1)
fcomp qword [0x6345d0]
fnstsw ax
fiadd dword [esp + 0x14]
test ah, 1
jne 0x58807f
fadd qword [0x634650]
jmp 0x588085
fsub qword [0x634650]
mov ebx, dword [esi + 4]
fstp qword [esp + 0x1c]
fld qword [esp + 0x94]
mov dword [esp + 0x14], ebx
call sub.MSVCR90.dll__CIcos
fmul qword [esp + 0x24]
fild dword [esp + 0x14]
mov dword [esp + 0x14], ebx
fadd st(1)
fcomp qword [0x6345d0]
fnstsw ax
fiadd dword [esp + 0x14]
test ah, 1
jne 0x5880c3
fadd qword [0x634650]
jmp 0x5880c9
fsub qword [0x634650]
call fcn.005fbb60
fld qword [esp + 0x1c]
mov dword [esp + 0x8c], eax
call fcn.005fbb60
fld qword [esp + 0x5c]
fld qword [esp + 0x2c]
push edi
sub esp, 8
fadd st(1), st(0)
mov dword [esp + 0x9c], eax
fxch st(1)
mov eax, esp
mov dword [esp + 0x28], esp
fstp qword [eax]
sub esp, 8
mov eax, esp
fstp qword [eax]
mov ecx, dword [esi + 0xc]
add ecx, ecx
add ecx, ecx
mov dword [esp + 0x30], esp
push ecx
lea edx, [esp + 0xa4]
push edx
lea ecx, [esp + 0x1c0]
call fcn.0051b990
lea ecx, [esp + 0x64]
mov byte [esp + 0x1d8], 4
call fcn.00520ea0
lea ecx, [esp + 0x78]
mov byte [esp + 0x1d8], 5
call fcn.00520ea0
xor eax, eax
xor ebx, ebx
cmp ax, word [esi + 0x16]
mov byte [esp + 0x1d8], 6
jge 0x5882e8
lea esp, [esp]
lea ecx, [esp + 0x94]
push ecx
lea ecx, [esp + 0x1a8]
call fcn.00520420
mov edx, dword [eax]
mov ecx, dword [esp + 0x1a8]
mov dword [esp + 0x68], edx
mov eax, dword [eax + 4]
mov edx, dword [esp + 0x1ac]
mov dword [esp + 0x6c], eax
lea eax, [esp + 0x19c]
mov dword [esp + 0x70], ecx
push eax
lea ecx, [esp + 0x1a8]
mov dword [esp + 0x78], edx
call fcn.00520420
mov ecx, dword [eax]
mov dword [esp + 0x7c], ecx
mov edx, dword [eax + 4]
mov eax, dword [esp + 0x1b0]
mov ecx, dword [esp + 0x1b4]
mov dword [esp + 0x80], edx
mov dword [esp + 0x84], eax
lea edx, [esp + 0x1c]
push edx
mov dword [esp + 0x8c], ecx
lea eax, [esp + 0xb0]
push eax
lea ecx, [esp + 0x1ac]
push ecx
lea edx, [esp + 0x54]
push edx
lea eax, [esp + 0x88]
push eax
lea ecx, [esp + 0x78]
push ecx
mov ecx, esi
call fcn.00587990
lea edx, [esp + 0x14]
push edx
lea eax, [esp + 0x150]
push eax
lea ecx, [esp + 0x1ac]
push ecx
lea edx, [esp + 0x40]
push edx
lea eax, [esp + 0x88]
push eax
lea ecx, [esp + 0x78]
push ecx
mov ecx, esi
call fcn.00587990
mov ecx, dword [esp + 0x14]
mov edi, dword [esp + 0x1c]
test ecx, ecx
jle 0x588270
lea eax, [esp + ecx*8 + 0x144]
jmp 0x588250
mov edx, dword [eax]
mov dword [esp + edi*8 + 0xac], edx
mov edx, dword [eax + 4]
mov dword [esp + edi*8 + 0xb0], edx
dec ecx
inc edi
sub eax, 8
test ecx, ecx
jg 0x588250
mov dword [esp + 0x14], ecx
push 0x14
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x24], eax
mov byte [esp + 0x1d8], 7
test eax, eax
je 0x58829c
push edi
lea ecx, [esp + 0xb0]
push ecx
mov ecx, eax
call fcn.00552290
jmp 0x58829e
xor eax, eax
mov edx, dword [esp + 0x18]
fld qword [esp + 0x5c]
mov dword [edx + ebx*4], eax
mov eax, dword [esi + 4]
mov ecx, dword [esi + 8]
lea edx, [esp + 0x2c]
push edx
sub esp, 8
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], ecx
mov eax, esp
lea ecx, [esp + 0x1b0]
fstp qword [eax]
mov byte [esp + 0x1e4], 6
mov dword [esp + 0x30], esp
call fcn.0051f570
movsx eax, word [esi + 0x16]
inc ebx
cmp ebx, eax
jl 0x588160
lea ecx, [esp + 0x78]
mov byte [esp + 0x1d8], 5
call fcn.00520f30
lea ecx, [esp + 0x64]
mov byte [esp + 0x1d8], 4
call fcn.00520f30
lea ecx, [esp + 0x1a4]
mov byte [esp + 0x1d8], 1
call fcn.0051c420
lea ecx, [esp + 0x48]
mov byte [esp + 0x1d8], 0
call fcn.00517ca0
lea ecx, [esp + 0x34]
mov dword [esp + 0x1d8], 0xffffffff
call fcn.00517ca0
mov ecx, dword [esp + 0x1d0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x1b8]
xor ecx, esp
call fcn.005fb9ce
mov esp, ebp
pop ebp
ret 4