dnsbty / level10

Phoenix LiveView multiplayer card game

Home Page:https://level10.games

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[FEATURE]

cwarrencoderedsafety opened this issue · comments

Not sure if this is a bug, but noticed that if the user is using iOS Safari and a day passes, they are unable to rejoin the game.

Would be nice feature if there was a way to register and join with any device, but I believe the intent is for the user to be able to rejoin using their current username.

Nice find! The server currently assigns a randomly generated UUID to each player, and so they need to have the same user ID in place to be able to rejoin the game. Currently, this relies on Phoenix LiveView's form state restoration if the websocket is disconnected, but I think storing the player information in localStorage or a cookie instead would be a better route forward and would probably fix the bug. Would you be interested in contributing a PR for that?