Hardware Reference
In-Depth Information
Scratch Command Quick Reference Table
Command
Description
Control Blocks
broadcast x
Sends a message to all the sprites and the stage which
can be used to synchronize scripts across multiple sprites
and the stage.
Repeatedly iterates actions within set.
forever
forever if
Checks whether a condition is true, over and over. If the
condition is true the program will run the blocks inside.
if…else
If the condition is true, the program will run the blocks
inside the if section. If not, it will run the blocks inside
the else section.
repeat x
Sets number of times for action to repeat.
Stops all scripts for all sprites.
stop all
Sets time before executing next command.
wait x secs
Begins script when green lag icon is clicked.
when
clicked
when I receive x
Begins script when a set broadcast message is heard.
Begins script when designated key is pressed.
When x key pressed
Motion Blocks
change x by _
Changes sprite's position on the stage x axis by a speci-
ied amount.
change y by _
Changes sprite's position on the stage y axis by a speci-
ied amount.
go to x:_ y:_
Moves sprite to set x and y coordinates on the stage.
Turns sprite in the opposite direction if it touches the edge
of the stage.
if on edge, bounce
Moves sprite forward or backwards x number of steps.
move x steps
point in direction x
Points sprite in direction x .
point towards x
Points sprite towards another sprite or a mouse cursor.
Sets sprite's position on the stage x axis to a designated
place.
set x to _
Sets sprite's position on the stage y axis to a designated
place.
set y to _
turn (clockwise) x
degrees
Rotates sprite clockwise x degrees.
turn (anti-clockwise) x
degrees
Rotates sprite anti-clockwise x degrees.
Looks Blocks
change size by x
Changes sprite's size by x amount.
hide
Hides a sprite from the stage.
next costume
Changes sprite's costume to the next costume in the list.
 
Search WWH ::




Custom Search