Page MenuHomeWildfire Games

Lobby reconnect dialog on disconnected
AbandonedPublic

Authored by ffffffff on Aug 15 2017, 2:36 PM.

Details

Reviewers
elexis
Trac Tickets
#3389
Summary

Dialog on disconnected lobby variable to the username with three options:

"Main Menu"
"Stay"
"Reconnect"

Disconnect dialog:

Reconnecting:

Reconnected:

Test Plan

Test it by joining the lobby in one window and then joining the lobby with the same account in a second window. So first window gets disconnected.

Diff Detail

Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

ffffffff created this revision.Aug 15 2017, 2:36 PM
elexis updated the Trac tickets for this revision.Aug 15 2017, 2:42 PM
ffffffff updated this revision to Diff 3133.Aug 15 2017, 2:56 PM
ffffffff updated this revision to Diff 3135.Aug 15 2017, 3:07 PM
ffffffff updated this revision to Diff 3136.
ffffffff updated this revision to Diff 3166.Aug 18 2017, 3:36 PM
ffffffff edited the summary of this revision. (Show Details)
Imarok added a subscriber: Imarok.Oct 1 2017, 10:17 PM

A test plan describing how to trigger a disconnect would help reviewing that patch.

That's easy, join the lobby in one window, join the lobby in a second window.

Imarok edited the test plan for this revision. (Show Details)Oct 1 2017, 10:27 PM
ffffffff added a comment.EditedNov 8 2017, 5:34 AM

Looks like this: (the name is taken from username)

ffffffff added a subscriber: bb.Nov 13 2017, 6:25 PM
ffffffff updated this revision to Diff 4271.Nov 18 2017, 8:44 PM

sync
contextdiff

ffffffff updated this revision to Diff 4868.Dec 22 2017, 1:40 AM
ffffffff edited the summary of this revision. (Show Details)

Adding stay option on reconnect dialog.

ffffffff edited the summary of this revision. (Show Details)Dec 22 2017, 1:41 AM
ffffffff edited the summary of this revision. (Show Details)Dec 22 2017, 1:45 AM
ffffffff edited the test plan for this revision. (Show Details)Dec 24 2017, 1:51 PM
ffffffff added a subscriber: mapkoc.

Seems like all chat activity remains after reconnecting
(can't test with no activity happening in svn)
which to me it would be the greatest use of the pach.
I see someone fixed a bug that bothered me so much,
before now when you used widowed mode and opened a second lobby, the option got wiped from config file and next time you started the game it started in full screen and the options page started with unsaved values. Glad that's fixed.

Why showing a dialog in the first place at all and not automatically reconnecting in the background (with exponential back-off, ...) and only showing a dialog of that continues to fail?

Dunedan, I see a problem with that. If you open a second window and join multiplayer, both windows would fight to auto reconnect. Maybe it's best to give the user the decision.

In D791#49737, @mapkoc wrote:

Dunedan, I see a problem with that. If you open a second window and join multiplayer, both windows would fight to auto reconnect. Maybe it's best to give the user the decision.

What would be a legit case to do that?

I don't know if legit.
That's how some players access lobby while playing a game.
I open a second 0ad when replacing by ip to copy credntials before leaving as spec (sometimes I have forgotten and enter lobby with second client).
As mod I may need to check someone's host while playing (I don't think I can see that otherwise).

An alternative is to connect using a regular XMPP client instead of a second instance of 0ad. As the second XMPP client uses another resource identifier it's not causing any problems.

I'm actually surprised about your statement that it's possible to connect with two 0ad instances in parallel. When I try to do that I immediately get disconnected with the first instance when I connect using the second instance. That's how it XMPP is supposed to work anyway.

In D791#49738, @Dunedan wrote:
In D791#49737, @mapkoc wrote:

Dunedan, I see a problem with that. If you open a second window and join multiplayer, both windows would fight to auto reconnect. Maybe it's best to give the user the decision.

What would be a legit case to do that?

A feedback loop should certainly be prevented, even if lobbyists do something they shouldn't.
But since it doesn't actually "auto reconnect" but asks the user for confirmation, there is no infinite reconnect loop, but only a handful of message boxes until the player gets tired of the message box.
(Exactly the reason why there should be a message box)

ffffffff abandoned this revision.Jan 16 2018, 7:33 PM

Abandon in favor of D817. Includes reconnect lobby as message box.