This commit is contained in:
2023-11-15 18:03:37 -05:00
parent 010d3d001d
commit 5d69880fcc
7 changed files with 13 additions and 13 deletions

View File

@@ -11,8 +11,9 @@ import frc.robot.subsystems.Lanceur;
public class Force2 extends CommandBase {
private Lanceur lanceur;
GenericEntry force2;
/** Creates a new Force1. */
public Force2(Lancer lancer) {
public Force2(Lanceur lanceur, GenericEntry force2) {
this.lanceur = lanceur;
addRequirements(lanceur);
this.force2 = force2;
@@ -28,7 +29,7 @@ public class Force2 extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
lanceur.lancer(500);
lanceur.lancer(force2.getDouble(0));
}
// Called once the command ends or is interrupted.