Ibnovate Course 1 · The Young Builders
⏱ 60 minLive session

Session 15 — Make Your First Game

Duration: 60 min · Format: live online

What you'll learn: by the end, you can open Scratch, add a sprite, and use key-press events to make it move and react on the stage.

Soft skill focus — Problem-solving

Today you'll also grow Problem-solving. Making a sprite move is really a stack of small problems — add a sprite, pick an event, snap on a motion block — solved one at a time.

Try this: when your sprite won't move, don't fix everything at once — ask yourself "what is the very next small thing that needs to happen?" (usually: snap the event to the motion block), then check just that one thing.

Think about: What was one small step you had to get right before your sprite would move?

What you'll need


Hook

Think about these questions:

Here's the big idea: today you become the boss of the game. You'll tell a character exactly what to do when you press a key — and you'll build it yourself in Scratch.


Teach — The stage, sprites, and blocks

Here are the parts of the Scratch screen:

Use this diagram to find your way around the Scratch screen — the blocks palette, the script area, and the stage:

Labelled diagram of the Scratch editor: on the left the blocks palette of coloured command blocks, in the middle the script area where blocks are snapped together, on the upper right the stage where the sprite acts, and below the stage the sprite list

Try it in Scratch: drag a move 10 steps block (blue, Motion) into the code area and click it. The cat scoots across the stage. Click it again — it keeps going.

⚠ Watch for the mix-up between "stage" and "sprite": it's easy to think the whole screen is the sprite. Remember: the cat is the sprite; the white area is the stage it stands on.

Quick question: if you want a second character in your game, what do you add — a new stage or a new sprite? (Answer: a new sprite.)


Teach — Events make things happen

A game has to wait for the player. In Scratch, the yellow Events blocks are the "listeners" — they wait for something to happen, then run the blocks under them.

Build this in Scratch:

Now add movement with events:

Key idea: an event block starts the action. Without an event, your blocks just sit there — nothing tells them when to run.

Try it: the change x by 10 block moves the cat right. What number would move it left? (Answer: a negative number, like -10.)


Activity

Now build it in your own Scratch project.

Build this, step by step:

  1. Keep the cat sprite (or click the sprite icon to pick a different one).
  2. Add when [right arrow] key pressedchange x by 10.
  3. Add when [left arrow] key pressedchange x by -10.
  4. Add when [up arrow] key pressedchange y by 10, and when [down arrow] key pressedchange y by -10.
  5. Add when [space] key pressedplay sound [Meow] (or any sound).
  6. Test all four arrows and the space bar.

If something's not working, check:

Tip: rename your project (top-left box) something like "My First Game."


Check yourself

Try these — answers are after the arrow.

  1. What is the difference between a sprite and the stage? → A sprite is a character or object; the stage is the background area where sprites live and the game happens.
  2. What kind of block do you need so a key press makes the cat move? → An event block, like when [right arrow] key pressed — it listens for the key, then runs the blocks under it.
  3. To move the cat left, do you use change x by 10 or change x by -10?change x by -10 — the negative number moves it left.

Wrap-up


Tips & extra challenges

Vocabulary

Term Meaning
Sprite A character or object that lives on the stage
Stage The background area where the game happens
Block A puzzle piece that gives a sprite an instruction
Event A block that waits for something (like a key press) then runs
Motion The blue blocks that move a sprite around

Resources

Practice set

Practise on your own. Answers are after the arrow.

  1. Add a sprite and make it move right when you press the right arrow key. → Use when [right arrow] key pressed snapped to change x by 10. Test by pressing the key.
  2. Make the same sprite move left, up, and down with the other three arrow keys. → Three more event blocks: left → change x by -10, up → change y by 10, down → change y by -10.
  3. Make your sprite play a sound when you press the space bar.when [space] key pressedplay sound [Meow] (or any sound from the Sound tab).
  4. Change the "10" to a bigger number, like 50. What happens? → The sprite jumps a bigger distance each press — it moves faster/further across the stage.
  5. Add a second sprite and give it its own key to move (for example, "d" to go right). → Click the sprite, add when [d] key pressedchange x by 10. Each sprite has its own blocks.
  6. Make your sprite say "Ouch!" when it reaches the edge — for now, just make it say "Ouch!" on a key press.when [key] pressedsay [Ouch!] for 1 seconds. (Real edge-detection comes in Session 17.)

Going deeper (optional)

Common mistakes & fixes

If it's not working, check these common mix-ups:

What's next

Session 16 — Score & Loops: you'll add a score with a variable, use forever loops to keep the game running, and send messages between sprites with broadcasts.

Ibnovate · Build · Innovate
Type to search · Esc to close
Welcome back
Sign in to continue building.
Accounts are created by Ibnovate — ask your instructor for your login.
🔒