Skip to content

Commit

Permalink
[Robot] Remove redundant intake code
Browse files Browse the repository at this point in the history
  • Loading branch information
mvog2501 committed Jul 18, 2024
1 parent 1a960cd commit d41aa26
Showing 1 changed file with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -214,16 +214,15 @@ public void periodic() {
return;
}

if (!operator.a.isPressed())
robot.intake.set(IntakeSubsystem.State.OFF);
// if (!operator.a.isPressed())
// robot.intake.set(IntakeSubsystem.State.OFF);

boolean forceToSubwoofer = forceSubwooferTrigger.getAsBoolean();
robot.drive.setEstimatorIgnoreVision(forceToSubwoofer || forceToStageCorner);
robot.drive.setEstimatorIgnoreVision(forceToSubwoofer);

if (forceToSubwoofer)
if (forceToSubwoofer) {
robot.drive.setPose(robot.drive.getFieldInfo().flipPoseForAlliance(new Pose2d(1.393, 5.512, new Rotation2d(Math.PI))));
if (forceToStageCorner)
robot.drive.setPose(robot.drive.getFieldInfo().flipPoseForAlliance(new Pose2d(3.354, 5.512, new Rotation2d(Math.PI))));
}


NTEntry<Double> pivotAdjust = PivotSubsystem.getAdjustForAlliance();
Expand Down Expand Up @@ -319,7 +318,7 @@ public void periodic() {
ShooterSubsystem.FlywheelControl flywheelControl = ShooterSubsystem.FlywheelControl.IDLE;
if (operator.start.isPressed())
flywheelControl = ShooterSubsystem.FlywheelControl.REVERSE;
else if (driverWantsAim() || shootAmp || shootManual || forceToSubwoofer || forceToStageCorner || lobbing != 0)
else if (driverWantsAim() || shootAmp || shootManual || forceToSubwoofer || lobbing != 0)
flywheelControl = ShooterSubsystem.FlywheelControl.SHOOT;
else if (operatorWantsShoot)
flywheelControl = ShooterSubsystem.FlywheelControl.POOP;
Expand Down

0 comments on commit d41aa26

Please sign in to comment.