0% found this document useful (0 votes)
8 views7 pages

نص

The document describes an interactive text-based game where players start with 5 coins and face various general knowledge and math questions to gain coins and rewards. Players must choose between knocking on a dragon's door or entering a cave, with correct answers leading to further exploration and challenges. The ultimate goal is to collect 15 coins and defeat a monster, while making strategic decisions and answering questions correctly to progress.

Uploaded by

gogolabib79
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views7 pages

نص

The document describes an interactive text-based game where players start with 5 coins and face various general knowledge and math questions to gain coins and rewards. Players must choose between knocking on a dragon's door or entering a cave, with correct answers leading to further exploration and challenges. The ultimate goal is to collect 15 coins and defeat a monster, while making strategic decisions and answering questions correctly to progress.

Uploaded by

gogolabib79
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 7

import time

def print_pause(text):
print(text)
time.sleep(2)

def ask_to_play_again():
print_pause("Would you like to play again? (y/n)")
choice = input("Write your choice here: ")
while choice != "y" and choice != "n":
print("Error! Please choose y or n.")
choice = input("Write your choice here: ")

if choice == "y":
print("Excellent! Restarting the game...")
start_game()
else:
print_pause("Thanks for playing! See you next time.")
print_pause("Instructions:")
print_pause("1- You will enter the game with 5 coins.")
print_pause("2- There will be an indicator showing how many stars you have.")
print_pause("3- You will face general knowledge and math questions. If you answer
correctly, you gain 2 coins and a reward.")
print_pause("4- Your goal is to fight the monster that threatens you and collect 15
coins.")
print_pause("5- Your magic wand can be upgraded 3 times to fight the monster, and
each upgrade costs 5 coins.")
print_pause("6- The difficulty of the questions increases gradually, and so does
the value of the rewards.")
print_pause("7- You lose the game if you answer even one question wrong, because
the monster becomes stronger than you.")

def start_game():
print_pause("You find yourself standing in an open field, full of grass and
yellow wildflowers.")
print_pause("Rumor has it that an evil fairy is somewhere around here, and has
been terrorizing the neighboring village.")
print_pause("In front of you is a house.")
print_pause("To your right is a mountain with a small, dark, cave-like
opening.")
print_pause("In your hand you hold your trusty (but not very effective) magic
wand.")
print_pause("You have two options:")
print_pause("1- Either knock on the door of the house")
print_pause("2- Or enter the cave")
print_pause("Please choose 1 or 2.")

choice = input("Write your choice here: ")


while choice != "1" and choice != "2":
print("Error! Please choose 1 or 2.")
choice = input("Write your choice here: ")

if choice == "1":
print_pause("You approach the door of the house.")
print_pause("You are about to knock when the door opens and out steps a
dragon.")
print_pause("Eep! This is the dragon's house!")
print_pause("The dragon finds you!")
print_pause("You feel a bit under-prepared for this, what with only having
a tiny, rusty old magic wand.")
print_pause("Would you like to (1) cast a spell or (2) run away?!")
choice = input("Write your choice here: ")

while choice != "1" and choice != "2":


print("Error! Please choose 1 or 2.")
choice = input("Write your choice here: ")

if choice == "1":
print_pause("You do your best...")
print_pause("but your rusty old magic wand is not matching for the
dragon.")
print_pause("You have been turned into a frog!")
print_pause("Unfortunately, you lost. Try again.")
ask_to_play_again()

elif choice == "2":


print_pause("You run back into the field without doing anything.
Luckily, you don't seem to have been followed.")
ask_to_play_again()

elif choice == "2":


print_pause("You peer cautiously into the cave.")
print_pause("It turns out to be only a very small cave.")
print_pause("You left it frustrated and without any tools to explore the
mountain.")
print_pause("The first question appears and says:")
print_pause("Something that gets bigger the more you take from it, and gets
smaller when you put something in it?")
choice = input("Write your answer here: ")
while choice != "the hole":
print("False, try again.")
choice = input("Write your answer here: ")
if choice == "the hole" :
print("Great, correct answer")
print_pause("Now you have two coins and an axe to break the mountain and
explore it.")
print_pause("Congratulations, you've found a very large cave.")
print_pause("What is this ??!")
print_pause("OMG....there's a little monster coming for you!")
print_pause("The second question appears and says:")
print_pause("5+5*5/5-5*5 = .......")
choice = input("Write your answer here: ")
while choice != "25":
print("False, try again.")
choice = input("Write your answer here: ")
if choice == "25" :
print("Great, correct answer")
print_pause("Now you got two coins, killed the little monster and got a
flashlight to light up the dark cave.")
print_pause("Now the cave has a lot of light.")
print_pause("Now you can continue exploring in the cave.")
print_pause("After more than an hour in the cave, you find something with a
bright glow.")
print_pause("What is this thing?")
print_pause("Ooooh!! It's such a shiny metal.")
print_pause("I think it's a rare metal.")
print_pause("you got it")
print_pause("You are starting to show signs of fatigue...")
print_pause("Wow! you found the metal.")
print_pause("It's not a metal...they are many metals.")
print_pause("Wow!! I found gold, iron and diamonds.")
print_pause("Now you gather them with your axe")
print_pause("You have collected a lot of them.")
print_pause("After three hours of exploring and collecting minerals, you
were very tired.")
print_pause("You became hungry, thirsty and short of breath")
print_pause("The third question appears and says:")
print_pause("What has leaves but no roots or stems?")
choice = input("Write your answer here: ")
while choice != "the book":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct answer")
print_pause("You have two coins and a bag with food, water and energy
drinks to restore your energy and continue exploring the cave.")
print_pause("Now after five hours of exploring the cave you decided to go
out.")
print_pause("But what is this thing?")
print_pause("Ooooh! They are lots of materials again.")
print_pause("I collected about 200 grams of each metal except iron, of
which I collected about half a kilo.")
print_pause("Gather them and then leave the cave.")
print_pause("Oh my God! You don't know where you are and the night is about
to fall upon you")
print_pause("You are lost in a place you don't know and you don't know your
way back")
print_pause("The fourth question appears and says:")
print_pause("What is the number that if we multiply it by the same number
and add 5 , the result becomes 30?")
choice = input("Write your answer here: ")
while choice != "5":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct answer")
print_pause("You now have two stars and a map to know where you are and how
to get back to the field.")
print_pause("On your way, you went to the place where the village farmers
lived.")
print_pause("They came out to you, surprised and afraid, in case of an
attack under any danger, because they did not know who you were.")
print_pause("You know yourself and that you are an explorer, an adventurer,
and a brave man who came to know about the existence of a monster that threatens
their lives with danger.")
print_pause("You came to save them from him and to destroy him.")
print_pause("So they know that he is not a danger to them")
print_pause("You find food with them, and you have used up all your food.")
print_pause("But there is a problem")
print_pause("This village uses barter.")
print_pause("And you have nothing to trade with them.")
print_pause("But the moment you have about half a kilo of iron")
print_pause("But will they agree to trade food for iron?")
print_pause("You went to ask them if they would accept to trade you.")
print_pause("And their answer was: Yes... they need iron to use it in their
own things.")
print_pause("They have fruit and bread.")
print_pause("100 pieces of bread = 4 grams of iron")
print_pause("To get 1 kg of fruit = 50 grams of iron")
print_pause("You got 1,250 pieces of bread.")
print_pause("That is, approximately 50 grams of iron")
print_pause("And you got 1 kilogram of fruit")
print_pause("Yes, you lost 100 grams of iron, which is very little.")
print_pause("The village chief comes out to welcome you.")
print_pause("He is the oldest and most important person in the village.")
print_pause("To give you advice with the fifth question:")
print_pause("Something that needs light but cannot see it. What is it?")
choice = input("Write your answer here: ")
while choice != "shadow":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct")

# �� ���� ���� ������ ��� �����


print("Please type 'Start' here to start the game. (You can copy the
word \"Start\")")
choice = input()

while choice != "Start":


print("Please type 'Start' here to start the game.")
choice = input()
if choice == "Start":
start_game()

import time

def print_pause(text):
print(text)
time.sleep(2)

def ask_to_play_again():
print_pause("Would you like to play again? (y/n)")
choice = input("Write your choice here: ")
while choice != "y" and choice != "n":
print("Error! Please choose y or n.")
choice = input("Write your choice here: ")

if choice == "y":
print("Excellent! Restarting the game...")
start_game()
else:
print_pause("Thanks for playing! See you next time.")
print_pause("Instructions:")
print_pause("1- You will enter the game with 5 coins.")
print_pause("2- There will be an indicator showing how many stars you have.")
print_pause("3- You will face general knowledge and math questions. If you answer
correctly, you gain 2 coins and a reward.")
print_pause("4- Your goal is to fight the monster that threatens you and collect 15
coins.")
print_pause("5- Your magic wand can be upgraded 3 times to fight the monster, and
each upgrade costs 5 coins.")
print_pause("6- The difficulty of the questions increases gradually, and so does
the value of the rewards.")
print_pause("7- You lose the game if you answer even one question wrong, because
the monster becomes stronger than you.")

def start_game():
print_pause("You find yourself standing in an open field, full of grass and
yellow wildflowers.")
print_pause("Rumor has it that an evil fairy is somewhere around here, and has
been terrorizing the neighboring village.")
print_pause("In front of you is a house.")
print_pause("To your right is a mountain with a small, dark, cave-like
opening.")
print_pause("In your hand you hold your trusty (but not very effective) magic
wand.")
print_pause("You have two options:")
print_pause("1- Either knock on the door of the house")
print_pause("2- Or enter the cave")
print_pause("Please choose 1 or 2.")

choice = input("Write your choice here: ")


while choice != "1" and choice != "2":
print("Error! Please choose 1 or 2.")
choice = input("Write your choice here: ")

if choice == "1":
print_pause("You approach the door of the house.")
print_pause("You are about to knock when the door opens and out steps a
dragon.")
print_pause("Eep! This is the dragon's house!")
print_pause("The dragon finds you!")
print_pause("You feel a bit under-prepared for this, what with only having
a tiny, rusty old magic wand.")
print_pause("Would you like to (1) cast a spell or (2) run away?!")
choice = input("Write your choice here: ")

while choice != "1" and choice != "2":


print("Error! Please choose 1 or 2.")
choice = input("Write your choice here: ")

if choice == "1":
print_pause("You do your best...")
print_pause("but your rusty old magic wand is not matching for the
dragon.")
print_pause("You have been turned into a frog!")
print_pause("Unfortunately, you lost. Try again.")
ask_to_play_again()

elif choice == "2":


print_pause("You run back into the field without doing anything.
Luckily, you don't seem to have been followed.")
ask_to_play_again()

elif choice == "2":


print_pause("You peer cautiously into the cave.")
print_pause("It turns out to be only a very small cave.")
print_pause("You left it frustrated and without any tools to explore the
mountain.")
print_pause("The first question appears and says:")
print_pause("Something that gets bigger the more you take from it, and gets
smaller when you put something in it?")
choice = input("Write your answer here: ")
while choice != "the hole":
print("False, try again.")
choice = input("Write your answer here: ")
if choice == "the hole" :
print("Great, correct answer")
print_pause("Now you have two coins and an axe to break the mountain and
explore it.")
print_pause("Congratulations, you've found a very large cave.")
print_pause("What is this ??!")
print_pause("OMG....there's a little monster coming for you!")
print_pause("The second question appears and says:")
print_pause("5+5*5/5-5*5 = .......")
choice = input("Write your answer here: ")
while choice != "25":
print("False, try again.")
choice = input("Write your answer here: ")
if choice == "25" :
print("Great, correct answer")
print_pause("Now you got two coins, killed the little monster and got a
flashlight to light up the dark cave.")
print_pause("Now the cave has a lot of light.")
print_pause("Now you can continue exploring in the cave.")
print_pause("After more than an hour in the cave, you find something with a
bright glow.")
print_pause("What is this thing?")
print_pause("Ooooh!! It's such a shiny metal.")
print_pause("I think it's a rare metal.")
print_pause("you got it")
print_pause("You are starting to show signs of fatigue...")
print_pause("Wow! you found the metal.")
print_pause("It's not a metal...they are many metals.")
print_pause("Wow!! I found gold, iron and diamonds.")
print_pause("Now you gather them with your axe")
print_pause("You have collected a lot of them.")
print_pause("After three hours of exploring and collecting minerals, you
were very tired.")
print_pause("You became hungry, thirsty and short of breath")
print_pause("The third question appears and says:")
print_pause("What has leaves but no roots or stems?")
choice = input("Write your answer here: ")
while choice != "the book":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct answer")
print_pause("You have two coins and a bag with food, water and energy
drinks to restore your energy and continue exploring the cave.")
print_pause("Now after five hours of exploring the cave you decided to go
out.")
print_pause("But what is this thing?")
print_pause("Ooooh! They are lots of materials again.")
print_pause("I collected about 200 grams of each metal except iron, of
which I collected about half a kilo.")
print_pause("Gather them and then leave the cave.")
print_pause("Oh my God! You don't know where you are and the night is about
to fall upon you")
print_pause("You are lost in a place you don't know and you don't know your
way back")
print_pause("The fourth question appears and says:")
print_pause("What is the number that if we multiply it by the same number
and add 5 , the result becomes 30?")
choice = input("Write your answer here: ")
while choice != "5":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct answer")
print_pause("You now have two stars and a map to know where you are and how
to get back to the field.")
print_pause("On your way, you went to the place where the village farmers
lived.")
print_pause("They came out to you, surprised and afraid, in case of an
attack under any danger, because they did not know who you were.")
print_pause("You know yourself and that you are an explorer, an adventurer,
and a brave man who came to know about the existence of a monster that threatens
their lives with danger.")
print_pause("You came to save them from him and to destroy him.")
print_pause("So they know that he is not a danger to them")
print_pause("You find food with them, and you have used up all your food.")
print_pause("But there is a problem")
print_pause("This village uses barter.")
print_pause("And you have nothing to trade with them.")
print_pause("But the moment you have about half a kilo of iron")
print_pause("But will they agree to trade food for iron?")
print_pause("You went to ask them if they would accept to trade you.")
print_pause("And their answer was: Yes... they need iron to use it in their
own things.")
print_pause("They have fruit and bread.")
print_pause("100 pieces of bread = 4 grams of iron")
print_pause("To get 1 kg of fruit = 50 grams of iron")
print_pause("You got 1,250 pieces of bread.")
print_pause("That is, approximately 50 grams of iron")
print_pause("And you got 1 kilogram of fruit")
print_pause("Yes, you lost 100 grams of iron, which is very little.")
print_pause("The village chief comes out to welcome you.")
print_pause("He is the oldest and most important person in the village.")
print_pause("To give you advice with the fifth question:")
print_pause("Something that needs light but cannot see it. What is it?")
choice = input("Write your answer here: ")
while choice != "shadow":
print("False, try again.")
choice = input("Write your answer here: ")
print("Great, correct")

# �� ���� ���� ������ ��� �����


print("Please type 'Start' here to start the game. (You can copy the
word \"Start\")")
choice = input()

while choice != "Start":


print("Please type 'Start' here to start the game.")
choice = input()
if choice == "Start":
start_game()

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy