From 2316772828db0cc6fa2221c7c4bd4fcd189817de Mon Sep 17 00:00:00 2001 From: Jay Date: Fri, 10 Nov 2023 20:37:31 -0800 Subject: [PATCH] spotless --- src/main/java/frc/robot/RobotContainer.java | 20 ++++-------- .../commands/GroundIntakeElevatorCommand.java | 31 +++++++++---------- .../robot/commands/GroundPickupCommand.java | 3 -- 3 files changed, 21 insertions(+), 33 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 2cad0d8..b5213a9 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -324,19 +324,11 @@ private void configureButtonBindings() { anthony .povDown() - .onTrue( - new GroundPickupCommand( - intakeSubsystem, - elevatorSubsystem, - anthony.rightBumper())); + .onTrue(new GroundPickupCommand(intakeSubsystem, elevatorSubsystem, anthony.rightBumper())); jacob .a() - .onTrue( - new GroundPickupCommand( - intakeSubsystem, - elevatorSubsystem, - jacob.leftBumper())); + .onTrue(new GroundPickupCommand(intakeSubsystem, elevatorSubsystem, jacob.leftBumper())); jacobLayer .off(jacob.povUp()) @@ -398,13 +390,13 @@ private void configureButtonBindings() { intakeSubsystem, elevatorSubsystem, Constants.SCORE_STEP_MAP.get(scoreType), - // jacob.b())); - anthony.povRight())); + // jacob.b())); + anthony.povRight())); anthony .povRight() - // jacob - // .b() + // jacob + // .b() .onTrue( new HashMapCommand<>( scoreCommandMap, () -> currentNodeSelection.get().getScoreTypeIdentifier())); diff --git a/src/main/java/frc/robot/commands/GroundIntakeElevatorCommand.java b/src/main/java/frc/robot/commands/GroundIntakeElevatorCommand.java index f281bd4..f84e59f 100644 --- a/src/main/java/frc/robot/commands/GroundIntakeElevatorCommand.java +++ b/src/main/java/frc/robot/commands/GroundIntakeElevatorCommand.java @@ -1,29 +1,28 @@ package frc.robot.commands; -import java.util.function.BooleanSupplier; - import edu.wpi.first.wpilibj2.command.CommandBase; import frc.robot.Constants; import frc.robot.subsystems.ElevatorSubsystem; +import java.util.function.BooleanSupplier; public class GroundIntakeElevatorCommand extends CommandBase { - private ElevatorSubsystem elevatorSubsystem; - private BooleanSupplier isCube; + private ElevatorSubsystem elevatorSubsystem; + private BooleanSupplier isCube; - public GroundIntakeElevatorCommand(ElevatorSubsystem elevatorSubsystem, BooleanSupplier isCube) { - this.elevatorSubsystem = elevatorSubsystem; - this.isCube = isCube; + public GroundIntakeElevatorCommand(ElevatorSubsystem elevatorSubsystem, BooleanSupplier isCube) { + this.elevatorSubsystem = elevatorSubsystem; + this.isCube = isCube; - addRequirements(this.elevatorSubsystem); - } + addRequirements(this.elevatorSubsystem); + } - @Override - public void execute() { - if(isCube.getAsBoolean()) { - elevatorSubsystem.setTargetState(Constants.Elevator.Setpoints.GROUND_INTAKE_CUBE); - } else { - elevatorSubsystem.setTargetState(Constants.Elevator.Setpoints.GROUND_INTAKE_CONE); - } + @Override + public void execute() { + if (isCube.getAsBoolean()) { + elevatorSubsystem.setTargetState(Constants.Elevator.Setpoints.GROUND_INTAKE_CUBE); + } else { + elevatorSubsystem.setTargetState(Constants.Elevator.Setpoints.GROUND_INTAKE_CONE); } + } } diff --git a/src/main/java/frc/robot/commands/GroundPickupCommand.java b/src/main/java/frc/robot/commands/GroundPickupCommand.java index 42f3ef7..873782b 100644 --- a/src/main/java/frc/robot/commands/GroundPickupCommand.java +++ b/src/main/java/frc/robot/commands/GroundPickupCommand.java @@ -4,15 +4,12 @@ package frc.robot.commands; -import edu.wpi.first.wpilibj2.command.Command; import edu.wpi.first.wpilibj2.command.SequentialCommandGroup; import frc.robot.Constants.Elevator; import frc.robot.subsystems.ElevatorSubsystem; -import frc.robot.subsystems.ElevatorSubsystem.ElevatorState; import frc.robot.subsystems.IntakeSubsystem; import frc.robot.subsystems.IntakeSubsystem.Modes; import java.util.function.BooleanSupplier; -import java.util.function.Supplier; // NOTE: Consider using this command inline, rather than writing a subclass. For more // information, see: