36 lines
1.6 KiB
Python
36 lines
1.6 KiB
Python
print("Welcome to the Forest Adventure Game!")
|
|
|
|
# Start of the game
|
|
print("You find yourself on the edge of a dark forest.")
|
|
print("Can you find your way through without getting lost?")
|
|
print("You see a path to your left and right.")
|
|
choice = input("Do you want to go left or right? (left/right) ")
|
|
|
|
# Decision making
|
|
if choice == "left":
|
|
print("You decide to go left and encounter a bear.")
|
|
action = input("Do you want to run or stay? (run/stay) ")
|
|
|
|
if action == "run":
|
|
print("You ran as fast as you could and safely made it out of the forest. You win!")
|
|
elif action == "stay":
|
|
print("You stayed calm. The bear sniffed you and walked away. You safely walk out of the forest. You win!")
|
|
else:
|
|
print("You didn't choose a valid action. The bear got confused and left. You safely walk out of the forest. You win by luck!")
|
|
|
|
elif choice == "right":
|
|
print("You go right and find a magical pond. A fairy offers you two potions: red and blue.")
|
|
potion = input("Which potion do you choose? (red/blue) ")
|
|
|
|
if potion == "red":
|
|
print("You drink the red potion and gain the strength of a bear. You confidently stroll out of the forest. You win!")
|
|
elif potion == "blue":
|
|
print("You drink the blue potion and gain the ability to fly. You fly out of the forest. You win!")
|
|
else:
|
|
print("You didn't choose a potion and the fairy turns you into a frog. Game over.")
|
|
|
|
else:
|
|
print("You didn't choose a valid path and got lost in the forest. Game over.")
|
|
|
|
print("Thank you for playing the Forest Adventure Game!")
|