Grade 6 Computer Science –
Chapter Notes: More About Scratch
What is Scratch?
• Scratch is a visual programming language that helps you create games,
animations, stories, and projects without typing long code.
• Instead of writing code, you use blocks that you snap together like puzzle pieces.
• Scratch is very popular among students and beginners around the world.
• It’s available in many languages, and projects are saved as files on your computer or
online account.
Types of Scratch Blocks (Based on Shape and Function)
1. Hat Blocks
• Shape: Rounded at the top, flat at the bottom.
• Purpose: These blocks start a script.
• No block can be placed above a Hat block.
• Example:
o when green flag clicked (Events)
o when this sprite clicked
Use: Think of Hat blocks as the beginning of a story or the “start button” for your
code.
2. Cap Blocks
• Shape: Flat at the bottom, no connection below.
• Purpose: These blocks are used to end a script or an action.
• Nothing can come after these blocks in the same sequence.
• Examples:
o stop all
o delete this clone
Use: Like the "The End" of your script.
3. Stack Blocks
• Shape: Flat on top and bump at the bottom to stack other blocks.
• Purpose: These blocks perform actions like moving, waiting, saying something,
changing size, etc.
• Examples:
o move 10 steps
o say "Hello!" for 2 seconds
o wait 1 seconds
Use: These are the action blocks in your program. You can stack many of them together!
4. Reporter Blocks
• Shape: Rounded like an oval or a capsule.
• Purpose: These blocks report a value (like a number or text).
• They fit inside other blocks where a value is needed.
• Examples:
o x position
o loudness
o length of [list]
Use: Think of them as answer blocks that give information.
5. Boolean Blocks
• Shape: Hexagonal (six-sided)
• Purpose: These blocks report True or False.
• Often used in conditions, like in “if” or “repeat until” blocks.
• Examples:
o touching mouse-pointer?
o key space pressed?
o loudness > 50
Use: Use these when you want to make decisions in your project.
6. Conditional Blocks
• Purpose: These blocks allow you to make decisions.
• You can run a set of blocks only if a certain condition is true.
• Some also have an “else” part to run when the condition is false.
• Examples:
o if [condition] then
o if [condition] then else
Use: Helps your Sprite choose what to do based on a situation.
7. Looping Blocks
• Purpose: Used to repeat actions several times or forever.
• Examples:
o repeat [10]
o forever
o repeat until [condition]
Use: Saves time by running the same code again and again.
Block Categories in Scratch
Each type of block belongs to a category and is color-coded.
Color Purpose Examples
Category
Motion Blue Moves Sprite move [ ] steps, turn [ ] degrees
Looks Purple Changes appearance say [ ], change size by [ ]
Sound Pink Plays sounds or play sound [meow] until done
music
Events Yellow Starts scripts when green flag clicked
Control Orange Controls script flow wait [ ] secs, repeat, if-then
Sensing Light Blue Detects inputs touching [ ]?, mouse x
Operators Green Math and logic +, -, <, =, and, or
Variables Dark Stores data set score to [0], change score
Orange by [1]
My Blocks Red Custom blocks define jump
Sprites and Stage
The Stage:
• The background where your project plays.
• You can change the backdrop by:
o Choosing one from the Backdrop Library
o Painting your own
o Uploading an image from your computer
o Taking a photo using your camera
Sprites:
• Characters or objects in your project.
• Each Sprite can:
o Move
o Speak
o Change costumes
o Interact with others
• You can change a Sprite’s costume by:
o Choosing from the library
o Drawing your own
o Uploading a picture
o Taking a photo using your webcam
Use the Looks blocks to:
• Change costumes
• Make Sprites speak
• Show/hide Sprites
• Add visual effects
🛠 Using Scratch Blocks Together
Here’s how to create a small program:
when green flag clicked
say "Hello!" for 2 seconds
move 10 steps
turn 15 degrees
This program makes the Sprite say “Hello!” and then move and turn.
"YOU ARE HERE" – Key Learnings:
• Combine move and turn blocks to make Sprites dance.
• Use say [ ] to show messages.
• Sprites can change costumes and appear to change clothes or shape.
• Backdrops help make projects look interesting.
• Use Conditional and Looping blocks to control what the Sprite does and how often it
happens.
EXERCISES
A. Fill in the blanks:
1. The Turn block is used to rotate the Sprite.
2. A Reporter block reports a value.
3. Control blocks are golden in colour and used to manage scripts.
4. A project is a file that contains blocks called scripts.
5. Any label with repeat or forever is a Looping block.
B. True or False:
1. The Backdrop of a project can be changed. – True
2. wait 1 secs makes the Sprite fly. – False
3. All movement blocks are in the Motion category. – True
C. Label the Scratch Interface
(Students label areas like Stage, Sprites Pane, Script Area, Blocks Palette, etc. using an
image in the book)
D. Answer in short:
1. Ways to change the Backdrop?
• Library
• Paint
• Upload
• Camera
2. Difference between Hat and Cap blocks?
• Hat: Starts a script, rounded top.
• Cap: Ends a script, flat bottom.
3. Two Control blocks:
• wait [ ] secs: Pauses the script.
• repeat [ ]: Repeats blocks a certain number of times.
4. Ways to change a Sprite’s costume:
• Library
• Paint
• Upload
• Camera
5. Explain Repeat block:
• The Repeat block repeats the blocks inside it for the number of times you choose.
LAB WORK
A. Create a dialogue between two Sprites
• Use say [ ] for [ ] secs blocks.
• Add wait [ ] secs to make the timing look natural.
• Use when green flag clicked to start the conversation.
Example:
when green flag clicked
Sprite1: say "Hi there!" for 2 secs
wait 2 secs
Sprite2: say "Hello! How are you?" for 2 secs
B. Change the Backdrop
1. Click on the Stage area.
2. Go to the Backdrops tab.
3. Choose a new backdrop using:
o Library
o Paint
o Upload
o Camera