Skip to content

Commit

Permalink
Renamed IntakeGamepieces enum to IntakeGamepiece
Browse files Browse the repository at this point in the history
  • Loading branch information
IanTapply22 committed Dec 19, 2023
1 parent 5316ff9 commit 56661d3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions src/main/java/frc/robot/subsystems/intake/IntakeSubsystem.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import edu.wpi.first.wpilibj2.command.Command;
import edu.wpi.first.wpilibj2.command.Commands;
import edu.wpi.first.wpilibj2.command.SubsystemBase;
import frc.robot.subsystems.intake.enums.IntakeGamepieces;
import frc.robot.subsystems.intake.enums.IntakeGamepiece;
import frc.robot.subsystems.intake.states.ScoringState;

/**
Expand Down Expand Up @@ -56,7 +56,7 @@ public Command stopIntakeCommand() {
* @param expectedPiece the type of gamepiece to expect when scoring
* @return a command that scores a gamepiece
*/
public Command intakeScoreCommand(ScoringState scoringState, IntakeGamepieces expectedGamepiece) {
public Command intakeScoreCommand(ScoringState scoringState, IntakeGamepiece expectedGamepiece) {
SmartDashboard.putString("INTAKE STATE", scoringState.getStateName());

return run(() -> {
Expand All @@ -74,7 +74,7 @@ public Command intakeScoreCommand(ScoringState scoringState, IntakeGamepieces ex
* @param gamepiece the type of gamepiece to expect
* @return a command that forces the intake to hold the specified gamepiece
*/
public Command intakeHoldCommand(IntakeGamepieces gamepiece) {
public Command intakeHoldCommand(IntakeGamepiece gamepiece) {
return run(() -> {
this.intakeMotor.set(IntakeConstants.INTAKING_SPEED);

Expand All @@ -85,12 +85,12 @@ public Command intakeHoldCommand(IntakeGamepieces gamepiece) {
this.pdp.getCurrent(IntakeConstants.INTAKE_MOTOR_CHANNEL)
< IntakeConstants.INTAKE_AMP_THRESHOLD);

if (gamepiece.equals(IntakeGamepieces.CUBE)) {
if (gamepiece.equals(IntakeGamepiece.CUBE)) {
// wait a short amount of time so the gamepiece gets pulled in
Commands.waitSeconds(IntakeConstants.INTAKE_CUBE_DELAY);
this.intakeMotor.set(IntakeConstants.HOLD_CUBE_SPEED);
}
if (gamepiece.equals(IntakeGamepieces.CONE)) {
if (gamepiece.equals(IntakeGamepiece.CONE)) {
// we have a cone, so run the motor at a higher speed
Commands.waitSeconds(IntakeConstants.INTAKE_CONE_DELAY);
this.intakeMotor.set(IntakeConstants.HOLD_CONE_SPEED);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package frc.robot.subsystems.intake.enums;

public enum IntakeGamepieces {
public enum IntakeGamepiece {
CONE,
CUBE
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package frc.robot.subsystems.intake.states;

import frc.robot.subsystems.intake.enums.IntakeGamepieces;
import frc.robot.subsystems.intake.enums.IntakeGamepiece;

public abstract class ScoringState {
double outtakeSpeed;
Expand Down Expand Up @@ -48,7 +48,7 @@ public String getStateName() {
*
* @return The outtake speed for the scoring state
*/
public double getOuttakeSpeed(IntakeGamepieces expectedGamepiece) {
public double getOuttakeSpeed(IntakeGamepiece expectedGamepiece) {
if (expectedGamepiece == null) {
return this.outtakeSpeed;
}
Expand Down

0 comments on commit 56661d3

Please sign in to comment.