diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/bindings/scripts/scripts/northrend/zuldrak.cpp | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/src/bindings/scripts/scripts/northrend/zuldrak.cpp b/src/bindings/scripts/scripts/northrend/zuldrak.cpp index dfeec6b6e3d..e6ee642e787 100644 --- a/src/bindings/scripts/scripts/northrend/zuldrak.cpp +++ b/src/bindings/scripts/scripts/northrend/zuldrak.cpp @@ -168,6 +168,44 @@ CreatureAI* GetAI_npc_captured_rageclaw(Creature* pCreature) return new npc_captured_rageclawAI (pCreature); } +/*#### +## npc_gymer +####*/ + +#define GOSSIP_ITEM_G "I'm ready, Gymer. Let's go!" + +enum +{ + QUEST_STORM_KING_VENGEANCE = 12919, + SPELL_GYMER = 55568 +}; + + bool GossipHello_npc_gymer(Player *pPlayer, Creature *pCreature) + { + if (pCreature->isQuestGiver()) + pPlayer->PrepareQuestMenu(pCreature->GetGUID()); + pPlayer->SEND_GOSSIP_MENU(pCreature->GetNpcTextId(), pCreature->GetGUID()); + + if (pPlayer->GetQuestStatus(QUEST_STORM_KING_VENGEANCE) == QUEST_STATUS_INCOMPLETE) + { + pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_G, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1); + pPlayer->SEND_GOSSIP_MENU(13640, pCreature->GetGUID()); + } + + return true; + } + + bool GossipSelect_npc_gymer(Player *pPlayer, Creature *pCreature, uint32 uiSender, uint32 uiAction) + { + if (uiAction == GOSSIP_ACTION_INFO_DEF+1) + { + pPlayer->CLOSE_GOSSIP_MENU(); + pPlayer->CastSpell(pPlayer, SPELL_GYMER, true); + } + + return true; + } + void AddSC_zuldrak() { Script *newscript; @@ -181,4 +219,10 @@ void AddSC_zuldrak() newscript->Name="npc_captured_rageclaw"; newscript->GetAI = &GetAI_npc_captured_rageclaw; newscript->RegisterSelf(); + + newscript = new Script; + newscript->Name = "npc_gymer"; + newscript->pGossipHello = &GossipHello_npc_gymer; + newscript->pGossipSelect = &GossipSelect_npc_gymer; + newscript->RegisterSelf(); } |