diff --git a/desktop/src/com/unciv/app/desktop/ImagePacker.kt b/desktop/src/com/unciv/app/desktop/ImagePacker.kt index aa20ff7019..fd38dd1f69 100644 --- a/desktop/src/com/unciv/app/desktop/ImagePacker.kt +++ b/desktop/src/com/unciv/app/desktop/ImagePacker.kt @@ -72,8 +72,13 @@ internal object ImagePacker { val modDirectory = File("mods") if (modDirectory.exists()) { for (mod in modDirectory.listFiles()!!) { - if (!mod.isHidden && File(mod.path + "/Images").exists()) - packImagesIfOutdated(defaultSettings, mod.path + "/Images", mod.path, "game") + if (!mod.isHidden && File(mod.path + "/Images").exists()) { + try { + packImagesIfOutdated(defaultSettings, mod.path + "/Images", mod.path, "game") + } catch (ex: Throwable) { + println("Exception in ImagePacker: ${ex.message}") + } + } } }