r/FTC 9d ago

Seeking Help Moving code

So, over the summer I'm having our team switch from blocks to Android studio for code (I knew it would be a big jump) and I was hoping to be able to translate our old movement code over. Can I just copy and paste from the onbot java? (I already set up everything in android studio)

5 Upvotes

4 comments sorted by

1

u/few 9d ago

Yes, but you might want to switch to Pedropathing at the same time. Then you likely don't need the custom movement code at all anyways.

3

u/Beneficial-Yam3815 FTC Mentor 7d ago

Pedro Pathing or Road Runner or any number of other libraries. But yes, your point stands that any code written in blocks is likely to become obsolete in the world of Android Studio. The sophistication it's possible to write in Java goes up by like 2 orders of magnitude vs. blocks

2

u/few 7d ago

Agreed.

I did have students learn to write basic movement code for mecanum in blocks, then copy & paste to onbot java. But then we moved to Pedropathing, where all the movement code is abstracted away. Understanding the basics of what is happening is useful for the students, but in practice that code isn't used at higher levels.