Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: lobby window doesn't close if no connection could be established #9223

Merged
merged 1 commit into from May 9, 2021

Conversation

TrueBrain
Copy link
Member

Motivation / Problem

In some cases it is possible that you could open the Lobby window, but the connection to the server could not be established. This leaves you in this weird state where the Lobby window is not receiving any company info, but also doesn't tell you the connection is not established.

Description

Drop out of the Lobby window if the connection could not be established.

Limitations

Checklist for review

Some things are not automated, and forgotten often. This list is a reminder for the reviewers.

  • The bug fix is important enough to be backported? (label: 'backport requested')
  • This PR affects the save game format? (label 'savegame upgrade')
  • This PR affects the GS/AI API? (label 'needs review: Script API')
    • ai_changelog.hpp, gs_changelog.hpp need updating.
    • The compatibility wrappers (compat_*.nut) need updating.
  • This PR affects the NewGRF API? (label 'needs review: NewGRF')

Copy link
Contributor

@rubidium42 rubidium42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

##Future work

Maybe we should think about splitting network_gui.cpp into a file per Window, and add everything specific to that window like these query connecters in the file specific to that Window. Technically the connecters are no GUI code, but... they are only used for that GUI and not of any use in the dedicated server. Of course after stun/turn/etc. have been implemented.

@TrueBrain TrueBrain merged commit 583011b into OpenTTD:master May 9, 2021
@TrueBrain TrueBrain deleted the fix-lobby-window branch May 9, 2021 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants