-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpath.py
25 lines (22 loc) · 807 Bytes
/
path.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import time
def slow_print(text, delay=0.03):
for char in text:
print(char, end='', flush=True)
time.sleep(delay)
print()
def path(delay_speed):
while True:
path_choice = input("Which path do you choose? (left/right) ")
if path_choice == "left":
slow_print("You have chosen the left path. Adventure awaits!")
from trees import forest
forest(delay_speed)
return path_choice
if path_choice == "right":
slow_print("You have chosen the right path. Adventure awaits!")
from graveyard import cemetery
cemetery()
return path_choice
else:
slow_print("Invalid choice. Please choose 'left' or 'right'.")
return path_choice