mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-18 14:10:18 -04:00
Core/Auras: fixed off by one error in counting SPELL_ATTR5_START_PERIODIC_AT_APPLY ticks
- Made SpellInfo::GetMaxTicks and AuraEffect::GetTotalTicks return the same number without mods (dumped arbitrary default return value of 6 and arbitrary 30 sec limit)
- They should be streamlined whenever SPELL_AURA_48 is implemented
(cherry picked from commit 7dff0e3246)
This commit is contained in:
@@ -452,6 +452,7 @@ class spell_mage_ignite : public AuraScript
|
||||
SpellInfo const* igniteDot = sSpellMgr->AssertSpellInfo(SPELL_MAGE_IGNITE, GetCastDifficulty());
|
||||
int32 pct = aurEff->GetAmount();
|
||||
|
||||
ASSERT(igniteDot->GetMaxTicks() > 0);
|
||||
int32 amount = int32(CalculatePct(eventInfo.GetDamageInfo()->GetDamage(), pct) / igniteDot->GetMaxTicks());
|
||||
amount += eventInfo.GetProcTarget()->GetRemainingPeriodicAmount(eventInfo.GetActor()->GetGUID(), SPELL_MAGE_IGNITE, SPELL_AURA_PERIODIC_DAMAGE);
|
||||
GetTarget()->CastCustomSpell(SPELL_MAGE_IGNITE, SPELLVALUE_BASE_POINT0, amount, eventInfo.GetProcTarget(), true, nullptr, aurEff);
|
||||
|
||||
Reference in New Issue
Block a user