From 5153207ed2570d9bd5e50022758a2aae1c265fb8 Mon Sep 17 00:00:00 2001 From: Map Date: Wed, 24 Apr 2024 05:08:40 -0500 Subject: [PATCH] move the statement to stop processing a mod earlier so we avoid wasteful screenshot cleanup. --- game/00src/mod_menu.rpy | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/game/00src/mod_menu.rpy b/game/00src/mod_menu.rpy index d097ffc..ca04827 100644 --- a/game/00src/mod_menu.rpy +++ b/game/00src/mod_menu.rpy @@ -441,9 +441,15 @@ init -999 python: mod_screenshots[lang_code] = [] mod_screenshots[lang_code].append((i, converted_number)) - # Refine collected screenshots so that translated screenshots use the english screenshots (the ones without a lang code) - # as a base, and then either replacing or adding the translated screenshots according to their number. + # Don't load the mod if there's mod breaking errors + if mod_exception: + continue + + # We're now gonna clean up the screenshots to be more usable as-is. + + # Refine collected screenshots so that translated screenshots use the english screenshots (the ones without a lang code) + # as a base, and then either replacing or adding the translated screenshots according to their order/number. for lang_key in mod_screenshots.keys(): if lang_key != "None": if mod_screenshots.get("None") == None: @@ -496,11 +502,6 @@ init -999 python: else: mod_data_final[lang_key]["Screenshot Displayables"] = None - - # Don't load the mod if there's mod breaking errors - if mod_exception: - continue - # Store the collected scripts and screenshots mod_data_final["Scripts"] = mod_scripts