Function at 0x140020798
Capabilities:
Create thread
Log keystrokes via polling

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r14
push rbp
lea rbp, [rax - 0x18]
sub rsp, 0x110
movaps xmmword [rax - 0x18], xmm6
mov rax, qword [0x1400b4040]
xor rax, rsp
mov qword [rbp - 8], rax
xor r14d, r14d
mov sil, r14b
xor eax, eax
mov qword [rbp - 0x18], rax
mov dword [rbp - 0x10], eax
lea eax, [r14 + 1]
xchg byte [0x1400b40e0], al
lea rcx, [rsp + 0x40]
mov qword [rbp - 0x60], rcx
lea rax, [rbp - 0x18]
mov qword [rbp - 0x58], rax
lea ecx, [r14 + 0x10]
call fcn.14008a608
movups xmm0, xmmword [rbp - 0x60]
movdqu xmmword [rax], xmm0
mov qword [rsp + 0x50], rax
lea rcx, [rbp - 0x48]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], r14d
mov r9, rax
lea r8, [0x140020fdc]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp - 0x50], rax
test rax, rax
je 0x140020b82
mov al, byte [0x1401fdeb1]
test al, al
jne 0x140020b4a
movss xmm6, dword [0x1400a6ec0]
mov dil, byte [rsp + 0x38]
mov rbx, qword [rsp + 0x50]
jmp 0x140020b27
lea rcx, [0x1400b40f0]
call qword [sym.imp.MSVCP140.dll__Mtx_lock]
test eax, eax
jne 0x140020b76
cmp dword [0x1400b413c], 0x7fffffff
je 0x140020b60
lea rcx, [rbp - 0x30]
call fcn.140001e30
mov rcx, qword [rax]
mov qword [0x1401fdf30], rcx
lea rcx, [0x1400b40f0]
call qword [sym.imp.MSVCP140.dll__Mtx_unlock]
cmp byte [0x1401fdfd4], r14b
je 0x140020b27
cmp byte [0x1401fdfa3], r14b
je 0x140020b14
mov ecx, dword [0x1400b71ac]
test ecx, ecx
je 0x1400208f2
sub ecx, 1
je 0x1400208d8
cmp ecx, 1
jne 0x14002090e
mov byte [0x1400b71b8], cl
jmp 0x14002091c
mov ecx, dword [0x1400b71a8]
call qword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, ax
setne al
mov byte [0x1400b71b8], al
jmp 0x140020914
mov ecx, dword [0x1400b71a8]
call qword [sym.imp.USER32.dll_GetAsyncKeyState]
test al, 1
je 0x14002090e
cmp byte [0x1400b71b8], r14b
sete al
jmp 0x1400208ea
mov al, byte [0x1400b71b8]
test al, al
je 0x140020afd
test sil, sil
jne 0x140020966
test dil, dil
je 0x140020946
test rbx, rbx
je 0x140020946
mov rcx, qword [0x1401fdfa8]
test rcx, rcx
je 0x140020946
mov rax, rbx
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x40], rcx
jmp 0x14002096b
mov sil, 1
lea rcx, [rbp - 0x40]
call fcn.140026e5c
mov rax, qword [rbp - 0x40]
mov qword [rsp + 0x40], rax
mov rax, qword [rbp - 0x38]
mov qword [rsp + 0x30], rax
jmp 0x14002096b
mov rax, qword [rsp + 0x30]
test rax, rax
je 0x140020afd
lea rdx, [rbp - 0x60]
lea rcx, [rsp + 0x30]
call fcn.1400280a4
movss xmm0, dword [rax + 4]
comiss xmm0, dword [0x1400a640c]
jbe 0x140020afd
cmp byte [0x1401fdfa0], r14b
je 0x1400209e8
lea rdx, [rsp + 0x78]
lea rcx, [rsp + 0x30]
call fcn.1400281e0
movss xmm0, dword [rsp + 0x78]
andps xmm0, xmm6
movss xmm1, dword [0x1400b4280]
comiss xmm0, xmm1
ja 0x1400209e0
movss xmm0, dword [rsp + 0x7c]
andps xmm0, xmm6
comiss xmm0, xmm1
ja 0x1400209e0
movss xmm0, dword [rbp - 0x80]
andps xmm0, xmm6
comiss xmm0, xmm1
mov al, r14b
jbe 0x1400209e2
mov al, 1
mov byte [0x1401fdfe5], al
mov rax, qword [0x1401fdfa8]
test rax, rax
je 0x140020aa8
cmp byte [0x1401fdfd3], r14b
je 0x140020a4b
mov qword [rsp + 0x48], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
mov qword [rsp + 0x68], 8
mov qword [rsp + 0x70], 0xf
mov rax, qword [str.Humanoid]
mov qword [rsp + 0x58], rax
mov byte [rsp + 0x60], r14b
lea r8, [rsp + 0x58]
lea rdx, [rbp - 0x28]
lea rcx, [rsp + 0x48]
call fcn.140027d90
mov rax, qword [0x1401fdfa8]
test rax, rax
je 0x140020aa8
cmp byte [0x1401fdfd1], r14b
je 0x140020aa8
lea rdx, [rsp + 0x50]
lea rcx, [0x1401fdfa8]
call fcn.140027f6c
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
mov qword [rsp + 0x68], 8
mov qword [rsp + 0x70], 0xf
mov rax, qword [str.Humanoid]
mov qword [rsp + 0x58], rax
mov byte [rsp + 0x60], r14b
lea r8, [rsp + 0x58]
lea rdx, [rbp - 0x20]
lea rcx, [rsp + 0x50]
call fcn.140027d90
mov rbx, qword [rsp + 0x30]
test sil, sil
je 0x140020aec
movsd xmm0, qword [rbp - 0x18]
movsd qword [rbp - 0x70], xmm0
mov eax, dword [rbp - 0x10]
mov dword [rbp - 0x68], eax
lea rdx, [rbp - 0x70]
mov rcx, rbx
call fcn.14001f17c
cmp byte [0x1401fdfd2], r14b
je 0x140020aec
mov ecx, 1
call qword [sym.imp.USER32.dll_GetAsyncKeyState]
mov rcx, qword [rsp + 0x40]
call fcn.140020184
mov rax, qword [rsp + 0x40]
mov qword [0x1401fdfa8], rax
mov dil, 1
jmp 0x140020b14
mov sil, r14b
mov dil, r14b
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x40], r14
mov qword [0x1401fdfa8], r14
mov qword [rsp + 0x48], 1
lea rcx, [rsp + 0x48]
call fcn.14001ee70
mov al, byte [0x1400b40e1]
test al, al
jne 0x14002085d
mov eax, 1
xchg byte [0x1400b40e1], al
mov cl, byte [0x1401fdeb1]
test cl, cl
je 0x140020b27
mov eax, r14d
xchg byte [0x1400b40e0], al
cmp dword [rbp - 0x48], r14d
je 0x140020b92
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_terminate]
nop
mov dword [0x1400b413c], 0x7ffffffe
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
int3
mov ecx, 5
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov dword [rbp - 0x48], r14d
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.14008a5e0
lea r11, [rsp + 0x110]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov r14, qword [r11 + 0x28]
movaps xmm6, xmmword [r11 - 0x10]
mov rsp, r11
pop rbp
ret