Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions Falcon BMS Alternative Launcher/Override/OverrideSettingFor437.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,19 @@ protected override void OverrideVRHMD(StreamWriter cfg)
+ Convert.ToInt32(mainWindow.Misc_VR.IsChecked)
+ CommonConstants.CFGOVERRIDECOMMENT + "\r\n");
}

protected override void WriteKeyLines(string filename, Hashtable inGameAxis, DeviceControl deviceControl, KeyFile keyFile, int DXnumber)
{
StreamWriter sw = new StreamWriter
(filename, false, Encoding.GetEncoding("utf-8"));
for (int i = 0; i < keyFile.keyAssign.Length; i++)
sw.Write(keyFile.keyAssign[i].GetKeyLine());
for (int i = 0; i < deviceControl.joyAssign.Length; i++)
{
sw.Write(deviceControl.joyAssign[i].GetKeyLineDX(i, deviceControl.joyAssign.Length, DXnumber));
sw.Write(deviceControl.joyAssign[i].GetKeyLinePOV());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't tested, but my worry is this will write out a block of pov-hat bindings for each HID joystick/gamepad device plugged in, in their DeviceSorting.txt order. And I have no idea if BMS keyfile parser keeps the first 2, or the last 2..

Copy link
Author

@Althar93 Althar93 Aug 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BMS - Auto.key.txt
You are right, it does output entries for each HID plugged in : my throttle for instance which does not have POV hats, even though it's setup XML contains entries 'PovAssgn' block generates stub entries - see my generated 'BMS - Auto.key' file.

That being said, as far as I can tell, BMS is quite happy with this arrangement. I will try plugging in a second joystick/device with POV hats and see whether that still holds up.

}
sw.Close();
}
}
}