Function at 0x100519d0
Capabilities:
Check for time delay via gettickcount
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
cmp dword [0x1083213c], 1
push ebx
push esi
jl 0x1005201f
movss xmm2, dword [0x100bc6ac]
xor eax, eax
movss xmm1, dword [0x11b3794]
comiss xmm2, xmm1
xorps xmm2, xmm2
setae al
movd xmm5, eax
cvtdq2ps xmm5, xmm5
ucomiss xmm5, xmm2
lahf
test ah, 0x44
jnp 0x10051a15
movaps xmm4, xmm1
jmp 0x10051a1d
movss xmm4, dword [0x11b3798]
mulss xmm4, dword [0x100bcc7c]
movaps xmm3, xmm1
mulss xmm3, dword [0x100bcc7c]
ucomiss xmm5, xmm2
subss xmm3, xmm4
lahf
test ah, 0x44
jp 0x10051a45
movss xmm1, dword [0x11b3798]
mulss xmm1, dword [0x100bcbfc]
sub esp, 0x10
mov esi, dword [sym.imp.OPENGL32.dll_glColor4f]
addss xmm1, xmm3
mov dword [esp + 0xc], 0x3f733333
mov dword [esp + 8], 0x3f800000
mov dword [esp + 4], 0x3f800000
mov dword [esp], 0x3f800000
movss dword [ebp - 8], xmm1
call esi
movss xmm0, dword [0x100bc6ac]
xor eax, eax
movss xmm2, dword [0x11b3794]
comiss xmm0, xmm2
xorps xmm0, xmm0
setae al
movd xmm1, eax
cvtdq2ps xmm1, xmm1
ucomiss xmm1, xmm0
lahf
test ah, 0x44
jnp 0x10051ab0
movaps xmm3, xmm2
jmp 0x10051ab8
movss xmm3, dword [0x11b3798]
mulss xmm3, dword [0x100bcbb8]
ucomiss xmm1, xmm0
lahf
test ah, 0x44
jnp 0x10051ad2
movaps xmm1, xmm2
addss xmm1, xmm2
jmp 0x10051ade
movss xmm1, dword [0x11b3798]
addss xmm1, xmm1
movss xmm0, dword [ebp - 8]
mov ebx, 0x631289
subss xmm0, xmm1
divss xmm3, xmm2
push ecx
mov dword [esp], 0
push 1
push 1
sub esp, 0x20
mov dword [esp + 0x1c], 0x3f800000
mov dword [esp + 0x18], 0x3f800000
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x42f00000
divss xmm0, xmm2
movss dword [esp + 8], xmm3
mov dword [esp + 4], 0x43020000
movss dword [esp], xmm0
push 0xf070
call ebx
add esp, 0x20
mov dword [esp + 0xc], 0x3f800000
mov dword [esp + 8], 0x3f800000
mov dword [esp + 4], 0x3f800000
mov dword [esp], 0x3f800000
call esi
movss xmm0, dword [0x100bc6ac]
xor eax, eax
movss xmm2, dword [0x11b3794]
xorps xmm1, xmm1
comiss xmm0, xmm2
setae al
movd xmm0, eax
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x10051b99
movaps xmm0, xmm2
jmp 0x10051ba1
movss xmm0, dword [0x11b3798]
mulss xmm0, dword [0x100bcbb8]
push str.Error
push 0
push 3
divss xmm0, xmm2
cvttss2si eax, xmm0
movss xmm0, dword [ebp - 8]
divss xmm0, xmm2
push eax
push 0x87
cvttss2si eax, xmm0
push eax
push 0xff19bdff
push 0x1023cd58
call fcn.100607a0
mov eax, dword [0x1083213c]
add esp, 0x20
xorps xmm1, xmm1
cmp eax, 3
jne 0x10051c5e
movss xmm2, dword [0x11b3794]
xor eax, eax
movss xmm0, dword [0x100bc6ac]
comiss xmm0, xmm2
movss dword [ebp - 0xc], xmm2
setae al
movd xmm0, eax
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x10051c21
movss dword [ebp - 4], xmm2
jmp 0x10051c2e
movss xmm0, dword [0x11b3798]
movss dword [ebp - 4], xmm0
push 0x15f
mov ecx, 0x10173658
call fcn.10036b80
movss xmm0, dword [ebp - 4]
mulss xmm0, dword [0x100bcbb8]
movss xmm1, dword [ebp - 8]
divss xmm1, dword [ebp - 0xc]
divss xmm0, dword [ebp - 0xc]
jmp 0x10051d83
movss xmm0, dword [0x11b3794]
movss xmm2, dword [0x100bc6ac]
movss dword [ebp - 4], xmm0
cmp eax, 4
jne 0x10051cd2
xor eax, eax
movss dword [ebp - 0xc], xmm0
comiss xmm2, xmm0
setae al
movd xmm0, eax
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jp 0x10051ca2
movss xmm0, dword [0x11b3798]
movss dword [ebp - 4], xmm0
push 0x160
mov ecx, 0x10173658
call fcn.10036b80
movss xmm0, dword [ebp - 4]
mulss xmm0, dword [0x100bcbb8]
movss xmm1, dword [ebp - 8]
divss xmm1, dword [ebp - 0xc]
divss xmm0, dword [ebp - 0xc]
jmp 0x10051d83
cmp eax, 1
jne 0x10051d2e
xor eax, eax
movss dword [ebp - 0xc], xmm0
comiss xmm2, xmm0
setae al
movd xmm0, eax
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jp 0x10051d01
movss xmm0, dword [0x11b3798]
movss dword [ebp - 4], xmm0
push 0x132
mov ecx, 0x10173658
call fcn.10036b80
movss xmm0, dword [ebp - 4]
mulss xmm0, dword [0x100bcbb8]
movss xmm1, dword [ebp - 8]
divss xmm1, dword [ebp - 0xc]
divss xmm0, dword [ebp - 0xc]
jmp 0x10051d83
xor eax, eax
movss dword [ebp - 0xc], xmm0
comiss xmm2, xmm0
setae al
movd xmm0, eax
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jp 0x10051d58
movss xmm0, dword [0x11b3798]
movss dword [ebp - 4], xmm0
push 0x159
mov ecx, 0x10173658
call fcn.10036b80
movss xmm0, dword [ebp - 4]
mulss xmm0, dword [0x100bcbb8]
movss xmm1, dword [ebp - 8]
divss xmm1, dword [ebp - 0xc]
divss xmm0, dword [ebp - 0xc]
push eax
cvttss2si eax, xmm0
push 0
push 3
push eax
cvttss2si eax, xmm1
push 0x9b
push eax
push 0xffffffffffffffff
push 0x1023cd58
call fcn.100607a0
movss xmm2, dword [0x11b3794]
xor eax, eax
movss xmm0, dword [0x100bc6ac]
add esp, 0x20
comiss xmm0, xmm2
xorps xmm1, xmm1
setae al
movd xmm3, eax
cvtdq2ps xmm3, xmm3
ucomiss xmm3, xmm1
lahf
test ah, 0x44
jnp 0x10051dd6
movaps xmm0, xmm2
jmp 0x10051dde
movss xmm0, dword [0x11b3798]
mulss xmm0, dword [0x100bca80]
ucomiss xmm3, xmm1
addss xmm0, dword [ebp - 8]
lahf
divss xmm0, xmm2
movss dword [ebp - 0xc], xmm0
test ah, 0x44
jnp 0x10051e02
movaps xmm1, xmm2
jmp 0x10051e0a
movss xmm1, dword [0x11b3798]
mulss xmm1, dword [0x100bcaac]
push 0x14
divss xmm1, xmm2
cvttss2si eax, xmm1
movss dword [ebp - 4], xmm1
push eax
cvttss2si eax, xmm0
push 0xc8
push eax
mov eax, 0x799756
call eax
mov esi, dword [sym.imp.OPENGL32.dll_glColor3f]
add esp, 0x10
movss xmm0, dword [ebp - 4]
push ecx
mov dword [esp], 0
push 1
push 1
cmp al, 1
jne 0x10051f29
sub esp, 0x20
mov dword [esp + 0x1c], 0x3e69d18c
mov dword [esp + 0x18], 0x3f341b1a
mov dword [esp + 0x14], 0x3ca3d70a
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x41a00000
movss dword [esp + 8], xmm0
movss xmm0, dword [ebp - 0xc]
mov dword [esp + 4], 0x43480000
movss dword [esp], xmm0
push 0xf06e
call ebx
add esp, 0x30
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x10832140]
cmp eax, 0x12c
jbe 0x10051f76
push 1
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jns 0x10051f76
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub esp, 0xc
mov dword [0x10832140], eax
mov dword [0x1083213c], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0x3f800000
call esi
movss xmm0, dword [ebp - 4]
push ecx
mov dword [esp], 0
push 1
push 1
sub esp, 0x20
mov dword [esp + 0x1c], 0x3e69d18c
mov dword [esp + 0x18], 0x3f341b1a
mov dword [esp + 0x14], 0x3f07ae14
jmp 0x10051f44
sub esp, 0x20
mov dword [esp + 0x1c], 0x3e69d18c
mov dword [esp + 0x18], 0x3f341b1a
mov dword [esp + 0x14], 0x3e8963a7
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x41a00000
movss dword [esp + 8], xmm0
movss xmm0, dword [ebp - 0xc]
mov dword [esp + 4], 0x43480000
movss dword [esp], xmm0
push 0xf06e
call ebx
add esp, 0x30
sub esp, 0xc
mov dword [esp + 8], 0x3f800000
mov dword [esp + 4], 0x3f800000
mov dword [esp], 0x3f800000
call esi
movss xmm0, dword [ebp - 8]
mov eax, 0x436d31
divss xmm0, dword [0x11b3794]
push 0x184
mov ecx, 0x8499de0
movss dword [ebp - 8], xmm0
call eax
movss xmm0, dword [0x100bc6ac]
xor ecx, ecx
movss xmm2, dword [0x11b3794]
xorps xmm1, xmm1
comiss xmm0, xmm2
mov edx, eax
setae cl
movd xmm0, ecx
cvtdq2ps xmm0, xmm0
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x10051fe7
movaps xmm0, xmm2
jmp 0x10051fef
movss xmm0, dword [0x11b3798]
mulss xmm0, dword [0x100bcbb8]
push edx
push 0
push 3
divss xmm0, xmm2
cvttss2si eax, xmm0
push eax
cvttss2si eax, dword [ebp - 8]
push 0xce
push eax
push 0xffffffffffffffff
push 0x1023cd58
call fcn.100607a0
add esp, 0x20
pop esi
pop ebx
mov esp, ebp
pop ebp
ret