mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-01 10:03:47 +00:00
feat(Core/Quests): Implemented quest_money_rewards (for quest with Qu… (#8610)
Fixes #8440
This commit is contained in:
@@ -690,6 +690,10 @@ struct DungeonEncounter
|
||||
typedef std::list<DungeonEncounter const*> DungeonEncounterList;
|
||||
typedef std::unordered_map<uint32, DungeonEncounterList> DungeonEncounterContainer;
|
||||
|
||||
static constexpr uint32 MAX_QUEST_MONEY_REWARDS = 10;
|
||||
typedef std::array<uint32, MAX_QUEST_MONEY_REWARDS> QuestMoneyRewardArray;
|
||||
typedef std::unordered_map<uint32, QuestMoneyRewardArray> QuestMoneyRewardStore;
|
||||
|
||||
class PlayerDumpReader;
|
||||
|
||||
class ObjectMgr
|
||||
@@ -915,6 +919,7 @@ public:
|
||||
}
|
||||
|
||||
void LoadQuests();
|
||||
void LoadQuestMoneyRewards();
|
||||
void LoadQuestStartersAndEnders()
|
||||
{
|
||||
LOG_INFO("server.loading", "Loading GO Start Quest Data...");
|
||||
@@ -1361,6 +1366,8 @@ public:
|
||||
|
||||
[[nodiscard]] bool IsTransportMap(uint32 mapId) const { return _transportMaps.count(mapId) != 0; }
|
||||
|
||||
[[nodiscard]] uint32 GetQuestMoneyReward(uint8 level, uint32 questMoneyDifficulty) const;
|
||||
|
||||
private:
|
||||
// first free id for selected id type
|
||||
uint32 _auctionId; // pussywizard: accessed by a single thread
|
||||
@@ -1523,6 +1530,8 @@ private:
|
||||
};
|
||||
|
||||
std::set<uint32> _transportMaps; // Helper container storing map ids that are for transports only, loaded from gameobject_template
|
||||
|
||||
QuestMoneyRewardStore _questMoneyRewards;
|
||||
};
|
||||
|
||||
#define sObjectMgr ObjectMgr::instance()
|
||||
|
||||
Reference in New Issue
Block a user