mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
Merge branch 'master' into 310
Conflicts: src/game/Unit.cpp
This commit is contained in:
commit
17d86309fa
22 changed files with 373 additions and 190 deletions
|
|
@ -1748,6 +1748,26 @@ void Spell::EffectDummy(uint32 i)
|
|||
return;
|
||||
}
|
||||
break;
|
||||
case SPELLFAMILY_DEATHKNIGHT:
|
||||
// Death Coil
|
||||
if(m_spellInfo->SpellFamilyFlags & 0x002000LL)
|
||||
{
|
||||
if(m_caster->IsFriendlyTo(unitTarget))
|
||||
{
|
||||
if(unitTarget->GetCreatureType() != CREATURE_TYPE_UNDEAD)
|
||||
return;
|
||||
|
||||
int32 bp = damage * 1.5f;
|
||||
m_caster->CastCustomSpell(unitTarget,47633,&bp,NULL,NULL,true);
|
||||
}
|
||||
else
|
||||
{
|
||||
int32 bp = damage;
|
||||
m_caster->CastCustomSpell(unitTarget,47632,&bp,NULL,NULL,true);
|
||||
}
|
||||
return;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
// pet auras
|
||||
|
|
@ -2375,6 +2395,14 @@ void Spell::EffectPowerBurn(uint32 i)
|
|||
if(damage < 0)
|
||||
return;
|
||||
|
||||
// burn x% of target's mana, up to maximum of 2x% of caster's mana (Mana Burn)
|
||||
if(m_spellInfo->ManaCostPercentage)
|
||||
{
|
||||
uint32 maxdamage = m_caster->GetMaxPower(powertype) * damage * 2 / 100;
|
||||
damage = unitTarget->GetMaxPower(powertype) * damage / 100;
|
||||
if(damage > maxdamage) damage = maxdamage;
|
||||
}
|
||||
|
||||
int32 curPower = int32(unitTarget->GetPower(powertype));
|
||||
|
||||
// resilience reduce mana draining effect at spell crit damage reduction (added in 2.4)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue