Function at 0x43be10
Capabilities:
Check if file exists
Create directory
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xec
mov eax, dword [0x524a60]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push edi
mov edi, ecx
mov dword [ebp - 0xec], 0
push dword [edi + 0x38]
call esi
test eax, eax
jne 0x43be4b
push eax
push dword [edi + 0x38]
push eax
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
push dword [edi + 0x38]
call esi
test eax, eax
je 0x43c198
push ebx
push 0x4f1844
push dword [edi + 0x2c]
call fcn.004ba61f
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x43c197
push ebx
mov dword [ebp - 0xec], 1
call fcn.004bbb62
add esp, 4
test eax, eax
jne 0x43be9c
push ebx
push 1
push 2
push 0x4f184c
call fcn.004bbda5
add esp, 0x10
cmp dword [edi + 0x30], 0
je 0x43bf65
lea eax, [ebp - 0xdc]
mov dword [edi + 0x30], 0
xorps xmm0, xmm0
push eax
movups xmmword [ebp - 0xdc], xmm0
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
push 0xc8
lea eax, [ebp - 0xcc]
push 0
push eax
call fcn.004b1030
movzx eax, word [ebp - 0xd0]
add esp, 0xc
push eax
movzx eax, word [ebp - 0xd2]
push eax
movzx eax, word [ebp - 0xd4]
push eax
movzx eax, word [ebp - 0xd6]
push eax
movzx eax, word [ebp - 0xda]
push eax
movzx eax, word [ebp - 0xdc]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push str._r_n_Start_Log___06x:_06x_:__04d__02d__02d__02d:_02d:_02d__n
lea eax, [ebp - 0xcc]
push 0x400
push eax
call fcn.0043c2f0
lea ecx, [ebp - 0xcc]
add esp, 0x2c
lea edx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x43bf40
sub ecx, edx
sar ecx, 1
push ebx
push 1
lea eax, [ecx + ecx]
push eax
lea eax, [ebp - 0xcc]
push eax
call fcn.004bbda5
add esp, 0x10
mov eax, dword [edi + 0x24]
xor esi, esi
sub eax, dword [edi + 0x20]
sar eax, 2
mov dword [ebp - 0xe4], eax
test eax, eax
jle 0x43bfa1
nop word [eax + eax]
mov eax, dword [edi + 0x20]
push ebx
push 1
mov ecx, dword [eax + esi*4]
mov eax, dword [ecx - 0xc]
add eax, eax
push eax
push ecx
call fcn.004bbda5
inc esi
add esp, 0x10
cmp esi, dword [ebp - 0xe4]
jl 0x43bf80
push ebx
call fcn.004bac32
push ebx
call fcn.004bbb62
push ebx
mov dword [ebp - 0xe4], eax
call fcn.004ba6ed
mov eax, dword [edi + 0x34]
add esp, 0xc
test eax, eax
jle 0x43c197
mov ebx, dword [ebp - 0xe4]
cmp ebx, eax
jl 0x43c197
cmp ebx, 0x32000
jge 0x43bfe8
mov eax, ebx
cdq
sub eax, edx
mov esi, eax
sar esi, 1
jmp 0x43bfed
mov esi, 0x19000
shr esi, 1
xor ecx, ecx
mov edx, 2
lea eax, [esi + 1]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004a1b70
mov ecx, eax
add esp, 4
mov dword [ebp - 0xe4], ecx
test ecx, ecx
je 0x43c197
lea eax, [esi + esi]
mov dword [ebp - 0xe8], eax
add eax, 2
push eax
push 0
push ecx
call fcn.004b1030
push 0x4f1910
push dword [edi + 0x2c]
mov byte [ebp - 0xdd], 0
call fcn.004ba61f
mov esi, eax
add esp, 0x14
test esi, esi
je 0x43c086
sub ebx, dword [ebp - 0xe8]
push 0
push ebx
push esi
call fcn.004bb569
mov ebx, dword [ebp - 0xe4]
push esi
push 1
push dword [ebp - 0xe8]
push ebx
call fcn.004bb128
cmp eax, 1
push esi
sete byte [ebp - 0xdd]
call fcn.004ba6ed
add esp, 0x20
jmp 0x43c08c
mov ebx, dword [ebp - 0xe4]
push 0x4f1918
push dword [edi + 0x2c]
call fcn.004ba61f
mov esi, eax
add esp, 8
test esi, esi
je 0x43c18e
push esi
push 1
push 2
push 0x4f184c
call fcn.004bbda5
add esp, 0x10
lea eax, [ebp - 0xdc]
xorps xmm0, xmm0
movups xmmword [ebp - 0xdc], xmm0
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
push 0xc8
lea eax, [ebp - 0xcc]
push 0
push eax
call fcn.004b1030
movzx eax, word [ebp - 0xd0]
add esp, 0xc
push eax
movzx eax, word [ebp - 0xd2]
push eax
movzx eax, word [ebp - 0xd4]
push eax
movzx eax, word [ebp - 0xd6]
push eax
movzx eax, word [ebp - 0xda]
push eax
movzx eax, word [ebp - 0xdc]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push str._r_n_Truncate_Log___06x:_06x_:__04d__02d__02d__02d:_02d:_02d__n
lea eax, [ebp - 0xcc]
push 0x400
push eax
call fcn.0043c2f0
lea ecx, [ebp - 0xcc]
add esp, 0x2c
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x43c145
sub ecx, edx
sar ecx, 1
push esi
push 1
lea eax, [ecx + ecx]
push eax
lea eax, [ebp - 0xcc]
push eax
call fcn.004bbda5
add esp, 0x10
cmp byte [ebp - 0xdd], 0
je 0x43c185
push esi
push 1
push dword [ebp - 0xe8]
push ebx
call fcn.004bbda5
add esp, 0x10
push esi
call fcn.004ba6ed
add esp, 4
push ebx
call fcn.004a1967
add esp, 4
pop ebx
lea ecx, [edi + 0x20]
call fcn.0043c370
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0xec]
xor ecx, ebp
pop edi
pop esi
call fcn.004a1588
mov esp, ebp
pop ebp
ret