RIP: MultiMystery and Mystery, now there's just Generate

Other changes:
host.yaml Multi Mystery options were moved and changed
generate_output now has an output_directory argument
MultiWorld.get_game_players(<game>) now replaces <game>_player_ids
Python venv should now work properly
This commit is contained in:
Fabian Dill
2021-07-21 18:08:15 +02:00
parent 47f7ec16c0
commit 2fc4006dfa
21 changed files with 305 additions and 645 deletions

View File

@@ -43,7 +43,7 @@ recipe_time_scales = {
Options.RecipeTime.option_vanilla: None
}
def generate_mod(world):
def generate_mod(world, output_directory: str):
player = world.player
multiworld = world.world
global data_final_template, locale_template, control_template, data_template
@@ -92,7 +92,7 @@ def generate_mod(world):
data_template_code = data_template.render(**template_data)
data_final_fixes_code = data_final_template.render(**template_data)
mod_dir = Utils.output_path(mod_name) + "_" + Utils.__version__
mod_dir = os.path.join(output_directory, mod_name + "_" + Utils.__version__)
en_locale_dir = os.path.join(mod_dir, "locale", "en")
os.makedirs(en_locale_dir, exist_ok=True)
shutil.copytree(Utils.local_path("data", "factorio", "mod"), mod_dir, dirs_exist_ok=True)