mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
added AiPlayerbot.LimitGearExpansion option so that bots <= 60 can be limited to expansions gear based on level (bot-level <= 60 gets vanilla gear, bot <= 70 gets TBC gear). also modified level thresholds for LimitEnchantExpansion option (which were <= 69 for vanilla enchants and <= 79 for TBC - those dont seem right because 61-69 are TBC levels, not vanilla, same for 71-79 being WOTLK)
This commit is contained in:
@@ -511,9 +511,15 @@ AiPlayerbot.RandomGearScoreLimit = 0
|
||||
# Default: 60
|
||||
AiPlayerbot.MinEnchantingBotLevel = 60
|
||||
|
||||
# Enable expansion limitation
|
||||
# Default: 1
|
||||
AiPlayerbot.LimitEnchantExpansion = 1
|
||||
# Enable expansion limitation for enchants - ie: level <= 60 bot only uses enchants
|
||||
# available in vanilla, level <= 70 bot only uses enchants available in TBC)
|
||||
# Default: 0
|
||||
AiPlayerbot.LimitEnchantExpansion = 0
|
||||
|
||||
# Enable expansion limitation for gear - ie: level <= 60 bot only uses gear
|
||||
# available in vanilla, level <= 70 bot only uses gear available in TBC)
|
||||
# Default: 0
|
||||
AiPlayerbot.LimitGearExpansion = 0
|
||||
|
||||
# Change random bot has lower gear
|
||||
AiPlayerbot.RandomGearLoweringChance = 0
|
||||
|
||||
@@ -300,7 +300,8 @@ bool PlayerbotAIConfig::Initialize()
|
||||
randombotsWalkingRPG = sConfigMgr->GetOption<bool>("AiPlayerbot.RandombotsWalkingRPG", false);
|
||||
randombotsWalkingRPGInDoors = sConfigMgr->GetOption<bool>("AiPlayerbot.RandombotsWalkingRPG.InDoors", false);
|
||||
minEnchantingBotLevel = sConfigMgr->GetOption<int32>("AiPlayerbot.MinEnchantingBotLevel", 60);
|
||||
limitEnchantExpansion = sConfigMgr->GetOption<int32>("AiPlayerbot.LimitEnchantExpansion", 1);
|
||||
limitEnchantExpansion = sConfigMgr->GetOption<int32>("AiPlayerbot.LimitEnchantExpansion", 0);
|
||||
limitGearExpansion = sConfigMgr->GetOption<int32>("AiPlayerbot.LimitGearExpansion", 0);
|
||||
randombotStartingLevel = sConfigMgr->GetOption<int32>("AiPlayerbot.RandombotStartingLevel", 5);
|
||||
enableRotation = sConfigMgr->GetOption<bool>("AiPlayerbot.EnableRotation", false);
|
||||
rotationPoolSize = sConfigMgr->GetOption<int32>("AiPlayerbot.RotationPoolSize", 500);
|
||||
|
||||
@@ -136,6 +136,7 @@ class PlayerbotAIConfig
|
||||
bool randombotsWalkingRPGInDoors;
|
||||
uint32 minEnchantingBotLevel;
|
||||
uint32 limitEnchantExpansion;
|
||||
uint32 limitGearExpansion;
|
||||
uint32 randombotStartingLevel;
|
||||
bool enableRotation;
|
||||
uint32 rotationPoolSize;
|
||||
|
||||
@@ -1456,6 +1456,14 @@ void PlayerbotFactory::InitEquipment(bool incremental)
|
||||
if (itemId == 46978) { // shaman earth ring totem
|
||||
continue;
|
||||
}
|
||||
|
||||
// disable next expansion gear
|
||||
if (sPlayerbotAIConfig->limitGearExpansion && bot->GetLevel() <= 60 && itemId >= 23728)
|
||||
continue;
|
||||
|
||||
if (sPlayerbotAIConfig->limitGearExpansion && bot->GetLevel() <= 70 && itemId >= 35570 && itemId != 36737 && itemId != 37739 && itemId != 37740)//transition point from TBC -> WOTLK isn't as clear, and there are other wearable TBC items above 35570 but nothing of significance
|
||||
continue;
|
||||
|
||||
ItemTemplate const* proto = sObjectMgr->GetItemTemplate(itemId);
|
||||
if (!proto)
|
||||
continue;
|
||||
@@ -3454,15 +3462,12 @@ void PlayerbotFactory::ApplyEnchantAndGemsNew(bool destoryOld)
|
||||
continue;
|
||||
}
|
||||
|
||||
// disable next expansion
|
||||
if (sPlayerbotAIConfig->limitEnchantExpansion && bot->GetLevel() <= 69 && enchantSpell >= 25072) {
|
||||
// disable next expansion enchantments
|
||||
if (sPlayerbotAIConfig->limitEnchantExpansion && bot->GetLevel() <= 60 && enchantSpell >= 25072)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (sPlayerbotAIConfig->limitEnchantExpansion && bot->GetLevel() <= 79 && enchantSpell > 48557) {
|
||||
if (sPlayerbotAIConfig->limitEnchantExpansion && bot->GetLevel() <= 70 && enchantSpell > 48557)
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
for (uint8 j = 0; j < MAX_SPELL_EFFECTS; ++j)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user