├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ ├── custom.md │ └── feature_request.md ├── pull_request_template.md └── workflows │ ├── greetings.yml │ └── label.yml ├── .gitignore ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── Procfile ├── README.md ├── Web_App ├── .gitignore ├── Direct_Keys.py ├── GesturePredictor.py ├── SetupGame.py ├── StartGame.py ├── Switch_Control.py ├── TrainedModel │ ├── GestureRecogModel.tfl.data-00000-of-00001 │ ├── GestureRecogModel.tfl.index │ ├── GestureRecogModel.tfl.meta │ ├── README.md │ └── checkpoint ├── __init__.py ├── asgi.py ├── models.py ├── settings.py ├── urls.py ├── views.py └── wsgi.py ├── appspec.yml ├── db.sqlite3 ├── manage.py ├── requirements.txt ├── scripts ├── install_dependencies ├── start_server └── stop_server ├── static ├── Images │ ├── Cool_game.jpg │ ├── Cool_image3.jpg │ ├── TeamMembers │ │ ├── Adwait_Agashe.jpg │ │ ├── Ashutosh_Saxena.jpg │ │ ├── Ravi_Prakash_Singh.jpg │ │ ├── Rishabh_Tripathi.jpg │ │ ├── Sanjay_Marreddi.jpg │ │ └── Sneha_Jayaganthan.png │ ├── Untitled design.png │ ├── Website_Glimpses │ │ ├── each_game.gif │ │ ├── game_play.gif │ │ ├── games_page.gif │ │ └── home_page.gif │ ├── about_us_bottom.svg │ ├── about_us_top.svg │ ├── background.jpg │ ├── backgrouund.png │ ├── bubbles.jpg │ ├── iit_goa2.png │ ├── image_3.png │ ├── image_4.jpg │ ├── img123.png │ ├── img1234.png │ ├── img12345.png │ ├── img_avatar.png │ └── wave.svg ├── css │ ├── about_us.css │ ├── front_web_1.css │ ├── game_page.css │ ├── image_3.jpg │ ├── image_4.jpg │ ├── slidding_web_car.css │ ├── slidding_web_mortal.css │ └── variables.css └── javascript │ ├── app.js │ └── game_mortal.js └── templates ├── about_us.html ├── front_web_1.html ├── game_car.html ├── game_mortal.html └── game_page.html /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Describe the bug** 11 | A clear and concise description of what the bug is. 12 | 13 | **To Reproduce** 14 | Steps to reproduce the behavior: 15 | 1. Go to '...' 16 | 2. Click on '....' 17 | 3. Scroll down to '....' 18 | 4. See error 19 | 20 | **Expected behavior** 21 | A clear and concise description of what you expected to happen. 22 | 23 | **Screenshots** 24 | If applicable, add screenshots to help explain your problem. 25 | 26 | **Desktop (please complete the following information):** 27 | - OS: [e.g. iOS] 28 | - Browser [e.g. chrome, safari] 29 | - Version [e.g. 22] 30 | 31 | **Smartphone (please complete the following information):** 32 | - Device: [e.g. iPhone6] 33 | - OS: [e.g. iOS8.1] 34 | - Browser [e.g. stock browser, safari] 35 | - Version [e.g. 22] 36 | 37 | **Additional context** 38 | Add any other context about the problem here. 39 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/custom.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Custom issue template 3 | about: Describe this issue template's purpose here. 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | 11 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Is your feature request related to a problem? Please describe.** 11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 12 | 13 | **Describe the solution you'd like** 14 | A clear and concise description of what you want to happen. 15 | 16 | **Describe alternatives you've considered** 17 | A clear and concise description of any alternative solutions or features you've considered. 18 | 19 | **Additional context** 20 | Add any other context or screenshots about the feature request here. 21 | -------------------------------------------------------------------------------- /.github/pull_request_template.md: -------------------------------------------------------------------------------- 1 | #### Issue Number 2 | ISSUE # 3 | 7 | 8 | #### Describe the changes you've made 9 | 12 | 13 | #### Describe if there is any unusual behaviour of your code(Write `NA` if there isn't) 14 | 17 | 18 | #### Additional context (OPTIONAL) 19 | 22 | 23 | #### Test plan (OPTIONAL) 24 | 28 | 29 | #### Checklist 30 | 34 | - [ ] My code follows the code style of this project. 35 | - [ ] I have performed a self-review of my own code. 36 | - [ ] My change requires a change to the documentation. 37 | - [ ] I have updated the documentation accordingly. 38 | - [ ] I have commented my code, particularly in hard-to-understand areas. 39 | - [ ] My changes generate no new warnings. 40 | - [ ] I have added tests that prove my fix is effective or that my feature works. 41 | - [ ] The title of my pull request is a short description of the requested changes. 42 | -------------------------------------------------------------------------------- /.github/workflows/greetings.yml: -------------------------------------------------------------------------------- 1 | name: Greetings 2 | 3 | on: [pull_request, issues] 4 | 5 | jobs: 6 | greeting: 7 | runs-on: ubuntu-latest 8 | permissions: 9 | issues: write 10 | pull-requests: write 11 | steps: 12 | - uses: actions/first-interaction@v1 13 | with: 14 | repo-token: ${{ secrets.GITHUB_TOKEN }} 15 | issue-message: 'Hello there!👋 Welcome to the project!🚀⚡ Thank you and congrats🎉 for opening your very first issue in this project. Please adhere to our Code of Conduct. Please make sure not to start working on the issue, unless you get assigned to it.😄' 16 | pr-message: 'Hello there!👋 Welcome to the project!💖 Thank you and congrats🎉 for opening your first pull request. Please adhere to our Code of Conduct. We will get back to you as soon as we can 😄.' 17 | -------------------------------------------------------------------------------- /.github/workflows/label.yml: -------------------------------------------------------------------------------- 1 | # This workflow will triage pull requests and apply a label based on the 2 | # paths that are modified in the pull request. 3 | # 4 | # To use this workflow, you will need to set up a .github/labeler.yml 5 | # file with configuration. For more information, see: 6 | # https://github.com/actions/labeler 7 | 8 | name: Labeler 9 | on: [pull_request] 10 | 11 | jobs: 12 | label: 13 | 14 | runs-on: ubuntu-latest 15 | permissions: 16 | contents: read 17 | pull-requests: write 18 | 19 | steps: 20 | - uses: actions/labeler@v2 21 | with: 22 | repo-token: "${{ secrets.GITHUB_TOKEN }}" 23 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | build/ 12 | develop-eggs/ 13 | dist/ 14 | downloads/ 15 | eggs/ 16 | .eggs/ 17 | lib/ 18 | lib64/ 19 | parts/ 20 | sdist/ 21 | var/ 22 | wheels/ 23 | share/python-wheels/ 24 | *.egg-info/ 25 | .installed.cfg 26 | *.egg 27 | MANIFEST 28 | 29 | # PyInstaller 30 | # Usually these files are written by a python script from a template 31 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 32 | *.manifest 33 | *.spec 34 | 35 | # Installer logs 36 | pip-log.txt 37 | pip-delete-this-directory.txt 38 | 39 | # Unit test / coverage reports 40 | htmlcov/ 41 | .tox/ 42 | .nox/ 43 | .coverage 44 | .coverage.* 45 | .cache 46 | nosetests.xml 47 | coverage.xml 48 | *.cover 49 | *.py,cover 50 | .hypothesis/ 51 | .pytest_cache/ 52 | cover/ 53 | 54 | # Translations 55 | *.mo 56 | *.pot 57 | 58 | # Django stuff: 59 | *.log 60 | local_settings.py 61 | db.sqlite3 62 | db.sqlite3-journal 63 | 64 | # Flask stuff: 65 | instance/ 66 | .webassets-cache 67 | 68 | # Scrapy stuff: 69 | .scrapy 70 | 71 | # Sphinx documentation 72 | docs/_build/ 73 | 74 | # PyBuilder 75 | .pybuilder/ 76 | target/ 77 | 78 | # Jupyter Notebook 79 | .ipynb_checkpoints 80 | 81 | # IPython 82 | profile_default/ 83 | ipython_config.py 84 | 85 | # PEP 582; used by e.g. github.com/David-OConnor/pyflow 86 | __pypackages__/ 87 | 88 | # Celery stuff 89 | celerybeat-schedule 90 | celerybeat.pid 91 | 92 | # SageMath parsed files 93 | *.sage.py 94 | 95 | # Environments 96 | .env 97 | .venv 98 | env/ 99 | /env 100 | venv/ 101 | ENV/ 102 | env.bak/ 103 | venv.bak/ 104 | 105 | ### VisualStudioCode ### 106 | .vscode/* 107 | !.vscode/settings.json 108 | !.vscode/tasks.json 109 | !.vscode/launch.json 110 | !.vscode/extensions.json 111 | 112 | ### VisualStudioCode Patch ### 113 | # Ignore all local history of files 114 | **/.history 115 | 116 | 117 | # Spyder project settings 118 | .spyderproject 119 | .spyproject 120 | 121 | # Rope project settings 122 | .ropeproject 123 | 124 | # mkdocs documentation 125 | /site 126 | 127 | # mypy 128 | .mypy_cache/ 129 | .dmypy.json 130 | dmypy.json 131 | 132 | # Pyre type checker 133 | .pyre/ 134 | 135 | # pytype static type analyzer 136 | .pytype/ 137 | 138 | # Cython debug symbols 139 | cython_debug/ 140 | 141 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Contributor Covenant Code of Conduct 2 | 3 | ## Our Pledge 4 | 5 | We as members, contributors, and leaders pledge to make participation in our 6 | community a harassment-free experience for everyone, regardless of age, body 7 | size, visible or invisible disability, ethnicity, sex characteristics, gender 8 | identity and expression, level of experience, education, socio-economic status, 9 | nationality, personal appearance, race, religion, or sexual identity 10 | and orientation. 11 | 12 | We pledge to act and interact in ways that contribute to an open, welcoming, 13 | diverse, inclusive, and healthy community. 14 | 15 | ## Our Standards 16 | 17 | Examples of behavior that contributes to a positive environment for our 18 | community include: 19 | 20 | * Demonstrating empathy and kindness toward other people 21 | * Being respectful of differing opinions, viewpoints, and experiences 22 | * Giving and gracefully accepting constructive feedback 23 | * Accepting responsibility and apologizing to those affected by our mistakes, 24 | and learning from the experience 25 | * Focusing on what is best not just for us as individuals, but for the 26 | overall community 27 | 28 | Examples of unacceptable behavior include: 29 | 30 | * The use of sexualized language or imagery, and sexual attention or 31 | advances of any kind 32 | * Trolling, insulting or derogatory comments, and personal or political attacks 33 | * Public or private harassment 34 | * Publishing others' private information, such as a physical or email 35 | address, without their explicit permission 36 | * Other conduct which could reasonably be considered inappropriate in a 37 | professional setting 38 | 39 | ## Enforcement Responsibilities 40 | 41 | Community leaders are responsible for clarifying and enforcing our standards of 42 | acceptable behavior and will take appropriate and fair corrective action in 43 | response to any behavior that they deem inappropriate, threatening, offensive, 44 | or harmful. 45 | 46 | Community leaders have the right and responsibility to remove, edit, or reject 47 | comments, commits, code, wiki edits, issues, and other contributions that are 48 | not aligned to this Code of Conduct, and will communicate reasons for moderation 49 | decisions when appropriate. 50 | 51 | ## Scope 52 | 53 | This Code of Conduct applies within all community spaces, and also applies when 54 | an individual is officially representing the community in public spaces. 55 | Examples of representing our community include using an official e-mail address, 56 | posting via an official social media account, or acting as an appointed 57 | representative at an online or offline event. 58 | 59 | ## Enforcement 60 | 61 | Instances of abusive, harassing, or otherwise unacceptable behavior may be 62 | reported to the community leaders responsible for enforcement at 63 | Innovation Skyline. 64 | All complaints will be reviewed and investigated promptly and fairly. 65 | 66 | All community leaders are obligated to respect the privacy and security of the 67 | reporter of any incident. 68 | 69 | ## Enforcement Guidelines 70 | 71 | Community leaders will follow these Community Impact Guidelines in determining 72 | the consequences for any action they deem in violation of this Code of Conduct: 73 | 74 | ### 1. Correction 75 | 76 | **Community Impact**: Use of inappropriate language or other behavior deemed 77 | unprofessional or unwelcome in the community. 78 | 79 | **Consequence**: A private, written warning from community leaders, providing 80 | clarity around the nature of the violation and an explanation of why the 81 | behavior was inappropriate. A public apology may be requested. 82 | 83 | ### 2. Warning 84 | 85 | **Community Impact**: A violation through a single incident or series 86 | of actions. 87 | 88 | **Consequence**: A warning with consequences for continued behavior. No 89 | interaction with the people involved, including unsolicited interaction with 90 | those enforcing the Code of Conduct, for a specified period of time. This 91 | includes avoiding interactions in community spaces as well as external channels 92 | like social media. Violating these terms may lead to a temporary or 93 | permanent ban. 94 | 95 | ### 3. Temporary Ban 96 | 97 | **Community Impact**: A serious violation of community standards, including 98 | sustained inappropriate behavior. 99 | 100 | **Consequence**: A temporary ban from any sort of interaction or public 101 | communication with the community for a specified period of time. No public or 102 | private interaction with the people involved, including unsolicited interaction 103 | with those enforcing the Code of Conduct, is allowed during this period. 104 | Violating these terms may lead to a permanent ban. 105 | 106 | ### 4. Permanent Ban 107 | 108 | **Community Impact**: Demonstrating a pattern of violation of community 109 | standards, including sustained inappropriate behavior, harassment of an 110 | individual, or aggression toward or disparagement of classes of individuals. 111 | 112 | **Consequence**: A permanent ban from any sort of public interaction within 113 | the community. 114 | 115 | ## Attribution 116 | 117 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], 118 | version 2.0, available at 119 | https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. 120 | 121 | Community Impact Guidelines were inspired by [Mozilla's code of conduct 122 | enforcement ladder](https://github.com/mozilla/diversity). 123 | 124 | [homepage]: https://www.contributor-covenant.org 125 | 126 | For answers to common questions about this code of conduct, see the FAQ at 127 | https://www.contributor-covenant.org/faq. Translations are available at 128 | https://www.contributor-covenant.org/translations. 129 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Introduction 2 | 3 | First off, thank you for considering contributing to GameInShape. It's people like you that make GameInShape such a great platform. 4 | 5 | Following these guidelines helps to communicate that you respect the time of the developers managing and developing this open source project. In return, they should reciprocate that respect in addressing your issue, assessing changes, and helping you finalize your pull requests. 6 | 7 | GameInShape is an open source project and we love to receive contributions from our community — you! There are many ways to contribute, from improving the documentation, submitting bug reports and feature requests or writing code which can be incorporated into GameInShape itself. 8 | 9 | 10 | # Ground Rules 11 | ### Responsibilities 12 | * Ensure that code that goes into core meets all requirements in this [checklist](https://github.com/Innovation-Skyline-2020/GameInShape/blob/main/requirements.txt). 13 | * Create issues for any major changes and enhancements that you wish to make. Discuss things transparently and get community feedback. 14 | * Keep feature versions as small as possible, preferably one new feature per version. 15 | * Be welcoming to newcomers and encourage diverse new contributors from all backgrounds. 16 | 17 | 18 | # Getting started 19 | ### Contributing to Project 20 | **Go through the link If you are new to Open Source Contribution [here](https://github.com/firstcontributions/first-contributions) on making your First Contribution !!** 21 | - Fork this repository 22 | - Clone the repository to your System using `git clone https://github.com/Innovation-Skyline-2020/GameInShape"` 23 | - Create a branch :- 24 | - Change to the repository directory on your computer `cd GameInShape` 25 | - Now create a branch using the git checkout command: `git checkout -b your-new-branch-name` 26 | - Make changes as per your requirement to solve the mentioned issues or new ones and commit those changes. 27 | - If you go to the project directory and execute the command `git status`, you'll see there are changes. 28 | - Add those changes to the branch you just created using the `git add`. 29 | - Now commit those changes using the git commit command: `git commit -m "Added the feature of Suggesting Music"` 30 | - Push your changes to GitHub using the command `git push origin ` 31 | - If you go to your repository on GitHub, you'll see a Compare & pull request button. Click on that button. 32 | - Now describe the changes you made and submit the `pull request`. 33 | - Wait for the Maintainers to review :) 34 | 35 | # How to suggest a feature or enhancement/ report a bug 36 | Use the auto populated Templates available when suggesting a feature or reporting a bug via opening an Issue. Make sure you fill in all the details asked in a clear and concise way. 37 | 38 | # Code review process 39 | 40 | The core team looks at Pull Requests on a regular basis in a weekly triage meeting that we hold. 41 | After feedback has been given we expect responses within two weeks. After two weeks we may close the pull request if it isn't showing any activity. 42 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Innovation Skyline 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Procfile: -------------------------------------------------------------------------------- 1 | web: gunicorn Web_App.wsgi --log-file - -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | [![GitHub license](https://img.shields.io/github/license/Naereen/StrapDown.js.svg)](https://github.com/Naereen/StrapDown.js/blob/master/LICENSE) 4 | [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) 5 | ![GitHub contributors](https://img.shields.io/github/contributors-anon/Innovation-Skyline-2020/GameInShape?style=social) 6 | ![GitHub forks](https://img.shields.io/github/forks/Innovation-Skyline-2020/GameInShape?style=social) 7 | ![GitHub Repo stars](https://img.shields.io/github/stars/Innovation-Skyline-2020/GameInShape?style=social) 8 | ![GitHub Repo Issues](https://img.shields.io/github/issues/Innovation-Skyline-2020/GameInShape?style=social) 9 | 10 | 11 | # Overview 12 | 13 | #### We can’t compromise on Health by playing Online Games. But we can’t compromise on the enjoyment aspect as well. Is there a way to integrate both of them ? Yes!! 14 | ###                 Online Games ?                                                                   Physical Fitness ? 15 | 16 | → 17 | 18 | 19 | 20 | 21 | 22 | 23 | - [x] We introduce you our innovative online gaming platform **GameInShape** that integrates Online gaming with varied levels of physical activity, providing users 24 | a unique and a flexible gaming experience thereby ensuring physical fitness at the same time. 25 | 26 | - [x] Users would have a choice to toggle between digital and physical modes of playing the individual games. 27 | 28 | # Glimpses of our product 29 | ## Watch the Short Video about Project [here!](https://youtu.be/CmwvdUrCMSc) 30 | 31 | 32 | 33 | 34 | 35 | ### Currently, Our product supports two popular games: 36 | - [Mortal Kombat X](https://en.wikipedia.org/wiki/Mortal_Kombat_X) 37 | - [Madalin Stunt Cars 2](https://www.crazygames.com/game/madalin-stunt-cars-2) 38 | ### But it is easily scalable to most of the games, We will release the updated version which incorporates many popular games soon! 39 | 40 | # Tech Stack 41 | 42 | 43 | 44 | 45 | 46 | # Wanna try our Product ? 47 | Head over this [GameInShape](http://52.15.230.103/) to start! 48 | 49 | # Getting Started 50 | ### Steps to run the Project in your local device !! 51 | - Fork this repository. 52 | - Clone the repository to your System using `git clone` 53 | - Example : `git clone https://github.com/Innovation-Skyline-2020/GameInShape` 54 | - Create a new Virtual Environment with python 3.8.3 version. 55 | - Install all the dependencies with `pip install -r requirements.txt`. 56 | - Make sure you are in root directory & run the command `python manage.py runserver`. 57 | - Once it shows `Running on http://127.0.0.1:8000/` go to *http://127.0.0.1:8000/* in your browser. 58 | 59 | 60 | # Contributing to Project 61 | **Go through the link If you are new to Open Source Contribution [here](https://github.com/firstcontributions/first-contributions) on making your First Contribution !!** 62 | - Fork this repository 63 | - Clone the repository to your System using `git clone https://github.com/Innovation-Skyline-2020/GameInShape"` 64 | - Create a branch :- 65 | - Change to the repository directory on your computer `cd GameInShape` 66 | - Now create a branch using the git checkout command: `git checkout -b your-new-branch-name` 67 | - Make changes as per your requirement to solve the mentioned issues or new ones and commit those changes. 68 | - If you go to the project directory and execute the command `git status`, you'll see there are changes. 69 | - Add those changes to the branch you just created using the `git add`. 70 | - Now commit those changes using the git commit command: `git commit -m "Added the feature of Suggesting Music"` 71 | - Push your changes to GitHub using the command `git push origin ` 72 | - If you go to your repository on GitHub, you'll see a Compare & pull request button. Click on that button. 73 | - Now describe the changes you made and submit the `pull request`. 74 | - Wait for the Maintainers to review :) 75 | - For more detailed Instructions, visit our Contributors Guideline [here](/GameInShape/CONTRIBUTING.md). 76 | 77 | ## Project Admin 78 | 79 | 80 | [![](https://github.com/SanjayMarreddi.png?size=80)](https://github.com/SanjayMarreddi) 81 | 82 | Reach out for queries here : [SanjayMarreddi](https://www.linkedin.com/in/sanjaymarreddi/) 83 | 84 | ## Contributors 85 | Thanks to all these wonderful developers who made this project awesome! 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | ## License 97 | This project is under [MIT License](/LICENSE) 98 | 99 | 100 | -------------------------------------------------------------------------------- /Web_App/.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | build/ 12 | develop-eggs/ 13 | dist/ 14 | downloads/ 15 | eggs/ 16 | .eggs/ 17 | lib/ 18 | lib64/ 19 | parts/ 20 | sdist/ 21 | var/ 22 | wheels/ 23 | share/python-wheels/ 24 | *.egg-info/ 25 | .installed.cfg 26 | *.egg 27 | MANIFEST 28 | 29 | # PyInstaller 30 | # Usually these files are written by a python script from a template 31 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 32 | *.manifest 33 | *.spec 34 | 35 | # Installer logs 36 | pip-log.txt 37 | pip-delete-this-directory.txt 38 | 39 | # Unit test / coverage reports 40 | htmlcov/ 41 | .tox/ 42 | .nox/ 43 | .coverage 44 | .coverage.* 45 | .cache 46 | nosetests.xml 47 | coverage.xml 48 | *.cover 49 | *.py,cover 50 | .hypothesis/ 51 | .pytest_cache/ 52 | cover/ 53 | 54 | # Translations 55 | *.mo 56 | *.pot 57 | 58 | # Django stuff: 59 | *.log 60 | local_settings.py 61 | db.sqlite3 62 | db.sqlite3-journal 63 | 64 | # Flask stuff: 65 | instance/ 66 | .webassets-cache 67 | 68 | # Scrapy stuff: 69 | .scrapy 70 | 71 | # Sphinx documentation 72 | docs/_build/ 73 | 74 | # PyBuilder 75 | .pybuilder/ 76 | target/ 77 | 78 | # Jupyter Notebook 79 | .ipynb_checkpoints 80 | 81 | # IPython 82 | profile_default/ 83 | ipython_config.py 84 | 85 | # pyenv 86 | # For a library or package, you might want to ignore these files since the code is 87 | # intended to run in multiple environments; otherwise, check them in: 88 | # .python-version 89 | 90 | # pipenv 91 | # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. 92 | # However, in case of collaboration, if having platform-specific dependencies or dependencies 93 | # having no cross-platform support, pipenv may install dependencies that don't work, or not 94 | # install all needed dependencies. 95 | #Pipfile.lock 96 | 97 | # PEP 582; used by e.g. github.com/David-OConnor/pyflow 98 | __pypackages__/ 99 | 100 | # Celery stuff 101 | celerybeat-schedule 102 | celerybeat.pid 103 | 104 | # SageMath parsed files 105 | *.sage.py 106 | 107 | # Environments 108 | .env 109 | .venv 110 | env/ 111 | venv/ 112 | ENV/ 113 | env.bak/ 114 | venv.bak/ 115 | 116 | # Spyder project settings 117 | .spyderproject 118 | .spyproject 119 | 120 | # Rope project settings 121 | .ropeproject 122 | 123 | # mkdocs documentation 124 | /site 125 | 126 | # mypy 127 | .mypy_cache/ 128 | .dmypy.json 129 | dmypy.json 130 | 131 | # Pyre type checker 132 | .pyre/ 133 | 134 | # pytype static type analyzer 135 | .pytype/ 136 | 137 | # Cython debug symbols 138 | cython_debug/ -------------------------------------------------------------------------------- /Web_App/Direct_Keys.py: -------------------------------------------------------------------------------- 1 | # Import the required Libraries 2 | import ctypes 3 | # It provides C compatible data types, and allows calling functions in DLLs or shared libraries. 4 | 5 | # Using a python builtin API to send Input 6 | SendInput = ctypes.windll.user32.SendInput 7 | 8 | # We define some global parameters so that its easier for us to tweak when required. 9 | INITIAL_VALUE = 0 10 | FINAL_VALUE = 1 11 | 12 | # Each key on a PC keyboard has a Scan Code rather than an ASCII code associated with it. 13 | # When a key is pressed it sends the Scan Code for the key that was pressed, to the Keyboard Interface Circuit on the Computers System Board. 14 | # These Scan codes are only applicable to non-U.S. keyboard installations. 15 | 16 | # When a key(A_key) is pressed then corresponding Hexagonal value(0x1E) which is the Scan Code. 17 | # Here are the Scan Codes of A-Z & 4 Arrow Keys : 18 | 19 | A_key = 0x1E 20 | B_key = 0x30 21 | C_key = 0x2E 22 | D_key = 0x20 23 | E_key = 0x12 24 | F_key = 0x21 25 | G_key = 0x22 26 | H_key = 0x23 27 | I_key = 0x17 28 | J_key = 0x24 29 | K_key = 0x25 30 | L_key = 0x26 31 | M_key = 0x32 32 | N_key = 0x31 33 | O_key = 0x18 34 | P_key = 0x19 35 | Q_key = 0x10 36 | R_key = 0x13 37 | S_key = 0x1F 38 | T_key = 0x14 39 | U_key = 0x16 40 | V_key = 0x2F 41 | W_key = 0x11 42 | X_key = 0x2D 43 | Y_key = 0x15 44 | Z_key = 0x2C 45 | 46 | key_0 = 0x01 47 | key_1 = 0x02 48 | key_2 = 0x03 49 | key_3 = 0x04 50 | key_4 = 0x05 51 | key_5 = 0x06 52 | key_6 = 0x07 53 | key_7 = 0x08 54 | key_8 = 0x09 55 | key_9 = 0x0A 56 | 57 | Up_arrow_key = 0x48 58 | Left_arrow_key = 0x4B 59 | Right_arrow_key = 0x4D 60 | Down_arrow_key = 0x50 61 | 62 | Shift_key = 0x36 # Right Shift Key 63 | Space_key = 0x39 64 | SemiColon_key = 0x27 # ; 65 | 66 | 67 | class KeyBoardInput(ctypes.Structure): 68 | 69 | _fields_ = [ 70 | # "qwe" is unsigned short int type variable 71 | ("qwe", ctypes.c_ushort), 72 | 73 | # "werty" is unsigned short int type variable 74 | ("werty", ctypes.c_ushort), 75 | 76 | # "tyui" is unsigned long int type variable 77 | ("tyui", ctypes.c_ulong), 78 | 79 | # "check" is unsigned long int type variable 80 | ("check", ctypes.c_ulong), 81 | 82 | # "diot" is pointer of unsigned long int variable 83 | ("diot", ctypes.POINTER(ctypes.c_ulong))] 84 | 85 | 86 | class HardwareInput(ctypes.Structure): 87 | 88 | _fields_ = [ 89 | # "asd" is unsigned long int type variable 90 | ("asd", ctypes.c_ulong), 91 | 92 | # "dfghj" is signed short int type variable 93 | ("dfghj", ctypes.c_short), 94 | 95 | # "jkdg" is unsigned short int type variable 96 | ("jkdg", ctypes.c_ushort)] 97 | 98 | 99 | class MouseInput(ctypes.Structure): 100 | 101 | _fields_ = [ 102 | # 'x_axis' is long int data type variable 103 | ("x_axis", ctypes.c_long), 104 | 105 | # "y_axis" is long int data type variable 106 | ("y_axis", ctypes.c_long), 107 | 108 | # "mouseData" is unsigned long int data type variable 109 | ("mouseData", ctypes.c_ulong), 110 | 111 | # "dwFlags" is unsigned long int data type variable 112 | ("dwFlags", ctypes.c_ulong), 113 | 114 | # "time" is unsigned long int data type variable 115 | ("time", ctypes.c_ulong), 116 | 117 | # "dioter" is unsigned long pointer variable 118 | ("dioter", ctypes.POINTER(ctypes.c_ulong))] 119 | 120 | 121 | # Creating a Union of all the above three Structures 122 | class InputTakingUnion(ctypes.Union): 123 | 124 | _fields_ = [("KBI", KeyBoardInput), 125 | ("MI", MouseInput), 126 | ("HI", HardwareInput)] 127 | 128 | 129 | # Creating a new structure which has both above union and unsigned long int data type 130 | class InputTaking(ctypes.Structure): 131 | _fields_ = [("type", ctypes.c_ulong), 132 | ("union", InputTakingUnion)] 133 | 134 | 135 | def PressTheKey(HexagonalKeyCode): 136 | 137 | value = ctypes.c_ulong(INITIAL_VALUE) 138 | Input = InputTakingUnion() 139 | 140 | Input.KBI = KeyBoardInput( 141 | INITIAL_VALUE, HexagonalKeyCode, 0x0008, INITIAL_VALUE, ctypes.pointer(value)) 142 | 143 | send = InputTaking(ctypes.c_ulong(FINAL_VALUE), Input) 144 | 145 | # Using the API to Press the Key based on the Provided Hexagonal Key Code. 146 | ctypes.windll.user32.SendInput( 147 | FINAL_VALUE, ctypes.pointer(send), ctypes.sizeof(send)) 148 | 149 | 150 | def ReleaseTheKey(HexagonalKeyCode): 151 | 152 | value = ctypes.c_ulong(INITIAL_VALUE) 153 | Input = InputTakingUnion() 154 | 155 | # "|" this is Bitwise OR operation 156 | Input.KBI = KeyBoardInput(INITIAL_VALUE, HexagonalKeyCode, 0x0008 | 0x0002, 157 | INITIAL_VALUE, ctypes.pointer(value)) 158 | 159 | send = InputTaking(ctypes.c_ulong(FINAL_VALUE), Input) 160 | 161 | # Using the API to Release the Pressed Key based on the Provided Hexagonal Key Code. 162 | ctypes.windll.user32.SendInput( 163 | FINAL_VALUE, ctypes.pointer(send), ctypes.sizeof(send)) 164 | 165 | 166 | # Dictionary to store Number of Bounding Boxes required in respective game. 167 | NoOfSwitchesDict = {'Mortal_Kombat': 5, 'Madalin_Stunt_Cars_2': 6} 168 | 169 | SwitchNames = {'Mortal_Kombat': ["Front Punch", 170 | "Back Punch", "Front Kick", "Back Kick", "Throw, Block, Interact"], 171 | 172 | 'Madalin_Stunt_Cars_2': ["Move Up", "Move Down", "Move Left", "Move Right", "Accelerate", "Hand Brake"]} 173 | 174 | 175 | Value2KeyMap_Games = {'Mortal_Kombat': {0: J_key, # Front Punch 176 | 1: I_key, # Back Punch 177 | 2: K_key, # Front Kick 178 | 3: L_key, # Back Kick 179 | 180 | 4: Space_key, # Throw -> Palm 181 | 5: O_key, # Block -> Fist 182 | 6: SemiColon_key, # Interact -> Swing 183 | }, 184 | 185 | 'Madalin_Stunt_Cars_2': {0: W_key, # Move Up 186 | 1: S_key, # Move Down 187 | 2: A_key, # Move Left 188 | 3: D_key, # Move Right 189 | 190 | 4: Shift_key, # Accelerate 191 | 5: Space_key, # Hand Brake 192 | 193 | }, } 194 | 195 | # This should come from the Web Page when Button is pressed. 196 | GameName = 'Madalin_Stunt_Cars_2' 197 | 198 | # Some Utility Functions 199 | 200 | 201 | def list_to_string(l): 202 | s = "" 203 | for i in l: 204 | s += (str(i) + ",") 205 | return s 206 | 207 | 208 | def string_to_list(s): 209 | s = s[:-1] 210 | a = [int(x) for x in s.split(",")] 211 | return a 212 | 213 | 214 | def listoflists_to_string(l): 215 | s = "" 216 | for i in l: 217 | s += (list_to_string(i) + "|") 218 | return s 219 | 220 | 221 | def string_to_listoflists(s): 222 | Final = [] 223 | 224 | s = s[:-1] 225 | a = [x for x in s.split("|")] 226 | 227 | for each in a: 228 | Final.append(string_to_list(each)) 229 | 230 | return Final 231 | 232 | 233 | """ 234 | Note: The references used are :- 235 | 236 | 1) http://www.philipstorr.id.au/pcbook/book3/scancode.htm 237 | 2) https://stackoverflow.com/questions/14489013/simulate-python-keypresses-for-controlling-a-game 238 | """ 239 | -------------------------------------------------------------------------------- /Web_App/GesturePredictor.py: -------------------------------------------------------------------------------- 1 | # Importing relevant libraries 2 | import cv2 3 | import imutils 4 | import tflearn 5 | import numpy as np 6 | from PIL import Image 7 | import tensorflow as tf 8 | 9 | from tensorflow.python.framework import ops 10 | from tflearn.layers.estimator import regression 11 | from tflearn.layers.conv import conv_2d, max_pool_2d 12 | from tflearn.layers.core import input_data, dropout, fully_connected 13 | 14 | # Import all the functionalities from Switch_Control 15 | from Web_App.Switch_Control import * 16 | 17 | # global variables 18 | bg = None 19 | 20 | 21 | def resizeImage(imageName): 22 | basewidth = 100 23 | img = Image.open(imageName) 24 | wpercent = (basewidth/float(img.size[0])) 25 | hsize = int((float(img.size[1])*float(wpercent))) 26 | img = img.resize((basewidth, hsize), Image.ANTIALIAS) 27 | img.save(imageName) 28 | 29 | 30 | def run_avg(image, aWeight): 31 | global bg 32 | # initialize the background 33 | if bg is None: 34 | bg = image.copy().astype("float") 35 | return 36 | 37 | # compute weighted average, accumulate it and update the background 38 | cv2.accumulateWeighted(image, bg, aWeight) 39 | 40 | 41 | def segment(image, threshold=25): 42 | global bg 43 | # find the absolute difference between background and current frame 44 | diff = cv2.absdiff(bg.astype("uint8"), image) 45 | 46 | # threshold the diff image so that we get the foreground 47 | thresholded = cv2.threshold(diff, 48 | threshold, 49 | 255, 50 | cv2.THRESH_BINARY)[1] 51 | 52 | # get the contours in the thresholded image 53 | (cnts, _) = cv2.findContours(thresholded.copy(), 54 | cv2.RETR_EXTERNAL, 55 | cv2.CHAIN_APPROX_SIMPLE) 56 | 57 | # return None, if no contours detected 58 | if len(cnts) == 0: 59 | return 60 | else: 61 | # based on contour area, get the maximum contour which is the hand 62 | segmented = max(cnts, key=cv2.contourArea) 63 | return (thresholded, segmented) 64 | 65 | 66 | def getPredictedClass(): 67 | 68 | image = cv2.imread('Temp.png') 69 | gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY) 70 | gray_image = cv2.resize(gray_image, (89, 100)) 71 | prediction = model.predict([gray_image.reshape(89, 100, 1)]) 72 | return np.argmax(prediction), (np.amax(prediction) / (prediction[0][0] + prediction[0][1] + prediction[0][2])) 73 | 74 | 75 | # Model defined 76 | ops.reset_default_graph() 77 | convnet = input_data(shape=[None, 89, 100, 1], name='input') 78 | convnet = conv_2d(convnet, 32, 2, activation='relu') 79 | convnet = max_pool_2d(convnet, 2) 80 | convnet = conv_2d(convnet, 64, 2, activation='relu') 81 | convnet = max_pool_2d(convnet, 2) 82 | 83 | convnet = conv_2d(convnet, 128, 2, activation='relu') 84 | convnet = max_pool_2d(convnet, 2) 85 | 86 | convnet = conv_2d(convnet, 256, 2, activation='relu') 87 | convnet = max_pool_2d(convnet, 2) 88 | 89 | convnet = conv_2d(convnet, 256, 2, activation='relu') 90 | convnet = max_pool_2d(convnet, 2) 91 | 92 | convnet = conv_2d(convnet, 128, 2, activation='relu') 93 | convnet = max_pool_2d(convnet, 2) 94 | 95 | convnet = conv_2d(convnet, 64, 2, activation='relu') 96 | convnet = max_pool_2d(convnet, 2) 97 | 98 | convnet = fully_connected(convnet, 1000, activation='relu') 99 | convnet = dropout(convnet, 0.75) 100 | 101 | convnet = fully_connected(convnet, 3, activation='softmax') 102 | 103 | convnet = regression(convnet, optimizer='adam', learning_rate=0.001, 104 | loss='categorical_crossentropy', name='regression') 105 | 106 | model = tflearn.DNN(convnet, tensorboard_verbose=0) 107 | 108 | # Load Saved Model 109 | model.load("Web_App/TrainedModel/GestureRecogModel.tfl") 110 | 111 | 112 | """ 113 | Note: This Trained Model for Hand Gesture Recognition is taken from 114 | https://github.com/SparshaSaha/Hand-Gesture-Recognition-Using-Background-Elllimination-and-Convolution-Neural-Network 115 | """ 116 | -------------------------------------------------------------------------------- /Web_App/SetupGame.py: -------------------------------------------------------------------------------- 1 | # Importing relevant libraries 2 | from skimage.exposure import is_low_contrast 3 | import cv2 4 | import time 5 | import numpy as np 6 | import imutils 7 | 8 | # Import all the functionalities from Switch_Control and Direct_Keys 9 | from Web_App.Direct_Keys import * 10 | from Web_App.Switch_Control import * 11 | 12 | 13 | class StartSetup(object): 14 | def __init__(self): 15 | self.url = cv2.VideoCapture(0) 16 | 17 | def __del__(self): 18 | cv2.destroyAllWindows() 19 | 20 | def get_frame(self): 21 | 22 | # For allowing web cam to open 23 | time.sleep(0.3) 24 | 25 | # Represents the Time given for the player to come to position to play game 26 | SetupTime = 5 27 | 28 | StartTime = time.time() 29 | 30 | # To Draw a rectangle/box around the frame with relevant text displayed 31 | while True: 32 | 33 | 34 | check,frame = GetFrame(self.url) 35 | 36 | # if we donot have sufficient light surrounding to user it will inform user 37 | if check==False : 38 | 39 | text = "For better Gaming Experience, make sure you have sufficient light in your environment!" 40 | 41 | color = (0, 0, 255) 42 | 43 | cv2.putText(frame, text, (10, 650), cv2.FONT_HERSHEY_SIMPLEX, 0.8,color, 2) 44 | 45 | CurrentTime = (time.time() - StartTime) 46 | if CurrentTime > SetupTime: 47 | break 48 | 49 | text = " You still have " + \ 50 | str(int(SetupTime - CurrentTime)+1) + " Seconds!" 51 | 52 | cv2.putText(frame, text, Coord_Text, 53 | Font_Type, Font_Scale, Text_Color, 4) 54 | 55 | cv2.imshow("Get Ready for Setup !!", frame) 56 | cv2.waitKey(1) 57 | 58 | cv2.destroyAllWindows() 59 | 60 | cv2.putText(frame, 'Make a box around Face', (30, 30), 61 | cv2.FONT_HERSHEY_SIMPLEX, 0.75, (0, 255, 0), 2) 62 | 63 | # bounding box for face 64 | bbox = cv2.selectROI(frame, False) 65 | 66 | # It destroys all the windows we created. 67 | cv2.destroyAllWindows() 68 | self.url.release() 69 | 70 | NoOfSwitches = NoOfSwitchesDict[GameName] 71 | 72 | buttons = Buttons(bbox, NoOfSwitches, Train=True) 73 | 74 | BoundingBoxFace = buttons.BoundingBoxFace 75 | 76 | BoundingBoxSwitchList = buttons.BoundingBoxSwitchList 77 | 78 | return ([BoundingBoxFace, BoundingBoxSwitchList]) 79 | -------------------------------------------------------------------------------- /Web_App/StartGame.py: -------------------------------------------------------------------------------- 1 | # Importing relevnt libraries 2 | from skimage.exposure import is_low_contrast 3 | import cv2 4 | import time 5 | import numpy as np 6 | import imutils 7 | 8 | # Import all the functionalities from Switch_Control and Direct_Keys 9 | from Web_App.Direct_Keys import * 10 | from Web_App.Switch_Control import * 11 | from Web_App.GesturePredictor import * 12 | from Web_App.models import BoundingBoxes 13 | 14 | ######################################################################################## 15 | 16 | 17 | def Start(request): 18 | 19 | # Getting the Recently stored Bounding Boxes from the Database 20 | bbox = BoundingBoxes.objects.filter(Game_Name=GameName).last() 21 | 22 | # Id = request.session['id'] 23 | # bbox = BoundingBoxes.objects.get(id=Id) 24 | 25 | # Conversion to required format. 26 | BoundingBoxFace = string_to_list(bbox.Face) 27 | BoundingBoxSwitchList = string_to_listoflists(bbox.Switches) 28 | 29 | # here we take number of switches respected to particular game 30 | NoOfSwitches = NoOfSwitchesDict[GameName] 31 | 32 | # Calling the Buttons class 33 | button = Buttons(BoundingBoxFace, NoOfSwitches, Train=False) 34 | 35 | # Here we use builtin CSRT traker of opencv for tracking user's face. 36 | tracker = cv2.TrackerCSRT_create() 37 | 38 | # Device index is just the number to specify which camera 39 | # Usually We have only one camera 40 | Device_index = 0 41 | 42 | # To get a video capture object for the camera. 43 | capture = cv2.VideoCapture(Device_index) 44 | 45 | # Represents the Time given for the player to come to position to play game 46 | SetupTime = 5 47 | 48 | StartTime = time.time() 49 | 50 | # To Draw a rectangle/box around the frame with relevant text displayed 51 | while True: 52 | 53 | check, frame = GetFrame(capture) 54 | 55 | # if we donot have sufficient light surrounding to user it will inform user 56 | if check == False: 57 | 58 | text = "For better Gaming Experience, make sure you have sufficient light in your environment!" 59 | 60 | color = (0, 0, 255) 61 | 62 | cv2.putText(frame, text, (10, 650), 63 | cv2.FONT_HERSHEY_SIMPLEX, 0.8, color, 2) 64 | 65 | CurrentTime = (time.time() - StartTime) 66 | 67 | if CurrentTime > SetupTime: 68 | break 69 | 70 | text = " You have " + \ 71 | str(int(SetupTime - CurrentTime)+1) + " Seconds !" 72 | 73 | cv2.putText(frame, text, Coord_Text, 74 | Font_Type, Font_Scale, Text_Color, 4) 75 | 76 | DrawBox(BoundingBoxFace, frame) 77 | 78 | cv2.imshow("Get Ready for Playing the Game !!", frame) 79 | cv2.waitKey(1) 80 | 81 | cv2.destroyAllWindows() 82 | 83 | # Initialising the Tracker for the User's Face 84 | tracker.init(frame, BoundingBoxFace) 85 | 86 | #################################### 87 | # Quantitites that help in Hand Gesture Recognition 88 | 89 | x, y, w, h = (679, 104, 200, 200) 90 | (left, top) = (x+w, y) 91 | (right, bottom) = (x, y+h) 92 | aWeight = 0.5 93 | 94 | # initialize num of frames 95 | num_frames = 0 96 | start_recording = False 97 | ########################################## 98 | 99 | # Once the Setup time finishes, the user actions will be recorded, and will be mapped to key in game. 100 | while True: 101 | 102 | check, frame = GetFrame(capture) 103 | 104 | # if we donot have sufficient light surrounding to user it will inform user 105 | if check == False: 106 | 107 | text = "For better Gaming Experience, make sure you have sufficient light in your environment!" 108 | 109 | color = (0, 0, 255) 110 | 111 | cv2.putText(frame, text, (10, 650), 112 | cv2.FONT_HERSHEY_SIMPLEX, 0.8, color, 2) 113 | 114 | # It will update frame with respect to traker positon 115 | Success, BoundingBoxRectangleFace = tracker.update(frame) 116 | 117 | # Updating BoundingBoxFace on when Success is True 118 | if Success: 119 | BoundingBoxFace = [int(x) for x in BoundingBoxRectangleFace] 120 | 121 | DrawBox(BoundingBoxFace, frame) 122 | 123 | clone = frame.copy() 124 | 125 | # get the height and width of the frame 126 | (height, width) = frame.shape[:2] 127 | 128 | # get the ROI 129 | roi = frame[top:bottom, right:left] 130 | 131 | # convert the roi to grayscale and blur it 132 | gray = cv2.cvtColor(roi, cv2.COLOR_BGR2GRAY) 133 | gray = cv2.GaussianBlur(gray, (7, 7), 0) 134 | 135 | # to get the background, keep looking till a threshold is reached 136 | # so that our running average model gets calibrated 137 | if num_frames < 30: 138 | run_avg(gray, aWeight) 139 | else: 140 | # segment the hand region 141 | hand = segment(gray) 142 | 143 | # check whether hand region is segmented 144 | if hand is not None: 145 | # if yes, unpack the thresholded image and 146 | # segmented region 147 | (thresholded, segmented) = hand 148 | 149 | # draw the segmented region and display the frame 150 | cv2.drawContours( 151 | clone, [segmented + (right, top)], -1, (0, 0, 255)) 152 | if start_recording: 153 | cv2.imwrite('Temp.png', thresholded) 154 | resizeImage('Temp.png') 155 | 156 | # draw the segmented hand 157 | cv2.rectangle(clone, (left, top), (right, bottom), (0, 255, 0), 2) 158 | 159 | # increment the number of frames 160 | num_frames += 1 161 | 162 | # Using the previously defined run function 163 | button.run(frame, FindCenter(BoundingBoxFace)) 164 | 165 | # Original video frames 166 | cv2.imshow("Tracking", frame) 167 | # cv2.resizeWindow("Tracking", 1000, 600) 168 | 169 | # If the user presses "q", then stop looping 170 | if cv2.waitKey(1) == ord("q"): 171 | break 172 | 173 | start_recording = True 174 | 175 | # It shut downs the webcam 176 | capture.release() 177 | 178 | # It destroys all the windows we created. 179 | cv2.destroyAllWindows() 180 | -------------------------------------------------------------------------------- /Web_App/Switch_Control.py: -------------------------------------------------------------------------------- 1 | # Import the required Libraries 2 | from Web_App.models import BoundingBoxes 3 | 4 | # from GameSetup import BoundingBoxFace, BoundingBoxSwitchList 5 | from skimage.exposure import is_low_contrast 6 | import cv2 7 | import imutils 8 | import time 9 | import numpy as np 10 | 11 | from Web_App.Direct_Keys import * 12 | ############################################################################### 13 | bbox = BoundingBoxes.objects.filter(Game_Name=GameName).last() 14 | BoundingBoxFace = string_to_list(bbox.Face) 15 | if (len(bbox.Switches) != 0): 16 | BoundingBoxSwitchList = string_to_listoflists(bbox.Switches) 17 | 18 | # Utility Function that Calculates and returns the Center of rectangle. 19 | 20 | 21 | def FindCenter(rectangle_box): 22 | 23 | x, y, w, h = rectangle_box 24 | 25 | # (x, y) -> Top Left Coordinates of the Box 26 | # w -> Width of the Box 27 | # h -> Height of the Box 28 | 29 | centre_x = int(x+w/2) 30 | centre_y = int(y+h/2) 31 | 32 | return (centre_x, centre_y) 33 | 34 | # Utility function that draw rectangle in frame 35 | 36 | 37 | def DrawBox(rectangle_box, frame): 38 | 39 | # Pixel values of Color in (B,G,R) format 40 | Color = (0, 255, 255) 41 | 42 | Line_thickness = 1 43 | x, y, w, h = rectangle_box 44 | Top_Left_Coordinates = (x, y) 45 | Bottom_Right_Coordinates = (x+w, y+h) 46 | 47 | # It draws rectangle on the frame at provided coordinates 48 | cv2.rectangle(frame, Top_Left_Coordinates, 49 | Bottom_Right_Coordinates, Color, Line_thickness) 50 | 51 | 52 | # Utility Function that returns frames 53 | def GetFrame(capture): 54 | 55 | _, frame = capture.read() 56 | 57 | # Flip a 2D array. "1" means flipping around y-axis 58 | frame = cv2.flip(frame, 1) 59 | 60 | frame = cv2.resize(frame, dsize=(900, 700)) 61 | gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY) 62 | 63 | check = True 64 | # Here we try to check either surrounding to user have not low intensity of light 65 | # if light present surrounding to user is less than 30% we not take picture of it 66 | if is_low_contrast(gray, fraction_threshold=0.30): 67 | 68 | check = False 69 | 70 | return check, frame 71 | 72 | ############################################################################### 73 | # We define some global parameters so that its easier for us to tweak when required. 74 | 75 | 76 | # We will activate the Switch, If Noise Level caused due to change in the pixels exceeds this Threshold value 77 | Threshold = 400 78 | 79 | # It is the coordinates of the bottom-left corner of the text string in the image 80 | Coord_Text = (50, 50) 81 | 82 | # It is the Type(style) of font being used 83 | Font_Type = cv2.FONT_HERSHEY_SIMPLEX 84 | 85 | # Font scale factor that is multiplied by the font-specific base size 86 | Font_Scale = 1.25 87 | 88 | # It is font color in BGR(Blue,Green,Red) format 89 | Text_Color = (255, 0, 255) 90 | 91 | # It is the thickness of the line in px 92 | Thickness = 2 93 | 94 | 95 | # List of Actions for which switches(except the last one) are being mapped into. 96 | CorrespondGameKeyName = SwitchNames[GameName] 97 | 98 | # Used for writing corresponding CorrespondGameKeyName on screen 99 | Count = 0 100 | ############################################################################### 101 | 102 | 103 | class VirtualSwitch(): 104 | 105 | def __init__(self, BoundingBoxFace, BoundingBoxSwitch=None, Threshold=100, SwitchingDelay=0.0001): 106 | 107 | self.Threshold = Threshold 108 | 109 | # For Avoiding the Continuous Pressing of Switch 110 | self.SwitchingDelay = SwitchingDelay 111 | 112 | self.LastSwitchTime = time.time() 113 | 114 | # Using the most efficient and accurate BackgroundSubstracter 115 | 116 | # It removes the Background noise and leaves only movable objects in a grayscale images 117 | self.backgroundobject = cv2.bgsegm.createBackgroundSubtractorMOG() 118 | 119 | # Creating kernal matrix (4X4) which is used for morphological operations that is for a broad set of image processing operations that process images based on shapes. 120 | self.kernel = cv2.getStructuringElement( 121 | cv2.MORPH_RECT, (4, 4)) 122 | 123 | if BoundingBoxSwitch: 124 | self.BoundingBoxSwitch = BoundingBoxSwitch 125 | 126 | else: 127 | self.Setup(BoundingBoxFace) 128 | 129 | def Setup(self, BoundingBoxFace): 130 | """ 131 | This sets up the Boundary Box for the Switch based on user Response 132 | """ 133 | 134 | # Timer for capturing base image, get reading in posture 135 | Setup_Time = 5 136 | 137 | # Keeping track of Time 138 | start_time = time.time() 139 | 140 | # Device index is just the number to specify which camera 141 | # Usually We have only one camera 142 | Device_index = 0 143 | 144 | # To get a video capture object for the camera. 145 | capture = cv2.VideoCapture(Device_index) 146 | 147 | while True: 148 | 149 | _, frame = capture.read() 150 | 151 | # Flip a 2D array. "1" means flipping around y-axis 152 | frame = cv2.flip(frame, 1) 153 | 154 | frame = cv2.resize(frame, dsize=(900, 700)) 155 | 156 | gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY) 157 | 158 | # Here we try to check either surrounding to user have not low intensity of light 159 | # if light present surrounding to user is less than 30% we not take picture of it 160 | if is_low_contrast(gray, fraction_threshold=0.30): 161 | 162 | text = "Low contrast: Yes Please visit where you have atleast 30 % light " 163 | 164 | color = (0, 0, 255) 165 | 166 | cv2.putText(frame, text, (10, 650), 167 | cv2.FONT_HERSHEY_SIMPLEX, 0.8, color, 2) 168 | 169 | current_time = (time.time() - start_time) 170 | 171 | if current_time > Setup_Time: 172 | break 173 | 174 | Text = " You still have " + \ 175 | str(int(Setup_Time - current_time)+1) + " Seconds!" 176 | 177 | cv2.putText(frame, Text, 178 | Coord_Text, Font_Type, Font_Scale, Text_Color, Thickness) 179 | 180 | DrawBox(BoundingBoxFace, frame) 181 | 182 | cv2.imshow("Get Ready for Setup !!", frame) 183 | 184 | cv2.waitKey(1) 185 | 186 | # It simply destroys all the windows we created. 187 | cv2.destroyAllWindows() 188 | 189 | cv2.putText(frame, 'Select region for {} Switch'.format(CorrespondGameKeyName[Count-1]), Coord_Text, 190 | Font_Type, Font_Scale, Text_Color, Thickness) 191 | 192 | # crosshair of selection rectangle will be shown. 193 | self.BoundingBoxSwitch = cv2.selectROI(frame, showCrosshair=True) 194 | 195 | # Use `space` or `enter` to finish selection, use key `c` to cancel selection. 196 | cv2.destroyAllWindows() 197 | 198 | def isActivated(self, frame): 199 | """ 200 | This returns `True` if Switch is pressed that is it is activated. 201 | """ 202 | 203 | # Checking if Bounding Box of the Switch goes outside the Frame 204 | try: 205 | 206 | # Picking up the switch region from the Frame 207 | x, y, w, h = self.BoundingBoxSwitch 208 | Switch_Region = frame[y:y+h, x:x+w] 209 | 210 | # Applying the Background Subtractor on this region of Switch 211 | Switch_Region_after_BGS = self.backgroundobject.apply( 212 | Switch_Region) 213 | 214 | # Morphological transformations are some simple operations based on the image shape. 215 | 216 | # We are performing Erosion followed by dilation 217 | # Dilation -> Adding imporatant imformation which lost during BackgroundSubstracter process 218 | # Erosion -> Remove unnessary noise which may possible add during dilation 219 | 220 | Switch_Region_Final = cv2.morphologyEx( 221 | Switch_Region_after_BGS, cv2.MORPH_OPEN, self.kernel, iterations=2) 222 | 223 | except: 224 | return False 225 | 226 | else: 227 | 228 | # Checking number of pixels changed by finding all the pixels that have value of 255 229 | # 255 pixel value represents complete White. 230 | switch_thresh = np.sum(Switch_Region_Final == 255) 231 | 232 | Text = "Number of Pixels changed : " + str(switch_thresh) 233 | 234 | cv2.putText(frame, Text, 235 | Coord_Text, Font_Type, Font_Scale, Text_Color, Thickness) 236 | 237 | # This shows our Region of Interest which is acting as Virtual Switch 238 | DrawBox(self.BoundingBoxSwitch, frame) 239 | 240 | if (time.time() - self.LastSwitchTime) < self.SwitchingDelay: 241 | DrawBox(self.BoundingBoxSwitch, frame) 242 | 243 | # Checking whether Switch is activated or not 244 | if (switch_thresh > Threshold) and ((time.time() - self.LastSwitchTime) > self.SwitchingDelay): 245 | 246 | DrawBox(self.BoundingBoxSwitch, frame) 247 | 248 | # Since Switch is activated, We Update the Last Time Switch Activation time. 249 | self.LastSwitchTime = time.time() 250 | 251 | return True 252 | 253 | return False 254 | 255 | 256 | class Buttons: 257 | 258 | """ 259 | For storing Switch objects and for deciding which Switch is to be pressed based on current frame. 260 | """ 261 | 262 | def __init__(self, BoundingBoxFace, NumberofSwitches=0, Train=False): 263 | 264 | self.Train = Train 265 | 266 | if Train: 267 | self.NumberofSwitches = NumberofSwitches 268 | self.BoundingBoxFace = BoundingBoxFace 269 | self.FaceCenter = FindCenter(self.BoundingBoxFace) 270 | 271 | # To store Bounding Boxes of all the Switches 272 | self.BoundingBoxSwitchList = [] 273 | 274 | else: 275 | self.NumberofSwitches = NumberofSwitches 276 | self.BoundingBoxFace = BoundingBoxFace 277 | 278 | self.FaceCenter = FindCenter(self.BoundingBoxFace) 279 | 280 | self.BoundingBoxSwitchList = BoundingBoxSwitchList 281 | 282 | # Calling the Function to setup the Bounding Boxes for Switches 283 | self.SetupSwitchBoundingBox() 284 | 285 | # Calling the Actions object 286 | self.action = Actions(self.FaceCenter, 5) 287 | 288 | # For Setup of Bounding Boxes for the Switches which are our regions of interest to provide action 289 | 290 | def SetupSwitchBoundingBox(self): 291 | 292 | # To store all the switch objects 293 | self.Switches = [] 294 | 295 | # To store Bounding Boxes of all the Switches wrt to the Center of Bounding Box of the User's face. 296 | self.BoundingBoxWrtCenterList = [] 297 | 298 | # Creating Bounding Boxes using our Virtual Switch Class. 299 | for i in range(self.NumberofSwitches): 300 | 301 | if self.Train: 302 | global Count 303 | Count = Count+1 304 | Switch_i = VirtualSwitch(self.BoundingBoxFace) 305 | 306 | self.BoundingBoxSwitchList.append(Switch_i.BoundingBoxSwitch) 307 | 308 | else: 309 | 310 | BBoxSwitch = self.BoundingBoxSwitchList[i] 311 | Switch_i = VirtualSwitch(self.BoundingBoxFace, BBoxSwitch) 312 | 313 | self.Switches.append(Switch_i) 314 | 315 | # Evaluating the Position of Bounding Boxes Position wrt Center of Bounding Box of the User's face. 316 | self.BoundingBoxWrtCenterList.append(self.BoundingBoxWrtCenter( 317 | Switch_i.BoundingBoxSwitch)) 318 | 319 | if self.Train: 320 | # Save this Printed Data For Later Use 321 | print( 322 | f'BoundingBoxFace = {self.BoundingBoxFace} \nBoundingBoxSwitches = {self.BoundingBoxSwitchList}') 323 | 324 | # Finds the relative position of the Bounding Box with respect to Center of User's Face. 325 | 326 | def BoundingBoxWrtCenter(self, BoundingBox): 327 | x_Center, y_Center = self.FaceCenter 328 | x, y, w, h = BoundingBox 329 | X, Y = x - x_Center, y - y_Center 330 | New_Position = (X, Y, w, h) 331 | return New_Position 332 | 333 | # Updates the Bounding Box to the new position with respect to Center of User's Face. 334 | def BoundingBoxUpdate(self, BoundingBox): 335 | x_Center, y_Center = self.FaceCenter 336 | x, y, w, h = BoundingBox 337 | X, Y = x + x_Center, y + y_Center 338 | New_Position = (X, Y, w, h) 339 | return New_Position 340 | 341 | # Presses the Buttons when Switches are activated. 342 | def run(self, frame, PresentCenter): 343 | 344 | self.PresentCenter = PresentCenter 345 | 346 | for each_switch in range(self.NumberofSwitches): 347 | 348 | switch, bbox = self.Switches[each_switch], self.BoundingBoxWrtCenterList[each_switch] 349 | 350 | switch.bbox = self.BoundingBoxUpdate(bbox) 351 | 352 | pressed = switch.isActivated(frame) 353 | 354 | if pressed and (each_switch != self.NumberofSwitches-1): 355 | self.action.PressValue(each_switch) 356 | 357 | if pressed and (each_switch == self.NumberofSwitches-1): 358 | 359 | if (GameName == 'Mortal_Kombat'): 360 | 361 | from GesturePredictor import getPredictedClass 362 | 363 | pred = getPredictedClass() 364 | 365 | if pred[0] == 0: # Swing 366 | self.action.PressValue(6) 367 | if pred[0] == 1: # Palm 368 | self.action.PressValue(4) 369 | if pred[0] == 2: # Fist 370 | self.action.PressValue(5) 371 | 372 | if (GameName == 'Madalin_Stunt_Cars_2'): 373 | self.action.PressValue(each_switch) 374 | 375 | # this activate when user do some jumping,or forward or backward motion 376 | if (GameName == 'Mortal_Kombat'): 377 | self.action.MovementAction(PresentCenter) 378 | 379 | 380 | class Actions(): 381 | 382 | """ Used for mapping the Virtual Switches with respective keys for Actions in the games. 383 | """ 384 | 385 | def __init__(self, FaceCenter, ActionThreshold): 386 | 387 | self.FaceCenter = FaceCenter 388 | self.ActionThreshold = ActionThreshold 389 | 390 | self.Previous = FaceCenter 391 | self.Middle = FaceCenter 392 | 393 | # Key for Up or Down movement of the User. 394 | self.VerticalKey = None 395 | 396 | # Key for Left or Right movement of the User. 397 | self.HorizontalKey = None 398 | 399 | # Reference line which is horizontal & passing through face. (Y Coordinate) 400 | self.ReferenceLine = FaceCenter[1] 401 | 402 | # To jump Up or Down. 403 | self.VerticalThreshold = 45 404 | 405 | # To move towards Left or Right. 406 | self.HorizontalThreshold = 20 407 | 408 | # Mapping the Switch index value to a corresponding Key to perform Action in the game. 409 | 410 | self.Value2KeyMap = Value2KeyMap_Games[GameName] 411 | 412 | def PressValue(self, value): 413 | 414 | if self.HorizontalKey != None: 415 | return 416 | 417 | key = self.Value2Key(value) 418 | self.PressAndReleaseTheKey(key) 419 | 420 | def Value2Key(self, value): 421 | 422 | key = self.Value2KeyMap[value] 423 | return key 424 | 425 | def PressAndReleaseTheKey(self, key, ContDelay=0.00001, DiscontDelay=0.00009, isContinued=False): 426 | 427 | # First, We Press the Key 428 | PressTheKey(key) 429 | 430 | if isContinued: 431 | # There is no Delay 432 | pass 433 | 434 | else: 435 | # There is some delay between Press and Release 436 | time.sleep(DiscontDelay) 437 | ReleaseTheKey(key) 438 | 439 | # Setting the delay for continous press 440 | time.sleep(ContDelay) 441 | 442 | # It monitors the User's Movement action 443 | def MovementAction(self, position): 444 | 445 | self.Current = position 446 | 447 | ChangeInX = self.Current[0] - self.Previous[0] 448 | ChangeInY = self.Current[1] - self.ReferenceLine 449 | 450 | if abs(self.Current[0] - self.Middle[0]) > self.HorizontalThreshold: 451 | 452 | index = 1 453 | if ChangeInX > 0: 454 | index = 2 455 | 456 | for j in range(index): 457 | self.HorizontalAction(ChangeInX) 458 | 459 | if np.absolute(ChangeInY) > self.VerticalThreshold: 460 | 461 | self.VerticalAction(ChangeInY) 462 | 463 | self.Previous = position 464 | 465 | # For monitoring User's Horizontal Action 466 | def HorizontalAction(self, Delta): 467 | 468 | if np.absolute(Delta) < self.ActionThreshold: 469 | 470 | self.Middle = self.Current 471 | 472 | if self.HorizontalKey != None: 473 | 474 | ReleaseTheKey(self.HorizontalKey) 475 | 476 | self.HorizontalKey = None 477 | return 478 | 479 | # Move to the Left 480 | if Delta < 0: 481 | self.HorizontalKey = A_key 482 | 483 | # Move to the Right 484 | else: 485 | self.HorizontalKey = D_key 486 | 487 | self.PressAndReleaseTheKey(self.HorizontalKey, True) 488 | 489 | # For monitoring User's Vertical motion Action 490 | def VerticalAction(self, Delta): 491 | 492 | if (Delta < 75) and (self.VerticalKey == S_key): 493 | 494 | ReleaseTheKey(self.VerticalKey) 495 | 496 | self.VerticalKey = None 497 | 498 | if (Delta > -45) and (self.VerticalKey == W_key): 499 | 500 | ReleaseTheKey(self.VerticalKey) 501 | 502 | self.VerticalKey = None 503 | 504 | isContinued = False 505 | 506 | # Monitering Jump 507 | if Delta < -45: 508 | self.VerticalKey = W_key 509 | 510 | # Monitering Duck 511 | elif Delta > 75: 512 | self.VerticalKey = S_key 513 | isContinued = True 514 | 515 | else: 516 | return 517 | 518 | self.PressAndReleaseTheKey(self.VerticalKey, isContinued) 519 | 520 | 521 | Count = 0 522 | -------------------------------------------------------------------------------- /Web_App/TrainedModel/GestureRecogModel.tfl.data-00000-of-00001: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/Web_App/TrainedModel/GestureRecogModel.tfl.data-00000-of-00001 -------------------------------------------------------------------------------- /Web_App/TrainedModel/GestureRecogModel.tfl.index: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/Web_App/TrainedModel/GestureRecogModel.tfl.index -------------------------------------------------------------------------------- /Web_App/TrainedModel/GestureRecogModel.tfl.meta: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/Web_App/TrainedModel/GestureRecogModel.tfl.meta -------------------------------------------------------------------------------- /Web_App/TrainedModel/README.md: -------------------------------------------------------------------------------- 1 | Contains the Open Sourced Deep Learning Model that helps in Hand Gesture Recognition 2 | -------------------------------------------------------------------------------- /Web_App/TrainedModel/checkpoint: -------------------------------------------------------------------------------- 1 | model_checkpoint_path: "C:\\Users\\t-spsah\\Documents\\Hand-Gesture-Recognition-Using-Background-Elllimination-and-Convolution-Neural-Network\\TrainedModel\\GestureRecogModel.tfl" 2 | all_model_checkpoint_paths: "C:\\Users\\t-spsah\\Documents\\Hand-Gesture-Recognition-Using-Background-Elllimination-and-Convolution-Neural-Network\\TrainedModel\\GestureRecogModel.tfl" 3 | -------------------------------------------------------------------------------- /Web_App/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/Web_App/__init__.py -------------------------------------------------------------------------------- /Web_App/asgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | ASGI config for Web_App project. 3 | 4 | It exposes the ASGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.1/howto/deployment/asgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.asgi import get_asgi_application 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'Web_App.settings') 15 | 16 | application = get_asgi_application() 17 | -------------------------------------------------------------------------------- /Web_App/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | 3 | 4 | class BoundingBoxes(models.Model): 5 | 6 | Game_Name = models.TextField() 7 | Face = models.TextField() 8 | Switches = models.TextField() 9 | -------------------------------------------------------------------------------- /Web_App/settings.py: -------------------------------------------------------------------------------- 1 | """ 2 | Django settings for Web_App project. 3 | 4 | Generated by 'django-admin startproject' using Django 3.1.4. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.1/topics/settings/ 8 | 9 | For the full list of settings and their values, see 10 | https://docs.djangoproject.com/en/3.1/ref/settings/ 11 | """ 12 | 13 | from pathlib import Path 14 | import os 15 | 16 | # Build paths inside the project like this: BASE_DIR / 'subdir'. 17 | BASE_DIR = Path(__file__).resolve().parent.parent 18 | 19 | 20 | # Quick-start development settings - unsuitable for production 21 | # See https://docs.djangoproject.com/en/3.1/howto/deployment/checklist/ 22 | 23 | # SECURITY WARNING: keep the secret key used in production secret! 24 | SECRET_KEY = 'io6sce#5o(g%gw=$kfwaec34!s*yd^qge28*+df3&_!2wa3=7q' 25 | 26 | # SECURITY WARNING: don't run with debug turned on in production! 27 | DEBUG = True 28 | 29 | ALLOWED_HOSTS = ["*"] 30 | 31 | 32 | # Application definition 33 | 34 | INSTALLED_APPS = [ 35 | 'django.contrib.admin', 36 | 'django.contrib.auth', 37 | 'django.contrib.contenttypes', 38 | 'django.contrib.sessions', 39 | 'django.contrib.messages', 40 | 'django.contrib.staticfiles', 41 | 42 | 'Web_App', 43 | ] 44 | 45 | MIDDLEWARE = [ 46 | 'django.middleware.security.SecurityMiddleware', 47 | 'whitenoise.middleware.WhiteNoiseMiddleware', 48 | 'django.contrib.sessions.middleware.SessionMiddleware', 49 | 'django.middleware.common.CommonMiddleware', 50 | 'django.middleware.csrf.CsrfViewMiddleware', 51 | 'django.contrib.auth.middleware.AuthenticationMiddleware', 52 | 'django.contrib.messages.middleware.MessageMiddleware', 53 | 'django.middleware.clickjacking.XFrameOptionsMiddleware', 54 | ] 55 | 56 | ROOT_URLCONF = 'Web_App.urls' 57 | 58 | STATICFILES_DIRS = [ 59 | os.path.join(BASE_DIR, 'static'), 60 | ] 61 | 62 | TEMPLATES = [ 63 | { 64 | 'BACKEND': 'django.template.backends.django.DjangoTemplates', 65 | 'DIRS': ['templates'], 66 | 'APP_DIRS': True, 67 | 'OPTIONS': { 68 | 'context_processors': [ 69 | 'django.template.context_processors.debug', 70 | 'django.template.context_processors.request', 71 | 'django.contrib.auth.context_processors.auth', 72 | 'django.contrib.messages.context_processors.messages', 73 | ], 74 | }, 75 | }, 76 | ] 77 | 78 | WSGI_APPLICATION = 'Web_App.wsgi.application' 79 | 80 | STATICFILES_STORAGE = 'whitenoise.storage.CompressedManifestStaticFilesStorage' 81 | 82 | 83 | # Database 84 | # https://docs.djangoproject.com/en/3.1/ref/settings/#databases 85 | 86 | DATABASES = { 87 | 'default': { 88 | 'ENGINE': 'django.db.backends.sqlite3', 89 | 'NAME': BASE_DIR / 'db.sqlite3', 90 | } 91 | } 92 | 93 | 94 | # Password validation 95 | # https://docs.djangoproject.com/en/3.1/ref/settings/#auth-password-validators 96 | 97 | AUTH_PASSWORD_VALIDATORS = [ 98 | { 99 | 'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator', 100 | }, 101 | { 102 | 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', 103 | }, 104 | { 105 | 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator', 106 | }, 107 | { 108 | 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator', 109 | }, 110 | ] 111 | 112 | 113 | # Internationalization 114 | # https://docs.djangoproject.com/en/3.1/topics/i18n/ 115 | 116 | LANGUAGE_CODE = 'en-us' 117 | 118 | TIME_ZONE = 'UTC' 119 | 120 | USE_I18N = True 121 | 122 | USE_L10N = True 123 | 124 | USE_TZ = True 125 | 126 | 127 | # Static files (CSS, JavaScript, Images) 128 | # https://docs.djangoproject.com/en/3.1/howto/static-files/ 129 | 130 | STATIC_URL = '/static/' 131 | STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles') 132 | -------------------------------------------------------------------------------- /Web_App/urls.py: -------------------------------------------------------------------------------- 1 | """Web_App URL Configuration 2 | 3 | The `urlpatterns` list routes URLs to views. For more information please see: 4 | https://docs.djangoproject.com/en/3.1/topics/http/urls/ 5 | Examples: 6 | Function views 7 | 1. Add an import: from my_app import views 8 | 2. Add a URL to urlpatterns: path('', views.home, name='home') 9 | Class-based views 10 | 1. Add an import: from other_app.views import Home 11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') 12 | Including another URLconf 13 | 1. Import the include() function: from django.urls import include, path 14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) 15 | """ 16 | from django.contrib import admin 17 | from django.urls import path 18 | from . import views 19 | 20 | urlpatterns = [ 21 | path('', views.home), 22 | path('front_web_1.html', views.home), 23 | path('game_page.html', views.game_page), 24 | path('about_us.html', views.about_us), 25 | path('game_mortal.html', views.game_mortal), 26 | path('admin.html', admin.site.urls), 27 | path('game_car.html', views.game_car), 28 | path('start_setup_car', views.start_setup_car, name='start_setup_car'), 29 | path('start_game_car', views.start_game_car, name='start_game_car'), 30 | path('start_setup_mortal', views.start_setup_mortal, name='start_setup_mortal'), 31 | path('start_game_mortal', views.start_game_mortal, name='start_game_mortal'), 32 | 33 | ] 34 | -------------------------------------------------------------------------------- /Web_App/views.py: -------------------------------------------------------------------------------- 1 | from django.shortcuts import render, redirect 2 | from django.http.response import StreamingHttpResponse 3 | from Web_App.SetupGame import StartSetup 4 | from Web_App.StartGame import Start 5 | from Web_App.models import BoundingBoxes 6 | from Web_App.Direct_Keys import * 7 | 8 | 9 | def home(request): 10 | return render(request, 'front_web_1.html') 11 | 12 | 13 | def game_page(request): 14 | return render(request, 'game_page.html') 15 | 16 | 17 | def game_car(request): 18 | return render(request, 'game_car.html') 19 | 20 | 21 | def game_mortal(request): 22 | return render(request, 'game_mortal.html') 23 | 24 | 25 | def about_us(request): 26 | return render(request, 'about_us.html') 27 | 28 | 29 | def start_setup_car(request): 30 | cam = StartSetup() 31 | Result_Setup_car = cam.get_frame() 32 | res = BoundingBoxes() 33 | res.Game_Name = GameName 34 | res.Face = list_to_string(Result_Setup_car[0]) 35 | res.Switches = listoflists_to_string(Result_Setup_car[1]) 36 | res.save() 37 | # request.session['id'] = res.id 38 | return render(request, 'game_car.html') 39 | 40 | 41 | def start_game_car(request): 42 | temp = Start(request) 43 | return render(request, 'game_car.html') 44 | 45 | 46 | def start_setup_mortal(request): 47 | cam = StartSetup() 48 | Result_Setup_mortal = cam.get_frame() 49 | res = BoundingBoxes() 50 | res.Game_Name = GameName 51 | res.Face = list_to_string(Result_Setup_mortal[0]) 52 | res.Switches = listoflists_to_string(Result_Setup_mortal[1]) 53 | res.save() 54 | # request.session['id'] = res.id 55 | return render(request, 'game_mortal.html') 56 | 57 | 58 | def start_game_mortal(request): 59 | temp = Start(request) 60 | return render(request, 'game_mortal.html') 61 | -------------------------------------------------------------------------------- /Web_App/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for Web_App project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.1/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | from django.core.wsgi import get_wsgi_application 12 | from whitenoise import WhiteNoise 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'Web_App.settings') 15 | 16 | application = get_wsgi_application() 17 | application = WhiteNoise(application) -------------------------------------------------------------------------------- /appspec.yml: -------------------------------------------------------------------------------- 1 | version: 0.0 2 | os: windows 3 | files: 4 | - source: / 5 | destination: /var/www/html/ 6 | hooks: 7 | BeforeInstall: 8 | - location: scripts/install_dependencies 9 | timeout: 300 10 | runas: root 11 | - location: scripts/start_server 12 | timeout: 300 13 | runas: root 14 | ApplicationStop: 15 | - location: scripts/stop_server 16 | timeout: 300 17 | runas: root 18 | -------------------------------------------------------------------------------- /db.sqlite3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/db.sqlite3 -------------------------------------------------------------------------------- /manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | """Django's command-line utility for administrative tasks.""" 3 | import os 4 | import sys 5 | 6 | 7 | def main(): 8 | """Run administrative tasks.""" 9 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'Web_App.settings') 10 | try: 11 | from django.core.management import execute_from_command_line 12 | except ImportError as exc: 13 | raise ImportError( 14 | "Couldn't import Django. Are you sure it's installed and " 15 | "available on your PYTHONPATH environment variable? Did you " 16 | "forget to activate a virtual environment?" 17 | ) from exc 18 | execute_from_command_line(sys.argv) 19 | 20 | 21 | if __name__ == '__main__': 22 | main() 23 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | Django>=3.1.6 2 | imutils==0.5.4 3 | tensorflow>=2.4.0 4 | tflearn==0.5.0 5 | opencv-contrib-python==4.5.1.48 6 | scikit-image==0.18.1 7 | whitenoise==5.2.0 8 | -------------------------------------------------------------------------------- /scripts/install_dependencies: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | yum install -y httpd 3 | 4 | -------------------------------------------------------------------------------- /scripts/start_server: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | service httpd start 3 | 4 | -------------------------------------------------------------------------------- /scripts/stop_server: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | isExistApp = `pgrep httpd` 3 | if [[ -n $isExistApp ]]; then 4 | service httpd stop 5 | fi 6 | 7 | -------------------------------------------------------------------------------- /static/Images/Cool_game.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Cool_game.jpg -------------------------------------------------------------------------------- /static/Images/Cool_image3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Cool_image3.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Adwait_Agashe.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Adwait_Agashe.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Ashutosh_Saxena.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Ashutosh_Saxena.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Ravi_Prakash_Singh.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Ravi_Prakash_Singh.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Rishabh_Tripathi.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Rishabh_Tripathi.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Sanjay_Marreddi.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Sanjay_Marreddi.jpg -------------------------------------------------------------------------------- /static/Images/TeamMembers/Sneha_Jayaganthan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/TeamMembers/Sneha_Jayaganthan.png -------------------------------------------------------------------------------- /static/Images/Untitled design.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Untitled design.png -------------------------------------------------------------------------------- /static/Images/Website_Glimpses/each_game.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Website_Glimpses/each_game.gif -------------------------------------------------------------------------------- /static/Images/Website_Glimpses/game_play.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Website_Glimpses/game_play.gif -------------------------------------------------------------------------------- /static/Images/Website_Glimpses/games_page.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Website_Glimpses/games_page.gif -------------------------------------------------------------------------------- /static/Images/Website_Glimpses/home_page.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/Website_Glimpses/home_page.gif -------------------------------------------------------------------------------- /static/Images/about_us_bottom.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 10 | 11 | -------------------------------------------------------------------------------- /static/Images/about_us_top.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 9 | 10 | -------------------------------------------------------------------------------- /static/Images/background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/background.jpg -------------------------------------------------------------------------------- /static/Images/backgrouund.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/backgrouund.png -------------------------------------------------------------------------------- /static/Images/bubbles.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/bubbles.jpg -------------------------------------------------------------------------------- /static/Images/iit_goa2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/iit_goa2.png -------------------------------------------------------------------------------- /static/Images/image_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/image_3.png -------------------------------------------------------------------------------- /static/Images/image_4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/image_4.jpg -------------------------------------------------------------------------------- /static/Images/img123.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/img123.png -------------------------------------------------------------------------------- /static/Images/img1234.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/img1234.png -------------------------------------------------------------------------------- /static/Images/img12345.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/img12345.png -------------------------------------------------------------------------------- /static/Images/img_avatar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/Images/img_avatar.png -------------------------------------------------------------------------------- /static/Images/wave.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /static/css/about_us.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: "Montserrat", sans-serif; 3 | font-weight: 400; 4 | overflow: hidden; 5 | } 6 | .navbar { 7 | background-color: white; 8 | padding: 10px 40px; 9 | } 10 | .nav-link { 11 | font-size: 1.5rem; 12 | } 13 | .navbar-brand { 14 | font-size: 1.5rem; 15 | } 16 | .main__body { 17 | height: 100vh; 18 | width: 100vw; 19 | background: var(--gradient-black); 20 | color: var(--white); 21 | } 22 | .top_img { 23 | width: 100vw; 24 | position: absolute; 25 | top: 68px; 26 | z-index: -1; 27 | animation: drop 1s ease-in-out; 28 | } 29 | @keyframes drop { 30 | from { 31 | top: -100px; 32 | } 33 | to { 34 | top: 68px; 35 | } 36 | } 37 | .bottom_img { 38 | width: 100vw; 39 | position: absolute; 40 | bottom: -250px; 41 | z-index: -1; 42 | animation: rise 1s ease-in-out; 43 | } 44 | @keyframes rise { 45 | from { 46 | bottom: -500px; 47 | } 48 | to { 49 | bottom: -250px; 50 | } 51 | } 52 | 53 | .about_us_title { 54 | color: var(--black); 55 | text-align: center; 56 | padding-top: 30px; 57 | } 58 | .our_team { 59 | font-size: 2.5rem; 60 | } 61 | .row { 62 | display: flex; 63 | justify-content: center; 64 | align-items: center; 65 | } 66 | 67 | .flip-card { 68 | background-color: transparent; 69 | width: 15rem; 70 | height: 15rem; 71 | perspective: 1000px; 72 | border-radius: 30px; 73 | margin: 10px 20px; 74 | } 75 | 76 | .flip-card-inner { 77 | position: relative; 78 | width: 100%; 79 | height: 100%; 80 | text-align: center; 81 | transition: transform 0.6s; 82 | transform-style: preserve-3d; 83 | box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2); 84 | border-radius: 30px; 85 | } 86 | 87 | .flip-card:hover .flip-card-inner { 88 | transform: rotateY(180deg); 89 | border-radius: 30px; 90 | } 91 | 92 | .flip-card-front, 93 | .flip-card-back { 94 | position: absolute; 95 | width: 100%; 96 | height: 100%; 97 | -webkit-backface-visibility: hidden; 98 | backface-visibility: hidden; 99 | border-radius: 30px; 100 | } 101 | 102 | .flip-card-front { 103 | background-color: #bbb; 104 | color: black; 105 | border-radius: 30px; 106 | } 107 | 108 | .flip-card-back { 109 | display: flex; 110 | flex-direction: column; 111 | justify-content: center; 112 | background: var(--gradient-black); 113 | color: white; 114 | transform: rotateY(180deg); 115 | border-radius: 30px; 116 | padding: 10px; 117 | } 118 | .person_name { 119 | font-size: 1.5rem; 120 | } 121 | .person_title { 122 | font-size: 1rem; 123 | } 124 | -------------------------------------------------------------------------------- /static/css/front_web_1.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: "Montserrat", sans-serif; 3 | font-weight: 400; 4 | } 5 | .navbar { 6 | background-color: black; 7 | padding: 10px 40px; 8 | } 9 | .nav-link { 10 | font-size: 1.5rem; 11 | } 12 | .navbar-brand { 13 | font-size: 1.5rem; 14 | } 15 | 16 | .main__div { 17 | width: 100vw; 18 | overflow-x: hidden; 19 | -ms-overflow-style: none; /* IE and Edge */ 20 | scrollbar-width: none; /* Firefox */ 21 | } 22 | .main__div::-webkit-scrollbar { 23 | display: none; 24 | } 25 | 26 | .top__content { 27 | display: flex; 28 | background: var(--gradient-black); 29 | padding: 25px 60px; 30 | width: 100%; 31 | height: 55vh; 32 | align-items: center; 33 | color: var(--white); 34 | } 35 | .top__left { 36 | width: 60%; 37 | justify-content: flex-start; 38 | } 39 | .website__title__text { 40 | font-weight: 500; 41 | font-size: 3.3rem; 42 | } 43 | .top__right { 44 | display: flex; 45 | flex-direction: column; 46 | align-content: center; 47 | } 48 | .tagline__div { 49 | width: 100%; 50 | display: flex; 51 | } 52 | .tagline__text { 53 | font-weight: 300; 54 | font-size: 1.5rem; 55 | justify-content: center; 56 | text-align: center; 57 | } 58 | .top__img__div { 59 | display: flex; 60 | justify-content: center; 61 | width: 100%; 62 | } 63 | 64 | .top__img { 65 | width: 300px; 66 | height: 300px; 67 | border-radius: 20px; 68 | } 69 | 70 | .middle__content { 71 | display: flex; 72 | flex-direction: column; 73 | justify-content: center; 74 | background: var(--gradient-blue); 75 | color: var(--gray); 76 | margin: 20px auto; 77 | padding: 10px 15px; 78 | align-items: center; 79 | border: 1px dashed var(--black); 80 | border-radius: 30px; 81 | width: 50%; 82 | } 83 | @media screen and (max-width: 1060px) { 84 | .middle__content { 85 | display: flex; 86 | flex-direction: column; 87 | justify-content: center; 88 | background: var(--gradient-blue); 89 | color: var(--gray); 90 | margin: 20px auto; 91 | padding: 10px 15px; 92 | align-items: center; 93 | border: 1px dashed var(--black); 94 | border-radius: 30px; 95 | width: 90%; 96 | } 97 | } 98 | .middle__motivation__text { 99 | font-size: 3.5rem; 100 | padding: 20px 0; 101 | font-weight: 500; 102 | } 103 | .question__answer__div { 104 | display: flex; 105 | justify-content: center; 106 | padding: 5px 30px; 107 | } 108 | .question__div { 109 | display: flex; 110 | width: 50%; 111 | justify-content: center; 112 | padding: 0px 35px; 113 | } 114 | .question__p { 115 | text-align: center; 116 | } 117 | .answer__div { 118 | display: flex; 119 | width: 50%; 120 | align-items: center; 121 | flex-direction: column; 122 | padding: 0px 50px; 123 | } 124 | .answer__p { 125 | text-align: center; 126 | } 127 | 128 | .bottom__content { 129 | display: flex; 130 | background: var(--gradient-black); 131 | color: var(--white); 132 | padding: 10px 60px; 133 | } 134 | .bottom__left__div { 135 | display: flex; 136 | flex-direction: column; 137 | align-items: center; 138 | margin: 10px 20px; 139 | padding: 5px 20px; 140 | width: 50%; 141 | border: 2px solid var(--sky-blue); 142 | border-radius: 30px; 143 | } 144 | .how__it__works { 145 | font-weight: 500; 146 | font-size: 3.5rem; 147 | } 148 | .instruction__list { 149 | display: flex; 150 | flex-direction: column; 151 | } 152 | .instruction__item { 153 | display: flex; 154 | align-items: center; 155 | } 156 | .number { 157 | display: flex; 158 | justify-content: center; 159 | align-items: center; 160 | padding: 5px; 161 | font-weight: 600; 162 | background: var(--gradient-blue); 163 | color: var(--black); 164 | width: 30px; 165 | height: 30px; 166 | border-radius: 50%; 167 | font-size: 1.2rem; 168 | } 169 | .instruction__text { 170 | padding: 0px 20px; 171 | font-size: 1.1rem; 172 | } 173 | 174 | .bottom__right__div { 175 | display: flex; 176 | flex-direction: column; 177 | align-items: center; 178 | margin: 10px 20px; 179 | padding: 5px 20px; 180 | width: 50%; 181 | border: 2px solid var(--sky-blue); 182 | border-radius: 30px; 183 | } 184 | .demo__video__text { 185 | font-weight: 500; 186 | font-size: 3.5rem; 187 | } 188 | .video__frame { 189 | width: 314px; 190 | height: 200px; 191 | border-radius: 30px; 192 | } 193 | -------------------------------------------------------------------------------- /static/css/game_page.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: "Montserrat", sans-serif; 3 | font-weight: 400; 4 | overflow: hidden; 5 | } 6 | * { 7 | -moz-box-sizing: inherit; 8 | box-sizing: inherit; 9 | -webkit-transition-property: all; 10 | transition-property: all; 11 | -webkit-transition-duration: 0.6s; 12 | transition-duration: 0.6s; 13 | -webkit-transition-timing-function: ease; 14 | transition-timing-function: ease; 15 | } 16 | .navbar { 17 | background-color: white; 18 | padding: 10px 40px; 19 | } 20 | .nav-link { 21 | font-size: 1.5rem; 22 | } 23 | .navbar-brand { 24 | font-size: 1.5rem; 25 | } 26 | 27 | .row { 28 | display: flex; 29 | justify-content: center; 30 | align-items: center; 31 | margin-top: 40px; 32 | } 33 | 34 | .flip-card { 35 | background-color: transparent; 36 | width: 30rem; 37 | height: 20rem; 38 | perspective: 1000px; 39 | border-radius: 30px; 40 | margin: 10px 20px; 41 | } 42 | 43 | .flip-card-inner { 44 | position: relative; 45 | width: 100%; 46 | height: 100%; 47 | text-align: center; 48 | transition: transform 0.6s; 49 | transform-style: preserve-3d; 50 | box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2); 51 | border-radius: 30px; 52 | } 53 | 54 | .flip-card:hover .flip-card-inner { 55 | transform: rotateX(180deg); 56 | border-radius: 30px; 57 | } 58 | 59 | .flip-card-front, 60 | .flip-card-back { 61 | position: absolute; 62 | width: 100%; 63 | height: 100%; 64 | -webkit-backface-visibility: hidden; 65 | backface-visibility: hidden; 66 | border-radius: 30px; 67 | } 68 | 69 | .flip-card-front { 70 | background-color: #bbb; 71 | color: black; 72 | border-radius: 30px; 73 | } 74 | 75 | .flip-card-back { 76 | display: flex; 77 | flex-direction: column; 78 | justify-content: center; 79 | background: var(--gradient-black); 80 | color: white; 81 | transform: rotateX(180deg); 82 | border-radius: 30px; 83 | padding: 10px; 84 | } 85 | .btnfos { 86 | color: #fff; 87 | cursor: pointer; 88 | display: block; 89 | font-size: 16px; 90 | font-weight: 400; 91 | line-height: 45px; 92 | max-width: 160px; 93 | position: relative; 94 | text-transform: uppercase; 95 | align-self: center; 96 | width: 100%; 97 | } 98 | 99 | .btnfos-1 { 100 | background: transparent; 101 | font-weight: 100; 102 | text-decoration: none; 103 | color: #fff; 104 | } 105 | .btnfos-1 svg { 106 | position: absolute; 107 | left: 0; 108 | top: 0; 109 | width: 100%; 110 | height: 45px; 111 | } 112 | .btnfos-1 rect { 113 | fill: none; 114 | stroke: #fff; 115 | stroke-width: 1; 116 | stroke-dasharray: 422, 0; 117 | } 118 | 119 | .btnfos-1:hover { 120 | background: rgba(225, 51, 45, 0); 121 | letter-spacing: 1px; 122 | font-weight: 300; 123 | text-decoration: none; 124 | color: #fff; 125 | } 126 | .btnfos-1:hover rect { 127 | stroke-width: 5; 128 | stroke-dasharray: 15, 310; 129 | stroke-dashoffset: 48; 130 | -webkit-transition: all 1.35s cubic-bezier(0.19, 1, 0.22, 1); 131 | transition: all 1.35s cubic-bezier(0.19, 1, 0.22, 1); 132 | } 133 | /* animation */ 134 | canvas { 135 | position: absolute; 136 | top: 0; 137 | left: 0; 138 | width: 100vw; 139 | height: 100vh; 140 | background-color: black; 141 | z-index: -1; 142 | } 143 | -------------------------------------------------------------------------------- /static/css/image_3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/css/image_3.jpg -------------------------------------------------------------------------------- /static/css/image_4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Innovation-Skyline-2020/GameInShape/782ad65717b9da1a8f6cbed78ecb196e2275eff0/static/css/image_4.jpg -------------------------------------------------------------------------------- /static/css/slidding_web_car.css: -------------------------------------------------------------------------------- 1 | html { 2 | scroll-behavior: smooth; 3 | } 4 | body { 5 | font-family: "Montserrat", sans-serif; 6 | font-weight: 400; 7 | overflow-x: hidden; 8 | } 9 | 10 | .navbar { 11 | background-color: white; 12 | padding: 10px 40px; 13 | } 14 | .nav-link { 15 | font-size: 1.5rem; 16 | } 17 | .navbar-brand { 18 | font-size: 1.5rem; 19 | } 20 | #section1 { 21 | height: 700px; 22 | } 23 | 24 | .content { 25 | background: white; 26 | width: 45%; 27 | padding: 80px 40px; 28 | margin-top: 500px; 29 | margin-left: 27vw; 30 | margin-right: 230px; 31 | font-family: calibri; 32 | border-radius: 10px; 33 | } 34 | 35 | .content:hover { 36 | transform: scale(1.1); 37 | } 38 | 39 | .putup { 40 | margin-left: 230px; 41 | margin-right: 0px; 42 | margin-top: 100px; 43 | width: 11.7%; 44 | padding: 0px 0px; 45 | } 46 | 47 | #top-part { 48 | background-color: orange; 49 | font-size: 30px; 50 | justify-content: space-around; 51 | display: flex; 52 | padding-top: 10px; 53 | padding-bottom: 10px; 54 | margin: 0px 0px; 55 | } 56 | .centres .btn:hover { 57 | transform: scale(1.5); 58 | } 59 | 60 | a { 61 | text-decoration: none; 62 | } 63 | 64 | [class^="btn-"] { 65 | position: relative; 66 | display: block; 67 | overflow: hidden; 68 | width: 100%; 69 | height: 80px; 70 | max-width: 250px; 71 | margin: 1rem auto; 72 | text-transform: uppercase; 73 | border: 1px solid currentColor; 74 | } 75 | .btn-6 { 76 | display: flex; 77 | justify-content: center; 78 | align-items: center; 79 | color: white; 80 | /* background-color: white; */ 81 | padding: 10px 30px; 82 | } 83 | .btn-6 span { 84 | position: absolute; 85 | display: block; 86 | width: 0; 87 | height: 0; 88 | border-radius: 50%; 89 | background: var(--gradient-black); 90 | transition: width 0.4s ease-in-out, height 0.4s ease-in-out; 91 | transform: translate(-50%, -50%); 92 | z-index: -1; 93 | } 94 | .btn-6:hover { 95 | color: white; 96 | } 97 | .btn-6:hover span { 98 | width: 225%; 99 | height: 562.5px; 100 | } 101 | .btn-6:active { 102 | background: var(--gradient-black); 103 | } 104 | 105 | .centres { 106 | justify-content: space-around; 107 | display: flex; 108 | padding-right: 0px; 109 | padding-left: 0px; 110 | margin-left: 400px; 111 | margin-right: 400px; 112 | margin-top: 260px; 113 | } 114 | 115 | /* animation */ 116 | canvas { 117 | position: absolute; 118 | top: 0; 119 | left: 0; 120 | width: 150vw; 121 | height: 260vh; 122 | background-color: black; 123 | z-index: -1; 124 | } 125 | -------------------------------------------------------------------------------- /static/css/slidding_web_mortal.css: -------------------------------------------------------------------------------- 1 | html { 2 | scroll-behavior: smooth; 3 | } 4 | body { 5 | font-family: "Montserrat", sans-serif; 6 | font-weight: 400; 7 | overflow-x: hidden; 8 | } 9 | 10 | .navbar { 11 | background-color: white; 12 | padding: 10px 40px; 13 | } 14 | .nav-link { 15 | font-size: 1.5rem; 16 | } 17 | .navbar-brand { 18 | font-size: 1.5rem; 19 | } 20 | #section1 { 21 | height: 700px; 22 | } 23 | 24 | .content { 25 | background: white; 26 | width: 45%; 27 | padding: 80px 40px; 28 | margin-top: 500px; 29 | margin-left: 27vw; 30 | margin-right: 230px; 31 | font-family: calibri; 32 | border-radius: 10px; 33 | } 34 | 35 | .content:hover { 36 | transform: scale(1.1); 37 | } 38 | 39 | .putup { 40 | margin-left: 230px; 41 | margin-right: 0px; 42 | margin-top: 100px; 43 | width: 11.7%; 44 | padding: 0px 0px; 45 | } 46 | 47 | #top-part { 48 | background-color: orange; 49 | font-size: 30px; 50 | justify-content: space-around; 51 | display: flex; 52 | padding-top: 10px; 53 | padding-bottom: 10px; 54 | margin: 0px 0px; 55 | } 56 | .centres .btn:hover { 57 | transform: scale(1.5); 58 | } 59 | 60 | a { 61 | text-decoration: none; 62 | } 63 | 64 | [class^="btn-"] { 65 | position: relative; 66 | display: block; 67 | overflow: hidden; 68 | width: 100%; 69 | height: 80px; 70 | max-width: 250px; 71 | margin: 1rem auto; 72 | text-transform: uppercase; 73 | border: 1px solid currentColor; 74 | } 75 | .btn-6 { 76 | display: flex; 77 | justify-content: center; 78 | align-items: center; 79 | color: white; 80 | /* background-color: white; */ 81 | padding: 10px 30px; 82 | } 83 | .btn-6 span { 84 | position: absolute; 85 | display: block; 86 | width: 0; 87 | height: 0; 88 | border-radius: 50%; 89 | background: var(--gradient-black); 90 | transition: width 0.4s ease-in-out, height 0.4s ease-in-out; 91 | transform: translate(-50%, -50%); 92 | z-index: -1; 93 | } 94 | .btn-6:hover { 95 | color: white; 96 | } 97 | .btn-6:hover span { 98 | width: 225%; 99 | height: 562.5px; 100 | } 101 | .btn-6:active { 102 | background: var(--gradient-black); 103 | } 104 | 105 | .centres { 106 | justify-content: space-around; 107 | display: flex; 108 | padding-right: 0px; 109 | padding-left: 0px; 110 | margin-left: 400px; 111 | margin-right: 400px; 112 | margin-top: 260px; 113 | } 114 | 115 | /* animation */ 116 | canvas { 117 | position: absolute; 118 | top: 0; 119 | left: 0; 120 | width: 150vw; 121 | height: 260vh; 122 | background-color: black; 123 | z-index: -1; 124 | } 125 | -------------------------------------------------------------------------------- /static/css/variables.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --blue: #0d7377; 3 | --sky-blue: #14ffec; 4 | --white: #eeeeee; 5 | --gray: #323232; 6 | --black: #212121; 7 | --gradient-blue: linear-gradient(to top, #00ffea, #14ffec, #ffffff); 8 | --gradient-black: linear-gradient(to right, #000000, #434343); 9 | } 10 | -------------------------------------------------------------------------------- /static/javascript/app.js: -------------------------------------------------------------------------------- 1 | var w = c.width = window.innerWidth, 2 | h = c.height = window.innerHeight, 3 | ctx = c.getContext( '2d' ), 4 | 5 | minDist = 10, 6 | maxDist = 30, 7 | initialWidth = 10, 8 | maxLines = 100, 9 | initialLines = 4, 10 | speed = 5, 11 | 12 | lines = [], 13 | frame = 0, 14 | timeSinceLast = 0, 15 | 16 | dirs = [ 17 | // straight x, y velocity 18 | [ 0, 1 ], 19 | [ 1, 0 ], 20 | [ 0, -1 ], 21 | [ -1, 0 ], 22 | // diagonals, 0.7 = sin(PI/4) = cos(PI/4) 23 | [ .7, .7 ], 24 | [ .7, -.7 ], 25 | [ -.7, .7 ], 26 | [ -.7, -.7] 27 | ], 28 | starter = { // starting parent line, just a pseudo line 29 | 30 | x: w / 2, 31 | y: h / 2, 32 | vx: 0, 33 | vy: 0, 34 | width: initialWidth 35 | }; 36 | 37 | function init() { 38 | 39 | lines.length = 0; 40 | 41 | for( var i = 0; i < initialLines; ++i ) 42 | lines.push( new Line( starter ) ); 43 | 44 | ctx.fillStyle = '#222'; 45 | ctx.fillRect( 0, 0, w, h ); 46 | 47 | // if you want a cookie ;) 48 | // ctx.lineCap = 'round'; 49 | } 50 | function getColor( x ) { 51 | 52 | return 'hsl( hue, 80%, 50% )'.replace( 53 | 'hue', x / w * 360 + frame 54 | ); 55 | } 56 | function anim() { 57 | 58 | window.requestAnimationFrame( anim ); 59 | 60 | ++frame; 61 | 62 | ctx.shadowBlur = 0; 63 | ctx.fillStyle = 'rgba(0,0,0,.02)'; 64 | ctx.fillRect( 0, 0, w, h ); 65 | ctx.shadowBlur = .5; 66 | 67 | for( var i = 0; i < lines.length; ++i ) 68 | 69 | if( lines[ i ].step() ) { // if true it's dead 70 | 71 | lines.splice( i, 1 ); 72 | --i; 73 | 74 | } 75 | 76 | // spawn new 77 | 78 | ++timeSinceLast 79 | 80 | if( lines.length < maxLines && timeSinceLast > 10 && Math.random() < .5 ) { 81 | 82 | timeSinceLast = 0; 83 | 84 | lines.push( new Line( starter ) ); 85 | 86 | // cover the middle; 87 | ctx.fillStyle = ctx.shadowColor = getColor( starter.x ); 88 | ctx.beginPath(); 89 | ctx.arc( starter.x, starter.y, initialWidth, 0, Math.PI * 2 ); 90 | ctx.fill(); 91 | } 92 | } 93 | 94 | function Line( parent ) { 95 | 96 | this.x = parent.x | 0; 97 | this.y = parent.y | 0; 98 | this.width = parent.width / 1.25; 99 | 100 | do { 101 | 102 | var dir = dirs[ ( Math.random() * dirs.length ) |0 ]; 103 | this.vx = dir[ 0 ]; 104 | this.vy = dir[ 1 ]; 105 | 106 | } while ( 107 | ( this.vx === -parent.vx && this.vy === -parent.vy ) || ( this.vx === parent.vx && this.vy === parent.vy) ); 108 | 109 | this.vx *= speed; 110 | this.vy *= speed; 111 | 112 | this.dist = ( Math.random() * ( maxDist - minDist ) + minDist ); 113 | 114 | } 115 | Line.prototype.step = function() { 116 | 117 | var dead = false; 118 | 119 | var prevX = this.x, 120 | prevY = this.y; 121 | 122 | this.x += this.vx; 123 | this.y += this.vy; 124 | 125 | --this.dist; 126 | 127 | // kill if out of screen 128 | if( this.x < 0 || this.x > w || this.y < 0 || this.y > h ) 129 | dead = true; 130 | 131 | // make children :D 132 | if( this.dist <= 0 && this.width > 1 ) { 133 | 134 | // keep yo self, sometimes 135 | this.dist = Math.random() * ( maxDist - minDist ) + minDist; 136 | 137 | // add 2 children 138 | if( lines.length < maxLines ) lines.push( new Line( this ) ); 139 | if( lines.length < maxLines && Math.random() < .5 ) lines.push( new Line( this ) ); 140 | 141 | // kill the poor thing 142 | if( Math.random() < .2 ) dead = true; 143 | } 144 | 145 | ctx.strokeStyle = ctx.shadowColor = getColor( this.x ); 146 | ctx.beginPath(); 147 | ctx.lineWidth = this.width; 148 | ctx.moveTo( this.x, this.y ); 149 | ctx.lineTo( prevX, prevY ); 150 | ctx.stroke(); 151 | 152 | if( dead ) return true 153 | } 154 | 155 | init(); 156 | anim(); 157 | 158 | window.addEventListener( 'resize', function() { 159 | 160 | w = c.width = window.innerWidth; 161 | h = c.height = window.innerHeight; 162 | starter.x = w / 2; 163 | starter.y = h / 2; 164 | 165 | init(); 166 | } ) -------------------------------------------------------------------------------- /static/javascript/game_mortal.js: -------------------------------------------------------------------------------- 1 | $(function () { 2 | $(".btn-6") 3 | .on("mouseenter", function (e) { 4 | var parentOffset = $(this).offset(), 5 | relX = e.pageX - parentOffset.left, 6 | relY = e.pageY - parentOffset.top; 7 | $(this).find("span").css({ top: relY, left: relX }); 8 | }) 9 | .on("mouseout", function (e) { 10 | var parentOffset = $(this).offset(), 11 | relX = e.pageX - parentOffset.left, 12 | relY = e.pageY - parentOffset.top; 13 | $(this).find("span").css({ top: relY, left: relX }); 14 | }); 15 | $("[href=#]").click(function () { 16 | return false; 17 | }); 18 | }); 19 | -------------------------------------------------------------------------------- /templates/about_us.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | About Us 11 | 17 | 18 | 22 | 27 | 32 | 33 | 34 | 72 |
73 | 74 |
75 |
76 |

