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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56d226
mov eax, dword fs:[0]
push eax
mov eax, 0x1524
call fcn.004fa110
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x1530], eax
mov dword [ebp - 0x152c], edi
mov eax, dword [edi]
cmp dword [eax - 0xc], 0
jne 0x418063
xor eax, eax
jmp 0x418314
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push eax
call ebx
test eax, eax
je 0x41805c
mov dword [ebp - 4], 0
call fcn.004062e0
mov ecx, eax
test ecx, ecx
je 0x418349
mov eax, dword [ecx]
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x1528], esi
push 0x208
lea eax, [ebp - 0x218]
mov dword [ebp - 4], 1
push 0
push eax
call fcn.0053f0a0
push 0x208
lea eax, [ebp - 0x520]
push 0
push eax
call fcn.0053f0a0
add esp, 0x18
lea eax, [ebp - 0x520]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea eax, [ebp - 0x520]
push eax
call fcn.00556a36
mov eax, dword [edi]
add esp, 4
cmp dword [eax - 0xc], 0
jl 0x418353
movzx eax, word [eax]
push eax
call fcn.00550430
movzx eax, ax
add esp, 4
cmp word [ebp - 0x520], ax
jne 0x41811d
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
jmp 0x418171
mov eax, dword [edi]
cmp dword [eax - 0xc], 0
jl 0x41835d
movzx eax, word [eax]
push eax
push str._c:.temp
lea eax, [ebp - 0x218]
push 0x104
push eax
call fcn.00408db0
add esp, 0x10
lea eax, [ebp - 0x218]
push eax
call ebx
test eax, eax
jne 0x418171
lea eax, [ebp - 0x218]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
push 2
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x1524]
call fcn.0040a2d0
mov edi, dword [ebp - 0x1524]
mov byte [ebp - 4], 2
cmp dword [edi - 0xc], 0x104
jg 0x418284
push 0x800
lea eax, [ebp - 0x1520]
push 0
push eax
call fcn.0053f0a0
push 0x800
lea eax, [ebp - 0xd20]
push 0
push eax
call fcn.0053f0a0
push edi
lea eax, [ebp - 0x1520]
push 0x400
push eax
call fcn.00542a8c
push 0x100
lea eax, [ebp - 0x318]
push 0
push eax
call fcn.0053f0a0
add esp, 0x30
xor edi, edi
nop word [eax + eax]
lea eax, [ebp - 0x318]
push 0x80
push eax
call fcn.0041a430
add esp, 8
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp - 0x1520]
push eax
lea eax, [ebp - 0xd20]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
push str..tmp
lea eax, [ebp - 0xd20]
push 0x400
push eax
call fcn.00550460
add esp, 0xc
lea eax, [ebp - 0xd20]
push eax
call ebx
test eax, eax
je 0x41824d
inc edi
cmp edi, 0xa
jl 0x4181f0
jmp 0x41827e
lea ecx, [ebp - 0xd20]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x418256
sub ecx, edx
lea eax, [ebp - 0xd20]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x1528]
call fcn.00406810
mov esi, dword [ebp - 0x1528]
mov edi, dword [ebp - 0x1524]
lea edx, [edi - 0x10]
mov byte [ebp - 4], 1
or edi, 0xffffffff
mov eax, edi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4182a2
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x152c]
push esi
push dword [eax]
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x4182fb
mov eax, dword [ebp - 0x152c]
push dword [eax]
call ebx
test eax, eax
je 0x418330
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x4182fb
push esi
call ebx
test eax, eax
je 0x4182fb
push 0x80
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x4182f0
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x4182fb
push 4
push 0
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
xor ebx, ebx
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], edi
dec edi
test edi, edi
jg 0x418312
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004fa0d4
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x1530]
lea eax, [ebp - 0x1528]
push eax
call fcn.00408680
mov ebx, 1
jmp 0x4182fd
push 0x80004005
call fcn.004061e0
push 0x80070057
call fcn.004061e0
push 0x80070057
call fcn.004061e0
int3