Function at 0x40f380
Capabilities:
Check if file exists
Create directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x520107
mov eax, dword fs:[0]
push eax
sub esp, 0xc8
mov eax, dword [0x5640a8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov edx, dword [0x56e850]
lea ecx, [ebp - 0xb8]
lea edx, [edx + 0x6c]
call fcn.004310a0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x70]
mov edx, dword [esi]
add edx, 0xaa0
call fcn.004310a0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x58]
push 6
xor eax, eax
mov dword [ebp - 0xd4], 0
push 0x53cb9c
mov dword [ebp - 0x44], 7
mov dword [ebp - 0x48], 0
mov word [ebp - 0x58], ax
call fcn.00402570
lea eax, [ebp - 0xd4]
mov byte [ebp - 4], 2
push eax
mov eax, dword [esi]
lea edx, [ebp - 0x58]
add eax, 0xc60
lea ecx, [ebp - 0x28]
push eax
call fcn.0041dfa0
add esp, 8
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x44]
cmp eax, 8
jb 0x40f445
inc eax
lea ecx, [ebp - 0x58]
push eax
push dword [ebp - 0x58]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x44], 7
mov dword [ebp - 0x48], 0
mov word [ebp - 0x58], ax
cmp dword [ebp - 0x18], eax
je 0x40f6a2
push 0x53ca00
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0xd0]
push eax
call fcn.0040ccf0
lea ecx, [ebp - 0xb8]
mov byte [ebp - 4], 5
push ecx
mov edx, eax
lea ecx, [ebp - 0x40]
call fcn.0040ce70
push 0x53ca00
push eax
lea eax, [ebp - 0xa0]
mov byte [ebp - 4], 6
push eax
call fcn.004151f0
lea ecx, [ebp - 0x70]
mov byte [ebp - 4], 7
push ecx
mov edx, eax
lea ecx, [ebp - 0x88]
call fcn.0040ce70
add esp, 0x20
mov edi, eax
lea eax, [ebp - 0x28]
cmp eax, edi
je 0x40f4f5
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x40f4d8
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x14], 7
push edi
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
call fcn.004032f0
mov eax, dword [ebp - 0x74]
cmp eax, 8
jb 0x40f510
inc eax
lea ecx, [ebp - 0x88]
push eax
push dword [ebp - 0x88]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x74], 7
mov word [ebp - 0x88], ax
mov eax, dword [ebp - 0x8c]
mov dword [ebp - 0x78], 0
cmp eax, 8
jb 0x40f545
inc eax
lea ecx, [ebp - 0xa0]
push eax
push dword [ebp - 0xa0]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x8c], 7
mov word [ebp - 0xa0], ax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x90], 0
cmp eax, 8
jb 0x40f577
inc eax
lea ecx, [ebp - 0x40]
push eax
push dword [ebp - 0x40]
call fcn.00402f10
xor eax, eax
mov byte [ebp - 4], 4
mov word [ebp - 0x40], ax
mov eax, dword [ebp - 0xbc]
mov dword [ebp - 0x2c], 7
mov dword [ebp - 0x30], 0
cmp eax, 8
jb 0x40f5ad
inc eax
lea ecx, [ebp - 0xd0]
push eax
push dword [ebp - 0xd0]
call fcn.00402f10
mov ecx, dword [esi]
lea eax, [ebp - 0x28]
add ecx, 0xc60
cmp ecx, eax
je 0x40f5c6
push 0xffffffffffffffff
push 0
push eax
call fcn.00402670
mov eax, dword [esi]
add eax, 0xc60
cmp dword [eax + 0x14], 8
jb 0x40f5d5
mov eax, dword [eax]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40f5fa
mov eax, dword [esi]
add eax, 0xc60
cmp dword [eax + 0x14], 8
jb 0x40f5ef
mov eax, dword [eax]
push 0
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
mov ecx, dword [esi]
mov edx, dword [ecx + 0xa40]
test edx, edx
je 0x40f642
add ecx, 0xc60
cmp dword [ecx + 0x14], 8
jb 0x40f614
mov ecx, dword [ecx]
mov eax, dword [edx]
push 0
push 0
push ecx
mov ecx, edx
call dword [eax + 0x34]
mov ecx, dword [esi]
cmp dword [ecx + 0xc74], 8
lea edx, [ecx + 0xc60]
jb 0x40f633
mov edx, dword [edx]
mov ecx, dword [ecx + 0xa40]
push edx
mov eax, dword [ecx]
call dword [eax + 0xb8]
push str.installPath
lea ecx, [ebp - 0x40]
call fcn.00403170
cmp dword [0x564a48], 8
lea edx, [ebp - 0x28]
mov esi, 0x564a34
lea ecx, [ebp - 0x40]
cmovae esi, dword [0x564a34]
lea eax, [ebp - 0x70]
cmp dword [ebp - 0x14], 8
push esi
cmovae edx, dword [ebp - 0x28]
cmp dword [ebp - 0x2c], 8
push edx
cmovae ecx, dword [ebp - 0x40]
cmp dword [ebp - 0x5c], 8
push ecx
cmovae eax, dword [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
mov eax, dword [ebp - 0x2c]
cmp eax, 8
jb 0x40f6a2
inc eax
lea ecx, [ebp - 0x40]
push eax
push dword [ebp - 0x40]
call fcn.00402f10
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x40f6b7
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x18], 0
cmp eax, 8
jb 0x40f6e0
inc eax
lea ecx, [ebp - 0x70]
push eax
push dword [ebp - 0x70]
call fcn.00402f10
xor eax, eax
mov dword [ebp - 0x5c], 7
mov word [ebp - 0x70], ax
mov eax, dword [ebp - 0xa4]
mov dword [ebp - 0x60], 0
cmp eax, 8
jb 0x40f712
inc eax
lea ecx, [ebp - 0xb8]
push eax
push dword [ebp - 0xb8]
call fcn.00402f10
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004e1de4
mov esp, ebp
pop ebp
ret