Fixed non-deterministic rocket silo recipe.

get_allowed_packs() was returning a list of the science packs in a non-deterministic random order, resulting in the recipe being non-deterministic.
This commit is contained in:
CaitSith2 2021-09-26 14:02:19 -07:00
parent f9a9189687
commit cf070e6dd9
1 changed files with 1 additions and 1 deletions

View File

@ -272,7 +272,7 @@ class Factorio(World):
if self.world.silo[self.player].value == Silo.option_randomize_recipe:
valid_pool = []
for pack in self.world.max_science_pack[self.player].get_allowed_packs():
for pack in sorted(self.world.max_science_pack[self.player].get_allowed_packs()):
valid_pool += sorted(science_pack_pools[pack])
new_recipe = self.make_balanced_recipe(recipes["rocket-silo"], valid_pool,
factor=(self.world.max_science_pack[self.player].value + 1) / 7)