Editing a Block
In this activity, you will customize the story by changing the words reported by one of the random
reporter blocks.
Some blocks are built into Snap! and can't be changed, but Snap! programmers (including you!) can also make and edit their own custom blocks. The random
blocks in this project are custom blocks that you can edit.
- If your project isn't open already, open your "Super Short Stories" project by choosing "Open" from the Snap! File menu (
).
-
Choose one of the
random
blocks (random job
, random action
, or random animal
), right-click it (or control-click it, if you're on a Mac), and select "edit…" from the menu that appears. This will open the "Block Editor."
In the "Block Editor," you can see that this custom block called random job
reports a random item from a list of jobs.
-
Customize the block by changing some of the items in the list. (That is, change some of the jobs to other jobs, some of the actions to other actions, or some of the places to other places, etc.)
Tip: You can also add more items to the list or reduce the number of items in the list by clicking the arrows at the end of the list block (◄ ►).
-
When you are finished editing, click the "OK" button, and click the block that you edited several times to make sure that it reports a random item from the list you edited.
Tip: If it doesn't work right, edit the block again and also edit another one of the random
blocks at the same time. Compare the code for your edited random
block that isn't working to the code from the random
block that is working.
- Once you have revised
random
block that works, try it out in your super short story
block.

- Edit another
random
block to customize the story further.
In this activity, you edited a list inside a custom block.