Function at 0x140002850
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
mov qword [rsp + 8], rbx
push rbp
lea rbp, [rsp - 0x3e0]
sub rsp, 0x4e0
mov rax, qword [0x14000c010]
xor rax, rsp
mov qword [rbp + 0x3d0], rax
lea rax, [rbp - 0x50]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 0x1c]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x140002bfd
lea rax, [rbp + 0x1c0]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 0x28]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x140002bfd
lea rdx, [rbp - 0x50]
lea rcx, [rbp - 0x70]
call fcn.140003f40
nop
lea rdx, str.Battlestate_Games
lea rcx, [rbp - 0x70]
call fcn.140004130
lea rcx, [rbp - 0x70]
cmp qword [rbp - 0x58], 8
cmovae rcx, qword [rbp - 0x70]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x14000290c
test al, 0x10
je 0x14000290c
lea rcx, [rbp - 0x70]
call fcn.140001460
lea rdx, str.Battlestate_Games_folder_in_AppDataLocal_removed_successfully.
jmp 0x140002913
lea rdx, str.Battlestate_Games_folder_in_AppDataLocal_does_not_exist.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.1400041f0
lea rdx, [0x1400043d0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rdx, [rbp + 0x1c0]
lea rcx, [rsp + 0x70]
call fcn.140003f40
nop
lea rdx, str.AppDataLocalLowBattlestate_Games
lea rcx, [rsp + 0x70]
call fcn.140004130
lea rcx, [rsp + 0x70]
cmp qword [rbp - 0x78], 8
cmovae rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x140002984
test al, 0x10
je 0x140002984
lea rcx, [rsp + 0x70]
call fcn.140001460
lea rdx, str.Battlestate_Games_folder_in_AppDataLocalLow_removed_successfully.
jmp 0x14000298b
lea rdx, str.Battlestate_Games_folder_in_AppDataLocalLow_does_not_exist.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.1400041f0
lea rdx, [0x1400043d0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rdx, [rbp - 0x50]
lea rcx, [rsp + 0x50]
call fcn.140003f40
nop
lea rdx, str.TempBattlestate_Games
lea rcx, [rsp + 0x50]
call fcn.140004130
lea rcx, [rsp + 0x50]
cmp qword [rsp + 0x68], 8
cmovae rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x1400029fa
test al, 0x10
je 0x1400029fa
lea rcx, [rsp + 0x50]
call fcn.140001460
lea rdx, str.TempBattlestate_Games_folder_in_AppDataLocal_removed_successfully.
jmp 0x140002a01
lea rdx, str.TempBattlestate_Games_folder_in_AppDataLocal_does_not_exist.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.1400041f0
lea rdx, [0x1400043d0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rdx, str.Battlestate_GamesEFTLogs
lea rcx, [rsp + 0x30]
call fcn.140003f40
nop
lea rcx, [rsp + 0x30]
call fcn.1400019a0
nop
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x140002a7f
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002a7a
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002a7a
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400055fc
call fcn.140001c60
mov r9d, 0x24
lea r8, str.Open_BsgLauncher
lea rdx, str.Do_you_want_to_open_BsgLauncher_
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxW]
cmp eax, 6
jne 0x140002b08
lea rdx, str.Battlestate_GamesBsgLauncherBsgLauncher.exe
lea rcx, [rsp + 0x30]
call fcn.140003f40
nop
lea rcx, [rsp + 0x30]
call fcn.1400023e0
nop
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x140002b08
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002b02
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002b02
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400055fc
nop
mov rdx, qword [rsp + 0x68]
cmp rdx, 8
jb 0x140002b4d
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002b48
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002b48
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400055fc
movdqa xmm0, xmmword [0x1400090c0]
movdqu xmmword [rsp + 0x60], xmm0
xor ebx, ebx
mov word [rsp + 0x50], bx
mov rdx, qword [rbp - 0x78]
cmp rdx, 8
jb 0x140002ba6
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x70]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002ba1
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002ba1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400055fc
movdqa xmm0, xmmword [0x1400090c0]
movdqu xmmword [rbp - 0x80], xmm0
mov word [rsp + 0x70], bx
mov rdx, qword [rbp - 0x58]
cmp rdx, 8
jb 0x140002c20
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x70]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002bf6
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002bf6
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400055fc
jmp 0x140002c20
lea rdx, str.Error_getting_Local_AppData_folder_paths.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.1400041f0
lea rdx, [0x1400043d0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rdx, str.Files_and_directories_cleaned.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.1400041f0
lea rdx, [0x1400043d0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
mov rcx, qword [rbp + 0x3d0]
xor rcx, rsp
call fcn.1400054d0
mov rbx, qword [rsp + 0x4f0]
add rsp, 0x4e0
pop rbp
ret