Function at 0x4121c3
Capabilities:
Check if file exists
Delete file
Get common file path
Move file

Disassembly:
push ebp
sub esp, 0x480
lea ebp, [esp - 4]
mov eax, dword [0x552994]
xor eax, ebp
mov dword [ebp + 0x480], eax
push 0x20
mov eax, 0x5071ca
call fcn.0041bac7
mov ebx, dword [ebp + 0x48c]
push ebx
mov dword [ebp - 0x10], ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x412423
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
xor esi, esi
cmp eax, esi
jne 0x412423
mov edi, 0x206
push edi
lea eax, [ebp + 0x72]
push esi
push eax
mov word [ebp + 0x70], si
call fcn.0041bd70
push edi
lea eax, [ebp + 0x27a]
push esi
push eax
mov word [ebp + 0x278], si
call fcn.0041bd70
add esp, 0x18
mov edi, 0x54b284
push edi
lea ecx, [ebp + 0x38]
call fcn.00401590
lea eax, [ebp + 0x278]
push eax
push 0x104
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp + 0x70]
push eax
push ebx
call fcn.00410356
lea eax, [ebp]
push ebx
push eax
call fcn.00411362
lea eax, [ebp + 0x278]
push eax
lea eax, [ebp + 0x1c]
push eax
mov byte [ebp - 4], 1
call fcn.00411362
lea eax, [ebp]
push eax
mov byte [ebp - 4], 2
call fcn.00410e52
lea eax, [ebp + 0x1c]
push eax
call fcn.00410e52
add esp, 0x20
lea eax, [ebp]
push eax
lea ecx, [ebp + 0x1c]
call fcn.0040745b
test eax, eax
jne 0x4122c1
lea eax, [ebp + 0x278]
push eax
lea ecx, [ebp + 0x38]
call fcn.00401760
jmp 0x4122ec
lea eax, [ebp + 0x54]
push ebx
push eax
call fcn.004113e1
pop ecx
pop ecx
push 0xffffffffffffffff
push esi
push eax
lea ecx, [ebp + 0x38]
mov byte [ebp - 4], 3
call fcn.00401d00
push esi
push 1
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 2
call fcn.00401790
xor ebx, ebx
push edi
lea ecx, [ebp + 0x54]
call fcn.00401590
push 0xffffffffffffffff
push esi
lea eax, [ebp + 0x38]
push eax
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 4
call fcn.00401d00
lea eax, [ebp + 0x70]
push eax
lea ecx, [ebp + 0x54]
call fcn.004035f0
push str..del
lea ecx, [ebp + 0x54]
call fcn.004035f0
cmp ebx, esi
jle 0x412357
mov eax, ebx
cdq
push edx
push eax
lea eax, [ebp - 0x2c]
push eax
call fcn.004118b8
add esp, 0xc
push 0xffffffffffffffff
push esi
push eax
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 5
call fcn.00403a80
push esi
push 1
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 4
call fcn.00401790
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x412363
lea eax, [ebp + 0x58]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x41239f
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x41237a
lea eax, [ebp + 0x58]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp eax, esi
jne 0x41239f
cmp ebx, 0xa
push esi
lea ecx, [ebp + 0x54]
jge 0x4123fc
push 1
inc ebx
mov byte [ebp - 4], 2
call fcn.00401790
jmp 0x4122ee
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x4123ab
lea eax, [ebp + 0x58]
push eax
push dword [ebp - 0x10]
call fcn.0041e90d
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
pop ecx
pop ecx
jae 0x4123c2
lea eax, [ebp + 0x58]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push eax
call ebx
test eax, eax
mov edi, dword [sym.imp.KERNEL32.dll_MoveFileExW]
je 0x4123e7
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x4123e1
lea eax, [ebp + 0x58]
push 5
push esi
push eax
call edi
push dword [ebp - 0x10]
call ebx
test eax, eax
je 0x4123f8
push 5
push esi
push dword [ebp - 0x10]
call edi
push esi
lea ecx, [ebp + 0x54]
xor edi, edi
inc edi
push edi
call fcn.00401790
push esi
push edi
lea ecx, [ebp + 0x1c]
call fcn.00401790
push esi
push edi
lea ecx, [ebp]
call fcn.00401790
push esi
push edi
lea ecx, [ebp + 0x38]
call fcn.00401790
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x480]
xor ecx, ebp
call fcn.0041bab8
add ebp, 0x484
leave
ret