UI: Add the ability to change a DualSense/DualShock 4's LED color.

Not functional yet. This is the UI & persistence side of #572.
This commit is contained in:
Evan Husted
2025-01-22 19:53:39 -06:00
parent 069f630776
commit c03cd50fa3
11 changed files with 125 additions and 14 deletions

View File

@@ -263,15 +263,12 @@ namespace Ryujinx.Ava.Utilities.Configuration
}),
(30, static cff =>
{
foreach (InputConfig config in cff.InputConfig)
foreach (StandardControllerInputConfig config in cff.InputConfig.OfType<StandardControllerInputConfig>())
{
if (config is StandardControllerInputConfig controllerConfig)
config.Rumble = new RumbleConfigController
{
controllerConfig.Rumble = new RumbleConfigController
{
EnableRumble = false, StrongRumble = 1f, WeakRumble = 1f,
};
}
EnableRumble = false, StrongRumble = 1f, WeakRumble = 1f,
};
}
}),
(31, static cff => cff.BackendThreading = BackendThreading.Auto),
@@ -416,7 +413,18 @@ namespace Ryujinx.Ava.Utilities.Configuration
// so as a compromise users who want to use it will simply need to re-enable it once after updating.
cff.IgnoreApplet = false;
}),
(60, static cff => cff.StartNoUI = false)
(60, static cff => cff.StartNoUI = false),
(61, static cff =>
{
foreach (StandardControllerInputConfig config in cff.InputConfig.OfType<StandardControllerInputConfig>())
{
config.Led = new LedConfigController
{
EnableLed = false,
LedColor = 328189
};
}
})
);
}
}