fixed jittering driving controller when using keyboard

This commit is contained in:
Thomas Jentzsch 2023-01-25 17:02:48 +01:00
parent 74a3b42903
commit 1f2e9bbb28
2 changed files with 2 additions and 2 deletions

View File

@ -114,7 +114,7 @@ void Driving::updateControllerAxes()
{
// Digital events (from keyboard or joystick hats & buttons)
const int d_axis = myEvent.get(myXAxisValue);
uInt32 oldCounterHires = myCounterHires;
const Int32 oldCounterHires = myCounterHires;
if(myEvent.get(myCCWEvent) != 0 && myLastCCWEvent == 0)
myCounterHires = ((myGrayIndex + 4) * 256.0F) / SENSITIVITY - 1; // set to end of previous counter interval

View File

@ -95,7 +95,7 @@ class Driving : public Controller
Int32 myCounter{0};
// Higher resolution counter for analog (non-Stelladaptor) inputs
uInt32 myCounterHires{0};
Int32 myCounterHires{0};
// Previous digital CCW event
Int32 myLastCCWEvent{0};