* Fix: correct dancing rune blade damage output - patch by tbaart

Fixes issue #1354
Fixes issue #1479

--HG--
branch : trunk
This commit is contained in:
click
2010-04-12 11:34:57 +02:00
parent 8bbbf0bc86
commit ca661f7acf
2 changed files with 11 additions and 8 deletions

View File

@@ -5531,8 +5531,9 @@ void AuraEffect::HandleAuraDummy(AuraApplication const * aurApp, uint8 mode, boo
target->ToPlayer()->RemoveAmmo(); // not use ammo and not allow use
break;
case 49028:
GetBase()->SetDuration(GetBase()->GetDuration() + (caster->GetPower(POWER_RUNIC_POWER) * 10));
caster->SetPower(POWER_RUNIC_POWER, 0);
if (caster)
if (AuraEffect *aurEff = caster->GetAuraEffect(63330, 0)) // glyph of Dancing Rune Weapon
GetBase()->SetDuration(GetBase()->GetDuration() + aurEff->GetAmount());
break;
case 62061: // Festive Holiday Mount
if (target->HasAuraType(SPELL_AURA_MOUNTED))

View File

@@ -7192,20 +7192,22 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger
if (dummySpell->Id == 49028)
{
// 1 dummy aura for dismiss rune blade
if (effIndex != 2)
if (effIndex != 1)
return false;
uint64 PetGUID = NULL;
Unit* pPet = NULL;
for (ControlList::const_iterator itr = m_Controlled.begin(); itr != m_Controlled.end(); ++itr) //Find Rune Weapon
if ((*itr)->GetEntry() == 27893)
{
PetGUID = (*itr)->GetGUID();
pPet = (*itr);
break;
}
if (PetGUID && pVictim && damage && procSpell)
if (pPet && pPet->getVictim() && damage && procSpell)
{
int32 procDmg = damage / 2;
CastCustomSpell(pVictim, procSpell->Id, &procDmg, NULL, NULL, true, NULL, NULL, PetGUID);
uint32 procDmg = damage / 2;
pPet->SendSpellNonMeleeDamageLog(pPet->getVictim(),procSpell->Id,procDmg,GetSpellSchoolMask(procSpell),0,0,false,0,false);
pPet->DealDamage(pPet->getVictim(),procDmg,NULL,SPELL_DIRECT_DAMAGE,GetSpellSchoolMask(procSpell),procSpell,true);
break;
}
else