Function at 0x41783b
Capabilities:
Check if file exists
Create directory
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [0x676f80]
xor ecx, ecx
cmp eax, 2
je 0x41786a
mov edx, 0x676f80
cmp eax, dword [ebp + 8]
jne 0x41785e
mov eax, dword [ebp + 0xc]
cmp dword [edx + 4], eax
je 0x41786a
mov eax, dword [edx + 0x20]
add edx, 0x20
inc ecx
cmp eax, 2
jne 0x417851
shl ecx, 5
push ebx
mov ebx, ecx
push esi
push edi
cmp dword [ebx + 0x676f80], 2
mov dword [ebp - 8], ebx
jne 0x417885
push 1
jmp 0x417a56
mov edi, dword [ebx + 0x676f8c]
cmp edi, 0xfffe
jne 0x4178a7
mov esi, dword [ebp + 0x14]
push esi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
jmp 0x417938
cmp edi, 0xffff
jne 0x4178db
call fcn.006092e4
mov esi, dword [ebp + 0x14]
mov eax, dword [eax + 8]
push 0x104
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0x5c
push esi
call fcn.00598696
pop ecx
test eax, eax
pop ecx
je 0x417938
and byte [eax + 1], 0
jmp 0x417938
cmp dword [0x6b5604], 0
mov esi, dword [ebp + 0x14]
jne 0x41791e
mov eax, dword [0x6b5608]
test eax, eax
jne 0x417904
push str.shfolder.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
mov dword [0x6b5608], eax
je 0x417915
push str.SHGetFolderPathA
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x6b5604], eax
cmp dword [0x6b5604], 0
je 0x41792d
xor eax, eax
push esi
push eax
push eax
push edi
push eax
call dword [0x6b5604]
jmp 0x417930
push 1
pop eax
test eax, eax
jne 0x417a54
cmp dword [ebp + 8], 1
jne 0x41797c
cmp dword [ebp + 0xc], 0xd
je 0x417950
cmp dword [ebp + 0xc], 0xa
je 0x417950
cmp dword [ebp + 0xc], 0xf
jne 0x41797c
push esi
call fcn.00598476
cmp byte [eax + esi - 1], 0x5c
pop ecx
jne 0x41796a
push esi
call fcn.00598476
and byte [eax + esi - 1], 0
pop ecx
push 0x5c
push esi
call fcn.00598696
pop ecx
test eax, eax
pop ecx
je 0x41797c
and byte [eax + 1], 0
lea edi, [ebx + 0x676f90]
test edi, edi
je 0x4179dc
mov ebx, edi
cmp dword [ebx], 0
je 0x4179d9
push esi
call fcn.00598476
cmp byte [eax + esi - 1], 0x5c
pop ecx
je 0x4179a8
push 0x67434c
push esi
call fcn.005986d3
pop ecx
pop ecx
push dword [ebx]
push esi
call fcn.005986d3
cmp word [ebp + 0x10], 0
pop ecx
pop ecx
je 0x4179d2
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4179d2
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x417a37
add ebx, 4
test edi, edi
jne 0x417988
mov ebx, dword [ebp - 8]
cmp word [ebx + 0x676f88], 0
je 0x417a3b
lea eax, [ebp - 8]
push eax
call fcn.0046974e
push esi
call fcn.00598476
cmp byte [eax + esi - 1], 0x5c
pop ecx
pop ecx
je 0x417a0b
push 0x67434c
push esi
call fcn.005986d3
pop ecx
pop ecx
lea eax, [ebp - 8]
push eax
push esi
call fcn.005986d3
cmp word [ebp + 0x10], 0
pop ecx
pop ecx
je 0x417a3b
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x417a3b
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x417a3b
push 3
jmp 0x417a56
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
push esi
call edi
cmp eax, 0xffffffff
je 0x417a54
push esi
call edi
test al, 0x10
je 0x417a54
xor eax, eax
jmp 0x417a57
push 4
pop eax
pop edi
pop esi
pop ebx
leave
ret