Function at 0x100003d5c
Capabilities:
Check if file exists
Get common file path
Get file attributes
Move file
Set current directory

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x880
mov rax, qword [0x10009e100]
xor rax, rsp
mov qword [rsp + 0x870], rax
mov r12b, r8b
mov r13d, edx
mov rdi, rcx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r9d, dword [0x10009e3b8]
xor ebx, ebx
mov esi, eax
test r9d, r9d
je 0x100003f56
mov rbp, qword [0x10009e3c8]
mov rdx, rbp
cmp qword [rdx], rdi
jne 0x100031a76
cmp ebx, r9d
jae 0x100003f56
mov r14d, 0x104
lea rcx, [rsp + 0x660]
xor edx, edx
mov r8, r14
call sub.msvcrt.dll_memset
lea rax, [rsp + 0x660]
mov edi, ebx
imul rdi, rdi, 0x218
mov edx, dword [rdi + rbp + 8]
xor r9d, r9d
xor r8d, r8d
xor ecx, ecx
mov qword [rsp + 0x20], rax
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea rcx, [rsp + 0x30]
mov r8, r14
xor edx, edx
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x30]
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea rcx, [rsp + 0x660]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
and r13d, 0x28
cmp r13b, 0x28
je 0x100031a8d
lea rcx, str.Microsoft_Games
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
test eax, eax
je 0x100031b09
mov rcx, qword [0x10009e158]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
test eax, eax
je 0x100031b09
mov rax, qword [0x10009e3c8]
lea rcx, [rsp + 0x450]
mov rdx, r14
lea r8, [rdi + rax + 0xc]
call sub.msvcrt.dll_wcscpy_s
lea r8, str..tmp
lea rcx, [rsp + 0x450]
mov rdx, r14
call sub.msvcrt.dll_wcscat_s
test r12b, r12b
je 0x100003f13
mov rax, qword [0x10009e3c8]
lea rcx, [rsp + 0x240]
mov rdx, r14
lea r8, [rdi + rax + 0xc]
call sub.msvcrt.dll_wcscpy_s
lea r8, str..bak
lea rcx, [rsp + 0x240]
mov rdx, r14
call sub.msvcrt.dll_wcscat_s
mov r11, qword [0x10009e3c8]
lea rcx, [rdi + r11 + 0xc]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x100003f13
mov rax, qword [0x10009e3c8]
lea rdx, [rsp + 0x240]
mov r8d, 1
lea rcx, [rdi + rax + 0xc]
call qword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
je 0x100031ac3
mov rax, qword [0x10009e3c8]
lea rcx, [rsp + 0x450]
mov r8d, 1
lea rdx, [rdi + rax + 0xc]
call qword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
je 0x100031b29
lea rcx, [0x10009e3b8]
mov edx, ebx
call fcn.1000246a8
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov eax, esi
mov rcx, qword [rsp + 0x870]
xor rcx, rsp
call fcn.1000024e0
lea r11, [rsp + 0x880]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsp, r11
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
inc ebx
add rdx, 0x218
cmp ebx, r9d
jae 0x100003dbd
jmp 0x100003db4
lea r9, [rsp + 0x240]
lea rcx, [0x10007ca20]
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0x20], r14d
call sub.SHELL32.dll_SHGetFolderPathEx
test eax, eax
js 0x100031b09
lea rcx, [rsp + 0x240]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
nop
jmp 0x100003e3f
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov r11, qword [0x10009e3c8]
lea rcx, [rsp + 0x240]
mov qword [rsp + 0x28], rcx
mov edx, 0xc5
lea rax, [rdi + r11 + 0xc]
lea r9, str.Couldnt_move_old_file__s_to_the_backup_file__s
lea r8, str.SaveFS.cpp
lea ecx, [rdx - 0x45]
mov qword [rsp + 0x20], rax
call fcn.100002c98
jmp 0x100031b14
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
lea rcx, [0x10009e3b8]
mov edx, ebx
call fcn.1000246a8
xor eax, eax
jmp 0x100003f56
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov r11, qword [0x10009e3c8]
mov edx, 0xcf
lea rax, [rdi + r11 + 0xc]
lea r9, str.Couldnt_move_backup_file__s_to_actual_file__s
lea r8, str.SaveFS.cpp
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x450]
lea ecx, [rdx - 0x4f]
mov qword [rsp + 0x20], rax
call fcn.100002c98
xor esi, esi
jmp 0x100003f3b