Commit | Line | Data |
---|---|---|
071ab315 KZ |
1 | package org.usfirst.frc.team3501.robot.commands.shooter; |
2 | ||
fee6b62e | 3 | import org.usfirst.frc.team3501.robot.Constants; |
071ab315 KZ |
4 | import org.usfirst.frc.team3501.robot.Robot; |
5 | ||
6 | import edu.wpi.first.wpilibj.command.Command; | |
7 | ||
3082b809 ME |
8 | /*** |
9 | * | |
10 | * This command will retract the catapult pistons. | |
11 | * | |
12 | */ | |
e4fbab02 HD |
13 | public class ResetCatapult extends Command { |
14 | ||
15 | public ResetCatapult() { | |
16 | requires(Robot.shooter); | |
17 | } | |
071ab315 KZ |
18 | |
19 | @Override | |
20 | protected void initialize() { | |
fee6b62e ME |
21 | if (Robot.shooter.getCatapult1State() == Constants.Shooter.SHOOT |
22 | || Robot.shooter.getCatapult2State() == Constants.Shooter.SHOOT) | |
23 | Robot.shooter.resetCatapult(); | |
071ab315 KZ |
24 | } |
25 | ||
26 | @Override | |
27 | protected void execute() { | |
28 | ||
29 | } | |
30 | ||
31 | @Override | |
32 | protected boolean isFinished() { | |
33 | return true; | |
34 | } | |
35 | ||
36 | @Override | |
37 | protected void end() { | |
90cf1657 | 38 | |
071ab315 KZ |
39 | } |
40 | ||
41 | @Override | |
42 | protected void interrupted() { | |
43 | ||
44 | } | |
45 | ||
46 | } |