Commit | Line | Data |
---|---|---|
6bb7f8ac | 1 | package org.usfirst.frc.team3501.robot.commands.auton; |
78d476cc | 2 | |
dd794a4e | 3 | import org.usfirst.frc.team3501.robot.Constants.Defense; |
6bb7f8ac | 4 | import org.usfirst.frc.team3501.robot.commands.shooter.Shoot; |
dd794a4e | 5 | |
78d476cc ME |
6 | import edu.wpi.first.wpilibj.command.CommandGroup; |
7 | ||
8 | /** | |
53d61b3e ME |
9 | * The default autonomous strategy involves passing the defense that is in front |
10 | * of it, aiming the robot/ shooter towards the goal, and shooting. | |
78d476cc | 11 | */ |
e4f7b3a7 | 12 | |
d607dcbb | 13 | public class DefaultAutonStrategy extends CommandGroup { |
ab237853 | 14 | |
dd794a4e | 15 | public DefaultAutonStrategy(int position, Defense defense) { |
78d476cc | 16 | |
53d61b3e | 17 | switch (defense) { |
ab237853 | 18 | |
dd794a4e | 19 | case PORTCULLIS: |
ab237853 | 20 | |
3c259ed2 | 21 | addSequential(new LiftPortcullis()); |
ab237853 | 22 | |
dd794a4e | 23 | case SALLY_PORT: |
ab237853 | 24 | |
86e1c4cc | 25 | addSequential(new PassSallyPort()); |
ab237853 | 26 | |
dd794a4e | 27 | case ROUGH_TERRAIN: |
3c259ed2 | 28 | |
d607dcbb | 29 | addSequential(new PassRoughTerrain()); |
3c259ed2 | 30 | |
dd794a4e | 31 | case LOW_BAR: |
3c259ed2 | 32 | |
d607dcbb | 33 | addSequential(new PassLowBar()); |
3c259ed2 | 34 | |
dd794a4e | 35 | case CHEVAL_DE_FRISE: |
3c259ed2 | 36 | |
af236b4e | 37 | addSequential(new PassChevalDeFrise()); |
3c259ed2 | 38 | |
dd794a4e | 39 | case DRAWBRIDGE: |
3c259ed2 | 40 | |
227fd1b1 | 41 | addSequential(new PassDrawBridge()); |
3c259ed2 | 42 | |
dd794a4e | 43 | case MOAT: |
3c259ed2 | 44 | |
d607dcbb | 45 | addSequential(new PassMoat()); |
3c259ed2 | 46 | |
dd794a4e | 47 | case ROCK_WALL: |
3c259ed2 | 48 | |
d607dcbb | 49 | addSequential(new PassRockWall()); |
3c259ed2 | 50 | |
dd794a4e | 51 | case RAMPART: |
3c259ed2 | 52 | |
d607dcbb | 53 | addSequential(new PassRampart()); |
3c259ed2 | 54 | |
dd794a4e ME |
55 | default: |
56 | break; | |
78d476cc | 57 | } |
53d61b3e | 58 | |
2c0fdbba | 59 | addSequential(new AimAndAlign()); |
a697f2ff | 60 | addSequential(new Shoot()); |
ab237853 | 61 | |
53d61b3e ME |
62 | } |
63 | ||
78d476cc | 64 | } |