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

Add ability to play in multiple games #46

Open
3 of 9 tasks
bromeostasis opened this issue Apr 3, 2020 · 1 comment
Open
3 of 9 tasks

Add ability to play in multiple games #46

bromeostasis opened this issue Apr 3, 2020 · 1 comment
Labels

Comments

@bromeostasis
Copy link
Owner

bromeostasis commented Apr 3, 2020

Even after a very brief time in pre-beta, it's clear that ability to play in multiple games is going to be important!

  • Add queued_message table (id, userId, dialogId, turnId, message, sent, queuedAt)
  • Make method to check the state for a given user (phone number) and see if they're active in any conversations
  • Make sayOrQueueMessage(user, message) method
  • Use sOQM method in endGame and restart methods
  • Create takeOrQueueTurn(turn) method
  • Use tOQT in takeTurn method (or maybe just replace that method)
  • Create sendNextQueuedMessage(user/phoneNumber) method
  • Use sNQM in every conversation's after method (may be a bit tricky w/ turn. If game completes, we want to say that before any queued message)
  • Make sNQM recursive, so if it's a simple say and there's another thing queued, say that as well.
@bromeostasis
Copy link
Owner Author

bromeostasis commented Apr 15, 2020

Note that this will impact the endgame restart functionality. It currently closes all conversations for a user, so if someone ends a user's game while it's their turn, they will have their turn finished.

Although, I guess the further upstream problem is that they wouldn't even be able to see the endgame conversation while it's their turn.. IDK how the f we're gonna cue this. We may have to just change restart to be non-conversation based. What about another link??!! Oh godd that would be so much better..

No longer relevant after #54

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

No branches or pull requests

1 participant