package org.usfirst.frc.team3501.robot.commands;
+import org.usfirst.frc.team3501.robot.Robot;
+
import edu.wpi.first.wpilibj.command.Command;
public class ExpelBall extends Command {
@Override
protected void initialize() {
-
+ if (Robot.photogate.isBallPresent())
+ Robot.intakeArm.outputBall();
}
@Override
protected void execute() {
-
}
@Override
protected boolean isFinished() {
- return true;
+ return !Robot.photogate.isBallPresent();
}
@Override