I am trying to make a remote keyboard application using WinSock2.
I'm currently using sendInput
to register a keydown event when a character comes in through the socket. This works great when writing a text documents, but not when playing video games as a keyup event is often required to end a certain action.
The problem is that I'm not sure in what format I should send the keyup event so that I can differentiate it from a keydown event in my code.
I have tried appending a string to char array that gets sent through the socket so I can identify a keyup, but this is very slow and only works ocassionaly for some reason.
Any suggestions on how I should do this would be appreciated.