|
|
|
@ -47,8 +47,9 @@ namespace ArtifactTracker |
|
|
|
|
const auto excludeKeywords = dataHandler->LookupForm<RE::BGSListForm>(0x801, "Artifact Tracker.esp"); // ETR_ExcludeMiscKeywords
|
|
|
|
|
const auto extraArtifactKeyword = dataHandler->LookupForm<RE::BGSKeyword>(0xDE3FD3, "Update.esm"); // ETR_ExtraArtifact
|
|
|
|
|
const auto notArtifactKeyword = dataHandler->LookupForm<RE::BGSKeyword>(0xDE3FD4, "Update.esm"); // ETR_NotArtifact
|
|
|
|
|
const auto npcRaceKeyword = dataHandler->LookupForm<RE::BGSKeyword>(0x13794, "Skyrim.esm"); // ActorTypeNPC
|
|
|
|
|
|
|
|
|
|
if (!g_cellContainer || !g_listNew || !g_listStored || !g_listFound || !g_persistentStorage || !g_homeKeyword || !recipeKeyword || !excludeKeywords || !extraArtifactKeyword || !notArtifactKeyword) { |
|
|
|
|
if (!g_cellContainer || !g_listNew || !g_listStored || !g_listFound || !g_persistentStorage || !g_homeKeyword || !recipeKeyword || !excludeKeywords || !extraArtifactKeyword || !notArtifactKeyword || !npcRaceKeyword) { |
|
|
|
|
SKSE::log::warn("Unable to load data from Artifact Tracker.esp"); |
|
|
|
|
RE::DebugMessageBox("Unable to load data from Artifact Tracker.esp, the mod is disabled."); |
|
|
|
|
return false; |
|
|
|
@ -73,7 +74,7 @@ namespace ArtifactTracker |
|
|
|
|
|
|
|
|
|
g_artifactFormTypes.insert(RE::FormType::Armor); |
|
|
|
|
for (const auto& form : dataHandler->GetFormArray<RE::TESObjectARMO>()) { |
|
|
|
|
if (form->GetPlayable() && !form->IsDeleted()) { |
|
|
|
|
if (form->GetPlayable() && !form->IsDeleted() && form->race && (form->race->formID == 0x19 || form->race->HasKeyword(npcRaceKeyword))) { |
|
|
|
|
if ((!form->HasKeyword(notArtifactKeyword) || form->HasKeyword(extraArtifactKeyword)) && strlen(form->GetName()) > 0) { |
|
|
|
|
g_artifactMap[form->formID] = form; |
|
|
|
|
} |
|
|
|
|