Core/Groups: Reimplement group id recycling

This commit is contained in:
leak
2011-02-27 00:55:45 +01:00
parent 3ac80ee3a4
commit aa2455b586
6 changed files with 119 additions and 110 deletions
+5 -2
View File
@@ -183,8 +183,8 @@ class Group
// group manipulation methods
bool Create(Player *leader);
bool LoadGroupFromDB(const uint32 &guid, QueryResult result, bool loadMembers = true);
bool LoadMemberFromDB(uint32 guidLow, uint8 memberFlags, uint8 subgroup, uint8 roles);
void LoadGroupFromDB(Field *field);
void LoadMemberFromDB(uint32 guidLow, uint8 memberFlags, uint8 subgroup, uint8 roles);
bool AddInvite(Player *player);
void RemoveInvite(Player *player);
void RemoveAllInvites();
@@ -213,6 +213,8 @@ class Group
const uint64& GetLooterGuid() const;
ItemQualities GetLootThreshold() const;
uint32 GetStorageId() { return m_storageId; };
// member manipulation methods
bool IsMember(const uint64& guid) const;
bool IsLeader(const uint64& guid) const;
@@ -328,5 +330,6 @@ class Group
uint64 m_guid;
uint32 m_counter; // used only in SMSG_GROUP_LIST
uint32 m_maxEnchantingLevel;
uint32 m_storageId; // Represents the ID used in database (Can be reused by other groups if group was disbanded)
};
#endif