Function at 0x180049110
Capabilities:
Allocate or change rwx memory
Create thread
Log keystrokes via polling
Spawn thread to rwx shellcode

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x60
mov rax, qword [0x1800a8010]
xor rax, rsp
mov qword [rsp + 0x50], rax
mov rbp, rdx
mov rsi, rcx
cmp dword [0x1800aaef4], 0xd
jne 0x1800493a3
call fcn.180046680
lea rcx, str.Dialogue
cmp rax, rcx
jne 0x180049165
movss xmm0, dword [0x18009be0c]
movss dword [0x1800aa084], xmm0
call fcn.180046680
lea rcx, str.Battle
cmp rax, rcx
jne 0x180049180
mov dword [0x1800aa084], 0x3f800000
call fcn.180046680
lea rcx, str.World
cmp rax, rcx
jne 0x1800491a4
cmp byte [0x1800ab158], 0
jne 0x1800491a4
mov dword [0x1800aa084], 0x3f800000
mov edi, 0x40
mov r14d, 0xc3
cmp byte [0x1800ab156], 0
cmovne edi, r14d
lea r9, [rsp + 0x30]
mov edx, 1
lea r8d, [rdx + 0x3f]
lea rcx, [rsi + 0x463c120]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov byte [rsi + 0x463c120], dil
lea r9, [rsp + 0x30]
mov r8d, dword [rsp + 0x30]
mov edx, 1
lea rcx, [rsi + 0x463c120]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov edi, 0x40
cmp byte [0x1800ab152], 0
cmovne edi, r14d
lea r9, [rsp + 0x30]
mov edx, 1
lea r8d, [rdx + 0x3f]
lea rcx, [rsi + 0x3bd9e60]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov byte [rsi + 0x3bd9e60], dil
lea r9, [rsp + 0x30]
mov r8d, dword [rsp + 0x30]
mov edx, 1
lea rcx, [rsi + 0x3bd9e60]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov edi, 0x33
cmp byte [0x1800ab160], 0
cmovne edi, r14d
lea r9, [rsp + 0x30]
mov edx, 1
lea r8d, [rdx + 0x3f]
lea rcx, [rsi + 0x1469b20]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov byte [rsi + 0x1469b20], dil
lea r9, [rsp + 0x30]
mov r8d, dword [rsp + 0x30]
mov edx, 1
lea rcx, [rsi + 0x1469b20]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov edi, 0x4c2c20f
mov eax, 0x4d2c20f
cmp byte [0x1800ab151], 0
cmovne edi, eax
lea r9, [rsp + 0x30]
mov edx, 4
lea r8d, [rdx + 0x3c]
lea rcx, [rbp + 0xe7a0ff]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov dword [rbp + 0xe7a0ff], edi
lea r9, [rsp + 0x30]
mov r8d, dword [rsp + 0x30]
mov edx, 4
lea rcx, [rbp + 0xe7a0ff]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov ecx, dword [0x1800aa08c]
call qword [sym.imp.USER32.dll_GetAsyncKeyState]
test al, 1
je 0x1800493a3
cmp byte [0x1800ab157], 0
sete al
mov byte [0x1800ab157], al
test al, al
je 0x1800493a3
mov qword [rsp + 0x30], 0x32
lea rcx, [rsp + 0x30]
call fcn.180050bb0
mov ecx, 8
call fcn.18005cfac
lea rcx, [0x180046730]
mov qword [rax], rcx
mov qword [rsp + 0x30], rax
lea rcx, [rsp + 0x48]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], 0
mov r9, rax
lea r8, [0x18005a880]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rsp + 0x40], rax
test rax, rax
je 0x1800493c5
cmp dword [rsp + 0x48], 0
jne 0x180049380
mov ecx, 1
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
int3
movaps xmm0, xmmword [rsp + 0x40]
movdqa xmmword [rsp + 0x30], xmm0
lea rcx, [rsp + 0x30]
call qword [sym.imp.MSVCP140.dll__Thrd_detach]
test eax, eax
je 0x1800493a3
mov ecx, eax
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_C_error_int_]
nop
mov rcx, qword [rsp + 0x50]
xor rcx, rsp
call fcn.18005c6b0
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
mov dword [rsp + 0x48], 0
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
int3