TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Quest Class Reference

#include <QuestDef.h>

Public Types

typedef std::vector< int32PrevQuests
 
typedef std::vector< uint32PrevChainQuests
 

Public Member Functions

 Quest (Field *questRecord)
 
void LoadQuestDetails (Field *fields)
 
void LoadQuestRequestItems (Field *fields)
 
void LoadQuestOfferReward (Field *fields)
 
void LoadQuestTemplateAddon (Field *fields)
 
void LoadQuestObjective (Field *fields)
 
void LoadQuestObjectiveVisualEffect (Field *fields)
 
uint32 XPValue (uint32 playerLevel) const
 
uint32 MoneyValue (uint8 playerLevel) const
 
bool HasFlag (uint32 flag) const
 
void SetFlag (uint32 flag)
 
bool HasSpecialFlag (uint32 flag) const
 
void SetSpecialFlag (uint32 flag)
 
uint32 GetQuestId () const
 
uint32 GetQuestType () const
 
uint32 GetQuestPackageID () const
 
int32 GetZoneOrSort () const
 
int32 GetMinLevel () const
 
uint32 GetMaxLevel () const
 
int32 GetQuestLevel () const
 
uint32 GetQuestInfoID () const
 
uint32 GetAllowableClasses () const
 
int32 GetAllowableRaces () const
 
uint32 GetRequiredSkill () const
 
uint32 GetRequiredSkillValue () const
 
uint32 GetRequiredMinRepFaction () const
 
int32 GetRequiredMinRepValue () const
 
uint32 GetRequiredMaxRepFaction () const
 
int32 GetRequiredMaxRepValue () const
 
uint32 GetSuggestedPlayers () const
 
uint32 GetLimitTime () const
 
int32 GetPrevQuestId () const
 
int32 GetNextQuestId () const
 
int32 GetExclusiveGroup () const
 
uint32 GetNextQuestInChain () const
 
uint32 GetBonusTalents () const
 
int32 GetRewArenaPoints () const
 
uint32 GetXPDifficulty () const
 
float GetXPMultiplier () const
 
float GetMoneyMultiplier () const
 
uint32 GetSrcItemId () const
 
uint32 GetSrcItemCount () const
 
uint32 GetSrcSpell () const
 
std::string constGetLogTitle () const
 
std::string constGetLogDescription () const
 
std::string constGetQuestDescription () const
 
std::string constGetAreaDescription () const
 
std::string constGetOfferRewardText () const
 
std::string constGetRequestItemsText () const
 
std::string constGetQuestCompletionLog () const
 
std::string constGetPortraitGiverText () const
 
std::string constGetPortraitGiverName () const
 
std::string constGetPortraitTurnInText () const
 
std::string constGetPortraitTurnInName () const
 
QuestObjectives constGetObjectives () const
 
uint32 GetRewMoneyDifficulty () const
 
uint32 GetRewHonor () const
 
uint32 GetRewKillHonor () const
 
uint32 GetRewMoneyMaxLevel () const
 
uint32 GetRewSpell () const
 
int32 GetRewDisplaySpell () const
 
uint32 GetRewMailTemplateId () const
 
uint32 GetRewMailDelaySecs () const
 
uint32 GetRewTitle () const
 
uint32 GetPOIContinent () const
 
float GetPOIx () const
 
float GetPOIy () const
 
uint32 GetPOIPriority () const
 
uint32 GetSoundAccept () const
 
uint32 GetSoundTurnIn () const
 
uint32 GetIncompleteEmote () const
 
uint32 GetCompleteEmote () const
 
bool IsRepeatable () const
 
bool IsAutoAccept () const
 
bool IsAutoComplete () const
 
uint32 GetFlags () const
 
uint32 GetFlagsEx () const
 
uint32 GetSpecialFlags () const
 
uint32 GetAreaGroupID () const
 
uint32 GetRewardSkillId () const
 
uint32 GetRewardSkillPoints () const
 
uint32 GetRewardReputationMask () const
 
uint32 GetQuestGiverPortrait () const
 
uint32 GetQuestTurnInPortrait () const
 
bool IsDaily () const
 
bool IsWeekly () const
 
bool IsMonthly () const
 
bool IsSeasonal () const
 
bool IsDailyOrWeekly () const
 
bool IsRaidQuest (Difficulty difficulty) const
 
bool IsAllowedInRaid (Difficulty difficulty) const
 
bool IsDFQuest () const
 
uint32 CalculateHonorGain (uint8 level) const
 
uint32 GetRewChoiceItemsCount () const
 
uint32 GetRewItemsCount () const
 
uint32 GetRewCurrencyCount () const
 
void BuildQuestRewards (WorldPackets::Quest::QuestRewards &rewards, Player *player) const
 

Public Attributes

PrevQuests prevQuests
 
PrevChainQuests prevChainQuests
 
uint32 ID
 
uint32 Type
 
int32 Level
 
uint32 PackageID
 
int32 MinLevel
 
int32 QuestSortID
 
uint32 QuestInfoID
 
uint32 SuggestedPlayers
 
uint32 NextQuestInChain
 
uint32 RewardXPDifficulty
 
float RewardXPMultiplier
 
int32 RewardMoney
 
uint32 RewardMoneyDifficulty
 
float RewardMoneyMultiplier
 
uint32 RewardBonusMoney
 
uint32 RewardDisplaySpell
 
uint32 RewardSpell
 
uint32 RewardHonor
 
uint32 RewardKillHonor
 
uint32 SourceItemId
 
uint32 Flags
 
uint32 FlagsEx
 
uint32 RewardItemId [QUEST_REWARD_ITEM_COUNT]
 
uint32 RewardItemCount [QUEST_REWARD_ITEM_COUNT]
 
uint32 ItemDrop [QUEST_ITEM_DROP_COUNT]
 
uint32 ItemDropQuantity [QUEST_ITEM_DROP_COUNT]
 
uint32 RewardChoiceItemId [QUEST_REWARD_CHOICES_COUNT]
 
uint32 RewardChoiceItemCount [QUEST_REWARD_CHOICES_COUNT]
 
uint32 RewardChoiceItemDisplayId [QUEST_REWARD_CHOICES_COUNT]
 
uint32 POIContinent
 
float POIx
 
float POIy
 
uint32 POIPriority
 
uint32 RewardTitleId
 
uint32 RewardTalents
 
int32 RewardArenaPoints
 
uint32 RewardSkillId
 
uint32 RewardSkillPoints
 
uint32 QuestGiverPortrait
 
uint32 QuestTurnInPortrait
 
uint32 RewardFactionId [QUEST_REWARD_REPUTATIONS_COUNT]
 
int32 RewardFactionValue [QUEST_REWARD_REPUTATIONS_COUNT]
 
int32 RewardFactionOverride [QUEST_REWARD_REPUTATIONS_COUNT]
 
uint32 RewardReputationMask
 
uint32 RewardCurrencyId [QUEST_REWARD_CURRENCY_COUNT]
 
uint32 RewardCurrencyCount [QUEST_REWARD_CURRENCY_COUNT]
 
uint32 SoundAccept
 
uint32 SoundTurnIn
 
uint32 AreaGroupID
 
uint32 LimitTime
 
int32 AllowableRaces
 
QuestObjectives Objectives
 
std::string LogTitle
 
std::string LogDescription
 
std::string QuestDescription
 
std::string AreaDescription
 
std::string PortraitGiverText
 
std::string PortraitGiverName
 