Our Team

77 | 78 | 79 |
80 |
81 |
82 |
83 | Avatar 88 |
89 |
90 |

SANJAY MARREDDI

91 |

Team Lead
( Backend Developer )

92 | 93 |
94 |
95 |
96 |
97 |
98 |
99 | Avatar 104 |
105 |
106 |

RISHABH TRIPATHI

107 |

Backend Developer

108 | 109 |
110 |
111 |
112 |
113 |
114 |
115 | Avatar 120 |
121 |
122 |

SNEHA JAYAGANTHAN

123 |

Backend Developer

124 | 125 |
126 |
127 |
128 |

129 |

130 |
131 |
132 | Avatar 137 |
138 |
139 |

ASHUTOSH SAXENA

140 |

Backend Developer

141 | 142 |
143 |
144 |
145 |
146 |
147 |
148 | Avatar 153 |
154 |
155 |

ADWAIT AGASHE

156 |

Frontend Developer

157 | 158 |
159 |
160 |
161 |
162 |
163 |
164 | Avatar 169 |
170 |
171 |

RAVI PRAKASH

172 |

Frontend Developer

173 | 174 |
175 |
176 |
177 |
178 |

179 |
180 |
181 | 182 |
183 | 184 | 189 | 190 | -------------------------------------------------------------------------------- /templates/front_web_1.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | GameInShape 12 | 14 | 15 | 16 | 17 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 45 | 46 | 47 | 93 | 94 | 95 | 96 |
97 |
98 |
99 |
100 |

