2D - SDG 12 - Recycling Quiz (Difficulty: 1)
-
Key Topics Covered
Introduction
The SDGs are 17 goals adopted by the United Nations in 2015. They are a to-do list for everyone to work on together.
This tutorial is about recycling, which is related to the 12th goal of “improving how we consume and produce”.
You will create a simple quiz for the player to choose whether an item should be recycled:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/ccc05310-a404-4190-b9d6-72ac811dcd2a.gif" width="500" style="border-radius: 5px; border: 1px solid #29622d;">
Step 1 - Remix a Template Project
First, please click this link to open the project template:
https://play.creaticode.com/projects/c6ff348d316b5d815fecd0f4
Click the “remix” button to make a remix project of your own. Note that you need to be signed in to do this.

This project contains 3 sprites. The Item sprite represents the waste item in question. It contains costumes for many common items. In this tutorial, we’ll only use the “Milk Jug” costume.
Step 2 - Move and Resize the Sprites
First, let’s move and resize the sprites to a better layout. For example, you can make the waste item larger, and place the 2 bins on the right with a smaller size.
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/104de983-4fab-4f81-8c2c-03fe31450021.gif" width="500" style="border-radius: 5px; border: 1px solid #29622d;">
Step 3 - Paint a new Sprite for Arrows
Next, let’s add another sprite to show 2 arrows from the waste item to the trash bins. You can add a new sprite with a blank costume using the “Paint” button on the bottom right:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/8aaf7599-599e-427e-b9e3-0da8c3095c96.gif" width="500" style="border-radius: 5px; border: 1px solid #29622d;">
In the costume editor of this new sprite, add a new arrow with a color you like, then rotate it to point upwards.https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/6f08f928-b6b6-4e1c-9098-bdd850c8a320.gif" width="1100" style="border-radius: 5px; border: 1px solid #29622d;">
Next, select this arrow, then make a copy of it. Place the new arrow below and point it downwards:https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/b2a0c5a2-2b89-4852-bf60-5245abb08887.gif" width="11000" style="border-radius: 5px; border: 1px solid #29622d;">
Step 4 - Add Text to the Trash Can Costume
When the player picks the trash can correctly, we need to show a big “Yes” over the trash can. The easiest way to do this is to add another costume with the word “Yes” over it. Please duplicate the trash can costume, and add the “Yes” text over it.
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/9d64700f-09b5-4868-857d-41aadf113819.gif" width="1000" style="border-radius: 5px; border: 1px solid #29622d;">
Similarly, please make another costume of the trash can with a big “NO”:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/7084a081-84fe-4e2a-94fd-1cb93435a59c.gif" width="1000" style="border-radius: 5px; border: 1px solid #29622d;">
Step 5 - Copy Text to Recycling Bin
We will also need the “YES” and “NO” versions of the recycling bin. You can duplicate the recycling bin 2 times, then copy the text from the trans can costumes.
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/93012e58-8ba6-4dc0-a71d-8a5a08bfd94b.gif" width="1100" style="border-radius: 5px; border: 1px solid #29622d;">
By now we have all the costumes we need, so it’s time to start adding code blocks.
Step 6 - Show the Trash Can with No Text
When the project starts to run, we should show the trash can with no text on it. You can add these 2 blocks to the trash can sprite:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/5afbf3bc-5fa2-48e7-b266-a61fbcf055da.gif" width="1100" style="border-radius: 5px; border: 1px solid #29622d;">
Step 7 - Switch to “NO” When Trash Can is Clicked
Since we are using the milk jug as our example, it should be recycled. So if the player picks the trash can, the answer is wrong. We can switch to the costume with “NO” on it when that happens. You should use these blocks in the trash can sprite:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/25dedb48-4e3a-438b-9e14-dc7f9e40866d.gif" width="1100" style="border-radius: 5px; border: 1px solid #29622d;">
Now our trash can sprite is working. It will start with no text, then switch to “NO” when we click on it:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/03a05eff-686c-43fb-a895-5da1db3e1aa4.gif" width="500" style="border-radius: 5px; border: 1px solid #29622d;">
Step 8 - Add Similar Code for Recycling Bin
Now please copy the 2 stacks of blocks to the recycling bin sprite, and make it say “YES” when clicked:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/bddc68b1-4760-49d3-9bc4-8965a655dde9.gif" width="1100" style="border-radius: 5px; border: 1px solid #29622d;">
Now our simple quiz project is complete. After the user clicks the green flag, he or she needs to pick the trash can or the recycling bin, and we will show the answer after that:
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/ccc05310-a404-4190-b9d6-72ac811dcd2a.gif" width="500" style="border-radius: 5px; border: 1px solid #29622d;">
Creative Ideas
There are many ways you can extend this project with your own creative ideas. Here are some examples:
-
Different Items: You can either select another item in the “item” sprite’s costume list, or add a new costume yourself. For your reference, this page contains many examples of things that are recyclable and not recyclable.
-
Smily Faces: Instead of showing “YES” or “NO”, you can also overlay a smiling or angry face over the trash can and recycling bin.
-
Multiple Levels: After the player has answered one question correctly, you can add 1 point to his score, and show another item. Keep going until he or she makes a wrong choice.
-
-
I CreatiCode pinned this topic on
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login