How to handle OnApplicationPause when client try to connect to server?

public override void Disconnected(BoltConnection connection) method not called

but is appear warning

Got a unexpected Disconnect in LoadBalancingClient State : Disconnected.

How must I handle this behaviour? How can I reconnect to server?


  • Hello!

    When the Editor/Game is paused, all networking loops are also stopped, this causes the absence of knowledge messages from the client to the server and later, the timeout of the connection, which causes the disconnection. This disconnection state is set on both the client (that has not been able to send any message to the server) and on the server (that has not received any message from the client).

    In order to recover the connection, the client needs to run all the connection negotiation and establishment, which can't be done when the game is unpaused, as this takes time.

    If this is a particular issue that affects your game, please, send us a report to [email protected], we will be glad to solve it.
  • Hello! Steps to reproduce:
    1. Create server
    2. Run client on android device
    3. Start to connect to server on android device
    4. lock screen on device when connecting proccess is not finished yet
    5. unlock screen on device. Disconnected event was not fired. Only warning "Got a unexpected Disconnect in LoadBalancingClient State : Disconnected."
    6. Available server list is empty
  • Hello!

    This issue is already on our roadmap, and it should be solved on the next release.
Sign In or Register to comment.