aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTartalo <none@none>2010-06-28 22:45:23 +0200
committerTartalo <none@none>2010-06-28 22:45:23 +0200
commit95aadc40371a4047bbf9c0ce419562a6aae6e013 (patch)
tree398cc63b2722a938d1bd59b4d26cd2c208391bbe
parent9bedc08b71427718b2dc3d6184b25b4caf996d2b (diff)
Violet Hold: More work on crystal activation thing.
Process the event that's throw by the activation spell --HG-- branch : trunk
-rw-r--r--src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp
index aa06cd4e2a8..b5963ed5f61 100644
--- a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp
+++ b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp
@@ -61,6 +61,11 @@ enum CrystalSpells
SPELL_ARCANE_LIGHTNING = 57912
};
+enum Events
+{
+ EVENT_ACTIVATE_CRYSTAL = 20001
+};
+
const Position PortalLocation[] =
{
{1877.51, 850.104, 44.6599, 4.7822 }, // WP 1
@@ -757,7 +762,6 @@ struct instance_violet_hold : public ScriptedInstance
{
// Kill all mobs registered with SetData64(ADD_TRASH_MOB)
// TODO: All visual, spells etc
- bCrystalActivated = true;
for (std::set<uint64>::const_iterator itr = trashMobs.begin(); itr != trashMobs.end(); ++itr)
{
Creature* pCreature = instance->GetCreature(*itr);
@@ -765,6 +769,17 @@ struct instance_violet_hold : public ScriptedInstance
pCreature->CastSpell(pCreature,SPELL_ARCANE_LIGHTNING,true); // Who should cast the spell?
}
}
+
+ void ProcessEvent(GameObject* pGO, uint32 uiEventId)
+ {
+ switch(uiEventId)
+ {
+ case EVENT_ACTIVATE_CRYSTAL:
+ bCrystalActivated = true; // Activation by player's will throw event signal
+ ActivateCrystal();
+ break;
+ }
+}
};
InstanceData* GetInstanceData_instance_violet_hold(Map* pMap)