Class LinearAxis
java.lang.Object
org.firstinspires.ftc.teamcode.fy23.gamepad2.primitives.axes.LinearAxis
- All Implemented Interfaces:
Axis
Represents an axis on a gamepad, including sticks or triggers, and directly reports the value.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.firstinspires.ftc.teamcode.fy23.gamepad2.primitives.Axis
Axis.DoubleLambda
-
Constructor Summary
ConstructorDescriptionLinearAxis
(Axis.DoubleLambda axis) Pass in a lambda expression that returns the value of aGamepad
axis field: new LinearAxis( () -> gamepad.left_stick_x );LinearAxis
(Axis.DoubleLambda axis, double scalingFactor) Specify a scaling factor (a number that the value should be multiplied by) -
Method Summary
Modifier and TypeMethodDescriptiondouble
value()
The value of an axis depends on the implementation and its parameters.
-
Constructor Details
-
LinearAxis
Pass in a lambda expression that returns the value of aGamepad
axis field: new LinearAxis( () -> gamepad.left_stick_x ); -
LinearAxis
Specify a scaling factor (a number that the value should be multiplied by)
-
-
Method Details