انتقل للمحتوى
Robo EgyptRobo Egypt
☰ Course contents

We build the story

Section 9: The big project: an interactive storyLesson 9.2 · ⏱ 12 min
📌 Note
Add a character: tap ➕ next to the characters and pick one. Tap a character to code it: every character has its own blocks.
🧩 Robo and the cat: two programs each
🤖 RoboBlocks of 🤖 Robo
  1. When 🚩 is tapped
  2. Say 💬 “Where is the cat?”
  3. Move right ➡️ 11
  4. Send a yellow message ✉️
  5. When a green message arrives 📩
  6. Say 💬 “I found you! 🎉”
  7. Hop 🦘
🐱 CatBlocks of 🐱 Cat
  1. When 🚩 is tapped
  2. Hide 🙈
  3. When a yellow message arrives 📩
  4. Show 👀
  5. Say 💬 “I am up here!”
  6. Move down ⬇️ 6
  7. Hop 🦘
  8. Send a green message ✉️
Scene 1: Robo looks
Scene 1: Robo looks
Scene 2: the cat appeared up in the tree
Scene 2: the cat appeared up in the tree
Scene 3: Robo found her
Scene 3: Robo found her
🖥️ What happens on the stage?
We ran the story in Robo Junior: both messages arrived, the cat talked, and Robo said “I found you”.

📌 Another example: the cat up in the tree

Another hiding place: the cat is at the top, Robo climbs up to her, and when he bumps her he stops and is happy.

🧩 The cat up in the tree
🤖 RoboBlocks of 🤖 Robo
  1. When 🚩 is tapped
  2. Say 💬 “Where is the cat? 🤔”
  3. Move up ⬆️ 10
  4. When it bumps into a character 💥
  5. Stop my other programs ✋
  6. Say 💬 “I found you up there! 🎉”
🐱 CatBlocks of 🐱 Cat
  1. When it bumps into a character 💥
  2. Say 💬 “Oh, you found me!”
Robo looks
Robo looks
He found her
He found her
✍️ Practise
Build the story, then change it: another character, or another hiding place.
✍️ Practise here in the lessonor open the lab in a new page ↗

🎯 Challenge yourself

Easy

Swap the character: Robo looks for the dog, and the dog says “I am here! 🐶” when they bump.

👀 Show the solution
🧩 Solution
🤖 RoboBlocks of 🤖 Robo
  1. When 🚩 is tapped
  2. Say 💬 “Where is the dog?”
  3. Move right ➡️ 11
🐶 DogBlocks of 🐶 Dog
  1. When it bumps into a character 💥
  2. Say 💬 “I am here! 🐶”
The result on the stage
The result on the stage
Medium

The cat is hidden 🙈, and shows when Robo arrives and sends a message.

👀 Show the solution
🧩 Solution
🤖 RoboBlocks of 🤖 Robo
  1. When 🚩 is tapped
  2. Say 💬 “Where is the cat?”
  3. Move right ➡️ 12
  4. Send a pink message ✉️
🐱 CatBlocks of 🐱 Cat
  1. When 🚩 is tapped
  2. Hide 🙈
  3. When a pink message arrives 📩
  4. Show 👀
  5. Say 💬 “I was hiding! 🙈”
The cat appeared
The cat appeared
Hard

A hide-and-seek game with two hidden characters: each message shows one of them.

👀 Show the solution
🧩 Solution
🤖 RoboBlocks of 🤖 Robo
  1. When 🚩 is tapped
  2. Say 💬 “I will look for you both!”
  3. Move right ➡️ 5
  4. Send a pink message ✉️
  5. Wait ⏱ 2
  6. Move right ➡️ 5
  7. Send a yellow message ✉️
🐱 CatBlocks of 🐱 Cat
  1. When 🚩 is tapped
  2. Hide 🙈
  3. When a pink message arrives 📩
  4. Show 👀
  5. Say 💬 “You found me!”
🐶 DogBlocks of 🐶 Dog
  1. When 🚩 is tapped
  2. Hide 🙈
  3. When a yellow message arrives 📩
  4. Show 👀
  5. Say 💬 “And I'm here! 🐶”
He found both
He found both
Finished the lesson? Mark it so your progress counts.