Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Scratch 1.4: Beginner's Guide

You're reading from   Scratch 1.4: Beginner's Guide Learn to program while creating interactive stories, games, and multimedia projects using Scratch

Arrow left icon
Product type Paperback
Published in Jul 2009
Publisher Packt
ISBN-13 9781847196767
Length 264 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Fortune-teller


Most of us enjoy a good circus, carnival, or county fair. There's fun, food, and fortunes. Aah, yes, what would a fair be without the fortune-teller's tent? By the end of the chapter, you'll know everything you need to spin your fortunes and amaze your friends with your wisdom.

Before we start the first exercise, create a new project and add two sprites. The first sprite will be the seeker. The second sprite will be the teller. Choose any sprites you want. My seeker will be a clam and my teller will be a snowman. If you want to add a background, go ahead.

Time for action – create a list of questions

In order to have a successful fortune-telling, we need two things: a question and an answer. Let's start by defining some questions and answers:

  1. Select the seeker from the list of sprites.

  2. From the Variables palette, click the Make a list button.

  3. In the list name dialog box, type questions and select For this sprite only.

  4. Click OK to create the list. Several new blocks display in the...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image