Theory
🐱 9. Talk to Sprite!
Let’s learn how to use a variable to talk to our sprites. Abby would love to meet you!
Step1:
Select Abby from your sprite library.
Step2:
🚩 Start script with flag clicked event and ask “What’s your name?”
📝💬 Upon clicking flag, Abby prompts question, a text box appears for user input, and responses are stored as a variable in the answer sensing block.
Step3:
🗣️ Add a “say for 2 seconds” looks block, replacing “Hello” with your answer sensing block
📝💭 Practice by hovering & releasing the answer sensing block onto the text bubble; Run & type your input – Abby will repeat it back!
Step4:
🎉 Enhance with another “say for 2 seconds” block saying “is a great name!”
📝💬 Abby now compliments your name; Now, it’s your turn to customize & challenge yourself further! 🤖🔄