std::string PortraitTurnInText
 
std::string PortraitTurnInName
 
std::string QuestCompletionLog
 

Protected Attributes

uint32 DetailsEmote [QUEST_EMOTE_COUNT] = {}
 
uint32 DetailsEmoteDelay [QUEST_EMOTE_COUNT] = {}
 
uint32 EmoteOnComplete = 0
 
uint32 EmoteOnIncomplete = 0
 
uint32 EmoteOnCompleteDelay = 0
 
uint32 EmoteOnIncompleteDelay = 0
 
std::string RequestItemsText
 
uint32 OfferRewardEmote [QUEST_EMOTE_COUNT] = {}
 
uint32 OfferRewardEmoteDelay [QUEST_EMOTE_COUNT] = {}
 
std::string OfferRewardText
 
uint32 MaxLevel = 0
 
uint32 AllowableClasses = 0
 
uint32 SourceSpellID = 0
 
int32 PrevQuestID = 0
 
int32 NextQuestID = 0
 
int32 ExclusiveGroup = 0
 
uint32 RewardMailTemplateId = 0
 
uint32 RewardMailDelay = 0
 
uint32 RequiredSkillId = 0
 
uint32 RequiredSkillPoints = 0
 
uint32 RequiredMinRepFaction = 0
 
int32 RequiredMinRepValue = 0
 
uint32 RequiredMaxRepFaction = 0
 
int32 RequiredMaxRepValue = 0
 
uint32 SourceItemIdCount = 0
 
uint32 SpecialFlags = 0
 

Private Attributes

uint32 _rewChoiceItemsCount
 
uint32 _rewItemsCount
 
uint32 _rewCurrencyCount
 

Friends

class ObjectMgr
 
class Player
 
class PlayerMenu
 

Member Typedef Documentation

typedef std::vector<uint32> Quest::PrevChainQuests
typedef std::vector<int32> Quest::PrevQuests

Constructor & Destructor Documentation

