X-Git-Url: http://challenge-bot.com/repos/?p=3501%2F2017steamworks;a=blobdiff_plain;f=src%2Forg%2Fusfirst%2Ffrc%2Fteam3501%2Frobot%2Fcommands%2Fshooter%2FReverseIndexWheel.java;h=544a81533158ec247845a4fb5c81869d1938fa38;hp=4c745159b404f53c04a2a47c2866559aecd0fbb3;hb=decaa301e5f2ce46ae6cc8c4b1b18ce6fa5d2ab8;hpb=21477e1d2cef725ba4a34edd75b77a5e0a898985 diff --git a/src/org/usfirst/frc/team3501/robot/commands/shooter/ReverseIndexWheel.java b/src/org/usfirst/frc/team3501/robot/commands/shooter/ReverseIndexWheel.java index 4c74515..544a815 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/shooter/ReverseIndexWheel.java +++ b/src/org/usfirst/frc/team3501/robot/commands/shooter/ReverseIndexWheel.java @@ -2,7 +2,6 @@ package org.usfirst.frc.team3501.robot.commands.shooter; import org.usfirst.frc.team3501.robot.Robot; -import edu.wpi.first.wpilibj.Timer; import edu.wpi.first.wpilibj.command.Command; /** @@ -13,7 +12,6 @@ import edu.wpi.first.wpilibj.command.Command; */ public class ReverseIndexWheel extends Command { - Timer timer; private double time; private double motorVal; @@ -28,14 +26,12 @@ public class ReverseIndexWheel extends Command { public ReverseIndexWheel(double time, double motorVal) { requires(Robot.getDriveTrain()); - timer = new Timer(); this.time = time; this.motorVal = motorVal; } @Override protected void initialize() { - timer.start(); } @@ -47,7 +43,7 @@ public class ReverseIndexWheel extends Command { @Override protected boolean isFinished() { - return timer.get() >= time; + return timeSinceInitialized() >= time; } @Override