Actually fix fuck ups

This commit is contained in:
Isaac Marovitz 2023-05-18 17:54:42 -04:00 committed by Isaac Marovitz
parent 1b037ca33d
commit 4a92d0b482

View file

@ -398,17 +398,6 @@ namespace Ryujinx.Ava.UI.Models.Input
} }
} }
private MotionInputBackendType _motionBackend;
public MotionInputBackendType MotionBackend
{
get => _motionBackend;
set
{
_motionBackend = value;
OnPropertyChanged();
}
}
private double _gyroDeadzone; private double _gyroDeadzone;
public double GyroDeadzone public double GyroDeadzone
{ {
@ -520,7 +509,6 @@ namespace Ryujinx.Ava.UI.Models.Input
if (controllerInput.Motion != null) if (controllerInput.Motion != null)
{ {
EnableMotion = controllerInput.Motion.EnableMotion; EnableMotion = controllerInput.Motion.EnableMotion;
MotionBackend = controllerInput.Motion.MotionBackend;
GyroDeadzone = controllerInput.Motion.GyroDeadzone; GyroDeadzone = controllerInput.Motion.GyroDeadzone;
Sensitivity = controllerInput.Motion.Sensitivity; Sensitivity = controllerInput.Motion.Sensitivity;
@ -598,13 +586,6 @@ namespace Ryujinx.Ava.UI.Models.Input
WeakRumble = WeakRumble, WeakRumble = WeakRumble,
StrongRumble = StrongRumble StrongRumble = StrongRumble
}, },
Motion = new MotionConfigController
{
EnableMotion = EnableMotion,
MotionBackend = MotionBackend,
GyroDeadzone = GyroDeadzone,
Sensitivity = Sensitivity,
},
Version = InputConfig.CurrentVersion, Version = InputConfig.CurrentVersion,
DeadzoneLeft = DeadzoneLeft, DeadzoneLeft = DeadzoneLeft,
DeadzoneRight = DeadzoneRight, DeadzoneRight = DeadzoneRight,
@ -615,13 +596,28 @@ namespace Ryujinx.Ava.UI.Models.Input
if (EnableCemuHookMotion) if (EnableCemuHookMotion)
{ {
var cemuHook = (CemuHookMotionConfigController)config.Motion; config.Motion = new CemuHookMotionConfigController
cemuHook.DsuServerHost = DsuServerHost; {
cemuHook.DsuServerPort = DsuServerPort; EnableMotion = EnableMotion,
cemuHook.Slot = Slot; MotionBackend = MotionInputBackendType.CemuHook,
cemuHook.AltSlot = AltSlot; GyroDeadzone = GyroDeadzone,
cemuHook.MirrorInput = MirrorInput; Sensitivity = Sensitivity,
config.Motion = cemuHook; DsuServerHost = DsuServerHost,
DsuServerPort = DsuServerPort,
Slot = Slot,
AltSlot = AltSlot,
MirrorInput = MirrorInput
};
}
else
{
config.Motion = new MotionConfigController
{
EnableMotion = EnableMotion,
MotionBackend = MotionInputBackendType.GamepadDriver,
GyroDeadzone = GyroDeadzone,
Sensitivity = Sensitivity
};
} }
return config; return config;