Reconnect MOBA

Options
Well, im trying to make a moba and i have one question.
ill implement a reconnect button if the player get some internet problem or other stuff.
but my question is, each player update his custom properties, like gold, score etc.. but if the player leave the room and join after a few seconds/minutes, he would still has his last custom properties before he left?
If not, do you have any tip for me?
Thanks

Comments

  • Tobias
    Options
    Counter question: Does it make sense to come back after 10+ seconds when the others played on and got an advantage?

    There is a timeout for connections that don't react anymore. When that's triggered, the client "leaves" any open game and is out. There are no player properties for that user anymore. Due to that you can't really re-join and be the same actor as before.

    This is not yet in PUN but coming: You could make your game "Turnbased" and the timeout disconnect no longer removes the player from the room. This player becomes inactive instead and can re-join.
    This is an upcoming feature for PUN but not too far away. You can assume it ready later on and implement it with relative ease. All player props stay the same, the room props and buffered events are automatically there as if you join late (but you re-take your actornumber and PhotonPlayer).
  • Is there a way i can check which room the player was before?
    So i can reconnect him in the same room.
  • vadim
    Options
    Store room name after you joined the room first time.
    With that name you can rejoin same room after disconnection.
    Of course that works only if you reconnect with same client instance.
  • luxel
    Options
    Good to hear that the Reconnection feature is coming? When can we expect it? Does it require any server side logic? :D
  • what version that the Reconnection feature is?