GameInShape

101 |
An Online Gaming Platform With Physical Fitness Integrated!
102 | Play 103 | Explore 104 |
105 |
106 |
107 |
108 | 109 |
110 | 111 | 112 | 113 |
114 |
115 | 116 |
117 |
118 |
119 |
120 | 121 | 122 |
123 |
124 |
125 |
126 | 127 |
128 |

Motivation

129 |

130 | “We can’t compromise on Health by playing Online Games.
We 131 | can’t compromise our enjoyment as well."


132 |

133 |

Is there a way to integrate both of them ?”

134 |

135 | Yes
136 | This site is the way to fulfill your dream of getting that well 137 | toned body while still having fun. 138 |

139 |
140 |
141 |
142 |
143 |
144 |

How it works?

145 |

146 |

    147 |
  • Click the link above and you will go to the games page.
  • 148 |
  • Choose the game you want to play
  • 149 |
  • You would be directed to the instructions.
  • 150 |
  • Game on.
  • 151 |
152 |

153 |

Didnt't get it? Don't worry, watch the video below.

154 |
155 |
156 |
157 | 158 | 159 |
160 |
161 |
162 |
163 |
164 |
165 | 166 | 167 |
168 | 169 |
170 | 171 |
172 |
173 |

Watch Demo Video

