-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconsole.py
More file actions
46 lines (42 loc) · 1 KB
/
Copy pathconsole.py
File metadata and controls
46 lines (42 loc) · 1 KB
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
from logic import Logic
def NumberOfHeroesInput():
numHeroes = 0
while numHeroes > 7 or numHeroes < 1:
print("\n\n")
n = input(Logic.NumberOfHeroesText())
try:
numHeroes = int(n)
except ValueError:
continue
return numHeroes
def FullProgram():
heroes = Logic.GetHeroes(NumberOfHeroesInput())
ship = Logic.GetShip()
threat = Logic.GetThreat()
PrintOut(heroes, ship, threat)
def PrintOut(heroes, ship, threat):
seperator = "---------------"
print("")
print("")
print("Heroes")
print(seperator)
print(*heroes, sep="\n")
print("")
print("The Raptor")
print(seperator)
print(*ship, sep="\n")
print("")
print("The Mission")
print(seperator)
print(threat)
#MAIN
print(*Logic.OpeningSpiel(), sep="\n")
goAgain = True
while goAgain:
FullProgram()
print("")
goAgain = input("Run again? (y/n)")
print("")
print("")
goAgain = True if goAgain is "y" else False
quit()