Function at 0x140013c50
Capabilities:
Get common file path
Get startup folder

Disassembly:
mov rax, rsp
push rsi
push rdi
push r14
sub rsp, 0x2a0
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov rax, qword [0x1402da8d8]
xor rax, rsp
mov qword [rsp + 0x290], rax
mov r14, rcx
mov qword [rsp + 0x50], rcx
lea rcx, [rsp + 0x58]
call fcn.1400594c0
nop
call fcn.14004aa80
mov rcx, rax
test rax, rax
je 0x140013ee0
mov rax, qword [rax]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x38], rax
xor edx, edx
mov r8d, 0x208
lea rcx, [rsp + 0x80]
call fcn.1401e67e0
lea rax, [rsp + 0x80]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 0x23]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea rcx, [rsp + 0x80]
mov rbp, 0xffffffffffffffff
mov rax, rbp
nop word [rax + rax]
inc rax
cmp word [rcx + rax*2], 0
jne 0x140013d00
mov r8d, eax
lea rdx, [rsp + 0x80]
lea rcx, [rsp + 0x38]
call fcn.1400054e0
lea rdx, str._rtkhdaud.dat
mov rax, rbp
nop dword [rax]
inc rax
cmp word [rdx + rax*2], 0
jne 0x140013d30
mov r8d, eax
lea rcx, [rsp + 0x38]
call fcn.140004b30
xor r9d, r9d
mov r8d, 0x9001
mov rbx, qword [rsp + 0x38]
mov rdx, rbx
lea rcx, [rsp + 0x58]
call fcn.140059c90
test eax, eax
je 0x140013e73
xor edi, edi
mov rcx, qword [r14]
cmp dword [rcx - 0x10], edi
jle 0x140013e68
nop dword [rax + rax]
xor ebx, ebx
test edi, edi
cmovns ebx, edi
mov eax, 0x7fffffff
sub eax, ebx
cmp eax, 2
jl 0x140013eeb
lea eax, [rbx + 2]
mov r8d, dword [rcx - 0x10]
mov edx, 2
cmp eax, r8d
jle 0x140013dad
mov edx, r8d
sub edx, ebx
xor esi, esi
cmp ebx, r8d
cmovle esi, edx
test ebx, ebx
jne 0x140013dd2
cmp esi, r8d
jne 0x140013dd2
add rcx, 0xffffffffffffffe8
call fcn.140004c20
lea rbx, [rax + 0x18]
mov qword [rsp + 0x40], rbx
jmp 0x140013e13
mov rcx, qword [rcx - 0x18]
test rcx, rcx
je 0x140013de6
mov rax, qword [rcx]
call qword [rax + 0x20]
test rax, rax
jne 0x140013df4
call fcn.14004aa80
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x20]
mov rdx, qword [r14]
movsxd rcx, ebx
lea rdx, [rdx + rcx*2]
mov r9, rax
mov r8d, esi
lea rcx, [rsp + 0x40]
call fcn.14000db20
mov rbx, qword [rsp + 0x40]
xor edx, edx
lea r8d, [rdx + 0x10]
mov rcx, rbx
call fcn.1401ef880
mov byte [rsp + 0x30], al
mov r8d, 1
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x58]
call fcn.14005a03c
nop
lea rdx, [rbx - 0x18]
mov eax, ebp
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140013e54
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
add edi, 2
mov rcx, qword [r14]
cmp edi, dword [rcx - 0x10]
jl 0x140013d80
mov rbx, qword [rsp + 0x38]
lea rcx, [rsp + 0x58]
call fcn.14005991c
nop
lea rdx, [rbx - 0x18]
mov eax, ebp
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140013e8d
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
lea rcx, [rsp + 0x58]
call fcn.1400595c8
nop
mov rdx, qword [r14]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], ebp
sub ebp, 1
jg 0x140013eb3
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rreloc.OLEAUT32.dll_VariantClear + 8]
mov eax, 1
mov rcx, qword [rsp + 0x290]
xor rcx, rsp
call fcn.1401e35b0
lea r11, [rsp + 0x2a0]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
mov ecx, 0x80004005
call fcn.140005680
nop
mov ecx, 0x80070216
call fcn.140005680
int3