174 |
175 |
176 | 177 |
178 |
179 |
180 |
182 |
183 |
184 |
185 | 188 |
189 |
190 |
191 |
192 |
193 |
194 |
195 |
196 |
197 | 198 |
199 |
200 |
201 | 202 | 203 | 204 | 230 | 231 | 232 | 234 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 249 | 250 | -------------------------------------------------------------------------------- /templates/game_car.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | Stunt Cars 2 12 | 18 | 19 | 23 | 28 | 33 | 34 | 35 | 36 | 37 | 38 | 76 | 77 |
78 |
79 | Normal Mode 80 |
81 |
82 | Physical Mode 85 |
86 |
87 |
88 |
89 |

Guidelines for Playing !

90 |
    91 |
  • 92 | If you are playing for the First Time, Click on 93 | Start Setup button. 94 |
  • 95 |
  • Be ready in a convient position to play game.
  • 96 |
  • 97 | Use Mouse to draw boxes and Press ENTER to confirm the particualr 98 | region to act as Switch for corresponding Action name shown 99 |
  • 100 |
  • 101 | Once you draw boxes for all the switches you will be directed to 102 | same page. 103 |
  • 104 |
  • 105 | Now Click on the Start Game button to start playing the Game 106 | ! 107 |
  • 108 |
