Function at 0x4570a0
Capabilities:
Check if file exists
Get common file path
Get program files directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50f238
mov eax, dword fs:[0]
push eax
sub esp, 0x284
mov eax, dword [0x568cb8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x280], ecx
mov eax, dword [ebp - 0x280]
xor ecx, ecx
cmp dword [eax + 0x58], 1
sete cl
mov byte [0x56d1ce], cl
mov edx, dword [ebp + 0xc]
push edx
mov ecx, dword [ebp - 0x280]
call fcn.00454ce0
test eax, eax
jne 0x457100
mov dword [ebp + 0xc], 0
cmp dword [ebp + 0xc], 0
je 0x457120
mov eax, dword [ebp + 0xc]
push eax
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
call fcn.004be924
add esp, 0xc
jmp 0x457199
mov edx, dword [ebp - 0x280]
cmp dword [edx + 0x58], 0
je 0x45715f
push 0x104
lea eax, [ebp - 0x21c]
push eax
mov ecx, dword [ebp - 0x280]
call fcn.00456f70
mov dword [ebp - 0x23c], eax
cmp dword [ebp - 0x23c], 0
je 0x45715d
mov eax, dword [ebp - 0x23c]
jmp 0x4573e6
jmp 0x457172
push 0
push 0x26
lea ecx, [ebp - 0x21c]
push ecx
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0x15
mov ecx, 0x56d2e8
call fcn.00474010
push eax
lea edx, [ebp - 0x21c]
push edx
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
lea ecx, [ebp - 0x21c]
push ecx
lea edx, [ebp - 0x260]
push edx
call fcn.0050d240
add esp, 8
mov dword [ebp - 0x284], eax
mov eax, dword [ebp - 0x284]
mov dword [ebp - 0x288], eax
mov dword [ebp - 4], 0
mov ecx, dword [ebp - 0x288]
push ecx
mov ecx, 0x56d2ac
call fcn.00401000
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x260]
call fcn.00402b40
lea edx, [ebp - 0x21c]
push edx
mov ecx, 0x56d218
call fcn.0040b030
call fcn.004796c0
call fcn.00479340
call fcn.00479bb0
movzx eax, byte [0x56d2c8]
test eax, eax
je 0x45721b
call fcn.00479c90
lea ecx, [ebp - 0x21c]
push ecx
mov ecx, dword [ebp - 0x280]
call fcn.00454ce0
test eax, eax
jne 0x45723b
mov eax, 1
jmp 0x4573e6
mov ecx, dword [ebp - 0x280]
add ecx, 0x6c
call fcn.004578b0
lea edx, [ebp - 0x21c]
push edx
mov ecx, dword [ebp - 0x280]
call fcn.00454df0
lea eax, [ebp - 0x244]
push eax
mov ecx, dword [ebp - 0x280]
add ecx, 0x6c
call fcn.00457840
jmp 0x457286
push 0
lea ecx, [ebp - 0x268]
push ecx
lea ecx, [ebp - 0x244]
call fcn.00451db0
lea edx, [ebp - 0x270]
push edx
mov ecx, dword [ebp - 0x280]
add ecx, 0x6c
call fcn.0045ca00
push eax
lea ecx, [ebp - 0x244]
call fcn.00451df0
movzx eax, al
test eax, eax
je 0x4572e8
lea ecx, [ebp - 0x244]
call fcn.00451d90
mov ecx, eax
call fcn.0040a1c0
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4572e6
lea ecx, [ebp - 0x244]
call fcn.00451d90
mov ecx, eax
call fcn.0040a1c0
push eax
call fcn.00438960
add esp, 4
jmp 0x457272
lea ecx, [ebp - 0x21c]
push ecx
mov ecx, dword [ebp - 0x280]
call fcn.00454df0
mov ecx, dword [ebp - 0x280]
add ecx, 0x6c
call fcn.004578b0
lea edx, [ebp - 0x21c]
push edx
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
push 0x51a27c
push 0x56d218
lea eax, [ebp - 0x238]
push eax
call fcn.0043ae80
add esp, 0xc
mov dword [ebp - 4], 1
push 0
sub esp, 0x1c
mov ecx, esp
mov dword [ebp - 0x274], esp
lea edx, [ebp - 0x238]
push edx
call fcn.0040de90
mov dword [ebp - 0x28c], eax
call fcn.00459370
add esp, 0x20
mov eax, dword [ebp - 0x280]
mov dword [eax + 0x54], 1
mov ecx, dword [ebp - 0x280]
push ecx
call fcn.004552d0
push 1
sub esp, 0x1c
mov ecx, esp
mov dword [ebp - 0x278], esp
lea edx, [ebp - 0x238]
push edx
call fcn.0040de90
mov dword [ebp - 0x290], eax
call fcn.00459370
add esp, 0x20
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
movzx eax, byte [ebp + 8]
test eax, eax
sete cl
movzx edx, cl
push edx
mov ecx, dword [ebp - 0x280]
call fcn.00456b50
call dword [sym.imp.ole32.dll_CoUninitialize]
mov dword [ebp - 0x27c], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x238]
call fcn.00401320
mov eax, dword [ebp - 0x27c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004b8307
mov esp, ebp
pop ebp
ret 8