Level 4

Graphic Effects

Level 4 · Chapter 3

What this lesson follows

CSTA K–12 Computer Science Standards (2017)

Algorithms & Programming · Grades 6–8

Combine loops and conditions, even nested ones.

Code 2-AP-12Read the official text

Common Core State Standards for Mathematics

Number & Operations — Fractions · Grade 5

Add fractions by making same-size parts.

Code 5.NF.A.1Read the official text

The short lines are our own words. We matched this lesson to these standards ourselves; the standards' owners have not reviewed or endorsed this course.

Common Core State Standards © 2010 National Governors Association Center for Best Practices and Council of Chief State School Officers. All rights reserved.

Today you will apply visual effects to sprites like color, ghost, and pixelate.

1👋 Warm-Up

For teachers · goals · guide
Lesson Outcomes · for teachersCSTA 2
✦ CSTA 2-AP-12 · ISTE 1.5.c · Standards
🎯 I canapply visual effects to sprites like color, ghost, and pixelate
🧩 New blocks1 block
📝 New words7 words
⏱ Lesson time~35 min
Teacher Guide

📋 Before class

⚠️ Common misconceptions

  • Students confuse 'set effect to' and 'change effect by' — set replaces the current value, change adds to it. Using set inside a loop does NOT animate unless the number also changes.
  • Students think ghost effect goes from 0 (hidden) to 100 (visible). The opposite is true: ghost 0 = fully visible, ghost 100 = fully hidden.
  • Students expect clear graphic effects to undo only the last effect they set. It removes ALL effects from the sprite at once.

🎯 Differentiation

🐢 Struggling: Start with only ghost effect. Use a single change ghost effect by (10) block inside a forever loop so students see the value increment clearly on screen.

🚀 Advanced: Combine two effects simultaneously (color cycling AND ghost pulsing) using two forever loops. Explore which effects interact visually.

💡 During the lesson

  • Warm-UpOptional: if the class is together, open Scratch and live-demo each of the 7 effects by dragging "set [color] effect to 50" into the editor and changing the dropdown. Let students call out "whoa!" or describe what they see. This front-loads curiosity. Keep it under 90 seconds — just a taste, not a full explanation. A set … effect to block uses an absolute 🎯 value — an exact number, not a change from the current one.
  • Try ItDraw the scale on the board: ghost 0 = solid, ghost 100 = hidden. Students almost always predict the opposite. After drawing the scale, run "set ghost to 100" to confirm. Then run "clear graphic effects" to show the reset. Emphasize: clear removes ALL effects, not just ghost.
    The third experiment is the key one: set ghost to 50 runs once before the loop, so Pico stays half see-through the whole time while the color keeps changing — the loop never touches ghost. In the second experiment, a bigger change number makes the colors jump faster. This concept (a value set before the loop stays until something changes it) is fundamental to loop-based animation.
  • PlanThe fade direction reverses by using two separate repeat 20 loops in sequence — there is no if block here. Ask: "How many times do we add 5 to go from 0 to 100?" (20). "How many times do we subtract 5 to go from 100 to 0?" (20). This arithmetic preview helps students choose the correct repeat count.
  • BuildAt step 7, the two repeat blocks must be sequentially inside forever, not nested inside each other. A common error is placing the second repeat inside the first. Check students' stacks visually — the indentation in Scratch shows nesting.