109 |

Note

110 |
    111 |
  • 112 | The Boxes you have drawn acts as switches and gets activated when 113 | you move your Hand in that area. So, Make sure you have Proper 114 | Lighting in your room while playing the game. 115 |
  • 116 |
117 |
118 | 119 |
120 |
121 |
122 | {% csrf_token %} 123 | Start Setup 129 |
130 |
131 |
132 |
133 | {% csrf_token %} 134 | Start Game 140 |
141 |
142 |
143 |
144 | 145 | 150 | 151 | 152 | 156 | 160 | 161 | -------------------------------------------------------------------------------- /templates/game_mortal.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | Mortal Kombat 12 | 18 | 19 | 23 | 28 | 33 | 34 | 35 | 36 | 37 | 38 | 76 | 77 |
78 |
79 | Normal Mode 80 |
81 |
82 | Physical Mode 85 |
86 |
87 |
88 |
89 |

Guidelines for Playing !

90 |
    91 |
  • 92 | If you are playing for the First Time, Click on 93 | Start Setup button. 94 |
  • 95 |
  • Be ready in a convient position to play game.
  • 96 |
  • 97 | Use Mouse to draw boxes and Press ENTER to confirm the particualr 98 | region to act as Switch for corresponding Action name shown 99 |
  • 100 |
  • 101 | Once you draw boxes for all the switches you will be directed to 102 | same page. 103 |
  • 104 |
  • 105 | Now Click on the Start Game button to start playing the Game 106 | ! 107 |
  • 108 |
