This commit is contained in:
scottbadger777
2021-08-12 19:01:03 -05:00
parent a647d6026a
commit b485f38d0b
3 changed files with 5 additions and 79 deletions

View File

@@ -17,16 +17,16 @@ public class dance extends CyberarmState {
@Override
public void exec() {
float rotation = robot.getIMURotation();
if (rotation <RotationLimit) {
powerWorks = -speed;
}else {
powerWorks = speed;
}
robot.driveBackRight.setPower(powerWorks);
robot.driveBackLeft.setPower(-powerWorks);
robot.driveFrontLeft.setPower(-powerWorks);
robot.driveFrontRight.setPower(powerWorks);
if (1 < rotation && rotation< 15){
powerWorks = 0;
}
}
}