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

Feature: Add cargo filter support to vehicle list. #8308

wants to merge 1 commit into
base: master
Choose a base branch


Copy link

@stormcone stormcone commented Sep 14, 2020

This patch is based on @KeldorKatarn's commits:

@stormcone stormcone force-pushed the cargo-filter-vehicle-list branch 2 times, most recently from d7ac3fa to 9847f67 Sep 25, 2020
@stormcone stormcone force-pushed the cargo-filter-vehicle-list branch from 9847f67 to 40923b1 Oct 14, 2020
Copy link

@andythenorth andythenorth commented Dec 15, 2020

Hi Stormcone. Thanks for this! :)

Would it be possible to add a brief description covering the list below?

  • 'intent' for the PR
  • edge cases considered / handled / known issues
  • tips for testing (if relevant, or none)
  • screenshot(s)

This just really aids reviewing, and we would like to make reviewing faster and frequent. We have lots of nice contributions stuck and we would like to change that. :)

Copy link
Contributor Author

@stormcone stormcone commented Dec 17, 2020

For example if you have trains that can transport multiple cargoes, and want to replace one kind of wagon to another one which can carry a specific cargo, then you can filter the trains which can carry that one cargo. A more detailed example, in the early game years you have only box cars to carry everything, but with time goes, a grain hopper getting available, so you want to use it to break the monotonicity of appearance of your trains, or the new wagon can carry more cargo, or can be hauled faster. So it makes easier to find the right trains to replace the wagons.

Or you can check on a station or on a waypoint whether a specific cargo goes through it or not.


@stormcone stormcone force-pushed the cargo-filter-vehicle-list branch from 40923b1 to c978c7c Dec 17, 2020
Copy link

@andythenorth andythenorth commented Dec 17, 2020


So currently I have to use 'Sort by' and 'Total capacity by cargo type' for the examples you give.

This new filter seems useful.

Does it have any weird interactions with 'refit at station' [to cargo] or [to any available]?

Copy link
Contributor Author

@stormcone stormcone commented Dec 18, 2020

Sorry, I did not see your reply yesterday.

This patch collects the cargoes by the current state of what the vehicles can carry. So for example if a wagon currently can carry steel, then with filter set to steel the train will appear in the list. But if the train reaches a station where the wagon is refitted to carry goods, then it will disappear from the list. There is no difference whether the refit is explicit to a specific cargo or to any available.

So I would not say that is weird interaction, but indeed it is not ideal in the case of refit orders.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants