Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- From d219bcc9d223b91575bfde31768f70a9189eb66b Mon Sep 17 00:00:00 2001
- From: unknown <cristi@cristis-PC.(none)>
- Date: Wed, 18 Jul 2012 21:27:24 +0300
- Subject: [PATCH] Fix quest Petrified Delicacies
- ---
- src/server/scripts/Maelstrom/deepholm.cpp | 45 +++++++++++++++++++++++++++++
- 1 file changed, 45 insertions(+)
- diff --git a/src/server/scripts/Maelstrom/deepholm.cpp b/src/server/scripts/Maelstrom/deepholm.cpp
- index d169461..61918b2 100644
- --- a/src/server/scripts/Maelstrom/deepholm.cpp
- +++ b/src/server/scripts/Maelstrom/deepholm.cpp
- @@ -285,6 +285,50 @@ class npc_violent_gale_credit_bunny : public CreatureScript
- }
- };
- +/*###
- +## Support for quest Petrified Delicacies - 26507
- +######*/
- +
- +enum ePetrifiedDelicaciesEntries
- +{
- + QUEST_PETRIFIED_DELICACIES = 26507,
- + SPELL_PETRIFIED_BAT = 80952,
- +};
- +
- +class npc_petrified_stone_bat : public CreatureScript
- +{
- + public:
- + npc_petrified_stone_bat() : CreatureScript("npc_petrified_stone_bat") { }
- +
- + bool OnGossipHello(Player* player, Creature* creature)
- + {
- + if(player->GetQuestStatus(QUEST_PETRIFIED_DELICACIES)==QUEST_STATUS_INCOMPLETE)
- + {
- + player->CastSpell(player,SPELL_PETRIFIED_BAT);
- + creature->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP);
- + creature->DespawnOrUnsummon(1000);
- + }
- + return true;
- + }
- +
- + struct npc_petrified_stone_batAI : public ScriptedAI
- + {
- + npc_petrified_stone_batAI(Creature* creature) : ScriptedAI(creature) { }
- +
- + void Reset()
- + {
- + me->SetFlag(UNIT_NPC_FLAGS,UNIT_NPC_FLAG_GOSSIP);
- + me->HandleEmoteCommand(65);
- + me->SetByteFlag(UNIT_FIELD_BYTES_1, 0, 7);
- + }
- + };
- +
- + CreatureAI* GetAI(Creature *creature) const
- + {
- + return new npc_petrified_stone_batAI(creature);
- + }
- +};
- +
- void AddSC_deepholm()
- {
- new npc_lodestone();
- @@ -292,4 +336,5 @@ void AddSC_deepholm()
- new npc_energized_geode();
- new npc_clues_gunship_down();
- new npc_violent_gale_credit_bunny();
- + new npc_petrified_stone_bat();
- }
- --
- 1.7.10.msysgit.1
Advertisement
Add Comment
Please, Sign In to add comment