mirror of
https://github.com/moonlight-stream/moonlight-embedded.git
synced 2026-06-17 06:11:36 +00:00
reimplemented the trigger checkbox
This commit is contained in:
@@ -85,11 +85,14 @@ public class Gamepad implements DeviceListener {
|
||||
}
|
||||
|
||||
private float sanitizeValue(Mapping mapped, float value) {
|
||||
float retVal = value;
|
||||
if (mapped.invert) {
|
||||
return -value;
|
||||
} else {
|
||||
return value;
|
||||
retVal = -retVal;
|
||||
}
|
||||
if (mapped.trigger) {
|
||||
retVal = (retVal + 1) / 2;
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
|
||||
private void handleAnalogComponent(GamepadComponent padComp, float value) {
|
||||
|
||||
Reference in New Issue
Block a user