Skip to content

Commit 45f81d2

Browse files
Kooolpoolkevinfrei
authored andcommitted
added opmodes for hoops because I got bored
1 parent ede598a commit 45f81d2

File tree

2 files changed

+43
-3
lines changed

2 files changed

+43
-3
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
package org.firstinspires.ftc.hoops.opmodes.tele;
2+
3+
import com.acmerobotics.dashboard.FtcDashboard;
4+
import com.acmerobotics.dashboard.telemetry.MultipleTelemetry;
5+
import com.qualcomm.robotcore.eventloop.opmode.TeleOp;
6+
import com.technototes.library.command.CommandScheduler;
7+
import com.technototes.library.structure.CommandOpMode;
8+
9+
import org.firstinspires.ftc.hoops.Hardware;
10+
import org.firstinspires.ftc.hoops.Robot;
11+
import org.firstinspires.ftc.hoops.Setup;
12+
import org.firstinspires.ftc.hoops.commands.EZCmd;
13+
14+
@TeleOp(name = "AllInOneTele")
15+
@SuppressWarnings("unused")
16+
public class AllInOneTele extends CommandOpMode {
17+
18+
public Robot robot;
19+
public org.firstinspires.ftc.hoops.controllers.AllinOneController Allcontrols;
20+
21+
public Hardware hardware;
22+
23+
@Override
24+
public void uponInit() {
25+
telemetry = new MultipleTelemetry(telemetry, FtcDashboard.getInstance().getTelemetry());
26+
hardware = new Hardware(hardwareMap);
27+
robot = new Robot(hardware);
28+
if (Setup.Connected.DRIVEBASE) {
29+
Allcontrols = new org.firstinspires.ftc.hoops.controllers.AllinOneController(
30+
driverGamepad,
31+
robot
32+
);
33+
34+
CommandScheduler.scheduleForState(
35+
EZCmd.Drive.ResetGyro(robot.drivebaseSubsystem),
36+
OpModeState.INIT
37+
);
38+
}
39+
}
40+
}

Hoops/src/main/java/org/firstinspires/ftc/hoops/controllers/TwoControllers.java renamed to Hoops/src/main/java/org/firstinspires/ftc/hoops/opmodes/tele/TwoControllers.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
package org.firstinspires.ftc.hoops.controllers;
1+
package org.firstinspires.ftc.hoops.opmodes.tele;
22

33
import com.acmerobotics.dashboard.FtcDashboard;
44
import com.acmerobotics.dashboard.telemetry.MultipleTelemetry;
55
import com.qualcomm.robotcore.eventloop.opmode.TeleOp;
66
import com.technototes.library.command.CommandScheduler;
77
import com.technototes.library.structure.CommandOpMode;
8-
import com.technototes.library.util.Alliance;
8+
99
import org.firstinspires.ftc.hoops.Hardware;
1010
import org.firstinspires.ftc.hoops.Robot;
1111
import org.firstinspires.ftc.hoops.Setup;
1212
import org.firstinspires.ftc.hoops.commands.EZCmd;
1313

14-
@TeleOp(name = "Driving w/Turbo!")
14+
@TeleOp(name = "TwoControllers")
1515
@SuppressWarnings("unused")
1616
public class TwoControllers extends CommandOpMode {
1717

0 commit comments

Comments
 (0)