forked from crawsome/PyRPG_Mini
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy path__init__.py
More file actions
69 lines (54 loc) · 1.77 KB
/
__init__.py
File metadata and controls
69 lines (54 loc) · 1.77 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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
import Game
from flask import Flask, render_template
app = Flask(__name__)
@app.route('/')
def login():
"""@brief This is a flask route for the first page
This routes the user to a login page that renders
login.html. The user will have to submit a username and password.
@param : none
"""
return render_template('login.html')
@app.route('/home')
def home():
"""@brief This is a flask route for the homepage
Once the user is logged in, it will route them to the home screen
which renders the home.html page.
@param : none
"""
return render_template('home.html')
@app.route('/play')
def play():
"""@brief This is a flask route for the play page
If the user selects the play tab in the navbar, they will be
routed to the play page which renders play.html.
@param : none
"""
return render_template('play.html')
@app.route('/about')
def about():
"""@brief This is a flask route for the about page
If the user selects the about tab in the navbar they will be routed
to the about page which renders about.html.
@param : none
"""
return render_template('about.html')
@app.route('/resetPass')
def resetPass():
"""@brief This is a flask route for the password reset page
If the user forgets their password on the login page, they can click a button
to redirect them here
@param : none
"""
return render_template('resetPass.html')
@app.route('/signUp')
def signUp():
"""@brief This is a flask route for the sign up page
The user can sign up for an account; upon success, it will redirect them to the home page
@param : none
"""
return render_template('signUp.html')
if __name__ == '__main__':
app.run(debug=True)
ourgame = Game.Game()
ourgame.gameloop()