From 76700cf44023256e98786f4a3696f01c75740a90 Mon Sep 17 00:00:00 2001 From: Sodi Date: Tue, 20 Sep 2022 19:07:10 -0500 Subject: [PATCH] Trying to clean up and finish adding Rack Risers. --- .../testing/states/PrototypeTeleOPState.java | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/TeamCode/src/main/java/org/timecrafters/testing/states/PrototypeTeleOPState.java b/TeamCode/src/main/java/org/timecrafters/testing/states/PrototypeTeleOPState.java index 43901c2..3a02556 100644 --- a/TeamCode/src/main/java/org/timecrafters/testing/states/PrototypeTeleOPState.java +++ b/TeamCode/src/main/java/org/timecrafters/testing/states/PrototypeTeleOPState.java @@ -90,8 +90,6 @@ public class PrototypeTeleOPState extends CyberarmState { robot.frontRightDrive.setPower(-frontRightPower); robot.backRightDrive.setPower(backRightPower); - - robot.armMotor.setPower(engine.gamepad2.left_stick_y * 0.5); @@ -181,5 +179,19 @@ public class PrototypeTeleOPState extends CyberarmState { // .5's are originally .13's. } + if (engine.gamepad2.right_stick_y > 0.1) { + + robot.RackRiserRight.setPosition(+ 1); + robot.RackRiserLeft.setPosition(+ 1); + + } + + if (engine.gamepad2.right_stick_y < -0.1) { + + robot.RackRiserLeft.setPosition(- 1); + robot.RackRiserRight.setPosition(- 1); + + } + } } \ No newline at end of file