separated each pass defense command (purely driving ones) into two, one based on...
[3501/stronghold-2016] / src / org / usfirst / frc / team3501 / robot / commands / auton / DefaultAutonStrategy.java
CommitLineData
6bb7f8ac 1package org.usfirst.frc.team3501.robot.commands.auton;
78d476cc 2
20cb908e 3import org.usfirst.frc.team3501.robot.Constants;
dd794a4e 4import org.usfirst.frc.team3501.robot.Constants.Defense;
6bb7f8ac 5import org.usfirst.frc.team3501.robot.commands.shooter.Shoot;
dd794a4e 6
78d476cc
ME
7import edu.wpi.first.wpilibj.command.CommandGroup;
8
9/**
53d61b3e
ME
10 * The default autonomous strategy involves passing the defense that is in front
11 * of it, aiming the robot/ shooter towards the goal, and shooting.
78d476cc 12 */
e4f7b3a7 13
d607dcbb 14public class DefaultAutonStrategy extends CommandGroup {
ab237853 15
dd794a4e 16 public DefaultAutonStrategy(int position, Defense defense) {
78d476cc 17
20cb908e 18 if (defense == Constants.Defense.PORTCULLIS)
3c259ed2 19 addSequential(new LiftPortcullis());
ab237853 20
20cb908e 21 else if (defense == Constants.Defense.SALLY_PORT)
86e1c4cc 22 addSequential(new PassSallyPort());
ab237853 23
20cb908e 24 else if (defense == Constants.Defense.ROUGH_TERRAIN)
5322db46 25 addSequential(new PassRoughTerrainTime());
3c259ed2 26
20cb908e 27 else if (defense == Constants.Defense.LOW_BAR)
5322db46 28 addSequential(new PassLowBarTime());
3c259ed2 29
20cb908e 30 else if (defense == Constants.Defense.CHEVAL_DE_FRISE)
af236b4e 31 addSequential(new PassChevalDeFrise());
3c259ed2 32
20cb908e 33 else if (defense == Constants.Defense.DRAWBRIDGE)
227fd1b1 34 addSequential(new PassDrawBridge());
3c259ed2 35
20cb908e 36 else if (defense == Constants.Defense.MOAT)
5322db46 37 addSequential(new PassMoatDistance());
3c259ed2 38
20cb908e 39 else if (defense == Constants.Defense.ROCK_WALL)
5322db46 40 addSequential(new PassRockWallDistance());
3c259ed2 41
20cb908e 42 else if (defense == Constants.Defense.RAMPART)
5322db46 43 addSequential(new PassRampartDistance());
3c259ed2 44
2c0fdbba 45 addSequential(new AimAndAlign());
a697f2ff 46 addSequential(new Shoot());
ab237853 47
53d61b3e
ME
48 }
49
78d476cc 50}