|
|
|
@ -4,6 +4,12 @@ static bool bMessageShown = false; |
|
|
|
|
|
|
|
|
|
static std::unordered_set<std::string> aModNames; |
|
|
|
|
|
|
|
|
|
inline bool DataFileExists(std::string filename, int maxSize = 1000000) |
|
|
|
|
{ |
|
|
|
|
const auto path = std::format("Data\\{}", filename); |
|
|
|
|
return std::filesystem::exists(path) && std::filesystem::file_size(path) > maxSize; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
inline void NotifyInvalidForm(const RE::TESForm* form) |
|
|
|
|
{ |
|
|
|
|
if (!form) { |
|
|
|
@ -1177,7 +1183,7 @@ inline void CheckCCMods() |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
for (short i = 0; i < 74; i++) { |
|
|
|
|
if (std::filesystem::exists(std::format("Data\\{}", filenames[i]))) { |
|
|
|
|
if (DataFileExists(filenames[i], 800)) { |
|
|
|
|
MessageBoxW(NULL, L"Creation Club mods are incompatible with Enderal.", L"Error", MB_OK | MB_ICONERROR); |
|
|
|
|
exit(EXIT_FAILURE); |
|
|
|
|
} |
|
|
|
|