Created
September 2, 2011 21:00
-
-
Save cesg/1189903 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum eQuest | |
{ | |
q10866 = 10866 | |
}; | |
/*######################################################## | |
# Unlocking Zuluhed's Chains | |
##########################################################*/ | |
class spell_zuluhed : public SpellScriptLoader | |
{ | |
public: | |
spell_zuluhed() : SpellScriptLoader("spell_Unlocking_Zuluhed") { } | |
class spell_zuluhed_sc : public SpellScript | |
{ | |
PrepareSpellScript(spell_zuluhed_sc); | |
void HandleEffectOpenLock(SpellEffIndex /*effIndex*/) | |
{ | |
if (Unit* caster = GetCaster()){ | |
if (caster->GetTypeId() == TYPEID_PLAYER) { | |
caster->ToPlayer()->CompleteQuest(q10866); | |
} | |
} | |
} | |
void Register() | |
{ | |
OnEffect += SpellEffectFn(spell_zuluhed_sc::HandleEffectOpenLock, EFFECT_0, SPELL_EFFECT_OPEN_LOCK); | |
} | |
}; | |
SpellScript *GetSpellScript() const | |
{ | |
return new spell_zuluhed_sc(); | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment