smol change

This commit is contained in:
aarav18
2022-03-20 16:22:11 -06:00
parent f2c86c4888
commit da8fac3377
2 changed files with 17 additions and 11 deletions
+15 -10
View File
@@ -74,6 +74,7 @@ import frc4388.robot.commands.ClimberCommands.RunClimberPath;
// import frc4388.robot.commands.ButtonBoxCommands.TurretManual;
import frc4388.robot.commands.ExtenderIntakeCommands.ExtenderIntakeGroup;
import frc4388.robot.commands.ShooterCommands.AimToCenter;
import frc4388.robot.commands.ShooterCommands.Seek;
import frc4388.robot.commands.ShooterCommands.Shoot;
import frc4388.robot.commands.ShooterCommands.TrackTarget;
import frc4388.robot.commands.StorageCommands.ManageStorage;
@@ -283,18 +284,22 @@ public class RobotContainer {
// .whenReleased(new InstantCommand(() -> m_robotTurret.runTurretWithInput(0.0), m_robotTurret))
// .whenReleased(() -> m_robotSwerveDrive.stopModules());
new JoystickButton(getDriverController(), XboxController.Button.kX.value)
.whileHeld(new TrackTarget(m_robotTurret, m_robotBoomBoom, m_robotHood, m_robotVisionOdometry));
// .whenReleased(new InstantCommand(() -> m_robotTurret.runTurretWithInput(0.0), m_robotTurret))
// .whenReleased(new InstantCommand(() -> m_robotHood.runHood(0.0), m_robotHood))
// .whenReleased(new InstantCommand(() -> m_robotBoomBoom.runDrumShooter(0.0), m_robotBoomBoom));
/* Operator Buttons */
// .whenReleased(new InstantCommand(() -> m_robotTurret.runTurretWithInput(0.0), m_robotTurret))
// .whenReleased(new InstantCommand(() -> m_robotHood.runHood(0.0), m_robotHood))
// .whenReleased(new InstantCommand(() -> m_robotBoomBoom.runDrumShooter(0.0), m_robotBoomBoom));
/* Operator Buttons */
new JoystickButton(getOperatorController(), XboxController.Button.kY.value)
.whenPressed(new Shoot(m_robotSwerveDrive, m_robotBoomBoom, m_robotTurret, m_robotHood, m_robotVisionOdometry, false, false));
.whenPressed(new Shoot(m_robotSwerveDrive, m_robotBoomBoom, m_robotTurret, m_robotHood, m_robotVisionOdometry, false, false));
// new JoystickButton(getDriverController(), XboxController.Button.kX.value)
// .whileHeld(new TrackTarget(m_robotTurret, m_robotBoomBoom, m_robotHood, m_robotVisionOdometry));
// new JoystickButton(getOperatorController(), XboxController.Button.kY.value)
new JoystickButton(getOperatorController(), XboxController.Button.kB.value)
.whileHeld(new Seek(m_robotSwerveDrive, m_robotBoomBoom, m_robotTurret, m_robotHood, m_robotVisionOdometry));
// new JoystickButton(getOperatorController(), XboxController.Button.kY.value)
// .whileHeld(new RunCommand(() -> m_robotClaws.setOpen(true)));
// new JoystickButton(getOperatorController(), XboxController.Button.kB.value)
@@ -76,6 +76,7 @@ public class Shoot extends CommandBase {
this.drum = drum;
this.turret = turret;
this.hood = hood;
this.visionOdometry = visionOdometry;
this.toShoot = toShoot;
this.endsWithLimelight = endsWithLimelight;
@@ -188,7 +189,7 @@ public class Shoot extends CommandBase {
// ? should stop the turret and the swerve
////this.swerve.stopModules();
////this.turret.runTurretWithInput(0);
this.turret.runTurretWithInput(0.0);
if (this.toShoot) {
this.hood.runHood(0.0);