Goal: Find out the answer to your question.
Vocabulary: setsh (setshape), pick
setsh pick [sure! of_course! please_ask_later totally! nope yes! no no_way right_on duh!]
- Setsh means "set shape" and tells the turtle to set its shape to the name that follows. Pick means, "Choose a word at random from the list in brackets." In the tell_me procedure, the words in the list are the names of shapes in the shapes center. The computer picks one name at random and sets the turtle's shape to that name.
- Make your own magic 8-ball shapes and messages, and use these shape names inside the brackets. Here's how:
- Draw a black circle with an off-white triangle inside. Use off-white, such as color 30, because white (color 0) is transparent when we use it in shapes. Select, copy, and paste your empty 8-ball into a shape.
- Make a text box and set the text color to pink. Type one of the answers. Make your text box transparent, drag it over the triangle, and stamp it. Select, copy, and paste this 8-ball into a new shape. Give it the same name as your answer, but don't put any spaces in the name.
- Make eight or more 8-ball messages by placing new messages into the triangle, stamping them onto empty 8-balls, and saving the balls as shapes.
Try putting more names or fewer names inside the brackets. Does the procedure still work?
Change the shapes and the procedure so that different messages are given on the magic 8-ball.
On Your Own - Project Ideas
Can you make the 8-ball jiggle before it gives an answer?