Skip to content

Commit

Permalink
Update AutoGyro.java
Browse files Browse the repository at this point in the history
Fix for getting the class name of the path segments.
  • Loading branch information
rhsftc committed Nov 15, 2024
1 parent 5f1de9f commit 2ad273b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ public void runOpMode() {
// Step through each segment of each path.
for (ArrayList path : paths) {
for (Object segment : path) {
switch (segment.getClass().getName()) {
switch (segment.getClass().getSimpleName()) {
case "DriveStraight":
driveStraight(DRIVE_SPEED, ((DriveStraight) segment).distance, ((DriveStraight) segment).heading);
break;
Expand Down

0 comments on commit 2ad273b

Please sign in to comment.