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

Disassembly:
push 0x240
mov eax, 0x446992
call fcn.00427f9e
mov dword [ebp - 0x22c], ecx
push 0x208
xor ebx, ebx
lea eax, [ebp - 0x218]
push ebx
push eax
call fcn.00428c30
add esp, 0xc
call fcn.0040e19e
push eax
lea ecx, [ebp - 0x224]
call fcn.00401339
mov dword [ebp - 4], ebx
mov dword [ebp - 0x24c], ebx
call fcn.0040e19e
push eax
lea ecx, [ebp - 0x234]
call fcn.00401339
xor eax, eax
inc eax
mov byte [ebp - 4], al
call fcn.0040e19e
push eax
lea ecx, [ebp - 0x240]
call fcn.00401339
mov byte [ebp - 4], 2
call fcn.0040e19e
push eax
lea ecx, [ebp - 0x23c]
call fcn.00401339
push ebx
push 0x25
lea eax, [ebp - 0x218]
mov byte [ebp - 4], 3
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
jne 0x402c8a
mov esi, str.Unable_to_get_system_folder_path._n
push esi
call fcn.0042c48c
pop ecx
push eax
push esi
mov ecx, 0x461d14
call fcn.00401822
mov ecx, 0x461c48
call fcn.0040c3c8
mov esi, dword [ebp - 0x234]
jmp 0x402f7d
lea eax, [ebp - 0x218]
push eax
call fcn.0042c48c
pop ecx
push eax
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x224]
call fcn.00401822
push str.kernel32.dll
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x230]
push eax
call fcn.0040190b
add esp, 0xc
push eax
lea ecx, [ebp - 0x234]
mov byte [ebp - 4], 4
call fcn.0040138a
mov ecx, dword [ebp - 0x230]
add ecx, 0xfffffff0
mov byte [ebp - 4], 3
call fcn.004017a5
mov esi, dword [ebp - 0x234]
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
mov dword [ebp - 0x238], edi
test edi, edi
je 0x402f7d
push str.Wow64DisableWow64FsRedirection
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.Wow64RevertWow64FsRedirection
push edi
mov dword [ebp - 0x21c], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp dword [ebp - 0x21c], 0
mov dword [ebp - 0x230], eax
je 0x402f76
test eax, eax
je 0x402f76
push ecx
mov ecx, esp
push 0x44a868
call fcn.004018b9
mov ecx, dword [ebp - 0x22c]
lea eax, [ebp - 0x220]
push eax
call fcn.004025dd
push eax
lea ecx, [ebp - 0x240]
mov byte [ebp - 4], 5
call fcn.0040138a
mov ecx, dword [ebp - 0x220]
add ecx, 0xfffffff0
mov byte [ebp - 4], 3
call fcn.004017a5
push ecx
mov ecx, esp
push str.msvcp120.dll
call fcn.004018b9
mov ecx, dword [ebp - 0x22c]
lea eax, [ebp - 0x220]
push eax
call fcn.004025dd
push eax
lea ecx, [ebp - 0x23c]
mov byte [ebp - 4], 6
call fcn.0040138a
mov ecx, dword [ebp - 0x220]
mov byte [ebp - 4], 3
lea ecx, [ecx - 0x10]
call fcn.004017a5
mov ecx, dword [ebp - 0x21c]
lea eax, [ebp - 0x24c]
push eax
call dword [0x44955c]
call dword [ebp - 0x21c]
test eax, eax
je 0x402f76
push 0x44a904
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x228]
push eax
call fcn.0040190b
push 0x44a868
push eax
lea eax, [ebp - 0x220]
mov byte [ebp - 4], 7
push eax
call fcn.0040190b
add esp, 0x18
mov ecx, dword [ebp - 0x228]
mov byte [ebp - 4], 9
lea ecx, [ecx - 0x10]
call fcn.004017a5
push 0x44a904
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x244]
push eax
call fcn.0040190b
push str.msvcp120.dll
push eax
lea eax, [ebp - 0x21c]
mov byte [ebp - 4], 0xa
push eax
call fcn.0040190b
add esp, 0x18
mov ecx, dword [ebp - 0x244]
add ecx, 0xfffffff0
mov byte [ebp - 4], 0xc
call fcn.004017a5
push dword [ebp - 0x220]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x402f42
push ecx
mov edi, esp
mov dword [ebp - 0x228], esp
mov dword [ebp - 0x248], edi
mov eax, dword [ebp - 0x220]
add eax, 0xfffffff0
push eax
call fcn.004013f4
add eax, 0x10
mov dword [edi], eax
mov edi, esp
mov byte [ebp - 4], 0xd
mov dword [ebp - 0x248], edi
mov eax, dword [ebp - 0x240]
add eax, 0xfffffff0
push eax
call fcn.004013f4
pop ecx
mov ecx, dword [ebp - 0x22c]
add eax, 0x10
mov dword [edi], eax
mov byte [ebp - 4], 0xc
call fcn.00402a63
test eax, eax
je 0x402f3c
push dword [ebp - 0x21c]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x402f3c
push ecx
mov edi, esp
mov dword [ebp - 0x248], esp
mov dword [ebp - 0x228], edi
mov eax, dword [ebp - 0x21c]
add eax, 0xfffffff0
push eax
call fcn.004013f4
add eax, 0x10
mov dword [edi], eax
mov edi, esp
mov byte [ebp - 4], 0xe
mov dword [ebp - 0x228], edi
mov eax, dword [ebp - 0x23c]
add eax, 0xfffffff0
push eax
call fcn.004013f4
pop ecx
mov ecx, dword [ebp - 0x22c]
add eax, 0x10
mov dword [edi], eax
mov byte [ebp - 4], 0xc
call fcn.00402a63
test eax, eax
push 1
pop eax
cmovne ebx, eax
mov edi, dword [ebp - 0x238]
push dword [ebp - 0x24c]
mov ecx, dword [ebp - 0x230]
call dword [0x44955c]
call dword [ebp - 0x230]
mov ecx, dword [ebp - 0x21c]
lea ecx, [ecx - 0x10]
call fcn.004017a5
mov ecx, dword [ebp - 0x220]
lea ecx, [ecx - 0x10]
call fcn.004017a5
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ecx, dword [ebp - 0x23c]
lea ecx, [ecx - 0x10]
call fcn.004017a5
mov ecx, dword [ebp - 0x240]
lea ecx, [ecx - 0x10]
call fcn.004017a5
lea ecx, [esi - 0x10]
call fcn.004017a5
mov ecx, dword [ebp - 0x224]
add ecx, 0xfffffff0
call fcn.004017a5
mov eax, ebx
call fcn.00427f48
ret