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

"Place Objects" menu sorts objects alphabetically even when there are no filter string provided. #8817

Closed
Azusa257 opened this issue Mar 7, 2021 · 2 comments
Assignees

Comments

@Azusa257
Copy link

Azusa257 commented Mar 7, 2021

Version of OpenTTD

Tested on the latest nightly (openttd-20210306-master-g2860de7bf4-windows-win64)

possible issue with PR #8603

Expected result

When the "filter strring" field is empty, it is expected of the game to sort the placeable objects with their default behaviour (to list them in their NewGRF load order).

The list should only be sorted alphabetically once the user starts entering string into the filter.

Actual result

The object menu lists the objects in alphabetical order without any input in the search box.
image

This breaks many NewGRFs for example the Auz objects seen here with unique classnames and categories. This also is a problem for players who have ordered their NewGRFs in their NewGRF settings in a specic manner so that similar NewGRFs get loaded closely.

Steps to reproduce

Loading different NewGRF Objects then opening the place objects menu. - the list is sorted alphabetically from the moment the window is opened.

@perezdidac
Copy link
Contributor

I am taking over this one as I implemented the recent change to filter and sort. Working on it.

@perezdidac
Copy link
Contributor

Here is the fix: #8818.
I also updated #8706 (same feature but for stations, still not merged to trunk) to sort by NewGRF as well, never alphabetically.

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

No branches or pull requests

2 participants