For your knowledge I am testing it by increasing my packet drop rate to 90%. It works fine if i leave the room with consented = false
. But doesn't reconnect if client connection is closed
Posts made by usamasermad
@endel Hey sorry to interrupt but I have noticed that unity client cant reconnect if our connection is closed i.e client.OnClose
. However Rejoin
works fine if client is not closed
- Like in this
Should i create new client and then try to Rejoin
it with server or it is not yet implemented on serverside?
@endel Thanks a lot for your quick solution. Rejoin
works like a charm for me now. New updated demo project is also very good organized and easy to understand and has cleared a lot of confusions.
Currently we don't have any kind of validation required for this room. It is just only named as onAuth()
because we send email and password to the server in this room but that is only after clicking on register button which means we dont have to send anything automatically to the server
As you suggested I changed my code to this but didn't reconnected
and these are my logs for your convenience
So you mean that in my Rejoin
coroutine i just need to add
room.OnReadyToConnect += (sender, e) =>
{
Debug.Log("Ready to connect to room!");
StartCoroutine (room.Connect ());
};
or only StartCoroutine (room.Connect ());
and everything else till Rejoin
remains the same
@endel we are using 0.9.32 on server side.
-
Here is the snippet of the server side code
-
Here is the snippet of the unity 3d
Thanks.
Hi, I am struggling to rejoin my client with server. I am using room.rejoin(roomName, sessionID) on my connection close event. But it is not sending request back to server. While we have also used allowReconnection on server side
Aah interesting I'm also wondering about this thing but don't know about forever package. Hope so it will solve my problem too while deploying the game I'm working on multiplayer puzzle game in JS. And noticed that whenever server is crashed need to spin it again.