109 |

Note

110 |
    111 |
  • 112 | The Boxes you have drawn acts as switches and gets activated when 113 | you move your Hand in that area. So, Make sure you have Proper 114 | Lighting in your room while playing the game 115 |
  • 116 |
117 |
118 |
119 |
120 |
125 | {% csrf_token %} 126 | Start Setup 132 |
133 |
134 |
135 |
140 | {% csrf_token %} 141 | Start Game 147 |
148 |
149 |
150 |
151 | 152 | 157 | 158 | 162 | 166 | 167 | -------------------------------------------------------------------------------- /templates/game_page.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | Games 12 | 18 | 19 | 23 | 28 | 33 | 34 | 35 | 36 | 37 | 38 | 76 | 77 |
78 |
79 |
80 |
81 | Mortal Kombat X 86 |
87 |
88 |

Mortal Kombat X

89 | 90 | 91 | 92 | 93 | 94 | Let's Go 95 | 96 |
97 |
98 |
99 |
100 |
101 |
102 | Stunt Cars 107 |
108 |
109 |

Stunt Cars

110 | 111 | 112 | 113 | 114 | 115 | Let's Go 116 | 117 |
118 |
119 |
120 |
121 | 122 | 127 | 128 | 132 | 136 | 137 | --------------------------------------------------------------------------------