Tentative fix for robot/runBlocking problem as per issue #2 added to competition code
This commit is contained in:
@ -107,6 +107,7 @@ public class CometBotTeleopCompetition {
|
||||
public void toHighBucketScore() {
|
||||
if (this.currentGP2.triangle && !this.previousGP2.triangle) {
|
||||
if (this.arm.getState() == ArmActionsSubsystem.ArmState.PARK) {
|
||||
this.follower.breakFollowing();
|
||||
fieldStates.setFieldLocation(FieldStates.FieldLocation.BUCKET);
|
||||
Actions.runBlocking(new SequentialAction(
|
||||
this.lift.toHighBucketPosition(),
|
||||
@ -123,6 +124,7 @@ public class CometBotTeleopCompetition {
|
||||
this.lift.toFloorPosition()
|
||||
));
|
||||
fieldStates.setFieldLocation(FieldStates.FieldLocation.TRAVELING);
|
||||
this.follower.startTeleopDrive();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -140,6 +142,7 @@ public class CometBotTeleopCompetition {
|
||||
public void toLowBucketScore() {
|
||||
if (this.currentGP2.circle && !this.previousGP2.circle) {
|
||||
if (this.arm.getState() == ArmActionsSubsystem.ArmState.PARK) {
|
||||
this.follower.breakFollowing();
|
||||
fieldStates.setFieldLocation(FieldStates.FieldLocation.BUCKET);
|
||||
Actions.runBlocking(new SequentialAction(
|
||||
this.lift.toLowBucketPosition(),
|
||||
@ -156,6 +159,7 @@ public class CometBotTeleopCompetition {
|
||||
this.lift.toFloorPosition()
|
||||
));
|
||||
fieldStates.setFieldLocation(FieldStates.FieldLocation.TRAVELING);
|
||||
this.follower.startTeleopDrive();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user