diff --git a/src/main/java/frc/robot/Robot.java b/src/main/java/frc/robot/Robot.java index 49925f9b..a7f0d95d 100644 --- a/src/main/java/frc/robot/Robot.java +++ b/src/main/java/frc/robot/Robot.java @@ -19,6 +19,7 @@ import frc.auton.guiauto.serialization.reflection.ClassInformationSender; import frc.subsystem.*; import frc.subsystem.Climber.ClimbState; +import frc.subsystem.Intake.IntakeSolState; import frc.utility.*; import frc.utility.Controller.XboxAxes; import frc.utility.Controller.XboxButtons; @@ -464,7 +465,7 @@ public void teleopPeriodic() { shooter.setFiring(false); shooter.setSpeed(0); visionManager.unForceVisionOn(driverForcingVisionOn); - if (xbox.getRawAxis(XboxAxes.LEFT_TRIGGER) > 0.1) { + if (xbox.getRawAxis(XboxAxes.LEFT_TRIGGER) > 0.1 && intake.getIntakeSolState() == IntakeSolState.OPEN) { drive.centerOntoBall(getControllerDriveInputs(), useFieldRelative); } else if (climber.getClimbState() == ClimbState.IDLE || climber.isPaused()) { // If we're climbing don't allow the robot to be // driven