[Tasks] Support Raw NPC Names in Task Goal List (#2333)

This commit is contained in:
hg
2022-07-30 14:33:53 -04:00
committed by GitHub
parent 2ccf692167
commit 6e2d11a283
3 changed files with 7 additions and 4 deletions
+5 -2
View File
@@ -1831,7 +1831,7 @@ void TaskManager::SyncClientSharedTaskStateToLocal(
}
}
void TaskManager::HandleUpdateTasksOnKill(Client *client, uint32 npc_type_id, std::string npc_name)
void TaskManager::HandleUpdateTasksOnKill(Client *client, uint32 npc_type_id, NPC* npc)
{
for (auto &c: client->GetPartyMembers()) {
if (!c->ClientDataLoaded() || !c->HasTaskState()) {
@@ -1897,7 +1897,10 @@ void TaskManager::HandleUpdateTasksOnKill(Client *client, uint32 npc_type_id, st
std::to_string(npc_type_id)
) && !TaskGoalListManager::IsInMatchListPartial(
activity_info->goal_match_list,
npc_name
npc->GetCleanName()
) && !TaskGoalListManager::IsInMatchListPartial(
activity_info->goal_match_list,
npc->GetName()
)) {
LogTasksDetail("[HandleUpdateTasksOnKill] Matched list goal");
continue;