Function at 0x5615c0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x626be3
mov eax, dword fs:[0]
push eax
sub esp, 0x78
mov eax, dword [0x685e38]
xor eax, esp
mov dword [esp + 0x70], eax
push ebx
push esi
push edi
mov eax, dword [0x685e38]
xor eax, esp
push eax
lea eax, [esp + 0x88]
mov dword fs:[0], eax
mov edi, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0x10]
mov ebx, dword [ebp + 0x14]
lea edx, [edi + edi*2 + 6]
add edx, edx
add edx, edx
add edx, edx
push edx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x30], ecx
mov dword [esp + 0x4c], ebx
call dword [sym.imp.MSVCR90.dll_malloc]
mov esi, eax
add esp, 4
lea eax, [esp + 0x34]
push eax
mov ecx, ebx
mov dword [esp + 0x34], esi
call fcn.0051d930
fld qword [eax]
lea ecx, [ebx + 4]
fstp qword [esp + 0x4c]
fld qword [eax + 8]
push ecx
mov ecx, esi
fstp qword [esp + 0x58]
call fcn.00522bf0
lea edx, [ebx + 0xc]
lea eax, [edi + edi*2 + 3]
push edx
lea ecx, [esi + eax*8]
call fcn.00522bf0
lea ecx, [esp + 0x34]
push ecx
mov ecx, ebx
call fcn.0051c490
fld qword [eax]
mov dx, word [ebx + 0x20]
fstp qword [esp + 0x34]
and dx, 0xfff9
cmp edi, 1
movzx eax, dx
mov dword [esp + 0x1c], eax
jl 0x561768
mov ecx, dword [esp + 0x18]
lea ebx, [esi + 0x28]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x20], edi
mov ecx, dword [esp + 0x14]
push esi
call fcn.005cbce0
lea ecx, [ebx - 0x10]
test eax, eax
je 0x5616b9
push esi
call fcn.005cbd10
fldz
fstp qword [ebx]
jmp 0x561755
mov edx, dword [esp + 0x14]
push edx
call fcn.005cbd10
mov eax, dword [esp + 0x14]
mov edx, dword [eax + 4]
mov ecx, dword [eax]
mov dword [esp + 0x44], edx
fild dword [esp + 0x44]
mov dword [esp + 0x24], ecx
fsub qword [esp + 0x54]
fild dword [esp + 0x24]
fsub qword [esp + 0x4c]
fldz
fld st(0)
fucomp st(2)
fnstsw ax
test ah, 0x44
jp 0x56171f
fstp st(1)
fld st(0)
fucomp st(2)
fnstsw ax
test ah, 0x44
jp 0x561704
fstp st(1)
fld st(0)
jmp 0x56172a
fcom st(1)
fnstsw ax
fstp st(1)
test ah, 5
jp 0x561717
fld qword [0x6345f0]
jmp 0x56172a
fld qword [0x6345e8]
jmp 0x56172a
fstp st(0)
call sub.MSVCR90.dll__CIatan2
fldz
fxch st(1)
cmp word [esp + 0x1c], 1
jne 0x561738
fsubr qword [esp + 0x34]
jmp 0x56173c
fsub qword [esp + 0x34]
fst qword [ebx]
fcom st(1)
fnstsw ax
fstp st(1)
test ah, 5
jp 0x561753
fadd qword [0x634610]
fstp qword [ebx]
jmp 0x561755
fstp st(0)
add dword [esp + 0x14], 0x10
add ebx, 0x18
sub dword [esp + 0x20], 1
jne 0x561699
push 0x560e70
push 0x18
lea eax, [esi + 0x18]
push edi
push eax
mov dword [esp + 0x2c], eax
call dword [sym.imp.MSVCR90.dll_qsort]
lea eax, [edi + 1]
add esp, 0x10
xor ebx, ebx
test eax, eax
jle 0x561878
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
lea ebx, [ebx]
mov ecx, dword [esp + 0x48]
push ecx
lea ecx, [esp + 0x60]
call fcn.0051ec30
mov edx, dword [esi - 0x18]
mov eax, dword [esi - 0x14]
lea ecx, [esp + 0x34]
push ecx
lea ecx, [esp + 0x60]
mov dword [esp + 0x94], 0
mov dword [esp + 0x38], edx
mov dword [esp + 0x3c], eax
call fcn.0051f1c0
mov edx, dword [esi]
mov eax, dword [esi + 4]
lea ecx, [esp + 0x24]
push ecx
lea ecx, [esp + 0x60]
mov dword [esp + 0x28], edx
mov dword [esp + 0x2c], eax
call fcn.0051f2f0
push 0x24
call sub.MSVCR90.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x1c], eax
mov byte [esp + 0x90], 1
test eax, eax
je 0x56181c
lea edx, [esp + 0x5c]
push edx
mov ecx, eax
call fcn.0051ec30
mov dword [esp + 0x18], eax
jmp 0x561824
mov dword [esp + 0x18], 0
mov ecx, dword [esp + 0x2c]
mov eax, dword [ecx]
push eax
mov byte [esp + 0x94], 0
call fcn.005f3cc0
cmp ebx, edi
mov ecx, dword [esp + 0x18]
mov dword [eax], ecx
jge 0x56184c
mov ecx, dword [esp + 0x14]
push esi
call fcn.005cbd10
lea ecx, [esp + 0x5c]
mov dword [esp + 0x90], 0xffffffff
call fcn.0051c420
add dword [esp + 0x14], 0x10
inc ebx
lea eax, [edi + 1]
add esi, 0x18
cmp ebx, eax
jl 0x5617a0
mov esi, dword [esp + 0x30]
push esi
call dword [sym.imp.MSVCR90.dll_free]
add esp, 4
mov ecx, dword [esp + 0x88]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x70]
xor ecx, esp
call fcn.005fb9ce
mov esp, ebp
pop ebp
ret