[commands] Add RepeatCommand (#4009)

Co-authored-by: Starlight220 <53231611+Starlight220@users.noreply.github.com>
This commit is contained in:
Excalibur FRC | 6738
2022-04-08 08:02:08 +03:00
committed by GitHub
parent 88222daa3d
commit 1b26e2d5da
8 changed files with 359 additions and 0 deletions

View File

@@ -11,6 +11,7 @@
#include "frc2/command/ParallelRaceGroup.h"
#include "frc2/command/PerpetualCommand.h"
#include "frc2/command/ProxyScheduleCommand.h"
#include "frc2/command/RepeatCommand.h"
#include "frc2/command/SequentialCommandGroup.h"
#include "frc2/command/WaitCommand.h"
#include "frc2/command/WaitUntilCommand.h"
@@ -87,6 +88,10 @@ PerpetualCommand Command::Perpetually() && {
return PerpetualCommand(std::move(*this).TransferOwnership());
}
RepeatCommand Command::Repeat() && {
return RepeatCommand(std::move(*this).TransferOwnership());
}
ProxyScheduleCommand Command::AsProxy() {
return ProxyScheduleCommand(this);
}