aboutsummaryrefslogtreecommitdiff
path: root/src/game/Player.cpp
diff options
context:
space:
mode:
authorclick <none@none>2010-05-10 02:59:41 +0200
committerclick <none@none>2010-05-10 02:59:41 +0200
commitc214b4afb0555b003216a707d29642d34a31f8fa (patch)
treeeeeba360d1aae56fdc13d0f3f0c20f3033b531b2 /src/game/Player.cpp
parent3b3f0caa69c9df629b6ab0793b50d20bd2f03ac6 (diff)
Correctly complete quests with QUEST_FLAGS_AUTO_ACCEPT which should be completed the moment you accept it.
This fixes the quests which weren't completable in starting areas. Fixes issue #2042. Patch by liberate. --HG-- branch : trunk
Diffstat (limited to 'src/game/Player.cpp')
-rw-r--r--src/game/Player.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index 5addf5db822..6534fb12280 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -13670,7 +13670,11 @@ void Player::SendPreparedQuest(uint64 guid)
}
if (pQuest->HasFlag(QUEST_FLAGS_AUTO_ACCEPT) && CanAddQuest(pQuest, true))
+ {
AddQuest(pQuest, pObject);
+ if (CanCompleteQuest(quest_id))
+ CompleteQuest(quest_id);
+ }
if ((pQuest->IsAutoComplete() && pQuest->IsRepeatable() && !pQuest->IsDailyOrWeekly()) || pQuest->HasFlag(QUEST_FLAGS_AUTOCOMPLETE))
PlayerTalkClass->SendQuestGiverRequestItems(pQuest, guid, CanCompleteRepeatableQuest(pQuest), true);