Changed stuff

This commit is contained in:
Aarav Shah
2021-10-04 17:02:05 -06:00
parent 8a04ae9423
commit dc61e69777
3 changed files with 30 additions and 18 deletions
@@ -36,8 +36,15 @@ public class RunLevelerWithJoystick extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
double input = m_controller.getRightXAxis();
m_leveler.runLeveler(input);
double input = m_controller.getDpadAngle();
if (input == 90)
{
m_leveler.runLeveler(0.5);
}
else if (input == 270)
{
m_leveler.runLeveler(-0.5);
}
}
// Called once the command ends or is interrupted.