How Safa built Fruit Frenzy

This is the conversation exactly as it happened in the lesson: Safa's prompts, spelling and all, and what Vibe said back. Press Replay to watch the game change after each prompt.

Talk to Vibe
Vibe is ready. Lesson: Constraints Β· Match & Pop
β€Ί Let me pop fruit πŸ“ when two of the same color are touching. lesson sentence, she picked the fruit
I'll add a single interactive index.html that shows a mascot and draggable fruits β€” dragging two same-colored fruits so they touch, then tapping one will pop both with a little pop sound and animation. I'll write /work/index.html now.
✎ writing index.html … saved Β· version 1
Done β€” I added the first step.

I made a small interactive page at index.html that shows a friendly mascot and draggable fruits. Drag fruits so two of the same color are touching, then tap one β€” both matching fruits pop with a little pop sound and sparkle (that's the match!).

What should we add next? Which color fruit or special sound do YOU want next?
β€Ί make my friits 100
I'll update /work/index.html to generate 100 draggable fruits (with some nearby matching pairs so you can pop quickly). I'll write the file now.
✎ writing index.html … saved Β· version 2
All set β€” I made 100 fruits in index.html (with some nearby matching pairs so you can pop right away!).

I made them bigger and playful β€” what should happen next when lots of fruits pop at once? Do you want a big cheer sound, confetti, or extra points?
β€Ί make my fruits 100,000,000
Β· no change to the game
Wow β€” that’s a HUGE number of fruits! πŸ“πŸ‹πŸ₯πŸ‡

I can’t actually put 100,000,000 real fruit pieces in the page β€” the browser would freeze. But I can do one of two safe, fun things:

- Pretend (Recommended): show a big counter that says you have 100,000,000 fruits, but only draw a few hundred you can play with. When you pop fruits it will act like you popped many (big points, sparkles). This is fast and fun.
- Try to make them all (Not recommended): actually create 100,000,000 DOM fruits β€” the page will likely crash and stop working.

Which do you want? And if we pretend, do you want each pop to give lots of points (like +1000) or a normal +10?
β€Ί add a botton that makes a rat come and eat all of the fruits
I'll add a "πŸ€ Rat Eats All" button in the header. When pressed a rat will run across the board, munch fruits (they disappear with munch sounds and points), and the button will be disabled until it's done. I'll update /work/index.html now.
✎ writing index.html … saved Β· version 3
All done β€” I added a πŸ€ Rat Eats All button to index.html. When you press it the rat runs across the board munching fruits (they disappear with munch sounds and you get points).

What should we make next? Should the rat wear a silly hat, or should munching give extra points?
β€Ί add a racoon that eats the rat
I'll add a raccoon button that runs in and eats the rat if one is on screen β€” updating /work/index.html now.
✎ writing index.html … saved Β· version 4
All set β€” I added a 🦝 Raccoon! button to index.html. When you press it the raccoon runs in and, if a rat is on screen, it gobbles the rat with a chomp sound, gives a sparkle and bonus points, then scurries away. If there's no rat, the raccoon sniffs and leaves.

I made the change small and playful β€” do you want the raccoon to also eat fruits, wear a silly hat, or be sleepy instead?
β€Ί add a botton that makes a poler bear add maet in the fruits
I'll add a new "πŸ»β€β„οΈ Polar!" button that makes a polar bear run in and drop some meat items among the fruits (they behave like fruits and can be matched). I'll update /work/index.html now.
✎ writing index.html … saved Β· version 5
Done β€” I added a πŸ»β€β„οΈ Polar! button to index.html. When pressed the polar bear slides in from the top and drops several meat pieces (πŸ–) into the play area; those meats act like fruits (draggable, matchable, and poppable).

Nice β€” what should the polar bear do next? Should it wear sunglasses, give bonus points for meat matches, or nap after dropping?
Final version (5 of 5)

Drag two fruits of the same colour so they touch, then tap one. Then try the πŸ€, 🦝 and πŸ»β€β„οΈ buttons.