Function at 0x412080
Capabilities:
Check if file exists
Delete file
Get common file path
Move file
Set file attributes

Disassembly:
push 0xffffffffffffffff
push 0x442536
mov eax, dword fs:[0]
push eax
sub esp, 0x660
mov eax, dword [0x4513e0]
xor eax, esp
mov dword [esp + 0x658], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4513e0]
xor eax, esp
push eax
lea eax, [esp + 0x674]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x684]
xor ebx, ebx
mov esi, ecx
mov dword [esp + 0x50], 7
mov dword [esp + 0x4c], ebx
mov word [esp + 0x3c], bx
lea eax, [esp + 0x1c]
push eax
push esi
mov ecx, str.path
mov dword [esp + 0x684], ebx
call fcn.00408280
push 0xffffffffffffffff
push ebx
lea ecx, [esp + 0x40]
mov byte [esp + 0x684], 1
call fcn.00403500
mov edi, 8
mov byte [esp + 0x67c], bl
cmp dword [esp + 0x34], edi
jb 0x412121
mov ecx, dword [esp + 0x20]
push ecx
call fcn.00429d64
add esp, 4
mov edx, dword [esi + 4]
push edx
push str.File
push str.__s____d_
push 0x4524d8
xor eax, eax
call fcn.0041eee0
add dword [0x4524f8], 1
push ebx
call fcn.004237c0
mov eax, dword [esp + 0x50]
add esp, 0x14
cmp dword [esp + 0x50], edi
jae 0x412159
lea eax, [esp + 0x3c]
push eax
push str.Deleting__s
push 0x4524d8
xor eax, eax
call fcn.0041eee0
mov ebx, dword [esp + 0x48]
add esp, 0xc
cmp dword [esp + 0x50], edi
jae 0x41217c
lea ebx, [esp + 0x3c]
mov ecx, 0xbbe
call fcn.00425dd0
cmp dword [esp + 0x50], edi
mov eax, dword [esp + 0x3c]
jae 0x412194
lea eax, [esp + 0x3c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp dword [esp + 0x50], edi
mov eax, dword [esp + 0x3c]
jae 0x4121ae
lea eax, [esp + 0x3c]
mov esi, dword [sym.imp.KERNEL32.dll_DeleteFileW]
push eax
call esi
test eax, eax
jne 0x41221c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x4121e5
cmp eax, 3
je 0x4121e5
push eax
push str.Delete_error_0x_X__marking_for_delete_on_next_reboot
push 0x4524d8
mov eax, 1
call fcn.0041eee0
add esp, 0xc
jmp 0x4121fc
push str.Does_not_exist__skipping
push 0x4524d8
mov eax, 1
call fcn.0041eee0
add esp, 8
cmp dword [esp + 0x50], edi
mov eax, dword [esp + 0x3c]
jae 0x41220a
lea eax, [esp + 0x3c]
push 4
push 0
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov dword [ebp + 0x34], 1
cmp dword [esp + 0x50], edi
mov eax, dword [esp + 0x3c]
jae 0x41222a
lea eax, [esp + 0x3c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindExtensionW]
test eax, eax
je 0x4123e8
push str..lnk
push eax
call fcn.0042a42f
add esp, 8
test eax, eax
jne 0x4123e8
push str.Deleted_a_shortcut__checking_for_empty_parent_folders
push 0x4524d8
mov dword [esp + 0x1c], vtable.CShellFileCount.0
mov dword [esp + 0x20], eax
call fcn.0041eee0
mov eax, dword [esp + 0x44]
add esp, 8
cmp dword [esp + 0x50], edi
jae 0x41227b
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x260]
push 0x104
push eax
call fcn.00429cf8
add esp, 0xc
lea ecx, [esp + 0x25c]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
je 0x4123e8
mov edi, dword [sym.imp.KERNEL32.dll_MoveFileW]
mov ebx, dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov ebp, dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea esp, [esp]
lea edx, [esp + 0x54]
push edx
push 0
push 0
push 0x19
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea eax, [esp + 0x54]
lea edx, [eax + 2]
lea ebx, [ebx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4122e0
sub eax, edx
sar eax, 1
push eax
lea eax, [esp + 0x58]
push eax
lea ecx, [esp + 0x264]
push ecx
call fcn.0042a756
add esp, 0xc
test eax, eax
je 0x4123e3
lea edx, [esp + 0x18]
push edx
push 0x4475fc
lea eax, [esp + 0x264]
push eax
lea ecx, [esp + 0x20]
call fcn.0041c5c0
test eax, eax
jne 0x412346
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x260]
push edx
mov edx, dword [eax + 4]
lea ecx, [esp + 0x1c]
call edx
cmp dword [esp + 0x18], 0
jne 0x4123e3
push 0x104
lea eax, [esp + 0x468]
push eax
call ebp
push str.temp
lea ecx, [esp + 0x468]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
lea edx, [esp + 0x54]
push edx
push 0
push 0x448b14
lea eax, [esp + 0x470]
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
lea ecx, [esp + 0x54]
push ecx
call esi
lea edx, [esp + 0x54]
push edx
call esi
lea eax, [esp + 0x54]
push eax
lea ecx, [esp + 0x260]
push ecx
call edi
lea edx, [esp + 0x54]
push edx
call ebx
lea eax, [esp + 0x25c]
push eax
push str.Deleted_folder__s
push 0x4524d8
xor eax, eax
call fcn.0041eee0
add esp, 0xc
lea ecx, [esp + 0x25c]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
jne 0x4122c0
mov edi, 8
push 1
call fcn.004237c0
sub dword [0x4524f8], 1
add esp, 4
cmp dword [esp + 0x50], edi
jb 0x41240c
mov edx, dword [esp + 0x3c]
push edx
call fcn.00429d64
add esp, 4
mov ecx, dword [esp + 0x674]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x658]
xor ecx, esp
call fcn.004289ca
add esp, 0x66c
ret 4