Warn about mods, containing unconverted map data

This commit is contained in:
Eddoursul 2022-08-08 13:07:07 +02:00
parent 29e20601a2
commit 4804f73787
4 changed files with 28 additions and 2 deletions

BIN
SKSE/Plugins/EnderalSE.dll (Stored with Git LFS)

Binary file not shown.

View File

@ -1183,3 +1183,26 @@ inline void CheckCCMods()
} }
} }
} }
inline void CheckUnconvertedMap()
{
auto* form = RE::TESForm::LookupByID(0x1D3C); // Vyn
RE::TESWorldSpace* world = form ? form->As<RE::TESWorldSpace>() : nullptr;
if (!form || !world) {
MessageBoxW(NULL, L"Unable to load Vyn, make sure you are not using EnderalSE.dll in Skyrim.", L"Error", MB_OK | MB_ICONERROR);
exit(EXIT_FAILURE);
}
if (world->worldMapOffsetData.mapScale > 1.1) {
if (!bMessageShown) {
bMessageShown = true;
RE::DebugMessageBox(std::format("{} is an Enderal LE mod, containing unconverted map data.\nCheck console for the list of flagged mods.", form->GetFile()->fileName).c_str());
RE::ConsoleLog::GetSingleton()->Print("Some of the installed mods are incompatible! This list is not exhaustive, always use xEdit to verify mod compatibility.");
}
if (!aModNames.contains(form->GetFile()->fileName)) {
aModNames.insert(form->GetFile()->fileName);
RE::ConsoleLog::GetSingleton()->Print(std::format("{} is unconverted", form->GetFile()->fileName).c_str());
}
}
}

View File

@ -49,6 +49,8 @@ auto EventListener::ProcessEvent(
if (RE::UI::GetSingleton()->IsMenuOpen(RE::DialogueMenu::MENU_NAME)) { if (RE::UI::GetSingleton()->IsMenuOpen(RE::DialogueMenu::MENU_NAME)) {
const auto movie = RE::UI::GetSingleton()->GetMovieView(RE::JournalMenu::MENU_NAME); const auto movie = RE::UI::GetSingleton()->GetMovieView(RE::JournalMenu::MENU_NAME);
if (movie) { if (movie) {
// skse.OpenMenu("Journal Menu") opens quest journal uninitialized, without any tab active and hotkeys bound
// We have to activate a tab for it to work properly
std::array<RE::GFxValue, 2> args; std::array<RE::GFxValue, 2> args;
args[0].SetNumber(2); args[0].SetNumber(2);
args[1].SetBoolean(true); args[1].SetBoolean(true);

View File

@ -54,6 +54,7 @@ inline void CheckIncompatibleMods()
RE::ConsoleLog::GetSingleton()->Print("Loaded SureAI's Enderal: Forgotten Stories | Special Edition port v2.0.12 by Eddoursul et al"); RE::ConsoleLog::GetSingleton()->Print("Loaded SureAI's Enderal: Forgotten Stories | Special Edition port v2.0.12 by Eddoursul et al");
CheckWorldspaces(); CheckWorldspaces();
CheckUnconvertedMap();
CheckSkyrimCells(); CheckSkyrimCells();
CheckEnderalCells(); CheckEnderalCells();
} }