U1L1 Click Alonzo BJC bug

In BJC U1L1P4, the instructions end with #7 'if (ghost effect == 100) {clear graphic effect; stop all}' But midway up the same page, the students are instructed to 'change ghost effect by -5' every time a click is missed, so they very well might land in an unwinnable situation.

Since there is no >= operator built-in, and custom blocks are just about to be introduced in U1L2, I'm instructing my students to test 'if (ghost effect > 99)'.

In other contexts, this bug might be considered a teachable moment, but right out of the gate Unit 1 Lab 1 I think it would be better if the students were not instructed to code bugs.

I don't know if there's any editing process for BJC, but for new teachers, it would be helpful to be aware of this. At a minimum, I think this deserves a note in the teacher's guide

Good point. I tested this increasing by 5 when hit, so it was always a multiple of 5, and forgot that the instructions didn't specify how many percent to increase. I'll fix this tonight.

Hey thanks!

's my job. :~)

EDIT: Whew! It's actually not a problem. The effect values max out at 100; if you set it to 103 or 110 or whatever, and then read it with the reporter, you get 100.

Interesting. I could have sworn in testing I was getting to an invisible alonzo that I couldn't find to click

Oh, probably you were getting a 99% invisible Alonzo or something like that. As a refinement, someone might want to make it IF ((GHOST EFFECT) > 90) ... so it'll be easier to win while you can still see him.

Looks like you're right (of course); also the -5 doesn't go negative. However, I had alonzo say the ghost effect whenever he's clicked, and it's pretty common for him to say like 44.99999999999 or 55.0000000001. When does Snap! use ints vs floats?

Interesting. Did you use a non-integer increment or decrement? Or divide it by something? Otherwise I don't know why.

The only numbers around are 100, 25 and -5