My student’s code for isTouching() is correctly included but gives an error message:
Line 38 should run but is giving an error message as seen in the screenshot.
I compared the code to other students’ code and it is identical. I switched from block to text back to block to be sure it was written correctly. It switched from block to text to block and executed the same error each time. I made sure the sprites were correctly spelled in line 38 according to how they were initialized.
This student had a similar error when trying to use a different block in Lesson 17.9:
I was able to take a look at your two projects and there are two different things going on here.
In the first one, the student creates the coin and then calls the setCoin function (on line 5). The setCoin function refers to the bunny, but the bunny hasn’t been created yet. If they move the setCoin function below the creation of the bunny, it should work.
In the 2nd one, there is a typo on line 36 where the student tries to change the flyer from a sprite to a number. I think they meant it to read flyer.velocityY = flyer.velocityY + 0.4; (but the .velocityY is missing from the first variable).
Hope this helps, but if you still have questions, we are more than happy to look at it again.