mirror of
https://github.com/mod-playerbots/mod-playerbots.git
synced 2026-01-18 03:05:43 +00:00
feature - (#1100) Linking of "trusted" accounts to allow altbot-control apart from own account or guild (#1267)
* Add table to store the security keys for accounts. * Add table to store relationships between accounts. * Add a new configuration option to enable or disable trusted account bots. * add checks for linked accounts * Handle account linking and chat commands * fix uppercase typo * change query & fix chatcommandtable * add missing functions to header * move account linking to updates dir * moved table creation to correct updates folder * use playerbots db instead of character db * fix db * fix install? * remove duplicated logic and add hashing to stored securityKey * add object before call * change chat variable * rename SQL file for correct execution order * add header include for ubuntu compatibility * remove old sql
This commit is contained in:
@@ -28,6 +28,7 @@ public:
|
||||
virtual ~PlayerbotHolder(){};
|
||||
|
||||
void AddPlayerBot(ObjectGuid guid, uint32 masterAccountId);
|
||||
bool IsAccountLinked(uint32 accountId, uint32 masterAccountId);
|
||||
void HandlePlayerBotLoginCallback(PlayerbotLoginQueryHolder const& holder);
|
||||
|
||||
void LogoutPlayerBot(ObjectGuid guid);
|
||||
@@ -82,6 +83,11 @@ public:
|
||||
|
||||
void SaveToDB();
|
||||
|
||||
void HandleSetSecurityKeyCommand(Player* player, const std::string& key);
|
||||
void HandleLinkAccountCommand(Player* player, const std::string& accountName, const std::string& key);
|
||||
void HandleViewLinkedAccountsCommand(Player* player);
|
||||
void HandleUnlinkAccountCommand(Player* player, const std::string& accountName);
|
||||
|
||||
protected:
|
||||
void OnBotLoginInternal(Player* const bot) override;
|
||||
void CheckTellErrors(uint32 elapsed);
|
||||
|
||||
Reference in New Issue
Block a user