Merge commit 'origin/master' into 310

Conflicts:
	src/game/UpdateData.cpp
This commit is contained in:
tomrus88 2009-06-07 21:42:02 +04:00
commit 1f87157edf
20 changed files with 195 additions and 139 deletions

View file

@ -1808,7 +1808,7 @@ void Unit::CalcAbsorbResist(Unit *pVictim,SpellSchoolMask schoolMask, DamageEffe
// This, if I'm not mistaken, shows that we get back ~2% of the absorbed damage as runic power.
int32 absorbed = RemainingDamage * currentAbsorb / 100;
int32 regen = absorbed * 2 / 10;
pVictim->CastCustomSpell(pVictim, 49088, &regen, 0, 0, true, 0, *i);
pVictim->CastCustomSpell(pVictim, 49088, &regen, NULL, NULL, true, NULL, *i);
RemainingDamage -= absorbed;
continue;
}
@ -5506,14 +5506,18 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu
int32 holy = caster->SpellBaseDamageBonus(SPELL_SCHOOL_MASK_HOLY) +
caster->SpellBaseDamageBonusForVictim(SPELL_SCHOOL_MASK_HOLY, this);
basepoints0 = int32(ap*0.10f + 0.10f*holy);
pVictim->CastCustomSpell(pVictim, 20267, &basepoints0, 0, 0, true, 0, triggeredByAura);
pVictim->CastCustomSpell(pVictim, 20267, &basepoints0, NULL, NULL, true, NULL, triggeredByAura);
return true;
}
// Judgement of Wisdom
case 20186:
{
if (pVictim->getPowerType() == POWER_MANA)
pVictim->CastSpell(pVictim, 20268, true, 0, triggeredByAura);
{
// 2% of maximum base mana
basepoints0 = int32(pVictim->GetCreateMana() * 2 / 100);
pVictim->CastCustomSpell(pVictim, 20268, &basepoints0, NULL, NULL, true, NULL, triggeredByAura);
}
return true;
}
// Holy Power (Redemption Armor set)
@ -5547,6 +5551,29 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu
}
break;
}
case 25899: // Greater Blessing of Sanctuary
case 20911: // Blessing of Sanctuary
{
if (target->GetTypeId() != TYPEID_PLAYER)
return false;
target = this;
switch (target->getPowerType())
{
case POWER_MANA:
triggered_spell_id = 57319;
break;
case POWER_RAGE:
triggered_spell_id = 57320;
break;
case POWER_RUNIC_POWER:
triggered_spell_id = 57321;
break;
default:
return false;
}
break;
}
// Seal of Vengeance (damage calc on apply aura)
case 31801:
{
@ -5640,7 +5667,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu
if (procSpell->Effect[i] == SPELL_EFFECT_ENERGIZE)
{
int32 mana = procSpell->EffectBasePoints[i];
CastCustomSpell(this, 54986, 0, &mana, 0, true, castItem, triggeredByAura);
CastCustomSpell(this, 54986, NULL, &mana, NULL, true, castItem, triggeredByAura);
break;
}
return true;
@ -6870,7 +6897,7 @@ bool Unit::HandleOverrideClassScriptAuraProc(Unit *pVictim, uint32 damage, Aura
return false;
int32 cost = procSpell->manaCost + procSpell->ManaCostPercentage * GetCreateMana() / 100;
int32 basepoints0 = cost * triggeredByAura->GetModifier()->m_amount/100;
CastCustomSpell(this, 47762, &basepoints0, 0, 0, true, 0, triggeredByAura);
CastCustomSpell(this, 47762, &basepoints0, NULL, NULL, true, NULL, triggeredByAura);
return true;
}
}
@ -10763,6 +10790,7 @@ void Unit::ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag
DealSpellDamage(&damageInfo, true);
break;
}
case SPELL_AURA_MOD_DAMAGE_PERCENT_TAKEN:
case SPELL_AURA_MANA_SHIELD:
case SPELL_AURA_OBS_MOD_MANA:
case SPELL_AURA_DUMMY: