Lesson 9 Sprite Movement - Watch_Me

#1

I am having trouble understanding and using the Watch_Me variable introduced in Lesson 9. I am teaching the lesson in 2 days, and I worked through all the bubbles myself this weekend.

In bubble 9, Debugging with Watchers, the var “watch_me” is introduced, but I cannot find it in the toolbox.

In bubble 15, students are encouraged to add watchers to help debug their program, but I don’t see where watchers can found or exactly how to use them. I see the “Watch” area of the Debug Console and I can add Variable/Property, but when I do add “sprite x” (which is in my program) it says “<not available”.

Can anyone offer any assistance? (This is my first time ever doing coding so everything is new to me.)
Thank you.

#2

Adding variables to the Watch is a very effective debugging tool. The Watch is located on your debug console. It is explained well on this tab.

See image and the part identified as (3)
Sometimes the Debug Console is collapsed to the bottom. Click and drag the bar up to make more of the Debug Console visible.
Here is an example where I added the new sprite’s x and y to the Watch.

Hope this helps.

3 Likes
#3

Thank you. I see in your code that you didn’t put the var watch_me. I thought that was needed based on the image above (bubble 9). Also I didn’t realize that I needed to type in the actual sprite’s name in the Watch box. I just went by the suggestions. Once I typed in the sprite names for the two I wanted to watch, they worked.

1 Like
#4

You are welcome. Glad it worked. Using the debug console does not come naturally to students. Model it a few times and also add it as a “go to” before they ask you for help.

2 Likes