Hunter wolf pet config and modify config file layout for activities

This commit is contained in:
Yunfan Li
2025-01-19 14:02:32 +08:00
parent f096975f90
commit 812702ea25
4 changed files with 55 additions and 30 deletions

View File

@@ -36,6 +36,7 @@
#include "SharedDefines.h"
#include "SpellAuraDefines.h"
#include "StatsWeightCalculator.h"
#include "World.h"
#define PLAYER_SKILL_INDEX(x) (PLAYER_SKILL_INFO_1_1 + ((x)*3))
@@ -786,6 +787,13 @@ void PlayerbotFactory::InitPet()
if (itr->second.minlevel > bot->GetLevel())
continue;
bool onlyWolf = sPlayerbotAIConfig->hunterWolfPet == 2 ||
(sPlayerbotAIConfig->hunterWolfPet == 1 &&
bot->GetLevel() >= sWorld->getIntConfig(CONFIG_MAX_PLAYER_LEVEL));
// Wolf only (for higher dps)
if (onlyWolf && itr->second.family != CREATURE_FAMILY_WOLF)
continue;
ids.push_back(itr->first);
}