Advertisement
Guest User

Untitled

a guest
Jun 19th, 2018
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. void SpellHit(Unit* caster, SpellInfo const* spell) override
  2. {
  3. if (spell->Id == 227993)
  4. {
  5. if (SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(227992))
  6. {
  7. float damage = spellInfo->GetEffect(EFFECT_0, GetCaster()->GetSpawnMode())->CalcValue();
  8. float healthPct = caster->GetHealthPct() > 5.0f ? caster->GetHealthPct() : 5.0f;
  9. CalculatePct(damage, healthPct);
  10. me->CastCustomSpell(caster, 227992, &damage, 0, 0, true);
  11. }
  12. }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement