Merge !2 into 'master'

See merge request ryubing/ryujinx!2
This commit is contained in:
GreemDev 2025-03-28 02:59:56 +00:00
commit 5bf656cb25

View file

@ -57,16 +57,19 @@ namespace Ryujinx.Input.SDL2
return null;
}
// Remove the first 4 char of the guid (CRC part) to make it stable
string guidString = "0000" + guid.ToString().Substring(4);
string id;
lock (_lock)
{
int guidIndex = 0;
id = guidIndex + "-" + guid;
id = guidIndex + "-" + guidString;
while (_gamepadsIds.Contains(id))
{
id = (++guidIndex) + "-" + guid;
id = (++guidIndex) + "-" + guidString;
}
}