mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
Fix keyring for low level bots (#1177)
This commit is contained in:
@@ -491,6 +491,7 @@ void PlayerbotFactory::Refresh()
|
||||
InitSpecialSpells();
|
||||
InitMounts();
|
||||
InitKeyring();
|
||||
InitPotions();
|
||||
if (bot->GetLevel() >= sPlayerbotAIConfig->minEnchantingBotLevel)
|
||||
{
|
||||
ApplyEnchantAndGemsNew();
|
||||
@@ -4280,6 +4281,9 @@ void PlayerbotFactory::InitKeyring()
|
||||
if (!bot)
|
||||
return;
|
||||
|
||||
if (bot->GetLevel() < 70)
|
||||
return;
|
||||
|
||||
ReputationMgr& repMgr = bot->GetReputationMgr(); // Reference, use . instead of ->
|
||||
|
||||
std::vector<std::pair<uint32, uint32>> keysToCheck;
|
||||
|
||||
@@ -140,6 +140,7 @@ public:
|
||||
void InitKeyring();
|
||||
void InitReputation();
|
||||
void InitAttunementQuests();
|
||||
void InitPotions();
|
||||
|
||||
private:
|
||||
void Prepare();
|
||||
@@ -159,7 +160,6 @@ private:
|
||||
void ClearInventory();
|
||||
void ClearAllItems();
|
||||
void ResetQuests();
|
||||
void InitPotions();
|
||||
|
||||
std::vector<uint32> GetCurrentGemsCount();
|
||||
bool CanEquipArmor(ItemTemplate const* proto);
|
||||
|
||||
@@ -181,6 +181,7 @@ bool MaintenanceAction::Execute(Event event)
|
||||
factory.InitMounts();
|
||||
factory.InitGlyphs(true);
|
||||
factory.InitKeyring();
|
||||
factory.InitPotions();
|
||||
if (bot->GetLevel() >= sPlayerbotAIConfig->minEnchantingBotLevel)
|
||||
factory.ApplyEnchantAndGemsNew();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user