I just started using Okapi, and I am getting an error that I do not know how to fix.
The error is
src/Auttons/Blue_Other_V1.cpp:13:11: error: 'class std::shared_ptr<okapi::ChassisController>' has no member named 'moveDistance'
13 | drive.moveDistance(8_in);
| ^~~~~~~~~~~~
The full code for this part of my code is:
code
#include "main.h" // Include the PROS API
void Blue_Other_V1(void) {
std::shared_ptr<ChassisController> drive =
ChassisControllerBuilder()
.withMotors(
{ MleftWheelFront, -MleftWheelBack },
{ MrightWheelFront, -MrightWheelBack }
)
// Green gearset, 4 inch wheel diameter, 11.5 inch wheel track
.withDimensions(AbstractMotor::gearset::green, { {4_in, 11.5_in}, imev5GreenTPR })
.withOdometry() // Use the same scales as the chassis (above)
.buildOdometry();
drive.moveDistance(8_in);
}
Okapi.zip (14.4 MB)
How would I fix this problem? Thanks