mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-19 03:45:43 +00:00
fix(Core/Spell): EffectQuestComplete, set quest to rewarded instead of complete (#20358)
set quest to rewarded instead of complete when targetted by SPELL_EFFECT_QUEST_COMPLETE Prevents people from ending up with strange quests in their quest logs. https://github.com/TrinityCore/TrinityCore/commit/6d62f852acf3e1a3ee57cde2442832280aee814 Co-authored-by: SnapperRy <snapperryen@gmail.com>
This commit is contained in:
@@ -4771,8 +4771,8 @@ void Spell::EffectQuestComplete(SpellEffIndex effIndex)
|
||||
uint16 logSlot = player->FindQuestSlot(questId);
|
||||
if (logSlot < MAX_QUEST_LOG_SIZE)
|
||||
player->AreaExploredOrEventHappens(questId);
|
||||
else if (player->CanTakeQuest(quest, false)) // never rewarded before
|
||||
player->CompleteQuest(questId); // quest not in log - for internal use
|
||||
else if (player->CanTakeQuest(quest, false)) // Check if the quest has already been turned in.
|
||||
player->SetRewardedQuest(questId); // If not, set status to rewarded without broadcasting it to client.
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user