Core/Spells: More generic implementation of Combustion

Closes #60 & #78
This commit is contained in:
tobmaps
2011-05-11 04:17:38 +07:00
parent 492e6fd3da
commit 09fb6f555f
3 changed files with 8 additions and 8 deletions
@@ -0,0 +1,2 @@
DELETE FROM `spell_linked_spell` WHERE `spell_trigger` = -11129;
INSERT INTO `spell_linked_spell` VALUES (-11129, -28682, 0, 'Combustion');
@@ -19630,6 +19630,10 @@ void Player::RemoveSpellMods(Spell * spell)
void Player::DropModCharge(SpellModifier * mod, Spell * spell)
{
// this mod shouldn't be removed here
if (mod->op == SPELLMOD_CRIT_DAMAGE_BONUS)
return;
if (spell && mod->ownerAura && mod->charges > 0)
{
--mod->charges;
+2 -8
View File
@@ -7908,17 +7908,11 @@ bool Unit::HandleAuraProc(Unit * pVictim, uint32 damage, Aura * triggeredByAura,
//last charge and crit
if (triggeredByAura->GetCharges() <= 1 && (procEx & PROC_EX_CRITICAL_HIT))
{
RemoveAurasDueToSpell(28682); //-> remove Combustion auras
return true; // charge counting (will removed)
}
// This function can be called twice during one spell hit (Area of Effect spells)
// Make sure 28682 wasn't already removed by previous call
if (HasAura(28682))
this->CastSpell(this, 28682, true);
CastSpell(this, 28682, true);
return false; // ordinary chrages will be removed during crit chance computations.
return (procEx & PROC_EX_CRITICAL_HIT) ? true : false;
}
// Empowered Fire
case 31656: