Added support for all raid quest types
Added new config option to allow non-raid quest progression when in raid group code by Vladimir --HG-- branch : trunk
This commit is contained in:
@@ -175,7 +175,7 @@ uint32 Quest::XPValue(Player *pPlayer) const
|
||||
if (!xpentry)
|
||||
return 0;
|
||||
|
||||
int diffFactor = 2 * (quest_level - pPlayer->getLevel()) + 20;
|
||||
int32 diffFactor = 2 * (quest_level - pPlayer->getLevel()) + 20;
|
||||
if (diffFactor < 1)
|
||||
diffFactor = 1;
|
||||
else if (diffFactor > 10)
|
||||
@@ -204,3 +204,11 @@ int32 Quest::GetRewOrReqMoney() const
|
||||
|
||||
return int32(RewOrReqMoney * sWorld.getRate(RATE_DROP_MONEY));
|
||||
}
|
||||
|
||||
bool Quest::IsAllowedInRaid() const
|
||||
{
|
||||
if (IsRaidQuest())
|
||||
return true;
|
||||
|
||||
return sWorld.getConfig(CONFIG_QUEST_IGNORE_RAID);
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include "Define.h"
|
||||
#include "DatabaseEnv.h"
|
||||
#include "SharedDefines.h"
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@@ -244,6 +245,8 @@ class Quest
|
||||
bool IsWeekly() const { return QuestFlags & QUEST_FLAGS_WEEKLY; }
|
||||
bool IsDailyOrWeekly() const { return QuestFlags & (QUEST_FLAGS_DAILY | QUEST_FLAGS_WEEKLY); }
|
||||
bool IsAutoAccept() const { return QuestFlags & QUEST_FLAGS_AUTO_ACCEPT; }
|
||||
bool IsRaidQuest() const { return Type == QUEST_TYPE_RAID || Type == QUEST_TYPE_RAID_10 || Type == QUEST_TYPE_RAID_25; }
|
||||
bool IsAllowedInRaid() const;
|
||||
|
||||
// multiple values
|
||||
std::string ObjectiveText[QUEST_OBJECTIVES_COUNT];
|
||||
|
||||
Reference in New Issue
Block a user