[Spells] AE Duration effect (Rains) will now work with Target Ring and PBAE spells. (#2000)

* done

* Update beacon.cpp

* [Spells] AE Duration effect (Rains) will now work with Target Ring and PBAE spells.

Mackals suggestions implemented.
This commit is contained in:
KayenEQ
2022-02-16 10:12:13 -05:00
committed by GitHub
parent 8ec80644ee
commit ba3c19ad0b
5 changed files with 47 additions and 19 deletions
+12 -3
View File
@@ -364,10 +364,19 @@ bool IsImprovedDamageSpell(uint16 spell_id)
bool IsAEDurationSpell(uint16 spell_id)
{
if (IsValidSpell(spell_id) &&
(spells[spell_id].target_type == ST_AETarget || spells[spell_id].target_type == ST_UndeadAE) &&
spells[spell_id].aoe_duration != 0)
/*
There are plenty of spells with aoe_duration set at single digit numbers, but these
do not act as duration effects.
*/
if (IsValidSpell(spell_id) &&
spells[spell_id].aoe_duration >= 2500 &&
( spells[spell_id].target_type == ST_AETarget ||
spells[spell_id].target_type == ST_UndeadAE ||
spells[spell_id].target_type == ST_AECaster ||
spells[spell_id].target_type == ST_Ring)
) {
return true;
}
return false;
}