mirror of
https://github.com/ayufan/steam-deck-tools.git
synced 2026-01-25 01:40:26 +01:00
FLM: Send haptic on pad presses when both lizard mouse and buttons are disabled
This commit is contained in:
parent
6d8ab9c321
commit
bc276b94a4
|
|
@ -2,6 +2,7 @@ using System.Diagnostics;
|
|||
using ExternalHelpers;
|
||||
using PowerControl.Helpers;
|
||||
using WindowsInput;
|
||||
using static SteamController.Devices.SteamController;
|
||||
|
||||
namespace SteamController.Profiles.Default
|
||||
{
|
||||
|
|
@ -120,6 +121,15 @@ namespace SteamController.Profiles.Default
|
|||
|
||||
protected void EmulateScrollOnLPad(Context c)
|
||||
{
|
||||
//Send haptic for pad presses
|
||||
if (!c.Steam.LizardButtons && !c.Steam.LizardMouse)
|
||||
{
|
||||
if (c.Steam.BtnLPadPress.Pressed() || c.Steam.BtnLPadPress.JustPressed())
|
||||
{
|
||||
c.Steam.SendHaptic(HapticPad.Left, HapticStyle.Strong, 8);
|
||||
}
|
||||
}
|
||||
|
||||
if (c.Steam.LPadX)
|
||||
{
|
||||
c.Mouse.HorizontalScroll(
|
||||
|
|
@ -174,6 +184,15 @@ namespace SteamController.Profiles.Default
|
|||
c.Mouse[Devices.MouseController.Button.Left] = c.Steam.BtnRPadPress;
|
||||
}
|
||||
|
||||
//Send haptic for pad presses
|
||||
if (!c.Steam.LizardButtons && !c.Steam.LizardMouse)
|
||||
{
|
||||
if (c.Steam.BtnRPadPress.Pressed() || c.Steam.BtnRPadPress.JustPressed())
|
||||
{
|
||||
c.Steam.SendHaptic(HapticPad.Right, HapticStyle.Strong, 8);
|
||||
}
|
||||
}
|
||||
|
||||
c.Mouse.MoveByFauxLizard(
|
||||
c.Steam.RPadX.GetDeltaValue(Context.PadToMouseSensitivity, Devices.DeltaValueMode.Delta, 10),
|
||||
-c.Steam.RPadY.GetDeltaValue(Context.PadToMouseSensitivity, Devices.DeltaValueMode.Delta, 10),
|
||||
|
|
|
|||
Loading…
Reference in a new issue