From: niyatisriram Date: Wed, 17 Feb 2016 19:23:09 +0000 (-0800) Subject: Fix intake/expel ball methods by calling shooter subsystem instead of photogate class X-Git-Url: http://challenge-bot.com/repos/?p=3501%2Fstronghold-2016;a=commitdiff_plain;h=c908edf8d7cac59b5b94a77676de4c9c69425d78 Fix intake/expel ball methods by calling shooter subsystem instead of photogate class --- diff --git a/src/org/usfirst/frc/team3501/robot/commands/intakearm/ExpelBall.java b/src/org/usfirst/frc/team3501/robot/commands/intakearm/ExpelBall.java index 83ee34e6..04fa1268 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/intakearm/ExpelBall.java +++ b/src/org/usfirst/frc/team3501/robot/commands/intakearm/ExpelBall.java @@ -28,7 +28,7 @@ public class ExpelBall extends Command { @Override protected void initialize() { this.setTimeout(TIMEOUT_AMOUNT); - if (Robot.photogate.isBallPresent()) + if (Robot.shooter.isBallInside()) Robot.intakeArm.outputBall(); } @@ -38,7 +38,7 @@ public class ExpelBall extends Command { @Override protected boolean isFinished() { - return (this.isTimedOut() || !Robot.photogate.isBallPresent()); + return (this.isTimedOut() || !Robot.shooter.isBallInside()); } @Override diff --git a/src/org/usfirst/frc/team3501/robot/commands/intakearm/IntakeBall.java b/src/org/usfirst/frc/team3501/robot/commands/intakearm/IntakeBall.java index 8eda8dba..7966c614 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/intakearm/IntakeBall.java +++ b/src/org/usfirst/frc/team3501/robot/commands/intakearm/IntakeBall.java @@ -28,7 +28,7 @@ public class IntakeBall extends Command { @Override protected void initialize() { this.setTimeout(TIMEOUT_AMOUNT); - if (!Robot.photogate.isBallPresent()) + if (!Robot.shooter.isBallInside()) Robot.intakeArm.intakeBall(); } @@ -40,7 +40,7 @@ public class IntakeBall extends Command { @Override protected boolean isFinished() { - return (this.isTimedOut() || Robot.photogate.isBallPresent()); + return (this.isTimedOut() || Robot.shooter.isBallInside()); } @Override