This commit is contained in:
2023-03-08 19:14:16 -05:00
parent 99ce225dc6
commit fc4607f3c6
7 changed files with 14 additions and 15 deletions

View File

@ -32,7 +32,7 @@ public class Apriltag extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw());
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw(), 0);
}
// Called once the command ends or is interrupted.

View File

@ -32,7 +32,7 @@ public class Cone extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw());
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw(), 0);
}
// Called once the command ends or is interrupted.

View File

@ -32,7 +32,7 @@ public class Cube extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw());
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw(), 0);
}
// Called once the command ends or is interrupted.

View File

@ -30,20 +30,20 @@ public class Gyro extends CommandBase {
public void execute() {
if(basePilotable.getpitch()>4)
{
basePilotable.drive(0.3*basePilotable.getpitch()/12, 0);
basePilotable.drive(0.3*basePilotable.getpitch()/12, 0, 0);
}
else if(basePilotable.getpitch()<-4)
{
basePilotable.drive(0.3*basePilotable.getpitch()/12, 0);
basePilotable.drive(0.3*basePilotable.getpitch()/15, 0);
basePilotable.drive(0.3*basePilotable.getpitch()/12, 0, 0);
basePilotable.drive(0.3*basePilotable.getpitch()/15, 0, 0);
}
else if(basePilotable.getpitch()<-4)
{
basePilotable.drive(0.3*basePilotable.getpitch()/15, 0);
basePilotable.drive(0.3*basePilotable.getpitch()/15, 0, 0);
}
else
{
basePilotable.drive(0, 0);
basePilotable.drive(0, 0, 0);
}
}

View File

@ -27,7 +27,7 @@ public class Reculer extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
basePilotable.drive(SmartDashboard.getNumber("vitesse auto", -0.3), 0);
basePilotable.drive(SmartDashboard.getNumber("vitesse auto", -0.3), 0, 0);
}
// Called once the command ends or is interrupted.

View File

@ -32,7 +32,7 @@ public class Tape extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw());
basePilotable.drive(doubleSupplier.getAsDouble(), limelight.getYaw(), 0);
}
// Called once the command ends or is interrupted.