[Spells] SPA 311 SE_LimitCombatSkills should prevent focusing of procs even if proc is a 'casted' spell. (#1961)

* proc limiter update

* Update spdat.h

* [Spells] SPA 311 SE_LimitCombatSkills should prevent focusing of procs even if proc is a 'casted' spell.
This commit is contained in:
KayenEQ 2022-02-04 21:14:40 -05:00 committed by GitHub
parent d300e78b39
commit dbe6adbed0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 19 additions and 23 deletions

View File

@ -1030,7 +1030,7 @@ typedef enum {
#define SE_ZoneSuspendMinion 308 // implemented, @Pet, allow suspended pets to be resummoned upon zoning, base: 1, limit: none, max: none, Calc: Bool
#define SE_GateCastersBindpoint 309 // implemented - Gate to casters bind point
#define SE_ReduceReuseTimer 310 // implemented, @Fc, On Caster, spell and disc reuse time mod by amount, base: milliseconds
#define SE_LimitCombatSkills 311 // implemented, @Ff, Include or exclude combat skills or procs (non-memorizable spells) from being focused, base1: 0=Exclude if proc 1=Allow only if proc
#define SE_LimitCombatSkills 311 // implemented, @Ff, Include or exclude combat skills or procs from being focused, base1: 0=Exclude if proc 1=Allow only if proc.
#define SE_Sanctuary 312 // implemented - Places caster at bottom hate list, effect fades if cast cast spell on targets other than self.
#define SE_ForageAdditionalItems 313 // implemented[AA] - chance to forage additional items
#define SE_Invisibility2 314 // implemented - fixed duration invisible

View File

@ -5836,22 +5836,20 @@ bool Mob::IsCombatProc(uint16 spell_id) {
if (spell_id == SPELL_UNKNOWN) {
return(false);
}
if ((spells[spell_id].cast_time == 0) && (spells[spell_id].recast_time == 0) && (spells[spell_id].recovery_time == 0))
{
for (int i = 0; i < MAX_PROCS; i++){
/*
Procs that originate from casted spells are still limited by SPA 311 (~Kayen confirmed on live 2/4/22)
*/
for (int i = 0; i < MAX_PROCS; i++) {
if (PermaProcs[i].spellID == spell_id ||
SpellProcs[i].spellID == spell_id ||
RangedProcs[i].spellID == spell_id ||
DefensiveProcs[i].spellID == spell_id){
DefensiveProcs[i].spellID == spell_id) {
return true;
}
}
if (IsClient()) {
for (int i = 0; i < MAX_AA_PROCS; i += 4) {
if (aabonuses.SpellProc[i + 1] == spell_id ||
aabonuses.RangedProc[i + 1] == spell_id ||
aabonuses.DefensiveProc[i + 1] == spell_id) {
@ -5859,8 +5857,6 @@ bool Mob::IsCombatProc(uint16 spell_id) {
}
}
}
}
return false;
}