[Code] SkillCaps Global to Singleton Cleanup (#4933)

This commit is contained in:
Alex King
2025-06-22 14:13:16 -04:00
committed by GitHub
parent 940f97c9ae
commit 2f4a5b56dd
10 changed files with 25 additions and 23 deletions
+5 -5
View File
@@ -1242,7 +1242,7 @@ uint16 Bot::GetPrimarySkillValue() {
}
uint16 Bot::MaxSkill(EQ::skills::SkillType skillid, uint16 class_, uint16 level) const {
return skill_caps.GetSkillCap(class_, skillid, level).cap;
return SkillCaps::Instance()->GetSkillCap(class_, skillid, level).cap;
}
uint32 Bot::GetTotalATK() {
@@ -3575,7 +3575,7 @@ void Bot::Depop() {
RemoveAllAuras();
Mob* bot_pet = GetPet();
if (bot_pet) {
if (bot_pet->Charmed()) {
bot_pet->BuffFadeByEffect(SE_Charm);
@@ -7342,7 +7342,7 @@ void Bot::CalcBotStats(bool showtext) {
SetLevel(GetBotOwner()->GetLevel());
for (int sindex = 0; sindex <= EQ::skills::HIGHEST_SKILL; ++sindex) {
skills[sindex] = skill_caps.GetSkillCap(GetClass(), (EQ::skills::SkillType)sindex, GetLevel()).cap;
skills[sindex] = SkillCaps::Instance()->GetSkillCap(GetClass(), (EQ::skills::SkillType)sindex, GetLevel()).cap;
}
taunt_timer.Start(1000);
@@ -11274,7 +11274,7 @@ void Bot::SetSpellTypePriority(uint16 spell_type, uint8 priority_type, uint16 pr
std::list<BotSpellTypeOrder> Bot::GetSpellTypesPrioritized(uint8 priority_type) {
std::list<BotSpellTypeOrder> cast_order;
for (uint16 i = BotSpellTypes::START; i <= BotSpellTypes::END; i++) {
BotSpellTypeOrder typeSettings = {
.spellType = i,
@@ -13463,4 +13463,4 @@ bool Bot::HasControllablePet(uint8 ranks_required) {
return GetClass() != Class::Enchanter ||
GetPet()->GetPetType() != petAnimation ||
GetAA(aaAnimationEmpathy) >= ranks_required;
}
}