Hello. I am doing some tests with Arduino Due and Counter-Strike Global Offensive inputs using native USB port.
I noticed something interesting and I am wondering if it comes from my code or CSGO itself or maybe it comes from variation in USB communication.
Game is working always at capped framerate. No difference if on offline or online server.
It goes like this: Press right key -> wait xxx miliseconds -> release right key -> Tap Left key
Position coordinates at which player stops are:
-391.86 -391.86 -393.54 -393.54 -393.54 -391.86 -395.32 -393.54
So it varies kinda a lot, but it is repeatable - every time it is one of those numbers.
Is this normal behavior expected from game or maybe I need to be somehow more precise in arduino code?
Maybe it is mismatch between arduino timing and game working in 128tick and it doesn't always happen on same tick so the result will vary? I got such suggestion on CSGO reddit.
It happens both offline and online.
Keyboard.press(KEY_RIGHT_ARROW);
delay(delayValue);
Keyboard.release(KEY_RIGHT_ARROW);
Keyboard.write(KEY_LEFT_ARROW);