Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sub avanzar(){
- OnFwd(OUT_C,50);
- OnFwd(OUT_B,40);
- }
- task main(){
- int x=1;
- SetSensorSound (IN_2);
- SetSensorLight (IN_3);
- SetSensorLowspeed (IN_4);
- while (TRUE){
- NumOut(5,5, SENSOR_3); //18-30
- if (x%2==1){
- Off(OUT_BC);
- OnFwd(OUT_C,50);
- }
- else if (x%2==0){
- Off(OUT_BC);
- OnFwd(OUT_B,40);
- }
- x++;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement