mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-11 21:01:29 +00:00
[Spells] Corrected implementation of SE_Purify 291 (#1541)
* Correct implementation of spa291 * debug removal
This commit is contained in:
parent
71870cbd1c
commit
df9d6bc506
@ -153,8 +153,10 @@
|
||||
#define SPELL_ACTING_SPIRIT_I 1921
|
||||
#define SPELL_ACTING_SPIRIT_II 1922
|
||||
#define SPELL_RESURRECTION_SICKNESS 756
|
||||
#define SPELL_RESURRECTION_SICKNESS4 757
|
||||
#define SPELL_RESURRECTION_SICKNESS2 5249
|
||||
#define SPELL_REVIVAL_SICKNESS 13087
|
||||
#define SPELL_RESURRECTION_SICKNESS3 37624
|
||||
#define SPELL_PACT_OF_HATE_RECOURSE 40375
|
||||
#define SPELL_INCENDIARY_OOZE_BUFF 32513
|
||||
|
||||
@ -974,7 +976,7 @@ typedef enum {
|
||||
#define SE_SkillAttackProc 288 // implemented[AA] - Chance to proc spell on skill attack usage (ex. Dragon Punch)
|
||||
#define SE_CastOnFadeEffect 289 // implemented - Triggers only if fades after natural duration.
|
||||
#define SE_IncreaseRunSpeedCap 290 // implemented[AA] - increases run speed over the hard cap
|
||||
#define SE_Purify 291 // implemented - Removes determental effects
|
||||
#define SE_Purify 291 // implemented, @Dispel, remove up specified amount of detiremental spells, base: amt removed, limit: none, max: none, Note: excluding charm, fear, resurrection, and revival sickness
|
||||
#define SE_StrikeThrough2 292 // implemented[AA] - increasing chance of bypassing an opponent's special defenses, such as dodge, block, parry, and riposte.
|
||||
#define SE_FrontalStunResist 293 // implemented[AA] - Reduce chance to be stunned from front. -- live descriptions sounds like this isn't limited to frontal anymore
|
||||
#define SE_CriticalSpellChance 294 // implemented - increase chance to critical hit and critical damage modifier.
|
||||
|
||||
@ -1118,13 +1118,23 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
|
||||
case SE_Purify:
|
||||
{
|
||||
//Attempt to remove all Deterimental buffs.
|
||||
int buff_count = GetMaxTotalSlots();
|
||||
for(int slot = 0; slot < buff_count; slot++) {
|
||||
if (buffs[slot].spellid != SPELL_UNKNOWN &&
|
||||
IsDetrimentalSpell(buffs[slot].spellid) && spells[buffs[slot].spellid].dispel_flag == 0)
|
||||
{
|
||||
if (caster && TryDispel(caster->GetLevel(),buffs[slot].casterlevel, effect_value)){
|
||||
//Attempt to remove up to base amount of detrimental effects (excluding charm, fear, resurrection, and revival sickness).
|
||||
int purify_count = spells[spell_id].base[i];
|
||||
if (purify_count > GetMaxTotalSlots()) {
|
||||
purify_count = GetMaxTotalSlots();
|
||||
}
|
||||
|
||||
for(int slot = 0; slot < purify_count; slot++) {
|
||||
if (IsValidSpell(buffs[slot].spellid) && IsDetrimentalSpell(buffs[slot].spellid)){
|
||||
|
||||
if (!IsEffectInSpell(buffs[slot].spellid, SE_Charm) &&
|
||||
!IsEffectInSpell(buffs[slot].spellid, SE_Fear) &&
|
||||
buffs[slot].spellid != SPELL_RESURRECTION_SICKNESS &&
|
||||
buffs[slot].spellid != SPELL_RESURRECTION_SICKNESS2 &&
|
||||
buffs[slot].spellid != SPELL_RESURRECTION_SICKNESS3 &&
|
||||
buffs[slot].spellid != SPELL_RESURRECTION_SICKNESS4 &&
|
||||
buffs[slot].spellid != SPELL_REVIVAL_SICKNESS)
|
||||
{
|
||||
BuffFadeBySlot(slot);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user