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

Fix room joining on refresh, user see a pending state #75

Open
dbertella opened this issue Jan 24, 2021 · 0 comments
Open

Fix room joining on refresh, user see a pending state #75

dbertella opened this issue Jan 24, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@dbertella
Copy link
Collaborator

dbertella commented Jan 24, 2021

Theory:
This is probably happening because of the order of events. Currently, it might be possible for the game state event to arrive before the handler for it has been initialised.
A possible solution for it is to split the current game state event, to one initial one, and the update one. The Game component would always have to ask explicitely for the current game state and only move on after server has responded (using socket.io callbacks). Then, it listens to game update events.

@dbertella dbertella added the bug Something isn't working label Jan 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant