In this lesson we create a shopping list and choose which items to add to it. Then when we're finished what's on the shopping list gets read back out.
Create a new Scratch project and delete the cat sprite.
Go to the Scratch website using the link below and click on the 'Create' link in the blue bar at the top.
By default, each new project starts with the cat sprite already added. To delete the cat click on the x in the blue circle beside the cat in the sprite list.
Create a new list called 'shopping list', this will store the items on our shopping list.
When you create your first list you will notice that new blocks for lists become available to use in the Data palette.
At the start, when you click the green flag, we want the shopping list to be empty and also to be hidden (as we're going to get a character to read out what's on the list). Add the following code:
when green flag clicked
hide list [shopping v]
delete all of [shopping v]
The delete all of [shopping] block deletes all of the items that are in the shopping list. We do this at the start as there may be some items in the list from the previous game.
In the Variables palette, create a new variable by clicking the 'Make a List' button.
Once you click this button a box will appear asking what you want to call your list. Give it a name that reminds you what you will be using it for. For example, if you wanted to keep track of top scores in a game, you would create a list called 'top scores'.
Add the Room 1 backdrop from the backdrop library.
To add a backdrop from the backdrop library follow these steps:
You can use search box or the filter links (Fantasy, Music, Sports etc) to locate your backdrop.
Add some sprites from the sprite library that you would normally find in a shop such as a banana, an orange, a water melon etc.
Drag each sprite to the sides of the stage area.
To add a sprite from the sprite library follow these steps:
You can use search box or the filter links (Animals, People, Fantasy etc) to locate your sprite.
You're previewing this lesson. Get full access to this lesson and hundreds more — each one ready to teach, with interactive activities, printable resources and pupil progress tracking built in.