Function at 0x5861d0
Capabilities:
Check if file exists

Disassembly:
push ecx
push ebx
push ebp
mov ebp, dword [0x6790a8]
xor ebx, ebx
cmp dword [ebp + 0xa4], ebx
push esi
push edi
jne 0x5864b9
mov ecx, dword [ebp + 0x18]
mov dword [ebp + 0x10], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp + 0xa4], 1
mov edx, dword [ecx]
mov edx, dword [edx + 4]
push eax
call edx
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x1c]
push eax
push ecx
call fcn.0059a6b0
mov edx, dword [ebp + 0x20]
mov eax, dword [ebp + 0x10]
mov dword [edx + 4], eax
mov esi, dword [ebp + 0x24]
call fcn.005a6080
mov eax, dword [ebp + 0x28]
push 1
mov dword [eax + 0x14], ebx
call fcn.0059e010
mov eax, dword [ebp + 0x2c]
call fcn.005a51c0
mov ecx, dword [ebp + 0x30]
mov edx, dword [ebp + 0x10]
mov dword [ecx + 0xc], edx
call fcn.005a1640
mov esi, dword [ebp + 0x38]
mov eax, dword [esi + 0x18]
cmp dword [eax - 0xc], ebx
lea edi, [esi + 0x18]
jne 0x58627c
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x58627c
xor edx, edx
call fcn.00403760
mov edi, dword [edi]
cmp dword [edi - 0xc], ebx
je 0x58627c
mov ecx, dword [esi + 0x1c]
cmp ecx, ebx
je 0x58627c
mov ebx, edi
call fcn.005852c0
xor ebx, ebx
mov esi, dword [ebp + 0x3c]
mov edi, dword [ebp + 0x10]
mov eax, esi
call fcn.005a0030
mov dword [esi + 0x14], edi
mov ecx, dword [ebp + 0x40]
mov edx, dword [ebp + 0x10]
mov dword [ecx + 8], edx
mov eax, dword [ebp + 0x88]
cmp eax, ebx
mov dword [ebp + 0x80], 2
je 0x5862b8
push eax
call fcn.005d28c2
add esp, 4
mov dword [ebp + 0x88], ebx
mov eax, dword [ebp + 0x8c]
cmp eax, ebx
je 0x5862d1
push eax
call fcn.005d28c2
add esp, 4
mov dword [ebp + 0x8c], ebx
lea esi, [ebp + 0x198]
mov eax, esi
mov dword [ebp + 0x98], ebx
mov dword [ebp + 0x9c], ebx
mov dword [ebp + 0xb4], ebx
mov dword [ebp + 0x84], ebx
call fcn.0057a810
test eax, eax
jle 0x5863a7
mov edi, edi
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x586313
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x586318
call fcn.005d29f1
mov ecx, dword [esi + 4]
cmp dword [ecx + ebx*4], 0
je 0x586395
test ecx, ecx
je 0x586331
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x586336
call fcn.005d29f1
mov eax, dword [esi + 4]
mov edi, dword [eax + ebx*4]
test edi, edi
je 0x586373
mov eax, dword [edi + 8]
test eax, eax
je 0x586355
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [edi + 8], 0
mov eax, dword [edi + 0xc]
test eax, eax
je 0x58636a
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [edi + 0xc], 0
push edi
call fcn.005d2367
add esp, 4
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x586386
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x58638b
call fcn.005d29f1
mov ecx, dword [esi + 4]
mov dword [ecx + ebx*4], 0
mov eax, esi
add ebx, 1
call fcn.0057a810
cmp ebx, eax
jl 0x586300
mov eax, esi
call fcn.004fc8d0
lea esi, [ebp + 0x184]
xor ebx, ebx
mov eax, esi
mov dword [ebp + 0x194], ebx
call fcn.0057a810
test eax, eax
jle 0x586477
jmp 0x5863d0
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x5863e3
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x5863e8
call fcn.005d29f1
mov ecx, dword [esi + 4]
cmp dword [ecx + ebx*4], 0
je 0x586465
test ecx, ecx
je 0x586401
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x586406
call fcn.005d29f1
mov edx, dword [esi + 4]
mov edi, dword [edx + ebx*4]
test edi, edi
je 0x586443
mov eax, dword [edi + 8]
test eax, eax
je 0x586425
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [edi + 8], 0
mov eax, dword [edi + 0xc]
test eax, eax
je 0x58643a
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [edi + 0xc], 0
push edi
call fcn.005d2367
add esp, 4
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x586456
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x58645b
call fcn.005d29f1
mov eax, dword [esi + 4]
mov dword [eax + ebx*4], 0
mov eax, esi
add ebx, 1
call fcn.0057a810
cmp ebx, eax
jl 0x5863d0
mov eax, esi
call fcn.004fc8d0
fldz
fst qword [ebp + 0x1a8]
xor eax, eax
fst qword [ebp + 0x1b0]
lea ecx, [ebp + 0x2d0]
fstp qword [ebp + 0x1b8]
push ecx
mov dword [ebp + 0xa8], eax
mov dword [ebp + 0xac], eax
mov dword [ebp + 0xb0], eax
push ebp
mov dword [ebp + 0xb8], eax
call fcn.00588af0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
pop ecx
ret