Crusher doesn't follow recipe priority

Bad behavior Production & Recipes
Decavoid [github] · 3 years ago

Issue description

When a multi-recipe building has multiple non-empty internal output storages and the current output belt throughput is lower than this building production rate, there is a case when this building is continuously working on the 2nd recipe only because it empties the wrong internal storage.
image

Reproduction steps

  1. Load attached save crusher.save.
  2. Select the crusher.
  3. Move Rock -> Gravel recipe to the top, making it the 1st recipe.
  4. Run the game at x3 speed for several in-game months.

Expected result:
Crusher empties Gravel internal buffer (for the 1st recipe) when there is space on the output belt, working on Rock -> Gravel (1st) recipe.

Actual result:
Crusher empties Slag crushed internal buffer (for the 2nd recipe) when there is space on the output belt, working on Slag -> Slag crushed (2nd) recipe only.

Suggested fix:
When there are multiple non-empty output internal storages in the building, it should first empty the storage corresponding to the top (1st) recipe.

Game version and build number

v0.5.5 b246

Operating system

Windows

1 attachment only for registered users
22 Showing 1–1 of 1