Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Game model #29

Merged
merged 3 commits into from
Dec 2, 2021
Merged

Game model #29

merged 3 commits into from
Dec 2, 2021

Conversation

ppeters0502
Copy link
Contributor

I added the basic game model to models.py, and set up the host game button on the home page to check for an active game attached to the given player, and if there isn't an active game, it creates a new game model and saves it to the DB.
On the Game page, if you're hosting there's also an "end game" link, that if you click on it, sets the active flag to false (I'll work on the game deletion part later, this is just to test db functions).

closes #27

@ppeters0502 ppeters0502 added this to the build models milestone Dec 1, 2021
Copy link
Collaborator

@abullockuno abullockuno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to verify game code creation on host. Once a game was created, moving away from the site, logging out and back in, etc, did not change host game id. Deleting the hosted game allowed for the creation of a new game id upon clicking host again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Game model for the host/join screen and as a base model for the beginning of the game
2 participants