mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-10 10:50:24 +00:00
Change GetSpellListSpellType to GetParentSpellType
This commit is contained in:
+1
-1
@@ -11168,7 +11168,7 @@ bool Bot::AttemptForcedCastSpell(Mob* tar, uint16 spell_id) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint16 Bot::GetSpellListSpellType(uint16 spellType) {
|
||||
uint16 Bot::GetParentSpellType(uint16 spellType) {
|
||||
switch (spellType) {
|
||||
case BotSpellTypes::AENukes:
|
||||
case BotSpellTypes::AERains:
|
||||
|
||||
+1
-1
@@ -539,7 +539,7 @@ public:
|
||||
bool HasLoS() const { return _hasLoS; }
|
||||
|
||||
std::list<BotSpellTypeOrder> GetSpellTypesPrioritized(uint8 priorityType);
|
||||
uint16 GetSpellListSpellType(uint16 spellType);
|
||||
uint16 GetParentSpellType(uint16 spellType);
|
||||
bool IsValidSpellTypeBySpellID(uint16 spellType, uint16 spell_id);
|
||||
inline uint16 GetCastedSpellType() const { return _castedSpellType; }
|
||||
void SetCastedSpellType(uint16 spellType);
|
||||
|
||||
@@ -885,7 +885,7 @@ std::list<BotSpell> Bot::GetBotSpellsForSpellEffect(Bot* botCaster, uint16 spell
|
||||
|
||||
if (
|
||||
botCaster->CheckSpellRecastTimer(botSpellList[i].spellid) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid) &&
|
||||
(IsEffectInSpell(botSpellList[i].spellid, spellEffect) || GetSpellTriggerSpellID(botSpellList[i].spellid, spellEffect))
|
||||
) {
|
||||
@@ -923,7 +923,7 @@ std::list<BotSpell> Bot::GetBotSpellsForSpellEffectAndTargetType(Bot* botCaster,
|
||||
|
||||
if (
|
||||
botCaster->CheckSpellRecastTimer(botSpellList[i].spellid) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid) &&
|
||||
(
|
||||
IsEffectInSpell(botSpellList[i].spellid, spellEffect) ||
|
||||
@@ -964,7 +964,7 @@ std::list<BotSpell> Bot::GetBotSpellsBySpellType(Bot* botCaster, uint16 spellTyp
|
||||
|
||||
if (
|
||||
botCaster->CheckSpellRecastTimer(botSpellList[i].spellid) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid)
|
||||
) {
|
||||
BotSpell botSpell;
|
||||
@@ -999,7 +999,7 @@ std::list<BotSpell_wPriority> Bot::GetPrioritizedBotSpellsBySpellType(Bot* botCa
|
||||
|
||||
if (
|
||||
botCaster->CheckSpellRecastTimer(botSpellList[i].spellid) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid)
|
||||
) {
|
||||
if (
|
||||
@@ -1080,7 +1080,7 @@ BotSpell Bot::GetFirstBotSpellBySpellType(Bot* botCaster, uint16 spellType) {
|
||||
|
||||
if (
|
||||
botCaster->CheckSpellRecastTimer(botSpellList[i].spellid) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid)
|
||||
) {
|
||||
result.SpellId = botSpellList[i].spellid;
|
||||
@@ -1186,7 +1186,7 @@ BotSpell Bot::GetBestBotSpellForPercentageHeal(Bot *botCaster, Mob* tar, uint16
|
||||
}
|
||||
|
||||
if (
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetSpellListSpellType(spellType)) &&
|
||||
(botSpellList[i].type == spellType || botSpellList[i].type == botCaster->GetParentSpellType(spellType)) &&
|
||||
botCaster->IsValidSpellTypeBySpellID(spellType, botSpellList[i].spellid) &&
|
||||
IsCompleteHealSpell(botSpellList[i].spellid) &&
|
||||
botCaster->CastChecks(botSpellList[i].spellid, tar, spellType)
|
||||
@@ -2839,7 +2839,7 @@ void Bot::CheckBotSpells() {
|
||||
}
|
||||
|
||||
correctType = GetCorrectSpellType(s.type, spell_id);
|
||||
parentType = GetSpellListSpellType(correctType);
|
||||
parentType = GetParentSpellType(correctType);
|
||||
|
||||
if (RuleB(Bots, UseParentSpellTypeForChecks)) {
|
||||
if (s.type == parentType || s.type == correctType) {
|
||||
|
||||
Reference in New Issue
Block a user