Navigation

  • Recent
  • Tags
  • Users
  • Search
  • Login
Colyseus
  • Login
  • Search
  • Recent
  • Tags
  • Users

Documentation GitHub

We're migrating to GitHub Discussions. This forum does not accept new registrations since April 6, 2023.
  1. Home
  2. AllNamesRTaken
AllNamesRTaken

AllNamesRTaken

@AllNamesRTaken

Chat Follow Unfollow
0
Reputation
6
Posts
1.2k
Profile views
0
Followers
0
Following
Joined 14 Mar 2021, 12:12 Last Online 27 Apr 2021, 17:37

  • Profile
  • More
    • Continue chat with AllNamesRTaken
    • Flag Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups
AllNamesRTaken Follow

Posts made by AllNamesRTaken

RE: Reconnect Stored By Frontend or Backend

@b-thanapat You should try more words to expain your scenario in order to make it easier for your friendly neighborhood programmer to help out.

That said. I store the roomid in a cloudstore under security rules so that only the relevant users can access it and use that to join if the room is created. But if everyone leaves the room will be disposed and you cannot rejoin that instance. In case what your are looking for is not the actual room but the room state, I serialize it ad store it as a file blob in the cloud, accessible only by the server. Then when the room is created I download and initialize the store using that state.

posted in Questions & Help • 31 Mar 2021, 11:24
RE: How to create private rooms for each group of players?

I ended up solving it by

  1. trying to join and listening to the ErrorCode.MATCHMAKE_INVALID_ROOM_ID.
  2. creating the room as private and listening to any error
  3. trying to join again after a backoff time

It works but feels lowlevel and protocol-ish.

J/

posted in Questions & Help • 31 Mar 2021, 11:20
RE: Auth

What you are saying is a bit unclear. I am not sure that you are running your own open id connect or oauth2 server locally so what are you running?
If you are running one, then you should be able to read up on how to validate the idtoken manually or find a library that does it for you.

If you are not running your own OIDC server then all bets are off and you just have to validate it using what ever function you can write up on your own.

But since you are running it locally then perhaps this is for dev/test purposes and you can just run your server in development mode where you just handwave the check inside onAuth.

Personally I use firebase login for my project which has a library that provides a verifyIdToken() function that handles the whole verification for me. Professionally I have rolled my own verification based on the OIDC standard and the OIDC provider we are using.

posted in Questions & Help • 28 Mar 2021, 15:31
RE: Can Colyseus store user data?

@gamedeveop
Being a Colyseus newb myself I still believe you are thinking about colyseus the wrong way. It is a way of distributing state to players as well as handling some common scenarios around that, such as joining, waiting for and finding groups. Storing user data is not one of them. Store that in your favourite cloud storage and just load it in the client or server as needed.

posted in Questions & Help • 28 Mar 2021, 10:55
How to create private rooms for each group of players?

Hi, New here.
I am making a battlemap tool and need to let players in a group join a room to share token states. So each group needs to create their own room I guess. I saw the addition of joinById() to the client but that would require that the group is already set up by the first player to join.

What is the recommended way of handling room creation when each group needs its own private room?

Many thanks,
J

posted in Questions & Help • 28 Mar 2021, 10:51
How to deserialize stored state snapshot?

Hi,
I am new here and I am building a VTT (virtual table top) where I store the board state on room dispose as JSON.
On create I would like to deserialize it into the new state.

Is there a quick way of doing it or do I need to nest constructors to consume the object?

Many thanks.
Joel

posted in Questions & Help • 14 Mar 2021, 12:16

© 2023 Endel Dreyer