I have this peace of code, everytime someone presses W it sends the unit only once, I want do make it that if someone holds the key repeat it over and over again.. any ideas how?
case 87: // W
if ((!wPressed) && (!isTyping)) {
sendMouseMove();
sendUint8(21);
wPressed = true;
}