From 5078a42dbbaad0a059a8851449a4d899225098ab Mon Sep 17 00:00:00 2001 From: Eddoursul Date: Thu, 1 Sep 2022 12:06:40 +0200 Subject: [PATCH] Added mod blacklist --- SKSE/Plugins/EnderalSE.dll | 4 ++-- source/Enderal DLL/src/CheckInvalidForms.h | 21 +++++++++++++++++++++ source/Enderal DLL/src/Util.h | 1 + 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/SKSE/Plugins/EnderalSE.dll b/SKSE/Plugins/EnderalSE.dll index 979427cd..c2172c3c 100644 --- a/SKSE/Plugins/EnderalSE.dll +++ b/SKSE/Plugins/EnderalSE.dll @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9996320987e1db1911f09c8724eedfb0655d3a34916eb6a4d59dd8b485f9563d -size 658944 +oid sha256:392d24293a9519119a8d1b9866a0d291515b7e00dfa0b74f1a08b6958117c230 +size 660992 diff --git a/source/Enderal DLL/src/CheckInvalidForms.h b/source/Enderal DLL/src/CheckInvalidForms.h index 6d528619..2f9e4671 100644 --- a/source/Enderal DLL/src/CheckInvalidForms.h +++ b/source/Enderal DLL/src/CheckInvalidForms.h @@ -10,6 +10,27 @@ inline bool DataFileExists(std::string filename, int maxSize = 1000000) return std::filesystem::exists(path) && std::filesystem::file_size(path) > maxSize; } +inline void CheckBlacklist() +{ + const auto dataHandler = RE::TESDataHandler::GetSingleton(); + + if (!dataHandler) { + return; + } + + std::string filenames[1] = { + "Enderal_FS_More_Affinities.esp", + }; + + for (short i = 0; i < 1; i++) { + if (dataHandler->LookupLoadedModByName(filenames[i])) { + aModNames.insert(filenames[i]); + RE::DebugMessageBox(std::format("{} is incompatible with Enderal SE.\nCheck console for the list of flagged mods.", filenames[i]).c_str()); + RE::ConsoleLog::GetSingleton()->Print(std::format("{} is incompatible", filenames[i]).c_str()); + } + } +} + inline void NotifyInvalidForm(const RE::TESForm* form) { if (!form) { diff --git a/source/Enderal DLL/src/Util.h b/source/Enderal DLL/src/Util.h index 44e02c89..42263551 100644 --- a/source/Enderal DLL/src/Util.h +++ b/source/Enderal DLL/src/Util.h @@ -53,6 +53,7 @@ inline void CheckIncompatibleMods() { RE::ConsoleLog::GetSingleton()->Print("Loaded SureAI's Enderal: Forgotten Stories | Special Edition v2.0.12 by Eddoursul and contributors"); + CheckBlacklist(); CheckWorldspaces(); CheckUnconvertedMap(); CheckSkyrimCells();