Search code examples
c#keyboardkeyeventanti-cheat

How do I see if any programs are emulating keys


I've made a game where the task is to press spacebar 100 times which is mutiplayer, People are starting to use simple applications which spam the key "space" and I'm wondering if there is a way to only listen for user input or detect programs which are emulating key events.

I've not tested one of these programs but my program listens for KeyUp event.

Just tested: They can emulate key presses


Solution

  • Best bet is to see if the time between all the spaces are exactly the same. A human would likely have some kind of variance. Make a judgement over some period of time.