Use SetDevRumble to avoid array checks

This commit is contained in:
Travis Nickles 2019-03-21 20:56:49 -05:00
parent 9614727566
commit 36a8382fdd

View File

@ -428,7 +428,7 @@ namespace DS4Windows
int devIndex = i;
x360controls[i].FeedbackReceived += (sender, args) =>
{
setRumble(args.LargeMotor, args.SmallMotor, devIndex);
SetDevRumble(device, args.LargeMotor, args.SmallMotor, devIndex);
};
x360controls[i].Connect();
LogDebug("X360 Controller #" + (i + 1) + " connected");
@ -684,7 +684,7 @@ namespace DS4Windows
int devIndex = Index;
x360controls[Index].FeedbackReceived += (sender, args) =>
{
setRumble(args.LargeMotor, args.SmallMotor, devIndex);
SetDevRumble(device, args.LargeMotor, args.SmallMotor, devIndex);
};
x360controls[Index].Connect();
LogDebug("X360 Controller #" + (Index + 1) + " connected");