Elementari

Cookie Clicker Game

Designed by:

Introduction

In this Hour of Code lesson, students will create a fun interactive Cookie Clicker game. They'll design a cookie that increases a counter when clicked, animate it with a bounce effect, and reward the player after reaching a target number of clicks.

Subjects:
Grades: 3-8
Estimated Time For Completion: 40

Objectives

Students will:

  • Design a simple interactive game using Elementari’s visual layout tools.
  • Use coding blocks to track and update a variable when an object is clicked.
  • Incorporate animation and sound to create engaging player feedback.
  • Apply basic logic to trigger events when specific conditions are met (e.g. reaching 10 clicks).

Code Stories and Games with Elementari

With Elementari, students bring their code to life through storytelling and interactive design. This project introduces core coding concepts like variables, events, and conditionals in a creative, game-based format that’s simple and fun for beginners.

New to Elementari? Click on the orange Start button to jump right into the lesson for free. Check out our Getting Started Guide for an overview of how Elementari works with your class. Get started for free for up to 35 student accounts.

Coding Concepts Covered

Functions in Sequence Increment Number Variable Conditionals

Student Instructions

1. Design Your Cookie Game Screen 🎨 (5 mins)

Choose a cookie image and a title text for your game screen.

2. Create and Display Your Cookie Counter 🍪 (10 mins)

Create and display a number variable to track the number of cookies.

3. Make the Cookie Clickable 👆 (10 mins)

Use the Increment Variable block to make the cookie image add 1 to the variable cookies each time it is clicked. Play a sound effect as well!

4. Challenge: Reward Every 10 Clicks 🌟 (10 mins)

Add logic to have the cookie bounce when players reach 10 cookies.

5. Make It Look Awesome 🎨 (5 mins)

Add a background and props!

Interactive Project Example for Students

Play through this lesson's example project created on Elementari. Use this example to guide and motivate your students.

Select Lessons or Create Your Own Lesson!