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

[Bug]: Airport menu selectability after closing window on a class with no available airports #11261

Closed
PikkaBird opened this issue Sep 4, 2023 · 0 comments · Fixed by #11344
Labels
component: interface This is an interface issue

Comments

@PikkaBird
Copy link

Version of OpenTTD

20230903-master-gdadf5182d8

Expected result

If you close the airport construction menu while on a class tab with no buildable airports, on reopening the menu it reverts to displaying "Small Airports" [presumably the first available class with buildable airports].

Actual result

However, as seen in the example below with opengfx+ airports, on reopening the window only the first two airports in the list are selectable. The "Vintage Commuter" airport is not selectable, until clicking on the "class" dropdown and reselecting "small airports".

Unnamed, 1950-01-17
Unnamed, 1950-01-22

[Presumably this is because there's a counter that is not reset properly when resetting the class to display on reopening the window - it only allows selecting as many "Small Airports" as there are "Hub Airports"].

Steps to reproduce

  1. Start a new game in 1950 with the OpenGFX+ Airports NewGRF with default parameters.
  2. Open the Airport Construction window and change the class to "Hub Airports".
  3. Close and reopen the Airport Construction window. It will have defaulted back to "Small Airports".
  4. Note how you cannot select "Vintage Commuter" until you click and reselect "Small Airports" at the top of the window.
@2TallTyler 2TallTyler added the component: interface This is an interface issue label Sep 4, 2023
merni-ns added a commit to merni-ns/OpenTTD that referenced this issue Oct 1, 2023
merni-ns added a commit to merni-ns/OpenTTD that referenced this issue Oct 1, 2023
merni-ns added a commit to merni-ns/OpenTTD that referenced this issue Oct 1, 2023
merni-ns added a commit to merni-ns/OpenTTD that referenced this issue Oct 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: interface This is an interface issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants