Function at 0x140002ba8
Capabilities:
Get graphical window text

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 8], rcx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1b0]
sub rsp, 0x2b0
mov r13, rdx
call qword [sym.imp.USER32.dll_GetForegroundWindow]
xor r15d, r15d
mov r14, rax
test rax, rax
jne 0x140002be9
lea eax, [r14 + 1]
jmp 0x140002f4f
xor edx, edx
lea rcx, [rbp - 0x20]
mov r8d, 0x80
call fcn.14003a5c0
mov r8d, 0x7f
lea rdx, [rbp - 0x20]
mov rcx, r14
call qword [sym.imp.USER32.dll_GetWindowTextA]
mov r8, qword [0x1400c50b0]
movabs rax, 0x2aaaaaaaaaaaaaab
mov r12d, r15d
mov ebx, 1
mov rcx, qword [r8 + 8]
sub rcx, qword [r8]
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
je 0x140002f4d
mov r9, r15
mov rsi, r15
lea rcx, [r9 + r9*2]
shl rcx, 5
lea rdx, [0x14009d380]
add rcx, qword [r8]
call fcn.140004f04
test eax, eax
jne 0x140002f11
mov rax, qword [0x1400c50b0]
mov rcx, qword [rax]
mov r15, qword [rsi + rcx + 0x30]
lea rdi, [rcx + 0x20]
add rdi, rsi
cmp qword [rdi + 0x18], 0x10
jb 0x140002c89
mov rdi, qword [rdi]
lea rcx, [rbp - 0x20]
call fcn.140045e50
mov rdx, rax
lea rcx, [rbp - 0x20]
mov r9d, r15d
mov r8, rdi
call fcn.140014768
xor r15d, r15d
test eax, eax
je 0x140002f11
lea rdx, [rbp + 0x200]
mov dword [rbp + 0x200], r15d
mov rcx, r14
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov edi, dword [rbp + 0x200]
test edi, edi
je 0x140002f11
xor edx, edx
lea rcx, [rbp + 0x60]
mov r8d, 0x144
call fcn.14003a5c0
mov r8d, 0x143
lea rdx, [rbp + 0x60]
mov ecx, edi
call fcn.140016400
mov rax, qword [0x1400c50b0]
mov rcx, qword [rax]
mov r15, qword [rsi + rcx + 0x50]
lea rdi, [rcx + 0x40]
add rdi, rsi
cmp qword [rdi + 0x18], 0x10
jb 0x140002d16
mov rdi, qword [rdi]
lea rcx, [rbp + 0x60]
call fcn.140045e50
mov r9, rax
lea r8, [rbp + 0x60]
xor eax, eax
mov edx, r15d
mov dword [rsp + 0x30], eax
mov rcx, rdi
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rax
call fcn.140013814
xor r15d, r15d
test eax, eax
jne 0x140002f11
lea edi, [rax + 0xf]
mov qword [rbp - 0x50], r15
mov qword [rbp - 0x48], rdi
mov byte [rbp - 0x60], r15b
cmp byte [rbp + 0x60], r15b
jne 0x140002d66
mov eax, r15d
jmp 0x140002d6f
lea rcx, [rbp + 0x60]
call fcn.140045e50
mov r8, rax
lea rdx, [rbp + 0x60]
lea rcx, [rbp - 0x60]
call fcn.140004d8c
mov qword [rbp - 0x68], rdi
mov qword [rbp - 0x70], r15
mov byte [rbp - 0x80], r15b
cmp byte [rbp - 0x20], r15b
jne 0x140002d96
mov rax, r15
jmp 0x140002d9f
lea rcx, [rbp - 0x20]
call fcn.140045e50
mov r8, rax
lea rdx, [rbp - 0x20]
lea rcx, [rbp - 0x80]
call fcn.140004d8c
lea rcx, [0x14009d388]
call fcn.140045e50
mov r9, rax
lea r8, [0x14009d388]
xor edx, edx
lea rcx, [rbp - 0x80]
call fcn.1400052f0
mov rdx, rax
mov qword [rsp + 0x78], rdi
lea rcx, [rsp + 0x60]
mov qword [rsp + 0x70], r15
mov byte [rsp + 0x60], r15b
call fcn.140004354
lea rcx, [0x14009d300]
call fcn.140045e50
mov r8, rax
lea rdx, [0x14009d300]
lea rcx, [rsp + 0x60]
call fcn.140004b2c
mov rdx, rax
mov qword [rsp + 0x58], rdi
lea rcx, [rsp + 0x40]
mov qword [rsp + 0x50], r15
mov byte [rsp + 0x40], r15b
call fcn.140004354
lea r8, [rbp - 0x60]
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x40]
call fcn.140001330
mov rdx, qword [rsp + 0x58]
cmp rdx, 0x10
jb 0x140002e55
mov rcx, qword [rsp + 0x40]
inc rdx
mov r8, rbx
call fcn.140004554
mov rdx, qword [rsp + 0x78]
mov qword [rsp + 0x58], rdi
mov qword [rsp + 0x50], r15
mov byte [rsp + 0x40], r15b
cmp rdx, 0x10
jb 0x140002e7f
mov rcx, qword [rsp + 0x60]
inc rdx
mov r8, rbx
call fcn.140004554
mov rdx, qword [rbp - 0x68]
mov qword [rsp + 0x78], rdi
mov qword [rsp + 0x70], r15
mov byte [rsp + 0x60], r15b
cmp rdx, 0x10
jb 0x140002ea7
mov rcx, qword [rbp - 0x80]
inc rdx
mov r8, rbx
call fcn.140004554
mov rdx, qword [rbp - 0x48]
mov qword [rbp - 0x68], rdi
mov qword [rbp - 0x70], r15
mov byte [rbp - 0x80], r15b
cmp rdx, 0x10
jb 0x140002ecc
mov rcx, qword [rbp - 0x60]
inc rdx
mov r8, rbx
call fcn.140004554
cmp qword [rbp - 0x28], 0x10
lea r8, [rbp - 0x40]
mov r9d, dword [rbp + 0x200]
mov rdx, r13
cmovae r8, qword [rbp - 0x40]
mov rcx, qword [rbp + 0x1f0]
mov dword [rsp + 0x20], 7
call fcn.140018c04
mov rdx, qword [rbp - 0x28]
cmp rdx, 0x10
jb 0x140002f11
mov rcx, qword [rbp - 0x40]
inc rdx
mov r8, rbx
call fcn.140004554
mov r8, qword [0x1400c50b0]
add r12d, ebx
movabs rax, 0x2aaaaaaaaaaaaaab
movsxd r9, r12d
add rsi, 0x60
mov rcx, qword [r8 + 8]
sub rcx, qword [r8]
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
cmp r9, rdx
jb 0x140002c4a
mov eax, ebx
mov rbx, qword [rsp + 0x2f8]
add rsp, 0x2b0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret