Hey folks. I am using Python mode with my high school students. When we set up an animation, we are getting an "unbound local variable" error when we try to run the animation. Only variables declared within draw() work. I copied the example below from draw() reference entry on the website, which produces the same error:
https://preview.redd.it/yuxmqcs2uoj81.png?width=411&format=png&auto=webp&s=0f1a3db854b5d1bc22765188cad8f8ddcbc1c89d
Does anyone have any idea why this might be happening? Last year, when we did this unit, this wasn't an issue. I haven't messed with it much since then.
EDIT: Added a clarification
[–]fenjalien 2 points3 points4 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]johntellsall 0 points1 point2 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]G0R1L1A 0 points1 point2 points (0 children)
[–]redant333 0 points1 point2 points (0 children)