Quest::Quest ( Field questRecord)
25 {
27  EmoteOnComplete = 0;
28  _rewItemsCount = 0;
31 
32  ID = questRecord[0].GetUInt32();
33  Type = questRecord[1].GetUInt8();
34  Level = questRecord[2].GetInt32();
35  PackageID = questRecord[3].GetUInt32();
36  MinLevel = questRecord[4].GetInt32();
37  QuestSortID = questRecord[5].GetInt16();
38  QuestInfoID = questRecord[6].GetUInt16();
39  SuggestedPlayers = questRecord[7].GetUInt8();
40  NextQuestInChain = questRecord[8].GetUInt32();
41  RewardXPDifficulty = questRecord[9].GetUInt32();
42  RewardXPMultiplier = questRecord[10].GetFloat();
43  RewardMoney = questRecord[11].GetUInt32();
44  RewardMoneyDifficulty = questRecord[12].GetUInt32();
45  RewardMoneyMultiplier = questRecord[13].GetFloat();
46  RewardBonusMoney = questRecord[14].GetUInt32();
47  RewardDisplaySpell = questRecord[15].GetUInt32();
48  RewardSpell = questRecord[16].GetUInt32();
49  RewardHonor = questRecord[17].GetUInt32();
50  RewardKillHonor = questRecord[18].GetUInt32();
51  SourceItemId = questRecord[19].GetUInt32();
52  Flags = questRecord[20].GetUInt32();
53  FlagsEx = questRecord[21].GetUInt32();
54 
55  for (uint32 i = 0; i < QUEST_ITEM_DROP_COUNT; ++i)
56  {
57  RewardItemId[i] = questRecord[22+i*4].GetUInt32();
58  RewardItemCount[i] = questRecord[23+i*4].GetUInt32();
59  ItemDrop[i] = questRecord[24+i*4].GetUInt32();
60  ItemDropQuantity[i] = questRecord[25+i*4].GetUInt32();
61 
62  if (RewardItemId[i])
64  }
65 
66  for (uint32 i = 0; i < QUEST_REWARD_CHOICES_COUNT; ++i)
67  {
68  RewardChoiceItemId[i] = questRecord[38+i*3].GetUInt32();
69  RewardChoiceItemCount[i] = questRecord[39+i*3].GetUInt32();
70  RewardChoiceItemDisplayId[i] = questRecord[40+i*3].GetUInt32();
71 
72  if (RewardChoiceItemId[i])
74  }
75 
76  POIContinent = questRecord[56].GetUInt32();
77  POIx = questRecord[57].GetFloat();
78  POIy = questRecord[58].GetFloat();
79  POIPriority = questRecord[59].GetUInt32();
80 
81  RewardTitleId = questRecord[60].GetUInt32();
82  RewardTalents = questRecord[61].GetUInt32();
83  RewardArenaPoints = questRecord[62].GetUInt32();
84  RewardSkillId = questRecord[63].GetUInt32();
85  RewardSkillPoints = questRecord[64].GetUInt32();
86 
87  QuestGiverPortrait = questRecord[65].GetUInt32();
88  QuestTurnInPortrait = questRecord[66].GetUInt32();
89 
90  for (uint32 i = 0; i < QUEST_REWARD_REPUTATIONS_COUNT; ++i)
91  {
92  RewardFactionId[i] = questRecord[67+i*3].GetUInt32();
93  RewardFactionValue[i] = questRecord[68+i*3].GetInt32();
94  RewardFactionOverride[i] = questRecord[69+i*3].GetInt32();
95  }
96 
97  RewardReputationMask = questRecord[82].GetUInt32();
98 
99  for (uint32 i = 0; i < QUEST_REWARD_CURRENCY_COUNT; ++i)
100  {
101  RewardCurrencyId[i] = questRecord[83+i*2].GetUInt32();
102  RewardCurrencyCount[i] = questRecord[84+i*2].GetUInt32();
103 
104  if (RewardCurrencyId[i])
106  }
107 
108  SoundAccept = questRecord[91].GetUInt32();
109  SoundTurnIn = questRecord[92].GetUInt32();
110  AreaGroupID = questRecord[93].GetUInt32();
111  LimitTime = questRecord[94].GetUInt32();
112  AllowableRaces = questRecord[95].GetInt32();
113 
114  LogTitle = questRecord[96].GetString();
115  LogDescription = questRecord[97].GetString();
116  QuestDescription = questRecord[98].GetString();
117  AreaDescription = questRecord[99].GetString();
118  PortraitGiverText = questRecord[100].GetString();
119  PortraitGiverName = questRecord[101].GetString();
120  PortraitTurnInText = questRecord[102].GetString();
121  PortraitTurnInName = questRecord[103].GetString();
122  QuestCompletionLog = questRecord[104].GetString();
123 
124  for (int i = 0; i < QUEST_EMOTE_COUNT; ++i)
125  {
126  DetailsEmote[i] = 0;
127  DetailsEmoteDelay[i] = 0;
128  OfferRewardEmote[i] = 0;
129  OfferRewardEmoteDelay[i] = 0;
130  }
131 }
uint32 RewardItemId[QUEST_REWARD_ITEM_COUNT]
Definition: QuestDef.h:425
uint32 RewardChoiceItemDisplayId[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestDef.h:431
uint32 RewardSkillId
Definition: QuestDef.h:439
uint32 ID
Definition: QuestDef.h:403
float POIy
Definition: QuestDef.h:434
std::string LogTitle
Definition: QuestDef.h:455
int32 RewardMoney
Definition: QuestDef.h:414
std::string PortraitGiverName
Definition: QuestDef.h:460
uint32 DetailsEmote[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:468
float RewardMoneyMultiplier
Definition: QuestDef.h:416
float GetFloat() const
Definition: Field.h:222
uint32 RewardSpell
Definition: QuestDef.h:419
uint32 RewardKillHonor
Definition: QuestDef.h:421
std::string LogDescription
Definition: QuestDef.h:456
#define QUEST_EMOTE_COUNT
Definition: QuestDef.h:50
uint32 SoundTurnIn
Definition: QuestDef.h:450
std::string QuestDescription
Definition: QuestDef.h:457
uint32 RewardFactionId[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:443
uint32 ItemDropQuantity[QUEST_ITEM_DROP_COUNT]
Definition: QuestDef.h:428
float RewardXPMultiplier
Definition: QuestDef.h:413
int32 AllowableRaces
Definition: QuestDef.h:453
std::string PortraitTurnInName
Definition: QuestDef.h:462
uint32 POIContinent
Definition: QuestDef.h:432
uint32 RewardCurrencyCount[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestDef.h:448
uint32 PackageID
Definition: QuestDef.h:406
std::string AreaDescription
Definition: QuestDef.h:458
uint32 RewardXPDifficulty
Definition: QuestDef.h:412
uint32 RewardTitleId
Definition: QuestDef.h:436
int32 RewardArenaPoints
Definition: QuestDef.h:438
uint32 QuestInfoID
Definition: QuestDef.h:409
uint32 RewardCurrencyId[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestDef.h:447
uint32 RewardHonor
Definition: QuestDef.h:420
#define QUEST_REWARD_CURRENCY_COUNT
Definition: QuestDef.h:51
uint32 RewardChoiceItemId[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestDef.h:429
uint8 GetUInt8() const
Definition: Field.h:70
uint32 RewardMoneyDifficulty
Definition: QuestDef.h:415
uint32 ItemDrop[QUEST_ITEM_DROP_COUNT]
Definition: QuestDef.h:427
uint32 RewardDisplaySpell
Definition: QuestDef.h:418
int32 QuestSortID
Definition: QuestDef.h:408
uint32 RewardTalents
Definition: QuestDef.h:437
uint32 QuestGiverPortrait
Definition: QuestDef.h:441
uint32 POIPriority
Definition: QuestDef.h:435
std::string QuestCompletionLog
Definition: QuestDef.h:463
uint32 RewardBonusMoney
Definition: QuestDef.h:417
uint32_t uint32
Definition: Define.h:150
int32 RewardFactionValue[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:444
std::string PortraitGiverText
Definition: QuestDef.h:459
std::string PortraitTurnInText
Definition: QuestDef.h:461
uint16 GetUInt16() const
Definition: Field.h:108
uint32 SuggestedPlayers
Definition: QuestDef.h:410
uint32 OfferRewardEmoteDelay[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:480
int32 GetInt32() const
Definition: Field.h:165
int16 GetInt16() const
Definition: Field.h:127
uint32 _rewChoiceItemsCount
Definition: QuestDef.h:397
uint32 LimitTime
Definition: QuestDef.h:452
uint32 QuestTurnInPortrait
Definition: QuestDef.h:442
uint32 FlagsEx
Definition: QuestDef.h:424
uint32 DetailsEmoteDelay[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:469
#define QUEST_REWARD_CHOICES_COUNT
Definition: QuestDef.h:46
uint32 RewardSkillPoints
Definition: QuestDef.h:440
uint32 GetUInt32() const
Definition: Field.h:146
float POIx
Definition: QuestDef.h:433
uint32 SourceItemId
Definition: QuestDef.h:422
uint32 EmoteOnIncomplete
Definition: QuestDef.h:473
int32 RewardFactionOverride[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:445
int32 MinLevel
Definition: QuestDef.h:407
uint32 NextQuestInChain
Definition: QuestDef.h:411
#define QUEST_ITEM_DROP_COUNT
Definition: QuestDef.h:45
Type
Type of JSON value.
Definition: rapidjson.h:642
std::string GetString() const
Definition: Field.h:276
uint32 AreaGroupID
Definition: QuestDef.h:451
uint32 _rewItemsCount
Definition: QuestDef.h:398
uint32 _rewCurrencyCount
Definition: QuestDef.h:399
uint32 EmoteOnComplete
Definition: QuestDef.h:472
uint32 RewardChoiceItemCount[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestDef.h:430
uint32 RewardReputationMask
Definition: QuestDef.h:446
uint32 SoundAccept
Definition: QuestDef.h:449
uint32 OfferRewardEmote[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:479
#define QUEST_REWARD_REPUTATIONS_COUNT
Definition: QuestDef.h:49
int32 Level
Definition: QuestDef.h:405
uint32 RewardItemCount[QUEST_REWARD_ITEM_COUNT]
Definition: QuestDef.h:426
uint32 Flags
Definition: QuestDef.h:423

+ Here is the call graph for this function:

Member Function Documentation

void Quest::BuildQuestRewards ( WorldPackets::Quest::QuestRewards rewards,
Player player 
) const
261 {
263  rewards.ItemCount = GetRewItemsCount();
264  rewards.Money = player->GetQuestMoneyReward(this);
265  rewards.XP = player->GetQuestXPReward(this);
266  rewards.Title = GetRewTitle();
267  rewards.Talents = GetBonusTalents();
270  rewards.SpellCompletionID = GetRewSpell();
271  rewards.SkillLineID = GetRewardSkillId();
272  rewards.NumSkillUps = GetRewardSkillPoints();
273 
274  for (uint32 i = 0; i < QUEST_REWARD_CHOICES_COUNT; ++i)
275  {
276  rewards.ChoiceItems[i].ItemID = RewardChoiceItemId[i];
278  }
279 
280  for (uint32 i = 0; i < QUEST_REWARD_ITEM_COUNT; ++i)
281  {
282  rewards.ItemID[i] = RewardItemId[i];
283  rewards.ItemQty[i] = RewardItemCount[i];
284  }
285 
286  for (uint32 i = 0; i < QUEST_REWARD_REPUTATIONS_COUNT; ++i)
287  {
288  rewards.FactionID[i] = RewardFactionId[i];
289  rewards.FactionValue[i] = RewardFactionValue[i];
290  rewards.FactionOverride[i] = RewardFactionOverride[i];
291  }
292 
293  for (uint32 i = 0; i < QUEST_REWARD_CURRENCY_COUNT; ++i)
294  {
295  rewards.CurrencyID[i] = RewardCurrencyId[i];
296  rewards.CurrencyQty[i] = RewardCurrencyCount[i];
297  }
298 }
uint32 GetRewChoiceItemsCount() const
Definition: QuestDef.h:385
uint32 RewardItemId[QUEST_REWARD_ITEM_COUNT]
Definition: QuestDef.h:425
uint32 GetRewTitle() const
Definition: QuestDef.h:354
int32 GetRewDisplaySpell() const
Definition: QuestDef.h:351
int32 Talents
Definition: QuestPackets.h:221
uint32 GetRewardReputationMask() const
Definition: QuestDef.h:372
int32 XP
Definition: QuestPackets.h:219
int32 Money
Definition: QuestPackets.h:218
int32 ItemQty[QUEST_REWARD_ITEM_COUNT]
Definition: QuestPackets.h:229
int32 FactionFlags
Definition: QuestPackets.h:222
uint32 GetRewItemsCount() const
Definition: QuestDef.h:386
int32 FactionOverride[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestPackets.h:232
uint32 RewardFactionId[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:443
int32 ItemCount
Definition: QuestPackets.h:217
int32 FactionID[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestPackets.h:230
uint32 RewardCurrencyCount[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestDef.h:448
int32 CurrencyID[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestPackets.h:233
uint32 GetRewardSkillId() const
Definition: QuestDef.h:370
int32 SpellCompletionID
Definition: QuestPackets.h:224
uint32 RewardCurrencyId[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestDef.h:447
#define QUEST_REWARD_CURRENCY_COUNT
Definition: QuestDef.h:51
uint32 RewardChoiceItemId[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestDef.h:429
uint32 GetBonusTalents() const
Definition: QuestDef.h:326
int32 ItemID[QUEST_REWARD_ITEM_COUNT]
Definition: QuestPackets.h:228
int32 ItemID
Definition: QuestPackets.h:210
uint32 GetRewardSkillPoints() const
Definition: QuestDef.h:371
uint32_t uint32
Definition: Define.h:150
int32 RewardFactionValue[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:444
int32 Title
Definition: QuestPackets.h:220
int32 NumSkillUps
Definition: QuestPackets.h:226
uint32 GetRewSpell() const
Definition: QuestDef.h:350
int32 FactionValue[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestPackets.h:231
int32 SkillLineID
Definition: QuestPackets.h:225
int32 SpellCompletionDisplayID
Definition: QuestPackets.h:223
#define QUEST_REWARD_CHOICES_COUNT
Definition: QuestDef.h:46
QuestChoiceItem ChoiceItems[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestPackets.h:227
int32 RewardFactionOverride[QUEST_REWARD_REPUTATIONS_COUNT]
Definition: QuestDef.h:445
#define QUEST_REWARD_ITEM_COUNT
Definition: QuestDef.h:47
int32 CurrencyQty[QUEST_REWARD_CURRENCY_COUNT]
Definition: QuestPackets.h:234
int32 ChoiceItemCount
Definition: QuestPackets.h:216
uint32 RewardChoiceItemCount[QUEST_REWARD_CHOICES_COUNT]
Definition: QuestDef.h:430
int32 Quantity
Definition: QuestPackets.h:211
#define QUEST_REWARD_REPUTATIONS_COUNT
Definition: QuestDef.h:49
uint32 RewardItemCount[QUEST_REWARD_ITEM_COUNT]
Definition: QuestDef.h:426

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

uint32 Quest::CalculateHonorGain ( uint8  level) const
346 {
347  uint32 honor = 0;
348 
349  /*if (GetRewHonorAddition() > 0 || GetRewHonorMultiplier() > 0.0f)
350  {
351  // values stored from 0.. for 1...
352  TeamContributionPointsEntry const* tc = sTeamContributionPointsStore.LookupEntry(level);
353  if (!tc)
354  return 0;
355 
356  honor = uint32(tc->value * GetRewHonorMultiplier() * 0.1f);
357  honor += GetRewHonorAddition();
358  }*/
359 
360  return honor;
361 }
uint32_t uint32
Definition: Define.h:150
uint32 Quest::GetAllowableClasses ( ) const
inline
312 { return AllowableClasses; }
uint32 AllowableClasses
Definition: QuestDef.h:485
int32 Quest::GetAllowableRaces ( ) const
inline
313 { return AllowableRaces; }
int32 AllowableRaces
Definition: QuestDef.h:453

+ Here is the caller graph for this function:

std::string const& Quest::GetAreaDescription ( ) const
inline
337 { return AreaDescription; }
std::string AreaDescription
Definition: QuestDef.h:458

+ Here is the caller graph for this function:

uint32 Quest::GetAreaGroupID ( ) const
inline
369 { return AreaGroupID; }
uint32 AreaGroupID
Definition: QuestDef.h:451

+ Here is the caller graph for this function:

uint32 Quest::GetBonusTalents ( ) const
inline
326 { return RewardTalents; }
uint32 RewardTalents
Definition: QuestDef.h:437

+ Here is the caller graph for this function:

uint32 Quest::GetCompleteEmote ( ) const
inline
362 { return EmoteOnComplete; }
uint32 EmoteOnComplete
Definition: QuestDef.h:472
int32 Quest::GetExclusiveGroup ( ) const
inline
324 { return ExclusiveGroup; }
int32 ExclusiveGroup
Definition: QuestDef.h:489
uint32 Quest::GetFlags ( ) const
inline
366 { return Flags; }
uint32 Flags
Definition: QuestDef.h:423

+ Here is the caller graph for this function:

uint32 Quest::GetFlagsEx ( ) const
inline
367 { return FlagsEx; }
uint32 FlagsEx
Definition: QuestDef.h:424

+ Here is the caller graph for this function:

uint32 Quest::GetIncompleteEmote ( ) const
inline
361 { return EmoteOnIncomplete; }
uint32 EmoteOnIncomplete
Definition: QuestDef.h:473
uint32 Quest::GetLimitTime ( ) const
inline
321 { return LimitTime; }
uint32 LimitTime
Definition: QuestDef.h:452

+ Here is the caller graph for this function:

std::string const& Quest::GetLogDescription ( ) const
inline
335 { return LogDescription; }
std::string LogDescription
Definition: QuestDef.h:456

+ Here is the caller graph for this function:

std::string const& Quest::GetLogTitle ( ) const
inline
334 { return LogTitle; }
std::string LogTitle
Definition: QuestDef.h:455

+ Here is the caller graph for this function:

uint32 Quest::GetMaxLevel ( ) const
inline
309 { return MaxLevel; }
uint32 MaxLevel
Definition: QuestDef.h:484
int32 Quest::GetMinLevel ( ) const
inline
308 { return MinLevel; }
int32 MinLevel
Definition: QuestDef.h:407

+ Here is the caller graph for this function:

float Quest::GetMoneyMultiplier ( ) const
inline
330 { return RewardMoneyMultiplier; }
float RewardMoneyMultiplier
Definition: QuestDef.h:416

+ Here is the caller graph for this function:

int32 Quest::GetNextQuestId ( ) const
inline
323 { return NextQuestID; }
int32 NextQuestID
Definition: QuestDef.h:488

+ Here is the caller graph for this function:

uint32 Quest::GetNextQuestInChain ( ) const
inline
325 { return NextQuestInChain; }
uint32 NextQuestInChain
Definition: QuestDef.h:411

+ Here is the caller graph for this function:

QuestObjectives const& Quest::GetObjectives ( ) const
inline
345 { return Objectives; }
QuestObjectives Objectives
Definition: QuestDef.h:454

+ Here is the caller graph for this function:

std::string const& Quest::GetOfferRewardText ( ) const
inline
338 { return OfferRewardText; }
std::string OfferRewardText
Definition: QuestDef.h:481

+ Here is the caller graph for this function:

uint32 Quest::GetPOIContinent ( ) const
inline
355 { return POIContinent; }
uint32 POIContinent
Definition: QuestDef.h:432

+ Here is the caller graph for this function:

uint32 Quest::GetPOIPriority ( ) const
inline
358 { return POIPriority; }
uint32 POIPriority
Definition: QuestDef.h:435

+ Here is the caller graph for this function:

float Quest::GetPOIx ( ) const
inline
356 { return POIx; }
float POIx
Definition: QuestDef.h:433

+ Here is the caller graph for this function:

float Quest::GetPOIy ( ) const
inline
357 { return POIy; }
float POIy
Definition: QuestDef.h:434

+ Here is the caller graph for this function:

std::string const& Quest::GetPortraitGiverName ( ) const
inline
342 { return PortraitGiverName; }
std::string PortraitGiverName
Definition: QuestDef.h:460

+ Here is the caller graph for this function:

std::string const& Quest::GetPortraitGiverText ( ) const
inline
341 { return PortraitGiverText; }
std::string PortraitGiverText
Definition: QuestDef.h:459

+ Here is the caller graph for this function:

std::string const& Quest::GetPortraitTurnInName ( ) const
inline
344 { return PortraitTurnInName; }
std::string PortraitTurnInName
Definition: QuestDef.h:462

+ Here is the caller graph for this function:

std::string const& Quest::GetPortraitTurnInText ( ) const
inline
343 { return PortraitTurnInText; }
std::string PortraitTurnInText
Definition: QuestDef.h:461

+ Here is the caller graph for this function:

int32 Quest::GetPrevQuestId ( ) const
inline
322 { return PrevQuestID; }
int32 PrevQuestID
Definition: QuestDef.h:487

+ Here is the caller graph for this function:

std::string const& Quest::GetQuestCompletionLog ( ) const
inline
340 { return QuestCompletionLog; }
std::string QuestCompletionLog
Definition: QuestDef.h:463

+ Here is the caller graph for this function:

std::string const& Quest::GetQuestDescription ( ) const
inline
336 { return QuestDescription; }
std::string QuestDescription
Definition: QuestDef.h:457

+ Here is the caller graph for this function:

uint32 Quest::GetQuestGiverPortrait ( ) const
inline
373 { return QuestGiverPortrait; }
uint32 QuestGiverPortrait
Definition: QuestDef.h:441

+ Here is the caller graph for this function:

uint32 Quest::GetQuestId ( ) const
inline
304 { return ID; }
uint32 ID
Definition: QuestDef.h:403
uint32 Quest::GetQuestInfoID ( ) const
inline
311 { return QuestInfoID; }
uint32 QuestInfoID
Definition: QuestDef.h:409

+ Here is the caller graph for this function:

int32 Quest::GetQuestLevel ( ) const
inline
310 { return Level; }
int32 Level
Definition: QuestDef.h:405

+ Here is the caller graph for this function:

uint32 Quest::GetQuestPackageID ( ) const
inline
306 { return PackageID; }
uint32 PackageID
Definition: QuestDef.h:406

+ Here is the caller graph for this function:

uint32 Quest::GetQuestTurnInPortrait ( ) const
inline
374 { return QuestTurnInPortrait; }
uint32 QuestTurnInPortrait
Definition: QuestDef.h:442

+ Here is the caller graph for this function:

uint32 Quest::GetQuestType ( ) const
inline
305 { return Type; }
uint32 Type
Definition: QuestDef.h:404

+ Here is the caller graph for this function:

std::string const& Quest::GetRequestItemsText ( ) const
inline
339 { return RequestItemsText; }
std::string RequestItemsText
Definition: QuestDef.h:476

+ Here is the caller graph for this function:

uint32 Quest::GetRequiredMaxRepFaction ( ) const
inline
318 { return RequiredMaxRepFaction; }
uint32 RequiredMaxRepFaction
Definition: QuestDef.h:496
int32 Quest::GetRequiredMaxRepValue ( ) const
inline
319 { return RequiredMaxRepValue; }
int32 RequiredMaxRepValue
Definition: QuestDef.h:497
uint32 Quest::GetRequiredMinRepFaction ( ) const
inline
316 { return RequiredMinRepFaction; }
uint32 RequiredMinRepFaction
Definition: QuestDef.h:494
int32 Quest::GetRequiredMinRepValue ( ) const
inline
317 { return RequiredMinRepValue; }
int32 RequiredMinRepValue
Definition: QuestDef.h:495
uint32 Quest::GetRequiredSkill ( ) const
inline
314 { return RequiredSkillId; }
uint32 RequiredSkillId
Definition: QuestDef.h:492
uint32 Quest::GetRequiredSkillValue ( ) const
inline
315 { return RequiredSkillPoints; }
uint32 RequiredSkillPoints
Definition: QuestDef.h:493
uint32 Quest::GetRewardReputationMask ( ) const
inline
372 { return RewardReputationMask; }
uint32 RewardReputationMask
Definition: QuestDef.h:446

+ Here is the caller graph for this function:

uint32 Quest::GetRewardSkillId ( ) const
inline
370 { return RewardSkillId; }
uint32 RewardSkillId
Definition: QuestDef.h:439

+ Here is the caller graph for this function:

uint32 Quest::GetRewardSkillPoints ( ) const
inline
371 { return RewardSkillPoints; }
uint32 RewardSkillPoints
Definition: QuestDef.h:440

+ Here is the caller graph for this function:

int32 Quest::GetRewArenaPoints ( ) const
inline
327 {return RewardArenaPoints; }
int32 RewardArenaPoints
Definition: QuestDef.h:438

+ Here is the caller graph for this function:

uint32 Quest::GetRewChoiceItemsCount ( ) const
inline
385 { return _rewChoiceItemsCount; }
uint32 _rewChoiceItemsCount
Definition: QuestDef.h:397

+ Here is the caller graph for this function:

uint32 Quest::GetRewCurrencyCount ( ) const
inline
387 { return _rewCurrencyCount; }
uint32 _rewCurrencyCount
Definition: QuestDef.h:399

+ Here is the caller graph for this function:

int32 Quest::GetRewDisplaySpell ( ) const
inline
351 { return RewardDisplaySpell; }
uint32 RewardDisplaySpell
Definition: QuestDef.h:418

+ Here is the caller graph for this function:

uint32 Quest::GetRewHonor ( ) const
inline
347 { return RewardHonor; }
uint32 RewardHonor
Definition: QuestDef.h:420

+ Here is the caller graph for this function:

uint32 Quest::GetRewItemsCount ( ) const
inline
386 { return _rewItemsCount; }
uint32 _rewItemsCount
Definition: QuestDef.h:398

+ Here is the caller graph for this function:

uint32 Quest::GetRewKillHonor ( ) const
inline
348 { return RewardKillHonor; }
uint32 RewardKillHonor
Definition: QuestDef.h:421

+ Here is the caller graph for this function:

uint32 Quest::GetRewMailDelaySecs ( ) const
inline
353 { return RewardMailDelay; }
uint32 RewardMailDelay
Definition: QuestDef.h:491
uint32 Quest::GetRewMailTemplateId ( ) const
inline
352 { return RewardMailTemplateId; }
uint32 RewardMailTemplateId
Definition: QuestDef.h:490
uint32 Quest::GetRewMoneyDifficulty ( ) const
inline
346 { return RewardMoneyDifficulty; }
uint32 RewardMoneyDifficulty
Definition: QuestDef.h:415

+ Here is the caller graph for this function:

uint32 Quest::GetRewMoneyMaxLevel ( ) const
301 {
302  // If Quest has flag to not give money on max level, it's 0
304  return 0;
305 
306  // Else, return the rewarded copper sum modified by the rate
308 }
#define sWorld
Definition: World.h:887
uint32 RewardBonusMoney
Definition: QuestDef.h:417
bool HasFlag(uint32 flag) const
Definition: QuestDef.h:297
Definition: World.h:447
uint32_t uint32
Definition: g3dmath.h:168
Definition: QuestDef.h:150

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

uint32 Quest::GetRewSpell ( ) const
inline
350 { return RewardSpell; }
uint32 RewardSpell
Definition: QuestDef.h:419

+ Here is the caller graph for this function:

uint32 Quest::GetRewTitle ( ) const
inline
354 { return RewardTitleId; }
uint32 RewardTitleId
Definition: QuestDef.h:436

+ Here is the caller graph for this function:

uint32 Quest::GetSoundAccept ( ) const
inline
359 { return SoundAccept; }
uint32 SoundAccept
Definition: QuestDef.h:449

+ Here is the caller graph for this function:

uint32 Quest::GetSoundTurnIn ( ) const
inline
360 { return SoundTurnIn; }
uint32 SoundTurnIn
Definition: QuestDef.h:450

+ Here is the caller graph for this function:

uint32 Quest::GetSpecialFlags ( ) const
inline
368 { return SpecialFlags; }
uint32 SpecialFlags
Definition: QuestDef.h:499
uint32 Quest::GetSrcItemCount ( ) const
inline
332 { return SourceItemIdCount; }
uint32 SourceItemIdCount
Definition: QuestDef.h:498
uint32 Quest::GetSrcItemId ( ) const
inline
331 { return SourceItemId; }
uint32 SourceItemId
Definition: QuestDef.h:422

+ Here is the caller graph for this function:

uint32 Quest::GetSrcSpell ( ) const
inline
333 { return SourceSpellID; }
uint32 SourceSpellID
Definition: QuestDef.h:486

+ Here is the caller graph for this function:

uint32 Quest::GetSuggestedPlayers ( ) const
inline
320 { return SuggestedPlayers; }
uint32 SuggestedPlayers
Definition: QuestDef.h:410

+ Here is the caller graph for this function:

uint32 Quest::GetXPDifficulty ( ) const
inline
328 { return RewardXPDifficulty; }
uint32 RewardXPDifficulty
Definition: QuestDef.h:412

+ Here is the caller graph for this function:

float Quest::GetXPMultiplier ( ) const
inline
329 { return RewardXPMultiplier; }
float RewardXPMultiplier
Definition: QuestDef.h:413

+ Here is the caller graph for this function:

int32 Quest::GetZoneOrSort ( ) const
inline
307 { return QuestSortID; }
int32 QuestSortID
Definition: QuestDef.h:408

+ Here is the caller graph for this function:

bool Quest::HasFlag ( uint32  flag) const
inline
297 { return (Flags & flag) != 0; }
uint32 Flags
Definition: QuestDef.h:423

+ Here is the caller graph for this function:

bool Quest::HasSpecialFlag ( uint32  flag) const
inline
300 { return (SpecialFlags & flag) != 0; }
uint32 SpecialFlags
Definition: QuestDef.h:499

+ Here is the caller graph for this function:

bool Quest::IsAllowedInRaid ( Difficulty  difficulty) const
338 {
339  if (IsRaidQuest(difficulty))
340  return true;
341 
342  return sWorld->getBoolConfig(CONFIG_QUEST_IGNORE_RAID);
343 }
bool IsRaidQuest(Difficulty difficulty) const
Definition: QuestDef.cpp:320
Definition: World.h:123
#define sWorld
Definition: World.h:887

+ Here is the call graph for this function:

bool Quest::IsAutoAccept ( ) const
311 {
313 }
Definition: World.h:163
#define sWorld
Definition: World.h:887
Definition: QuestDef.h:161
bool HasFlag(uint32 flag) const
Definition: QuestDef.h:297

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Quest::IsAutoComplete ( ) const
316 {
318 }
#define sWorld
Definition: World.h:887
Definition: SharedDefines.h:3771
Definition: World.h:164
Type
Type of JSON value.
Definition: rapidjson.h:642

+ Here is the caller graph for this function:

bool Quest::IsDaily ( ) const
inline
375 { return (Flags & QUEST_FLAGS_DAILY) != 0; }
Definition: QuestDef.h:154
uint32 Flags
Definition: QuestDef.h:423

+ Here is the caller graph for this function:

bool Quest::IsDailyOrWeekly ( ) const
inline
379 { return (Flags & (QUEST_FLAGS_DAILY | QUEST_FLAGS_WEEKLY)) != 0; }
Definition: QuestDef.h:154
Definition: QuestDef.h:157
uint32 Flags
Definition: QuestDef.h:423

+ Here is the caller graph for this function:

bool Quest::IsDFQuest ( ) const
inline
382 { return (SpecialFlags & QUEST_SPECIAL_FLAGS_DF_QUEST) != 0; }
uint32 SpecialFlags
Definition: QuestDef.h:499
Definition: QuestDef.h:204
bool Quest::IsMonthly ( ) const
inline
377 { return (SpecialFlags & QUEST_SPECIAL_FLAGS_MONTHLY) != 0; }
uint32 SpecialFlags
Definition: QuestDef.h:499
Definition: QuestDef.h:205
bool Quest::IsRaidQuest ( Difficulty  difficulty) const
321 {
322  switch (Type)
323  {
324  case QUEST_INFO_RAID:
325  return true;
326  case QUEST_INFO_RAID_10:
327  return difficulty == DIFFICULTY_10_N || difficulty == DIFFICULTY_10_HC;
328  case QUEST_INFO_RAID_25:
329  return difficulty == DIFFICULTY_25_N || difficulty == DIFFICULTY_25_HC;
330  default:
331  break;
332  }
333 
334  return false;
335 }
Definition: SharedDefines.h:3784
Definition: DBCEnums.h:407
Definition: SharedDefines.h:3791
Definition: SharedDefines.h:3790
Definition: DBCEnums.h:409
Definition: DBCEnums.h:408
Definition: DBCEnums.h:410
Type
Type of JSON value.
Definition: rapidjson.h:642

+ Here is the caller graph for this function:

bool Quest::IsRepeatable ( ) const
inline
uint32 SpecialFlags
Definition: QuestDef.h:499
Definition: QuestDef.h:201

+ Here is the caller graph for this function:

bool Quest::IsSeasonal ( ) const
inline
Definition: SharedDefines.h:3833
Definition: SharedDefines.h:3830
Definition: SharedDefines.h:3838
Definition: SharedDefines.h:3840
bool IsRepeatable() const
Definition: QuestDef.h:363
Definition: SharedDefines.h:3802
int32 QuestSortID
Definition: QuestDef.h:408
Definition: SharedDefines.h:3834
Definition: SharedDefines.h:3824
bool Quest::IsWeekly ( ) const
inline
376 { return (Flags & QUEST_FLAGS_WEEKLY) != 0; }
Definition: QuestDef.h:157
uint32 Flags
Definition: QuestDef.h:423
void Quest::LoadQuestDetails ( Field fields)
134 {
135  for (int i = 0; i < QUEST_EMOTE_COUNT; ++i)
136  DetailsEmote[i] = fields[1+i].GetUInt16();
137 
138  for (int i = 0; i < QUEST_EMOTE_COUNT; ++i)
139  DetailsEmoteDelay[i] = fields[5+i].GetUInt32();
140 }
uint32 DetailsEmote[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:468
#define QUEST_EMOTE_COUNT
Definition: QuestDef.h:50
uint32 DetailsEmoteDelay[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:469
void Quest::LoadQuestObjective ( Field fields)
187 {
188  QuestObjective obj;
189  obj.ID = fields[0].GetUInt32();
190  obj.Type = fields[2].GetUInt8();
191  obj.StorageIndex = fields[3].GetInt8();
192  obj.ObjectID = fields[4].GetInt32();
193  obj.Amount = fields[5].GetInt32();
194  obj.Flags = fields[6].GetUInt32();
195  obj.UnkFloat = fields[7].GetFloat();
196  obj.Description = fields[8].GetString();
197 
198  Objectives.push_back(obj);
199 }
float GetFloat() const
Definition: Field.h:222
Definition: QuestDef.h:261
uint32 ID
Definition: QuestDef.h:263
int8 StorageIndex
Definition: QuestDef.h:265
std::string Description
Definition: QuestDef.h:270
uint32 Flags
Definition: QuestDef.h:268
uint8 Type
Definition: QuestDef.h:264
uint8 GetUInt8() const
Definition: Field.h:70
int32 ObjectID
Definition: QuestDef.h:266
int32 GetInt32() const
Definition: Field.h:165
uint32 GetUInt32() const
Definition: Field.h:146
int8 GetInt8() const
Definition: Field.h:89
float UnkFloat
Definition: QuestDef.h:269
std::string GetString() const
Definition: Field.h:276
int32 Amount
Definition: QuestDef.h:267
QuestObjectives Objectives
Definition: QuestDef.h:454

+ Here is the call graph for this function:

void Quest::LoadQuestObjectiveVisualEffect ( Field fields)
202 {
203  uint32 objID = fields[1].GetUInt32();
204 
205  for (QuestObjective& obj : Objectives)
206  {
207  if (obj.ID == objID)
208  {
209  uint8 effectIndex = fields[3].GetUInt8();
210  if (effectIndex >= obj.VisualEffects.size())
211  obj.VisualEffects.resize(effectIndex+1, 0);
212 
213  obj.VisualEffects[effectIndex] = fields[4].GetInt32();
214  break;
215  }
216  }
217 }
Definition: QuestDef.h:261
uint8 GetUInt8() const
Definition: Field.h:70
uint32_t uint32
Definition: Define.h:150
int32 GetInt32() const
Definition: Field.h:165
uint32 GetUInt32() const
Definition: Field.h:146
uint8_t uint8
Definition: Define.h:152
QuestObjectives Objectives
Definition: QuestDef.h:454

+ Here is the call graph for this function:

void Quest::LoadQuestOfferReward ( Field fields)
153 {
154  for (int i = 0; i < QUEST_EMOTE_COUNT; ++i)
155  OfferRewardEmote[i] = fields[1+i].GetUInt16();
156 
157  for (int i = 0; i < QUEST_EMOTE_COUNT; ++i)
158  OfferRewardEmoteDelay[i] = fields[5+i].GetUInt32();
159 
160  OfferRewardText = fields[9].GetString();
161 }
std::string OfferRewardText
Definition: QuestDef.h:481
#define QUEST_EMOTE_COUNT
Definition: QuestDef.h:50
uint32 OfferRewardEmoteDelay[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:480
std::string GetString() const
Definition: Field.h:276
uint32 OfferRewardEmote[QUEST_EMOTE_COUNT]
Definition: QuestDef.h:479

+ Here is the call graph for this function:

void Quest::LoadQuestRequestItems ( Field fields)
143 {
144  EmoteOnComplete = fields[1].GetUInt16();
145  EmoteOnIncomplete = fields[2].GetUInt16();
146  EmoteOnCompleteDelay = fields[3].GetUInt32();
147  EmoteOnIncompleteDelay = fields[4].GetUInt32();
148  RequestItemsText = fields[5].GetString();
149 }
uint32 EmoteOnIncompleteDelay
Definition: QuestDef.h:475
std::string RequestItemsText
Definition: QuestDef.h:476
uint16 GetUInt16() const
Definition: Field.h:108
uint32 EmoteOnCompleteDelay
Definition: QuestDef.h:474
uint32 GetUInt32() const
Definition: Field.h:146
uint32 EmoteOnIncomplete
Definition: QuestDef.h:473
std::string GetString() const
Definition: Field.h:276
uint32 EmoteOnComplete
Definition: QuestDef.h:472

+ Here is the call graph for this function:

void Quest::LoadQuestTemplateAddon ( Field fields)
164 {
165  MaxLevel = fields[1].GetUInt8();
166  AllowableClasses = fields[2].GetUInt32();
167  SourceSpellID = fields[3].GetUInt32();
168  PrevQuestID = fields[4].GetInt32();
169  NextQuestID = fields[5].GetInt32();
170  ExclusiveGroup = fields[6].GetInt32();
171  RewardMailTemplateId = fields[7].GetUInt32();
172  RewardMailDelay = fields[8].GetUInt32();
173  RequiredSkillId = fields[9].GetUInt16();
174  RequiredSkillPoints = fields[10].GetUInt16();
175  RequiredMinRepFaction = fields[11].GetUInt16();
176  RequiredMaxRepFaction = fields[12].GetUInt16();
177  RequiredMinRepValue = fields[13].GetInt32();
178  RequiredMaxRepValue = fields[14].GetInt32();
179  SourceItemIdCount = fields[15].GetUInt8();
180  SpecialFlags = fields[16].GetUInt8();
181 
184 }
uint32 SpecialFlags
Definition: QuestDef.h:499
uint32 SourceItemIdCount
Definition: QuestDef.h:498
uint32 RequiredSkillId
Definition: QuestDef.h:492
uint32 RequiredMaxRepFaction
Definition: QuestDef.h:496
Definition: QuestDef.h:203
int32 PrevQuestID
Definition: QuestDef.h:487
uint32 MaxLevel
Definition: QuestDef.h:484
Definition: QuestDef.h:161
uint8 GetUInt8() const
Definition: Field.h:70
uint32 RequiredMinRepFaction
Definition: QuestDef.h:494
uint32 SourceSpellID
Definition: QuestDef.h:486
int32 RequiredMinRepValue
Definition: QuestDef.h:495
uint32 RewardMailTemplateId
Definition: QuestDef.h:490
uint16 GetUInt16() const
Definition: Field.h:108
int32 ExclusiveGroup
Definition: QuestDef.h:489
uint32 AllowableClasses
Definition: QuestDef.h:485
int32 GetInt32() const
Definition: Field.h:165
uint32 GetUInt32() const
Definition: Field.h:146
int32 RequiredMaxRepValue
Definition: QuestDef.h:497
int32 NextQuestID
Definition: QuestDef.h:488
uint32 RewardMailDelay
Definition: QuestDef.h:491
uint32 RequiredSkillPoints
Definition: QuestDef.h:493
uint32 Flags
Definition: QuestDef.h:423

+ Here is the call graph for this function:

uint32 Quest::MoneyValue ( uint8  playerLevel) const
251 {
252  uint8 level = Level == -1 ? playerLevel : Level;
253 
254  if (QuestMoneyRewardEntry const* money = sQuestMoneyRewardStore.LookupEntry(level))
255  return money->Money[GetRewMoneyDifficulty()] * GetMoneyMultiplier();
256  else
257  return 0;
258 }
uint32 GetRewMoneyDifficulty() const
Definition: QuestDef.h:346
Definition: DB2Structure.h:1073
DB2Storage< QuestMoneyRewardEntry > sQuestMoneyRewardStore("QuestMoneyReward.db2", QuestMoneyRewardFormat, HOTFIX_SEL_QUEST_MONEY_REWARD)
uint8_t uint8
Definition: Define.h:152
float GetMoneyMultiplier() const
Definition: QuestDef.h:330
int32 Level
Definition: QuestDef.h:405

+ Here is the call graph for this function:

void Quest::SetFlag ( uint32  flag)
inline
298 { Flags |= flag; }
uint32 Flags
Definition: QuestDef.h:423
void Quest::SetSpecialFlag ( uint32  flag)
inline
301 { SpecialFlags |= flag; }
uint32 SpecialFlags
Definition: QuestDef.h:499

+ Here is the caller graph for this function:

uint32 Quest::XPValue ( uint32  playerLevel) const
220 {
221  if (playerLevel)
222  {
223  int32 quest_level = (Level == -1 ? playerLevel : Level);
224  const QuestXPEntry* xpentry = sQuestXPStore.LookupEntry(quest_level);
225  if (!xpentry)
226  return 0;
227 
228  int32 diffFactor = 2 * (quest_level - playerLevel) + 20;
229  if (diffFactor < 1)
230  diffFactor = 1;
231  else if (diffFactor > 10)
232  diffFactor = 10;
233 
234  uint32 xp = diffFactor * xpentry->Exp[RewardXPDifficulty] * RewardXPMultiplier / 10;
235  if (xp <= 100)
236  xp = 5 * ((xp + 2) / 5);
237  else if (xp <= 500)
238  xp = 10 * ((xp + 5) / 10);
239  else if (xp <= 1000)
240  xp = 25 * ((xp + 12) / 25);
241  else
242  xp = 50 * ((xp + 25) / 50);
243 
244  return xp;
245  }
246 
247  return 0;
248 }
float RewardXPMultiplier
Definition: QuestDef.h:413
uint32 RewardXPDifficulty
Definition: QuestDef.h:412
int32_t int32
Definition: Define.h:146
uint32_t uint32
Definition: Define.h:150
Definition: DB2Structure.h:1100
DB2Storage< QuestXPEntry > sQuestXPStore("QuestXP.db2", QuestXPFormat, HOTFIX_SEL_QUEST_XP)
int32 Level
Definition: QuestDef.h:405
uint32 Exp[10]
Definition: DB2Structure.h:1103

Friends And Related Function Documentation

friend class ObjectMgr
friend
friend class Player
friend
friend class PlayerMenu
friend

Member Data Documentation

uint32 Quest::_rewChoiceItemsCount
private
uint32 Quest::_rewCurrencyCount
private
uint32 Quest::_rewItemsCount
private
uint32 Quest::AllowableClasses = 0
protected
int32 Quest::AllowableRaces
std::string Quest::AreaDescription
uint32 Quest::AreaGroupID
uint32 Quest::DetailsEmote[QUEST_EMOTE_COUNT] = {}
protected
uint32 Quest::DetailsEmoteDelay[QUEST_EMOTE_COUNT] = {}
protected
uint32 Quest::EmoteOnComplete = 0
protected
uint32 Quest::EmoteOnCompleteDelay = 0
protected
uint32 Quest::EmoteOnIncomplete = 0
protected
uint32 Quest::EmoteOnIncompleteDelay = 0
protected
int32 Quest::ExclusiveGroup = 0
protected
uint32 Quest::Flags
uint32 Quest::FlagsEx
uint32 Quest::ID
uint32 Quest::ItemDrop[QUEST_ITEM_DROP_COUNT]
uint32 Quest::ItemDropQuantity[QUEST_ITEM_DROP_COUNT]
int32 Quest::Level
uint32 Quest::LimitTime
std::string Quest::LogDescription
std::string Quest::LogTitle
uint32 Quest::MaxLevel = 0
protected
int32 Quest::MinLevel
int32 Quest::NextQuestID = 0
protected
uint32 Quest::NextQuestInChain
QuestObjectives Quest::Objectives
uint32 Quest::OfferRewardEmote[QUEST_EMOTE_COUNT] = {}
protected
uint32 Quest::OfferRewardEmoteDelay[QUEST_EMOTE_COUNT] = {}
protected
std::string Quest::OfferRewardText
protected
uint32 Quest::PackageID
uint32 Quest::POIContinent
uint32 Quest::POIPriority
float Quest::POIx
float Quest::POIy
std::string Quest::PortraitGiverName
std::string Quest::PortraitGiverText
std::string Quest::PortraitTurnInName
std::string Quest::PortraitTurnInText
PrevChainQuests Quest::prevChainQuests
int32 Quest::PrevQuestID = 0
protected
PrevQuests Quest::prevQuests
std::string Quest::QuestCompletionLog
std::string Quest::QuestDescription
uint32 Quest::QuestGiverPortrait
uint32 Quest::QuestInfoID
int32 Quest::QuestSortID
uint32 Quest::QuestTurnInPortrait
std::string Quest::RequestItemsText
protected
uint32 Quest::RequiredMaxRepFaction = 0
protected
int32 Quest::RequiredMaxRepValue = 0
protected
uint32 Quest::RequiredMinRepFaction = 0
protected
int32 Quest::RequiredMinRepValue = 0
protected
uint32 Quest::RequiredSkillId = 0
protected
uint32 Quest::RequiredSkillPoints = 0
protected
int32 Quest::RewardArenaPoints
uint32 Quest::RewardBonusMoney
uint32 Quest::RewardChoiceItemCount[QUEST_REWARD_CHOICES_COUNT]
uint32 Quest::RewardChoiceItemDisplayId[QUEST_REWARD_CHOICES_COUNT]
uint32 Quest::RewardChoiceItemId[QUEST_REWARD_CHOICES_COUNT]
uint32 Quest::RewardCurrencyCount[QUEST_REWARD_CURRENCY_COUNT]
uint32 Quest::RewardCurrencyId[QUEST_REWARD_CURRENCY_COUNT]
uint32 Quest::RewardDisplaySpell
uint32 Quest::RewardFactionId[QUEST_REWARD_REPUTATIONS_COUNT]
int32 Quest::RewardFactionOverride[QUEST_REWARD_REPUTATIONS_COUNT]
int32 Quest::RewardFactionValue[QUEST_REWARD_REPUTATIONS_COUNT]
uint32 Quest::RewardHonor
uint32 Quest::RewardItemCount[QUEST_REWARD_ITEM_COUNT]
uint32 Quest::RewardItemId[QUEST_REWARD_ITEM_COUNT]
uint32 Quest::RewardKillHonor
uint32 Quest::RewardMailDelay = 0
protected
uint32 Quest::RewardMailTemplateId = 0
protected
int32 Quest::RewardMoney
uint32 Quest::RewardMoneyDifficulty
float Quest::RewardMoneyMultiplier
uint32 Quest::RewardReputationMask
uint32 Quest::RewardSkillId
uint32 Quest::RewardSkillPoints
uint32 Quest::RewardSpell
uint32 Quest::RewardTalents
uint32 Quest::RewardTitleId
uint32 Quest::RewardXPDifficulty
float Quest::RewardXPMultiplier
uint32 Quest::SoundAccept
uint32 Quest::SoundTurnIn
uint32 Quest::SourceItemId
uint32 Quest::SourceItemIdCount = 0
protected
uint32 Quest::SourceSpellID = 0
protected
uint32 Quest::SpecialFlags = 0
protected
uint32 Quest::SuggestedPlayers
uint32 Quest::Type

The documentation for this class was generated from the following files: