mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-23 13:46:24 +00:00
refactor(Core/Account): Move account flag logic from AccountMgr to WorldSession (#22558)
This commit is contained in:
@@ -329,9 +329,14 @@ struct PacketCounter
|
||||
class WorldSession
|
||||
{
|
||||
public:
|
||||
WorldSession(uint32 id, std::string&& name, std::shared_ptr<WorldSocket> sock, AccountTypes sec, uint8 expansion, time_t mute_time, LocaleConstant locale, uint32 recruiter, bool isARecruiter, bool skipQueue, uint32 TotalTime);
|
||||
WorldSession(uint32 id, std::string&& name, uint32 accountFlags, std::shared_ptr<WorldSocket> sock, AccountTypes sec, uint8 expansion, time_t mute_time, LocaleConstant locale, uint32 recruiter, bool isARecruiter, bool skipQueue, uint32 TotalTime);
|
||||
~WorldSession();
|
||||
|
||||
uint32 GetAccountFlags() const { return _accountFlags; }
|
||||
bool HasAccountFlag(uint32 flag) const { return (_accountFlags & flag) != 0; }
|
||||
void UpdateAccountFlag(uint32 flag, bool remove = false);
|
||||
void ValidateAccountFlags();
|
||||
|
||||
bool IsGMAccount() const;
|
||||
|
||||
bool PlayerLoading() const { return m_playerLoading; }
|
||||
@@ -1158,6 +1163,7 @@ private:
|
||||
bool _skipQueue;
|
||||
uint32 _accountId;
|
||||
std::string _accountName;
|
||||
uint32 _accountFlags;
|
||||
uint8 m_expansion;
|
||||
uint32 m_total_time;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user