unity photon sdk ,disconnect problem

Options
ymlyjq
edited April 2014 in Photon Server
ios ,when i put the lock sceen button, my photon server receive client disconnect message,

server calls :
    protected override void OnDisconnect(DisconnectReason reasonCode, string reasonDetail) reasoncode = ClientDisconnect;

why? when i put the lock sceen button , the wiff is not immediately turn off,
and other apps without photon , have no this problem,

so i think ,use photon client sdk, when put lock sceen , in it's ground floor, something happend,

how can i solve this problem?

and or you can tell me ,what 's module can call this problem ?

i known this problem is not the wiff cut reason,

sdk version = 3.2.2.1

help me ?

Comments

  • Tobias
    Options
    This is a client problem which we can't fix really. iOS doesn't allow apps to keep their connection while in the background.
    The client can't get any messages suddenly. It will time out (as time passes) when you get the app back to foreground.
    Thus the "ClientDisconnect" (it's not a server thing, actually).

    If you return quickly to the app, the game should be able to keep the connection.

    Are you sure the apps you use actually use wifi in the background? Maybe they just re-connect, which we don't (yet).
    We could check if we can streamline the process to reconnect on connection loss. I'm not sure how quickly we could do this, however.

    Aside from that, if a player doesn't react several seconds in a multiplayer game, do you really want the others to wait for him to catch up?
    There is not only the technical question if this behaviour would make sense.