Function at 0x40cf50
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [sym.imp.USER32.dll_GetKeyState]
mov ebx, ecx
push 0x11
call esi
test ax, ax
jns 0x40d278
push 0x12
call esi
test ax, ax
jns 0x40d278
cmp dword [ebp + 8], 0x2e
jne 0x40d278
push edi
push 1
push dword [ebx + 0x20]
mov dword [0x5db850], 0
call dword [sym.imp.USER32.dll_KillTimer]
mov ecx, dword [0x5e448c]
mov eax, 0x105
sub ecx, dword [0x5e4484]
sub eax, dword [0x5db850]
movd xmm1, ecx
cvtdq2ps xmm1, xmm1
movd xmm0, eax
mov eax, 0x66666667
divss xmm1, dword [0x5bc878]
cvtdq2ps xmm0, xmm0
imul ecx
mulss xmm1, xmm0
cvttss2si esi, xmm1
sar edx, 5
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
mov eax, esi
cdq
idiv ecx
mov edi, edx
test edi, edi
je 0x40d00d
jle 0x40cff9
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
cmp edi, eax
jge 0x40cff9
sub esi, edi
jmp 0x40d00d
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
cmp edi, eax
jl 0x40d03a
cmp edi, ecx
jge 0x40d03a
sub esi, edi
add esi, 8
mov ecx, dword [0x5e4488]
mov eax, dword [0x5e4490]
push 6
sub eax, ecx
push eax
mov eax, dword [0x5e4484]
push esi
push ecx
push eax
push 0
push 0x3ed
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042bdb0
push dword [0x5db850]
push dword [0x5e4478]
push 0x5e447c
call fcn.004026a0
add esp, 0xc
mov ecx, ebx
push dword [0x5e447c]
push 0x3ec
call fcn.0042b403
mov ecx, eax
call fcn.0042be0d
push 0
push 0
push 0
push str.close__._res_bgm.wma_
call dword [sym.imp.WINMM.dll_mciSendStringW]
push 0x20001
push 0
push str.._res_boom.wav
call dword [sym.imp.WINMM.dll_PlaySoundW]
push 0
push 0x3e8
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3e8
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3e9
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3e9
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3ea
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3ea
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3eb
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3eb
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3ec
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3ec
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3ee
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3ee
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
push 0
push 0x3ed
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042b2c2
push 0
push 0x3ed
mov ecx, ebx
call fcn.0042b403
mov ecx, eax
call fcn.0042be5f
mov esi, dword [sym.imp.GDI32.dll_CreateSolidBrush]
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xd0]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xd8]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xe0]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xe8]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xf0]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0xf8]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0x100]
call fcn.00420d08
push 0x1000013
call esi
push eax
lea ecx, [ebx + 0x108]
call fcn.00420d08
push 0x105
push 0
push 0
push dword [ebx + 0x20]
call dword [sym.imp.USER32.dll_RedrawWindow]
push 0
push 0x1f4
push 2
push dword [ebx + 0x20]
call dword [sym.imp.USER32.dll_SetTimer]
pop edi
mov ecx, ebx
call fcn.004260d8
pop esi
pop ebx
pop ebp
ret 0xc