mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
AuraConvertRune, EffectActivateRune, dunno if it's correct way to do that...
This commit is contained in:
parent
afc4d91ed8
commit
0e0d721292
6 changed files with 60 additions and 4 deletions
|
|
@ -202,7 +202,7 @@ pEffect SpellEffects[TOTAL_SPELL_EFFECTS]=
|
|||
&Spell::EffectApplyAreaAura, //143 SPELL_EFFECT_APPLY_AREA_AURA_OWNER
|
||||
&Spell::EffectNULL, //144 SPELL_EFFECT_144 Spectral Blast
|
||||
&Spell::EffectNULL, //145 SPELL_EFFECT_145 Black Hole Effect
|
||||
&Spell::EffectUnused, //146 SPELL_EFFECT_146 unused
|
||||
&Spell::EffectActivateRune, //146 SPELL_EFFECT_ACTIVATE_RUNE
|
||||
&Spell::EffectQuestFail, //147 SPELL_EFFECT_QUEST_FAIL quest fail
|
||||
&Spell::EffectUnused, //148 SPELL_EFFECT_148 unused
|
||||
&Spell::EffectNULL, //149 SPELL_EFFECT_149 swoop
|
||||
|
|
@ -6282,3 +6282,22 @@ void Spell::EffectQuestFail(uint32 i)
|
|||
|
||||
((Player*)unitTarget)->FailQuest(m_spellInfo->EffectMiscValue[i]);
|
||||
}
|
||||
|
||||
void Spell::EffectActivateRune(uint32 i)
|
||||
{
|
||||
if(m_caster->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
Player *plr = (Player*)m_caster;
|
||||
|
||||
if(plr->getClass() != CLASS_DEATH_KNIGHT)
|
||||
return;
|
||||
|
||||
for(uint32 j = 0; j < MAX_RUNES; ++j)
|
||||
{
|
||||
if(plr->GetRuneCooldown(j) && plr->GetCurrentRune(j) == m_spellInfo->EffectMiscValue[i])
|
||||
{
|
||||
plr->SetRuneCooldown(j, 0));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue