🏃♀️ Character Movement
Use arrow key controls with change x by
and change y by
for player-controlled characters.
This comprehensive reference covers every block in Scratch 3.0, organized by category with practical examples and common use cases. Perfect for quick lookups during project development!
Motion blocks control how sprites move and position themselves on the stage.
move (10) steps
move (-5) steps
moves 5 steps backwardturn ↻ (15) degrees
/ turn ↺ (15) degrees
turn ↻ (90) degrees
faces sprite to the rightpoint in direction (90)
point in direction (0)
makes sprite face uppoint towards (mouse-pointer ▼)
go to x:(0) y:(0)
go to x:(200) y:(100)
moves to upper right areago to (mouse-pointer ▼)
glide (1) secs to x:(0) y:(0)
glide (2) secs to x:(100) y:(50)
for smooth transitionschange x by (10)
/ change y by (10)
set x to (0)
/ set y to (0)
set y to (0)
keeps sprite on horizontal center lineif on edge, bounce
set rotation style (left-right only ▼)
x position
/ y position
if <(x position) > (200)> then
(if sprite is far right)direction
🏃♀️ Character Movement
Use arrow key controls with change x by
and change y by
for player-controlled characters.
⚽ Ball Physics
Combine move steps
, if on edge, bounce
, and turn degrees
for realistic ball movement.
🌟 Following Effects
Use point towards
and move steps
to create enemies that chase the player.
🎯 Precise Animations
Use glide
blocks for smooth, timed movements between specific positions.
Looks blocks control sprite appearance, visibility, and visual effects.
say [Hello!] for (2) seconds
say [Hello!]
think [Hmm...] for (2) seconds
/ think [Hmm...]
join
operator to combine text: say (join [Score: ] (score))
say (player_name) for (3) seconds
switch costume to (costume1 ▼)
next costume
switch backdrop to (backdrop1 ▼)
/ next backdrop
// Walking animationforever next costume wait (0.2) seconds
// Smooth costume cyclingrepeat until <(costume number) = (5)> next costume wait (0.1) seconds
change size by (10)
/ set size to (100) %
show
/ hide
go to (front ▼) layer
/ go (forward ▼) (1) layers
change [color ▼] effect by (25)
set [color ▼] effect to (50)
set [ghost ▼] effect to (50)
makes sprite 50% transparentclear graphic effects
🎭 Character Animation
Use costume changes with timing to create walking, running, or flying animations.
💬 Interactive Dialogue
Combine say blocks with ask blocks for conversation systems in stories and games.
✨ Special Effects
Use graphic effects for power-ups, damage indicators, or magical transformations.
🎬 Scene Management
Use backdrop changes and layer controls to create cinematic experiences.
Sound blocks add audio to your projects, from simple sound effects to complex musical compositions.
play sound (meow ▼) until done
start sound (meow ▼)
stop all sounds
Scratch includes categories of sounds:
play note (60) for (0.5) beats
rest for (0.5) beats
set instrument to (1) Piano
// Simple melodyset instrument to (1) Pianoplay note (60) for (1) beats // Cplay note (62) for (1) beats // Dplay note (64) for (1) beats // Eplay note (60) for (2) beats // C (longer)
// Drum beatset instrument to (9) Drumsrepeat (4) play note (36) for (0.5) beats // Kick drum rest for (0.5) beats
change volume by (-10)
/ set volume to (50)
change [pitch ▼] effect by (10)
/ set [pitch ▼] effect to (50)
clear sound effects
volume
// Fade out effectrepeat (10) change volume by (-10) wait (0.1) seconds
// Dynamic sound effectsif <(score) > (100)> then set [pitch ▼] effect to (20) // Victory sound higher pitchelse set [pitch ▼] effect to (-10) // Normal sound lower pitch
🎮 Game Audio
Layer background music, sound effects, and UI sounds for immersive gaming experiences.
🎵 Music Composition
Create original songs using note blocks and different instruments.
📚 Audio Stories
Add narration, character voices, and sound effects to interactive stories.
🔔 Feedback Systems
Use sounds to provide immediate feedback for user actions and game events.
Events blocks determine when scripts start running - they’re the triggers that make everything happen.
when green flag clicked
when this sprite clicked
when stage clicked
// Game initializationwhen green flag clickedset [score ▼] to (0)set [lives ▼] to (3)go to x:(0) y:(0)show
// Interactive spritewhen this sprite clickedsay [You clicked me!] for (2) secondschange [clicks ▼] by (1)
when [space ▼] key pressed
// Jump characterwhen [space ▼] key pressedif <touching (ground ▼)?> then change y by (50) play sound (jump ▼) until doneend
// Pause gamewhen [p ▼] key pressedif <(game_paused) = (0)> then set [game_paused ▼] to (1) say [PAUSED] for (9999) secondselse set [game_paused ▼] to (0) say [] // Clear pause messageend
broadcast (message1 ▼)
broadcast (message1 ▼) and wait
when I receive (message1 ▼)
// Game controller spritewhen green flag clickedwait (3) secondssay [Ready?] for (2) secondsbroadcast (start game ▼)
// Player spritewhen I receive (start game ▼)forever // Game controls here
// Coordinated animationwhen [enter ▼] key pressedbroadcast (dance party ▼) and waitsay [What a show!] for (3) seconds
// Multiple spriteswhen I receive (dance party ▼)repeat (10) turn ↻ (36) degrees wait (0.1) seconds
when [loudness ▼] > (10)
when [timer ▼] > (10)
when backdrop switches to (backdrop1 ▼)
// Voice-controlled spritewhen [loudness ▼] > (20)say [I heard you!] for (1) secondschange size by (10)wait (1) secondschange size by (-10)
// Timed level progressionwhen [timer ▼] > (60)say [Time for the next level!] for (2) secondsbroadcast (next level ▼)reset timer
when I start as a clone
// Clone initializationwhen I start as a clonego to (random position ▼)set [my speed ▼] to (pick random (1) to (5))show
forever move (my speed) steps if on edge, bounce
🎮 Game Controls
Map keyboard inputs to character actions for responsive game controls.
📡 Sprite Communication
Use broadcast messages to coordinate complex interactions between multiple sprites.
🎭 Interactive Experiences
Respond to clicks, voice, and other inputs for engaging user interactions.
⏰ Timed Events
Create automatic progressions, countdowns, and time-based gameplay elements.
when green flag clicked
→ forever
loopwhen [key] pressed
→ movement/actionif <touching [sprite]?> then
→ responserepeat
loop with next costume
and wait
This reference guide grows with your programming journey. Bookmark it and return whenever you need quick help with specific blocks or techniques! 📚✨