Advertisement
Guest User

Untitled

a guest
Jul 18th, 2014
236
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. // 2094 - blind
  2. class spell_rog_blind : public SpellScriptLoader
  3. {
  4. public:
  5. spell_rog_blind() : SpellScriptLoader("spell_rog_blind") { }
  6.  
  7. class spell_rog_blind_SpellScript : public SpellScript
  8. {
  9. PrepareSpellScript(spell_rog_blind_SpellScript);
  10.  
  11. void HandleOnHit()
  12. {
  13. if (Unit* target = GetHitUnit())
  14. {
  15. if (target->HasAuraType(SPELL_AURA_MOD_STEALTH))
  16. target->RemoveAurasByType(SPELL_AURA_MOD_STEALTH);
  17. }
  18. }
  19.  
  20. void Register()
  21. {
  22. OnHit += SpellHitFn(spell_rog_blind_SpellScript::HandleOnHit);
  23. }
  24.  
  25. };
  26.  
  27. SpellScript* GetSpellScript() const
  28. {
  29. return new spell_rog_blind_SpellScript();
  30. }
  31. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement