Skip to content
This repository has been archived by the owner on Apr 27, 2024. It is now read-only.

Commit

Permalink
Fix independent brake not using keyboard mappings
Browse files Browse the repository at this point in the history
  • Loading branch information
Yamazaki93 committed Apr 29, 2020
1 parent 8464068 commit 2774f6e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions TSWMod/TSW/CSX/AC4400CWIndependentBrake.cs
Expand Up @@ -23,15 +23,15 @@ public void EngageBailOffIfNeeded()
if (!_bailOff && CurrentValue.AlmostEquals(0.2f))
{
_bailOff = true;
InputHelpers.KeyDown(HWND, InputHelpers.VKCodes.VK_OEM_4);
InputHelpers.KeyComboDown(HWND, KeyboardLayoutManager.Current.IndependentBrakeDecrease);
}
}

public void DisengageBailOffIfNeeded()
{
if (_bailOff)
{
InputHelpers.KeyUp(HWND, InputHelpers.VKCodes.VK_OEM_4);
InputHelpers.KeyComboUp(HWND, KeyboardLayoutManager.Current.IndependentBrakeDecrease);
_bailOff = false;
}
}
Expand Down
4 changes: 2 additions & 2 deletions TSWMod/TSW/CSX/SD40_2IndependentBrake.cs
Expand Up @@ -28,15 +28,15 @@ public void EngageBailOffIfNeeded()
if (!_bailOff && CurrentValue.AlmostEquals(0.25f))
{
_bailOff = true;
InputHelpers.KeyDown(HWND, InputHelpers.VKCodes.VK_OEM_4);
InputHelpers.KeyComboDown(HWND, KeyboardLayoutManager.Current.IndependentBrakeDecrease);
}
}

public void DisengageBailOffIfNeeded()
{
if (_bailOff)
{
InputHelpers.KeyUp(HWND, InputHelpers.VKCodes.VK_OEM_4);
InputHelpers.KeyComboUp(HWND, KeyboardLayoutManager.Current.IndependentBrakeDecrease);
_bailOff = false;
}
}
Expand Down

0 comments on commit 2774f6e

Please sign in to comment.