[10624] Fix quests w/QuestFlags QUEST_FLAGS_AUTO_REWARDED

Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
NoFantasy 2010-10-19 11:57:49 +02:00
parent 22bc9c80a1
commit 4b83c5c88e
2 changed files with 12 additions and 1 deletions

View file

@ -13324,6 +13324,17 @@ bool Player::CanCompleteQuest( uint32 quest_id ) const
if (!qInfo)
return false;
// only used for "flag" quests and not real in-game quests
if (qInfo->HasFlag(QUEST_FLAGS_AUTO_REWARDED))
{
// a few checks, not all "satisfy" is needed
if (SatisfyQuestPreviousQuest(qInfo, false) && SatisfyQuestLevel(qInfo, false) &&
SatisfyQuestSkill(qInfo, false) && SatisfyQuestRace(qInfo, false) && SatisfyQuestClass(qInfo, false))
return true;
return false;
}
// auto complete quest
if (qInfo->IsAutoComplete() && CanTakeQuest(qInfo, false))
return true;

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10623"
#define REVISION_NR "10624"
#endif // __REVISION_NR_H__