Step 5: Adding the Third Rating

Goal:


Let’s add the third rating when the power is between 120 and 160.

Steps:

  1. Select the “Sprite3” sprite
  2. From Events place a “when I receive” block
  3. Change the message to be “PumpkinSmashed!
  4. From Control place an if then block
  5. From Operators place an and block inside the if then block
  6. From Operators place a < (less than) block on the left side of the and block
  7. From Data place “Power:” on the left side of the < block
  8. Type in 160 on the right side of the < block
  9. From Operators place a > (greater than) block on the right side of the and block
  10. From Data place “Power:” on the left side of the > block
  11. Type in 120 on the right side of the > block
  12. From Looks place a show block inside the if then block

Code: