- Learnt27 min · keys as cues, and a front door
- Basic25 min · turn the video into a show
- Challenge 1–327 min · the keys, the title, the live set
- Extrabonus · two players, one keyboard
Review — where we got to 5 min
Last lesson the video got a running order.
- One sprite holds the plan and sends a cue for each section.
- Everybody else has a
when I receive [verse v]stack per section. - Each of those starts with
stop [other scripts in sprite v].
Quick-fire
Your director sends chorus after eight seconds. What else in Scratch could send exactly that same message?
Reveal the answer
Anything at all. A key press, a click on a sprite, another sprite. A message does not care who sent it, and that is the whole of today.
Today’s Topic 3 min
when [1 v] key pressedas a way to send a cue- A title screen: a name, instructions, and one button
when this sprite clickedto start the show- Saving, sharing, and writing instructions somebody else can follow
Learning outcome
By the end of this lesson you will be able to:
- Let a person call the sections of your video from the keyboard.
- Build a title screen that explains the show without you standing there.
- Save your project as a file and, if you have an account, share it.
Learnt — keys, a front door, and shipping it 27 min
1 · A key can send a cue
The dancers do not know or care where a message comes from. So a key press can send the same one the director sends.
when [1 v] key pressed
broadcast [verse v]
when [2 v] key pressed
broadcast [chorus v]
when [3 v] key pressed
broadcast [breakdown v]
Put these on the Microphone, beside the automatic running order. Now there are two ways to reach every section, and nothing else in the project had to change.
How to use this: Click the green flag, then click the stage once and press 1, 2 or 3 to change the section.
2 · A show needs a front door
Someone opening your project sees the stage mid-song and has no idea what to press. A title screen fixes that in three parts: a name, the instructions, and one thing to click.
- Add a backdrop for the title. Theater works, with the curtain down.
- Add a button sprite — a Bell, a Button, or something you draw.
- On the Stage, a
when flag clickedthat switches to the title backdrop. - On every dancer, hide on the flag and show when the section starts.
- On the button, a click stack that hides it and broadcasts the first section.
when flag clicked
go to x: (0) y: (-30)
show
when this sprite clicked
hide
broadcast [verse v]
The words on a title screen can be say bubbles, or a backdrop you paint in the editor. Both are fine at Level 1. What matters is that a stranger knows what to press.
How to use this: Click the green flag, then click the stage once and press 1, 2 or 3 to change the section. Click the bell on the stage to start the show.
3 · Shipping it
A project on your screen is not finished. A project somebody else can open and understand is.
- Give the project a real name, not
Untitled-4. - File → Save to your computer. That is an
.sb3file you can carry. - Close the tab, reopen Scratch, load the file and run it once.
- With a scratch.mit.edu account, press Share and fill in Instructions: which keys do what.
Basic — turn it into a show 25 min
Open your video. By the end of this it should be something you can hand to somebody.
How to use this: Click the green flag, then click the stage once and press 1, 2 or 3 to change the section. Click the bell on the stage to start the show.
Step 1 — the keys
- On the Microphone, add the three key hats.
- Each one broadcasts a section you already have.
- Play, click the Stage, and press 1, 2, 3 in any order.
Step 2 — take the timer out
- Delete the automatic running order, or drag it aside for now.
- Leave one
when flag clickedthat sets the stage up and stops. - Play. Nothing should happen until you press a key.
Step 3 — the title screen
- Add the Theater backdrop and switch to it on the flag.
- Hide every dancer on the flag.
- Add your button sprite and its two stacks.
Step 4 — bring the dancers back
- Add
showto the top of each dancer’s section stacks. - Click the button. Everybody should appear and start.
- Press the flag again. Back to the title screen, cleanly.
Step 5 — write the instructions
- Put the key list on the title screen, where the audience will see it.
- Leave it for five minutes, come back, and start it using only what is on the screen.
- Watch what they try first. That is your instructions being tested.
Step 6 — save it
- Name it, then File → Save to your computer.
- Reopen it from the file and run it once more.
My dancers never come back after the title screen.
They were hidden on the flag and nothing shows them again. Every section stack needs a show near the top.
The keys do nothing.
Click the Stage once. Scratch sends key presses to whatever was clicked last, and if that was a block in the code area, the Stage never hears them.
The show changes section on its own.
The old automatic director is still running. Delete it, or keep it and drop the keys — but not both at once.
Three keys, three sections
Give the audience the controls.
- Three keys, each calling a section you have already built.
- The change happens the instant the key goes down.
- Pressing the same key twice does not break anything.
A front door
Build a title screen for your show, for somebody who has never seen it — and that includes you, a month from now.
- The name of the show.
- Who made it.
- What the keys do.
- One thing to click, and nothing moving until they click it.
Teacher note — the silent handover
“Say nothing” is the whole assessment. Pupils always want to explain their project while somebody uses it, and the moment they cannot, every missing instruction becomes obvious to them without a word from you.
The live set
Make a version with no timer anywhere in it. Every single change comes from a person.
- No waits deciding when a section ends.
- A section carries on for as long as nobody presses anything.
- At least three sections, all reachable at any time.
- You can perform a two-minute set with it in front of the class.
How to use this: Click the green flag, then click the stage once and press 1, 2 or 3 to change the section.
Teacher reveal — what “no timer” really removes
Only the director’s waits go. The waits inside the sections stay — those are the beat, not the running order. Pupils who delete those too end up with dancers flickering thirty times a second, which is a useful thing to see once.
A second pair of hands
The space bar becomes a crash: hit it and the whole stage flashes and a cymbal sounds, over whatever section is running. One hand on 1, 2 and 3, the other on space — and it works just as well with a friend on the space bar if one is around.
How to use this: Click the green flag, click the stage once, then press 1, 2 or 3 to change the section and the space bar for the crash. Both are yours — one hand each.
- The space bar works in every section, without stopping it.
- The flash lasts a moment and puts itself back.
- Holding space down does not jam the show.
- You can drive both halves at once — one hand on the keys, the track running.
Teacher notes — the hit that must not stop the section
when [space v] key pressed
play sound [Cymbal Crash v]
change size by (30)
wait (0.2) seconds
change size by (-30)
Note there is no stop [other scripts in sprite v] here. This is a hit, not a section: it happens over the top of whatever is already running, and then puts the size back.
Holding the key repeats the hat, so the size can climb before it comes down. That is worth letting them find, and the fix — a set size to (120) % rather than a change — is the same “set, do not change” lesson as the pulse in Topic 1.17.
Going further: a real light rig flashes and fades. That is repeat (10) around change [brightness v] effect by (-5), and it is one block you have not met in a loop you have.
Summary 4 min
The video became a show, and it cost almost no new code.
- A key hat can send the same cue the director sends. Messages do not care who shouts them.
- A title screen is a name, instructions and one button.
- Anything hidden on the flag must be shown again by whatever starts it.
- A project is finished when somebody else can open it and use it.
- Live control
- A show driven by a person rather than a timer.
- Title screen
- What a stranger sees first. It says what this is and what to press.
- Instructions
- The words that make a project usable without you standing next to it.
- Sharing
- Putting the project on scratch.mit.edu so it has a link. The file works too.
Next lesson: a new arc, and a different kind of problem. A maze, with walls you cannot walk through.