About The Same ClientID

Hi @endel ,
It's said in the document that there will be the same ClientID when I connect to the same device twice. But it's not the same when I open two browser tabs for testing. Is my understanding wrong? Thank you

0_1582908323589_QQ20200229-004502@2x.png

Hi @BlueBang, thanks for pointing out, this piece of documentation is outdated. I've just removed this paragraph, as it is no longer valid. The only way to ensure you have the same client on multiple sessions is through authentication

Hi @endel thank you for report,
How to understand 'the sample client on multiple sessions', for example

//client
let ws= new Colyseus.Client("ws://localhost:2567")
ws.joinOrCreate("room");
ws.joinOrCreate("room");

//server
onAuth(client){
console.log(client.id) //the clientId will be same,right?
}

Thanks a million.

Hi @BlueBang,

The easiest way to have authentication is by installing MongoDB and using colyseus/social.

Hope this helps! Cheers!