So recently when my team has been coding autons, everytime we run the code it just skips a part of a code and just continues to another random point in the code like it just stops at the same point for like 3 seconds and then does some other random code part. ( we are using block code but we also tried converting it to c++ and python and it still doesn’t work and we are using when auton then wait (amount of seconds and then a string of code) we have a bunch of strings like that where it starts with the wait and we just space them apart. Does anyone know what to do?
I don’t know a definite reason for this but I recommend you read through your code one line at a time. Read it like a computer would. Compare it to other code that you know works (maybe from another team you know). If the spot it stops at is the same every time, try removing that and see if it fixes the issue (of course this doesn’t solve your problem but it identifies the source of it). Once you know the source, it is much easier to figure out a solution.
If you have a screenshot of the code that is giving you troubles it may be useful for myself (and anyone else that may try to help) in diagnosing the issue.
Also consider what the bot is doing. For example, if you set a lift to rotate x degrees but it hits the ground before finishing that x degrees, it will never move onto the next part of auton (this doesn’t seem to be your issue though since yours continues to a random spot in the code). I had this exact issue (being the one I mentioned not your issue) and couldn’t figure it out because I was too focused on what in the code was wrong while the problem was actually with the hardware.
If you send me your code I will look at it.
DM/PM is best… I don’t come here every day.
Hey when I try to upload the code it says new user can’t upload files so please add me on discord, (Omelette001#001) then I can send it to you. Thank You
Just copy the code and paste it in wherever you’re trying to send it on the forum and put ``` on both sides of the code
Unless it’s got super secret stuff in there, you can just post it in the thread,
tried discord
failed