From c50441f67a53ffa38f8f82e85aafbd4206bafc14 Mon Sep 17 00:00:00 2001 From: cat_or_not <41955154+catornot@users.noreply.github.com> Date: Sun, 23 Apr 2023 07:10:50 -0400 Subject: Fix initscript issue (#457) Fix initscript issue that prevented Northstar from being run without any mods enabled/installed. --- NorthstarDLL/squirrel/squirrel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NorthstarDLL/squirrel/squirrel.cpp b/NorthstarDLL/squirrel/squirrel.cpp index 62287245..43c5296b 100644 --- a/NorthstarDLL/squirrel/squirrel.cpp +++ b/NorthstarDLL/squirrel/squirrel.cpp @@ -415,7 +415,7 @@ template bool __fastcall CSquirrelVM_initHook(CSquirrelV bool ret = CSquirrelVM_init(vm, realContext, time); for (Mod mod : g_pModManager->m_LoadedMods) { - if (mod.initScript.size() != 0) + if (mod.m_bEnabled && mod.initScript.size() != 0) { std::string name = mod.initScript.substr(mod.initScript.find_last_of('/') + 1); std::string path = std::string("scripts/vscripts/") + mod.initScript; -- cgit v1.2.3