1

Rescan the found list when followers change location

This commit is contained in:
Eddoursul 2022-07-13 00:30:54 +02:00
parent 7918a84386
commit 9fe55a34b7
3 changed files with 1 additions and 2 deletions

Binary file not shown.

View File

@ -755,7 +755,6 @@ namespace ArtifactTracker
g_iFollowerIndex = iCurrentFollowers;
std::thread([]() {
std::this_thread::sleep_for(std::chrono::milliseconds(3000)); // wait for followers to load into the new cell
RE::DebugNotification("Team changed, rescanning the found list");
RescanFoundArtifacts();
}).detach();
}

View File

@ -127,7 +127,7 @@ auto EventListener::ProcessEvent(
RE::BSTEventSource<RE::TESActorLocationChangeEvent>* a_eventSource)
-> RE::BSEventNotifyControl
{
if (a_event->actor->IsPlayerRef()) {
if (a_event->actor->IsPlayerRef() || (a_event->actor->As<RE::Actor>() && a_event->actor->As<RE::Actor>()->IsPlayerTeammate())) {
ArtifactTracker::OnLocationChange();
}