competition fixes
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / commands / shooter / StopFlyWheel.java
index cbce00577b05d1b952d8cf4d0b1485f2e65c8b74..0d1bbe83cf212d0022ccba2f3a54091351b1b85e 100644 (file)
@@ -1,6 +1,7 @@
 package org.usfirst.frc.team3501.robot.commands.shooter;
 
 import org.usfirst.frc.team3501.robot.Robot;
+import org.usfirst.frc.team3501.robot.subsystems.Shooter;
 
 import edu.wpi.first.wpilibj.command.Command;
 
@@ -12,11 +13,13 @@ import edu.wpi.first.wpilibj.command.Command;
  * @author Shaina
  */
 public class StopFlyWheel extends Command {
+  private Shooter shooter = Robot.getShooter();
+
   /**
    * This command stops the fly wheel.
    */
   public StopFlyWheel() {
-
+    requires(shooter);
   }
 
   // Called just before this Command runs the first time
@@ -39,6 +42,7 @@ public class StopFlyWheel extends Command {
   // subsystems is scheduled to run
   @Override
   protected void interrupted() {
+    end();
   }
 
   @Override