Function at 0x140008ae0
Capabilities:
Check for foreground window switch
Get graphical window text

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x2c0]
sub rsp, 0x3c0
mov rax, qword [0x14001b010]
xor rax, rsp
mov qword [rbp + 0x2b0], rax
xor r15d, r15d
mov ebx, r15d
mov dword [rsp + 0x40], ebx
call qword [sym.imp.MSVCP140.dll__Xtime_get_ticks]
mov rcx, rax
movabs r12, 0xd6bf94d5e57a42bd
mov rax, r12
imul rcx
lea rdi, [rcx + rdx]
sar rdi, 0x17
mov rax, rdi
shr rax, 0x3f
add rdi, rax
xorps xmm0, xmm0
movups xmmword [rbp + 0x48], xmm0
mov esi, r15d
mov qword [rbp + 0x58], r15
mov r14d, 7
mov qword [rbp + 0x60], r14
mov word [rbp + 0x48], r15w
nop word [rax + rax]
xor edx, edx
lea rcx, str.TFruityLoopsMainForm
call qword [sym.imp.USER32.dll_FindWindowW]
test rax, rax
je 0x140008fc1
mov r8d, 0x200
lea rdx, [rbp + 0xb0]
mov rcx, rax
call qword [sym.imp.USER32.dll_GetWindowTextW]
lea rdx, [rbp + 0xb0]
lea rcx, [rbp + 0x28]
call fcn.140009f60
nop
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbp + 0x68], xmm0
movups xmmword [rbp + 0x78], xmm0
mov qword [rbp + 0x88], rax
lea rcx, [rbp + 0x68]
call fcn.140009a00
nop
xorps xmm0, xmm0
movups xmmword [rsp + 0x48], xmm0
mov qword [rsp + 0x58], r15
mov qword [rsp + 0x60], 7
mov word [rsp + 0x48], r15w
or ebx, 1
mov dword [rsp + 0x40], ebx
lea rdx, [0x14001676c]
lea rcx, [rbp + 0x90]
call fcn.140009f60
nop
lea rcx, [rbp + 0x28]
mov rax, qword [rbp + 0x38]
cmp qword [rbp + 0x40], 8
jb 0x140008c1d
mov r8, qword [rbp + 0x28]
lea r9, [r8 + rax*2]
jmp 0x140008c25
lea r9, [rcx + rax*2]
lea r8, [rbp + 0x28]
lea rax, [rbp + 0x90]
mov qword [rsp + 0x28], rax
lea rax, [rbp + 0x68]
mov qword [rsp + 0x20], rax
lea rdx, [rsp + 0x48]
lea rcx, [rbp - 0x20]
call fcn.14000b240
nop
mov rdx, qword [rbp + 0xa8]
cmp rdx, 8
jb 0x140008c8f
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x90]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140008c8a
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400090c4
call fcn.140012cf0
mov rdx, qword [rbp + 0x40]
cmp rdx, 8
jb 0x140008ccf
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140008cca
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400090cb
call fcn.140012cf0
movups xmm0, xmmword [rsp + 0x48]
movups xmmword [rbp + 0x28], xmm0
movups xmm1, xmmword [rsp + 0x58]
movups xmmword [rbp + 0x38], xmm1
and ebx, 0xfffffffe
mov dword [rsp + 0x40], ebx
lea r8, [rbp + 0x28]
movq rcx, xmm0
psrldq xmm1, 8
movq rax, xmm1
cmp rax, 8
cmovae r8, rcx
mov qword [rsp + 0x38], r15
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], r15
xor edx, edx
mov ecx, 0xfde9
lea r9d, [rdx - 1]
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
movsxd rbx, eax
mov rcx, rbx
call fcn.140012df0
mov r13, rax
lea r8, [rbp + 0x28]
cmp qword [rbp + 0x40], 8
cmovae r8, qword [rbp + 0x28]
mov qword [rsp + 0x38], r15
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], ebx
mov qword [rsp + 0x20], rax
xor edx, edx
mov ecx, 0xfde9
lea r9d, [rdx - 1]
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea rdx, [rbp + 0x48]
cmp r14, 8
setae r12b
mov r15, qword [rbp + 0x48]
cmovae rdx, r15
lea rax, [rbp + 0x28]
cmp qword [rbp + 0x40], 8
cmovae rax, qword [rbp + 0x28]
mov r8, qword [rbp + 0x38]
cmp r8, rsi
jne 0x140008db8
test r8, r8
je 0x140008e2b
nop dword [rax]
movzx ecx, word [rdx]
cmp word [rax], cx
jne 0x140008db8
add rax, 2
add rdx, 2
sub r8, 1
jne 0x140008da0
jmp 0x140008e2b
call qword [sym.imp.MSVCP140.dll__Xtime_get_ticks]
mov rcx, rax
movabs rax, 0xd6bf94d5e57a42bd
imul rcx
lea rdi, [rcx + rdx]
sar rdi, 0x17
mov rax, rdi
shr rax, 0x3f
add rdi, rax
lea r9, [rbp + 0x28]
cmp qword [rbp + 0x40], 8
cmovae r9, qword [rbp + 0x28]
mov rsi, qword [rbp + 0x38]
cmp rsi, r14
ja 0x140008e1f
lea rbx, [rbp + 0x48]
test r12b, r12b
cmovne rbx, r15
mov qword [rbp + 0x58], rsi
lea r8, [rsi + rsi]
mov rdx, r9
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
xor r15d, r15d
mov word [rbx + rsi*2], r15w
jmp 0x140008e2e
mov rdx, rsi
lea rcx, [rbp + 0x48]
call fcn.14000a3c0
xor r15d, r15d
xorps xmm0, xmm0
movups xmmword [rsp + 0x70], xmm0
movaps xmmword [rbp - 0x80], xmm0
movups xmmword [rbp - 0x70], xmm0
movups xmmword [rbp - 0x60], xmm0
movups xmmword [rbp - 0x50], xmm0
movups xmmword [rbp - 0x40], xmm0
movups xmmword [rbp - 0x30], xmm0
mov qword [rsp + 0x78], r13
lea rax, str.fl_logo
mov qword [rbp - 0x70], rax
lea rax, str.FL_Studio
mov qword [rbp - 0x68], rax
xor edx, edx
lea rcx, str.TFruityLoopsMainForm
call qword [sym.imp.USER32.dll_FindWindowW]
mov rbx, rax
call qword [sym.imp.USER32.dll_GetForegroundWindow]
lea rcx, str.idle
cmp rax, rbx
cmove rcx, r15
mov qword [rbp - 0x60], rcx
lea rax, str.Idle
mov qword [rbp - 0x58], rax
mov byte [rbp - 0x28], 1
xor edx, edx
lea rcx, str.TFruityLoopsMainForm
call qword [sym.imp.USER32.dll_FindWindowW]
mov rbx, rax
call qword [sym.imp.USER32.dll_GetForegroundWindow]
xorps xmm0, xmm0
movq rcx, xmm0
cmp rax, rbx
cmove rcx, rdi
mov qword [rbp - 0x80], rcx
lea rcx, [0x14001de60]
call qword [sym.imp.MSVCP140.dll__Mtx_lock]
test eax, eax
jne 0x1400090d9
mov r8d, dword [0x14001c420]
lea eax, [r8 + 1]
mov dword [0x14001c420], eax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x20], rax
lea rcx, [0x14004e4e8]
call fcn.140005fe0
mov qword [0x14004e4e0], rax
mov eax, 1
xchg byte [0x14001ce03], al
lea rcx, [0x14001de60]
call qword [sym.imp.MSVCP140.dll__Mtx_unlock]
mov rcx, qword [0x14001deb8]
test rcx, rcx
je 0x140008f3f
add rcx, 0x58
call qword [sym.imp.MSVCP140.dll__Cnd_broadcast]
nop
lea rcx, [rbp + 0x68]
call fcn.14000a190
mov rcx, qword [rbp + 0x88]
test rcx, rcx
je 0x140008f6e
mov rax, qword [rcx]
call qword [rax + 0x10]
test rax, rax
je 0x140008f6e
mov r8, qword [rax]
mov edx, 1
mov rcx, rax
call qword [r8]
nop
mov rdx, qword [rbp + 0x40]
cmp rdx, 8
jb 0x140008fae
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140008fa9
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400090d2
call fcn.140012cf0
mov ebx, dword [rsp + 0x40]
movabs r12, 0xd6bf94d5e57a42bd
jmp 0x1400090ac
lea rdx, str.FL64.exe
lea rcx, [rbp - 0x18]
call fcn.140009f60
lea rcx, [rbp - 0x18]
call fcn.140008a00
mov rdx, qword [rbp]
cmp rdx, 8
jb 0x14000901a
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x18]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140009015
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400090e2
call fcn.140012cf0
lea rdx, str.FL32.exe
lea rcx, [rbp + 8]
call fcn.140009f60
lea rcx, [rbp + 8]
call fcn.140008a00
mov rdx, qword [rbp + 0x20]
cmp rdx, 8
jb 0x14000906f
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14000906a
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400090e2
call fcn.140012cf0
xor ecx, ecx
call fcn.1400029e0
call qword [sym.imp.MSVCP140.dll__Xtime_get_ticks]
mov rcx, rax
mov rax, r12
imul rcx
lea rdi, [rcx + rdx]
sar rdi, 0x17
mov rax, rdi
shr rax, 0x3f
add rdi, rax
mov qword [rbp + 0x58], r15
lea rax, [rbp + 0x48]
cmp r14, 8
cmovae rax, qword [rbp + 0x48]
mov word [rax], r15w
mov ecx, 0x1f4
call qword [sym.imp.KERNEL32.dll_Sleep]
mov r14, qword [rbp + 0x60]
mov rsi, qword [rbp + 0x58]
jmp 0x140008b70
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
mov ecx, eax
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_C_error_int_]
nop
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3