Commit | Line | Data |
---|---|---|
f11ce98e KZ |
1 | package org.usfirst.frc3501.RiceCatRobot.commands; |
2 | ||
4b8a525f | 3 | import org.usfirst.frc3501.RiceCatRobot.robot.Robot; |
f11ce98e KZ |
4 | |
5 | import edu.wpi.first.wpilibj.command.Command; | |
6 | ||
7 | /** | |
8 | * | |
9 | */ | |
10 | public class ToggleClaw extends Command { | |
11 | ||
12 | public ToggleClaw() { | |
13 | ||
14 | } | |
15 | ||
16 | protected void initialize() { | |
17 | Robot.claw.toggleOn = !Robot.claw.toggleOn; | |
18 | } | |
19 | ||
20 | protected void execute() { | |
21 | if (Robot.claw.toggleOn && Robot.claw.isOpen()) { | |
22 | Robot.claw.closeClaw(); | |
23 | } | |
24 | } | |
25 | ||
26 | protected boolean isFinished() { | |
27 | return true; | |
28 | } | |
29 | ||
30 | protected void end() { | |
31 | ||
32 | } | |
33 | ||
34 | protected void interrupted() { | |
35 | } | |
36 | } |