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

Join game functionality #2

Closed
7 tasks done
Albin-Rohde opened this issue Feb 4, 2021 · 2 comments
Closed
7 tasks done

Join game functionality #2

Albin-Rohde opened this issue Feb 4, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@Albin-Rohde
Copy link
Owner

Albin-Rohde commented Feb 4, 2021

Intro

When a game is crated by a user, it should be possible for other users to join the game. This should be handled by a websocket connection, as the game will be dependent on realtime data.

The first milestone should be to open a socket connection when a game is created, and allow other users to join that session. The connection should make sure to update all clients connected to game; that a new player has joined the game.

Story

As a user i want people to be able to join my game, in addition i want to see when a new player has joined. I do not want my browser to poll the backend for new data, as that could "feel" slow and laggy.

I want my game to be secure, and i don't want people who i did not invite; being able to see any data about my game.

Value

Users can join other users game, which will make it possible to start a game together.
Using websockets for this will make it very snappy and responsive.
We will establish a specific "socket-session" for a specific game. All players linked to a game will sort of subscribe to updates to the game.

Criteria

  • User can create a game

  • A created game should open a socket connection.

  • User should be able to join a game

  • Joining a game should result in joining the "game connection".

  • Websocket should not broadcast data to users outside of gamecontext see Replace 'express-ws' #1

Tasks

  • Create game

  • Create game via static routes

  • Use key from game to establish socket connection on game room

  • Update game data on events

  • Join game

  • Input game key

  • use game key from input to establish socket connection on game room

  • Update game data on events

  • User can not join a full game

@Albin-Rohde Albin-Rohde added the enhancement New feature or request label Feb 4, 2021
@Albin-Rohde
Copy link
Owner Author

Progress can now be tracked at #5

@Albin-Rohde
Copy link
Owner Author

Solved with #5
Closing.

Albin-Rohde added a commit that referenced this issue Mar 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant