Truth or Dare Game
Truth or Dare is a fun and interactive game created using Scratch. The game allows the player to choose between Truth and Dare and then generates a random question or challenge.
This project uses Scratch lists, variables, operators, conditions, loops, user input, and random numbers to make the game interactive. The player enters Truth or Dare, and the program responds accordingly. For Truth, it displays a random question from the Truth List. For Dare, it provides a random challenge from the Dare List.
Supplies
- Pictoblox Software: Download PictoBlox | Windows, MacOS, Linux, Chromebook, Android & iOS
- Laptop/PC
- Inbuilt or External Camera Setup
- Speaker or Headphones
Create the Lists
Open Scratch.
Create a new project.
Add a suitable background for the Truth or Dare game.
Add or select a sprite to interact with the player.
Rename the project Truth or Dare Game.
Create the Lists
Go to Variables → Make a List and create these three lists:
Truth List
Dare List
Answer
Add at least 5 questions to the Truth List.
Truth Questions
What is your favorite food?
What is your favorite movie?
What is your biggest fear?
Who is your best friend?
What is your dream job?
Dare Challenges
Dance for 10 seconds.
Sing a song.
Act like a robot.
Say the alphabet backwards.
Do 5 jumping jacks.
Truth or Dare – Step-by-Step Block Code
Step 1: Create the Lists
Go to Variables → Make a List and create these 3 lists:
- Truth List
- Dare List
- Answer
Add items to Truth List
For example:
- What is your favorite food?
- Who is your best friend?
- What is your favorite movie?
- What is your hobby?
- What is your dream job?
Add items to Dare List
- Sing a song.
- Dance for 10 seconds.
- Make a funny face.
- Do 5 jumping jacks.
- Say the alphabet backwards.
Step 2: Main Starting Code
From Events, drag:
From Motion, add:
Then from Variables, add:
So the complete starting code is:
Step 3: Create the Forever Loop
From Control, add:
Inside the forever loop, go to Sensing and add:
So far:
Step 4: Create the Truth Condition
From Control, add:
From Operators, use the or block.
You need two OR blocks to create three possible inputs.
Build the condition like this:
This means the game accepts:
- Truth
- truth
- t
Step 5: Add Truth List Blocks
Inside the Truth if block, add:
1. Show Truth List
2. Ask the player to pick a number
From Sensing:
For the 1 to 5 part, go to Operators and use:
So:
3. Add answer to Answer list
From Variables:
4. Show Answer list
5. Wait
6. Hide Answer list
7. Hide Truth List
Complete Truth section
Step 6: Create the Dare Condition
Below the Truth if block, create another:
Build the condition:
This accepts:
- Dare
- dare
- D
Step 7: Add Dare List Blocks
Inside the Dare if block, add:
1. Show Dare List
2. Pick a random number
From Operators:
Put it inside:
3. Add Dare to Answer
4. Show Answer
5. Wait
6. Hide Answer
7. Hide Dare List
Complete Dare section
Step 8: Add Background Music
Create a separate script.
From Events:
From Control:
From Sound:
Complete code:
This will continuously play the Eggs sound while the game is running.
Step 9: Complete Block Structure
Your final code should look like this:
And separately:
Applications of the Truth or Dare Game
Entertainment – Can be played with friends and family for fun.
Classroom Icebreaker – Teachers can use it to help students interact and become comfortable with each other.
Team-Building Activities – Can encourage communication and participation among team members.
Party Games – Can be used as an interactive game during parties and social gatherings.
Learning Programming – Helps students understand Scratch concepts such as lists, conditions, loops, variables, and random numbers.
Conclusion
The Truth or Dare Game is an interactive Scratch project that combines fun with programming concepts. By using lists, variables, loops, conditions, user input, random numbers, and sounds, the project creates an engaging game experience. This project helps students improve their logical thinking, creativity, problem-solving, and programming skills while learning how to build an interactive game in Scratch.