Hi, I’m trying to code my data with the following. However, the cata does not seem to stop at the bumper switch.
if (catabumper.get_value()){
cata.move(0);
}
else{
cata.move(-127);
}
if (master[ControllerDigital::R1].changedToPressed()){
shooter_time = pros::millis();
state = 1;
}
if (state == 1){
cata.move(-127);
if (pros::millis() - shooter_time > 300){
state = 0;
}
}