From 32cb9d0828828da3068259c9e0a3c0f5da170439 Mon Sep 17 00:00:00 2001 From: SmallJoker Date: Sat, 31 Jul 2021 19:54:52 +0200 Subject: Mods: Combine mod loading checks and deprection logging (#11503) This limits the logged deprecation messages to the mods that are loaded Unifies the mod naming convention check for CSM & SSM --- src/client/client.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/client') diff --git a/src/client/client.cpp b/src/client/client.cpp index 17661c242..923369afe 100644 --- a/src/client/client.cpp +++ b/src/client/client.cpp @@ -177,11 +177,7 @@ void Client::loadMods() // Load "mod" scripts for (const ModSpec &mod : m_mods) { - if (!string_allowed(mod.name, MODNAME_ALLOWED_CHARS)) { - throw ModError("Error loading mod \"" + mod.name + - "\": Mod name does not follow naming conventions: " - "Only characters [a-z0-9_] are allowed."); - } + mod.checkAndLog(); scanModIntoMemory(mod.name, mod.path); } -- cgit v1.2.3