mirror of
https://github.com/EQEmu/Server.git
synced 2026-09-05 03:06:38 +00:00
[Loot] Remove from shared memory, simplification (#3988)
* First pass of pulling loot out of shared memory, functional * More code cleanup * More cleanup * More cleanup * More cleanup * Add loot reload type * Reload, logging * Update npc.h * Cleanup * Logging, don't load attempt to load loottable id 0 * Update worldserver.cpp * Update client.cpp * Update zone_loot.cpp * PR feedback * Update zone.cpp * Memory leak suggestion * Update CMakeLists.txt * Post rebase issues
This commit is contained in:
+20
@@ -41,6 +41,10 @@
|
||||
#include "../common/repositories/npc_faction_repository.h"
|
||||
#include "../common/repositories/npc_faction_entries_repository.h"
|
||||
#include "../common/repositories/faction_association_repository.h"
|
||||
#include "../common/repositories/loottable_repository.h"
|
||||
#include "../common/repositories/loottable_entries_repository.h"
|
||||
#include "../common/repositories/lootdrop_repository.h"
|
||||
#include "../common/repositories/lootdrop_entries_repository.h"
|
||||
|
||||
struct EXPModifier
|
||||
{
|
||||
@@ -425,6 +429,16 @@ public:
|
||||
void ReloadFactionAssociations();
|
||||
FactionAssociationRepository::FactionAssociation* GetFactionAssociation(const uint32 faction_id);
|
||||
|
||||
// loot
|
||||
void LoadLootTable(const uint32 loottable_id);
|
||||
void LoadLootTables(const std::vector<uint32>& loottable_ids);
|
||||
void ClearLootTables();
|
||||
void ReloadLootTables();
|
||||
LoottableRepository::Loottable *GetLootTable(const uint32 loottable_id);
|
||||
std::vector<LoottableEntriesRepository::LoottableEntries> GetLootTableEntries(const uint32 loottable_id) const;
|
||||
LootdropRepository::Lootdrop GetLootdrop(const uint32 lootdrop_id) const;
|
||||
std::vector<LootdropEntriesRepository::LootdropEntries> GetLootdropEntries(const uint32 lootdrop_id) const;
|
||||
|
||||
private:
|
||||
bool allow_mercs;
|
||||
bool can_bind;
|
||||
@@ -479,6 +493,12 @@ private:
|
||||
std::vector<NpcFactionRepository::NpcFaction> m_npc_factions = { };
|
||||
std::vector<NpcFactionEntriesRepository::NpcFactionEntries> m_npc_faction_entries = { };
|
||||
std::vector<FactionAssociationRepository::FactionAssociation> m_faction_associations = { };
|
||||
|
||||
// loot
|
||||
std::vector<LoottableRepository::Loottable> m_loottables = {};
|
||||
std::vector<LoottableEntriesRepository::LoottableEntries> m_loottable_entries = {};
|
||||
std::vector<LootdropRepository::Lootdrop> m_lootdrops = {};
|
||||
std::vector<LootdropEntriesRepository::LootdropEntries> m_lootdrop_entries = {};
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user