Code: Select all
bool keypressed = receiver.IsKeyDown(KEY_KEY_W);
...
while(device->run()){
...
...
if(!keypressed){
if(receiver.IsKeyDown(KEY_KEY_W)){ print("TEST");}
keypressed = 1;
}
else{
keypressed = receiver.IsKeyDown(KEY_KEY_W);
}
...
...
}