-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbutton.py
79 lines (73 loc) · 2.29 KB
/
button.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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
def main():
print "Gathering necessary data: \n"
buttonColor = raw_input("What color is the button? ")
buttonText = raw_input("What does the button read? ")
buttonBatterys = raw_input("How many batteries are present on the bomb? ")
print "\n"
if buttonBatterys >= "1" and buttonText == "detonate":
print "[Press and release immediatly.]"
elif buttonBatterys >= "2":
statusFRK = raw_input("Is there a lit FRK indicator present on the bomb? ")
if statusFRK == "yes":
print "[Press and release immediatly.]"
else:
if buttonColor == "white":
statusCAR = raw_input("Is there a lit CAR indicator present on the bomb? ")
if statusCAR == "yes":
print "[Press and hold...]\n"
hold()
else:
if buttonColor == "blue" and buttonText == "abort":
print "[Press and hold...]\n"
hold()
elif buttonColor == "yellow":
print "[Press and hold...]\n"
hold()
elif buttonColor == "red":
print "[Press and release immediatly.]"
else:
print "[Press and hold...]\n"
hold()
elif buttonColor == "blue" and buttonText == "abort":
print "[Press and hold...]\n"
hold()
elif buttonColor == "yellow":
print "[Press and hold...]\n"
hold()
elif buttonColor == "red":
print "[Press and release immediatly.]"
else:
print "[Press and hold...]\n"
hold()
else:
if buttonColor == "white":
statusCAR = raw_input("Is there a lit CAR indicator present on the bomb? ")
if statusCAR == "yes":
print "[Press and hold...]\n"
hold()
elif buttonColor == "blue" and buttonText == "abort":
print "[Press and hold...]\n"
hold()
elif buttonColor == "yellow":
print "[Press and hold...]\n"
hold()
elif buttonColor == "red":
print "[Press and release immediatly.]"
else:
print "[Press and hold...]\n"
hold()
def hold():
stripColor = raw_input("What color is the strip? ")
if stripColor == "blue":
print "\n"
print "[Release when the countdown timer has a 4 in any position.]"
elif stripColor == "white":
print "\n"
print "[Release when the countdown timer has a 1 in any position.]"
elif stripColor == "yellow":
print "\n"
print "[Release when the countdown timer has a 5 in any position.]"
else:
print "\n"
print "[Release when the countdown timer has a 1 in any position.]"
main()