1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-17 00:07:41 +02:00

Merge pull request #968 from kambala-decapitator/disable-scripting

Disable scripting modules by default
This commit is contained in:
Andrii Danylchenko
2022-09-22 15:23:17 +03:00
committed by GitHub
31 changed files with 132 additions and 17 deletions

View File

@ -434,7 +434,9 @@ void CContentHandler::init()
handlers.insert(std::make_pair("spells", ContentTypeHandler(VLC->spellh, "spell")));
handlers.insert(std::make_pair("skills", ContentTypeHandler(VLC->skillh, "skill")));
handlers.insert(std::make_pair("templates", ContentTypeHandler((IHandlerBase *)VLC->tplh, "template")));
#if SCRIPTING_ENABLED
handlers.insert(std::make_pair("scripts", ContentTypeHandler(VLC->scriptHandler, "script")));
#endif
handlers.insert(std::make_pair("battlefields", ContentTypeHandler(VLC->battlefieldsHandler, "battlefield")));
handlers.insert(std::make_pair("obstacles", ContentTypeHandler(VLC->obstacleHandler, "obstacle")));
//TODO: any other types of moddables?
@ -1045,7 +1047,9 @@ void CModHandler::load()
for(const TModID & modName : activeMods)
content->load(allMods[modName]);
#if SCRIPTING_ENABLED
VLC->scriptHandler->performRegistration(VLC);//todo: this should be done before any other handlers load
#endif
content->loadCustom();