-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
executable file
·38 lines (28 loc) · 922 Bytes
/
main.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
'''
Hockey Game in Python using Pygame
by: Josh Kennedy
I can be reached by email at: [email protected]
This version was released during May 2017
'''
import sys, game, menu
def main():
# holder variables for optional data to include between menus
opt = [False]
while True:
# response holds the answer to what button the user clicked
response, opt = menu.main(opt)
# quit button
if response == "quit":
# ends application
sys.exit()
# start button
elif response == "start":
# launches game
game.main()
# rules button
elif response == "rules":
# show rules page
opt = menu.mainRules(opt)
# This is the file you want to run if you want everything to work correctly! Have fun!
if __name__ == "__main__":
main()