aboutsummaryrefslogtreecommitdiff
path: root/src/scripts/northrend/dalaran.cpp
diff options
context:
space:
mode:
authorBrian <runningnak3d@gmail.com>2010-04-01 12:56:52 -0600
committerBrian <runningnak3d@gmail.com>2010-04-01 12:56:52 -0600
commit8ddcc2985c002b4158509ff6cca23e58bd6322d2 (patch)
tree87bc1d26ea631955267d32d9f8dca448389750aa /src/scripts/northrend/dalaran.cpp
parent0b38c48ec9cbed0702d9fa3c3708b6b85db36382 (diff)
parentf78b766705104444f695a265bce712d59a22cbb3 (diff)
* Merge
--HG-- branch : trunk
Diffstat (limited to 'src/scripts/northrend/dalaran.cpp')
-rw-r--r--src/scripts/northrend/dalaran.cpp38
1 files changed, 38 insertions, 0 deletions
diff --git a/src/scripts/northrend/dalaran.cpp b/src/scripts/northrend/dalaran.cpp
index 903118444ae..61dc6abc7cb 100644
--- a/src/scripts/northrend/dalaran.cpp
+++ b/src/scripts/northrend/dalaran.cpp
@@ -105,6 +105,38 @@ CreatureAI* GetAI_npc_mageguard_dalaran(Creature* pCreature)
return new npc_mageguard_dalaranAI(pCreature);
}
+/*######
+## npc_hira_snowdawn
+######*/
+
+#define GOSSIP_TEXT_TRAIN_HIRA "I seek training to ride a steed."
+
+bool GossipHello_npc_hira_snowdawn(Player* pPlayer, Creature* pCreature)
+{
+ if (!pCreature->isVendor() || !pCreature->isTrainer())
+ return false;
+
+ pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_VENDOR, GOSSIP_TEXT_TRAIN_HIRA, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRAIN);
+
+ if (pPlayer->getLevel() == 80)
+ pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_VENDOR, GOSSIP_TEXT_BROWSE_GOODS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRADE);
+
+ pPlayer->SEND_GOSSIP_MENU(pPlayer->GetGossipTextId(pCreature), pCreature->GetGUID());
+
+ return true;
+}
+
+bool GossipSelect_npc_hira_snowdawn(Player* pPlayer, Creature* pCreature, uint32 uiSender, uint32 uiAction)
+{
+ if (uiAction == GOSSIP_ACTION_TRAIN)
+ pPlayer->SEND_TRAINERLIST(pCreature->GetGUID());
+
+ if (uiAction == GOSSIP_ACTION_TRADE)
+ pPlayer->SEND_VENDORLIST(pCreature->GetGUID());
+
+ return true;
+}
+
void AddSC_dalaran()
{
Script *newscript;
@@ -113,4 +145,10 @@ void AddSC_dalaran()
newscript->Name = "npc_mageguard_dalaran";
newscript->GetAI = &GetAI_npc_mageguard_dalaran;
newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "npc_hira_snowdawn";
+ newscript->pGossipHello = &GossipHello_npc_hira_snowdawn;
+ newscript->pGossipSelect = &GossipSelect_npc_hira_snowdawn;
+ newscript->RegisterSelf();
}