From 2c4236f7332b0469c34704136c111457e4a28106 Mon Sep 17 00:00:00 2001 From: mika Date: Thu, 23 Jan 2025 03:39:33 +0100 Subject: [PATCH] test --- src/Ryujinx.Input.SDL2/SDL2Gamepad.cs | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/Ryujinx.Input.SDL2/SDL2Gamepad.cs b/src/Ryujinx.Input.SDL2/SDL2Gamepad.cs index 3e712a389..039567228 100644 --- a/src/Ryujinx.Input.SDL2/SDL2Gamepad.cs +++ b/src/Ryujinx.Input.SDL2/SDL2Gamepad.cs @@ -87,9 +87,9 @@ namespace Ryujinx.Input.SDL2 Features = GetFeaturesFlag(); _triggerThreshold = 0.0f; - if (SDL_GameControllerHasLED(_gamepadHandle) == SDL_bool.SDL_TRUE) + if (Features.HasFlag(GamepadFeaturesFlag.Led)) { - SetLedColor("FFE3B5"); + SetLedColor(); } // Enable motion tracking @@ -107,12 +107,13 @@ namespace Ryujinx.Input.SDL2 } } - public void SetLedColor(string hex) + public void SetLedColor() { - ulong LEDcolor = Convert.ToUInt64(hex, 16); - byte red = (byte)((LEDcolor >> 16) % 256); - byte green = (byte)((LEDcolor >> 8) % 256); - byte blue = (byte)(LEDcolor % 256); + //IAMTOOTIREDWILLCONTINUETOMORROWSORRY + uint rawColor = 100; + byte red = (byte)(rawColor >> 16); + byte green = (byte)(rawColor >> 8); + byte blue = (byte)(rawColor % 256); SDL_GameControllerSetLED(_gamepadHandle, red, green, blue); }