Function at 0x407800
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x32c
mov eax, dword [0x4f62a0]
xor eax, ebp
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x31c], ecx
mov eax, dword [ebp - 0x31c]
add eax, 4
push eax
lea ecx, [ebp - 0xc]
call fcn.00407080
mov dword [ebp - 0x14], 0
mov ecx, dword [ebp - 0x31c]
add ecx, 0x30
call sym.Setup.exe_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const
mov dword [ebp - 0x320], eax
mov ecx, dword [ebp - 0x320]
add ecx, 2
mov dword [ebp - 0x324], ecx
mov edx, dword [ebp - 0x320]
mov ax, word [edx]
mov word [ebp - 0x326], ax
add dword [ebp - 0x320], 2
cmp word [ebp - 0x326], 0
jne 0x407855
mov ecx, dword [ebp - 0x320]
sub ecx, dword [ebp - 0x324]
sar ecx, 1
mov dword [ebp - 0x32c], ecx
mov edx, dword [ebp - 0x32c]
add edx, 1
mov dword [ebp - 0x10], edx
xor ecx, ecx
mov eax, dword [ebp - 0x10]
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00424d7a
add esp, 4
mov dword [ebp - 0x310], eax
mov eax, dword [ebp - 0x310]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0x10]
shl ecx, 1
push ecx
push 0
mov edx, dword [ebp - 4]
push edx
call fcn.0042efe0
add esp, 0xc
mov ecx, dword [ebp - 0x31c]
add ecx, 0x30
call sym.Setup.exe_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const
push eax
mov eax, dword [ebp - 0x10]
shl eax, 1
push eax
mov ecx, dword [ebp - 4]
push ecx
call fcn.00407160
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x407917
push 0
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x407b22
xor eax, eax
mov word [ebp - 0xf8], ax
xor ecx, ecx
mov dword [ebp - 0xf6], ecx
mov dword [ebp - 0xf2], ecx
mov dword [ebp - 0xee], ecx
mov word [ebp - 0xea], cx
lea edx, [ebp - 0xf8]
push edx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
xor eax, eax
mov word [ebp - 0xe8], ax
push 0xc6
push 0
lea ecx, [ebp - 0xe6]
push ecx
call fcn.0042efe0
add esp, 0xc
movzx edx, word [ebp - 0xec]
push edx
movzx eax, word [ebp - 0xee]
push eax
movzx ecx, word [ebp - 0xf0]
push ecx
movzx edx, word [ebp - 0xf2]
push edx
movzx eax, word [ebp - 0xf6]
push eax
movzx ecx, word [ebp - 0xf8]
push ecx
push str._04d__02d__02d__02d:_02d:_02d
push 0x400
lea edx, [ebp - 0xe8]
push edx
call fcn.00406a30
add esp, 0x24
mov dword [ebp - 0x1c], 0
mov ecx, dword [ebp - 0x31c]
add ecx, 0x30
call sym.Setup.exe_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], 0
push 0x4d2098
mov ecx, dword [ebp - 0x31c]
add ecx, 0x30
call sym.Setup.exe_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.00426c5e
add esp, 0xc
cmp dword [ebp - 0x18], 0
je 0x407b22
mov dword [ebp - 0x14], 1
mov ecx, dword [ebp - 0x31c]
cmp dword [ecx + 0x34], 0
je 0x407aa2
cmp dword [ebp - 0x1c], 0xffffffff
jne 0x407a84
push 0x208
push 0
lea edx, [ebp - 0x308]
push edx
call fcn.0042efe0
add esp, 0xc
push 0x208
lea eax, [ebp - 0x308]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [ebp - 0x308]
push ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
lea edx, [ebp - 0xe8]
push edx
push 0x4d20a0
mov eax, dword [ebp - 0x18]
push eax
call fcn.00426ca5
add esp, 0x14
jmp 0x407a95
push 0x4d209c
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00426ca5
add esp, 8
mov edx, dword [ebp - 0x31c]
mov dword [edx + 0x34], 0
mov ecx, dword [ebp - 0x31c]
add ecx, 0x20
call fcn.00407da0
mov dword [ebp - 0xfc], eax
mov dword [ebp - 0x30c], 0
jmp 0x407ad1
mov eax, dword [ebp - 0x30c]
add eax, 1
mov dword [ebp - 0x30c], eax
mov ecx, dword [ebp - 0x30c]
cmp ecx, dword [ebp - 0xfc]
jge 0x407b0a
mov edx, dword [ebp - 0x30c]
push edx
mov ecx, dword [ebp - 0x31c]
add ecx, 0x20
call fcn.00407dc0
mov ecx, eax
call sym.Setup.exe_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const
push eax
mov eax, dword [ebp - 0x18]
push eax
call fcn.00426ca5
add esp, 8
jmp 0x407ac2
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00426ebb
add esp, 4
mov edx, dword [ebp - 0x18]
push edx
call fcn.00427da6
add esp, 4
cmp dword [ebp - 4], 0
je 0x407b40
mov eax, dword [ebp - 4]
mov dword [ebp - 0x314], eax
mov ecx, dword [ebp - 0x314]
push ecx
call fcn.004262e5
add esp, 4
mov ecx, dword [ebp - 0x31c]
call fcn.004077d0
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x318], edx
lea ecx, [ebp - 0xc]
call fcn.004070c0
mov eax, dword [ebp - 0x318]
mov ecx, dword [ebp - 0x20]
xor ecx, ebp
call fcn.00425912
mov esp, ebp
pop ebp
ret