Skip to content

Commit

Permalink
Added Perk filter.
Browse files Browse the repository at this point in the history
  • Loading branch information
adya committed Apr 21, 2024
1 parent 2c80429 commit e245649
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion SPID/include/Cache.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ namespace FormType
RE::FormType::FormList,
RE::FormType::Spell,
RE::FormType::Armor,
RE::FormType::Location
RE::FormType::Location,
RE::FormType::Perk
};

bool GetWhitelisted(RE::FormType a_type);
Expand Down
5 changes: 5 additions & 0 deletions SPID/src/LookupNPC.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,11 @@ namespace NPC
const auto location = a_form->As<RE::BGSLocation>();
return actor->GetEditorLocation() == location;
}
case RE::FormType::Perk:
{
const auto perk = a_form->As<RE::BGSPerk>();
return actor->HasPerk(perk);
}
case RE::FormType::FormList:
{
bool result = false;
Expand Down

0 comments on commit e245649

Please sign in to comment.