aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/EasternKingdoms
diff options
context:
space:
mode:
authorjoschiwald <joschiwald@online.de>2012-05-28 04:27:51 +0200
committerjoschiwald <joschiwald@online.de>2012-05-28 04:27:51 +0200
commitcd7ab6f3a5e86e51d19621ce5ab5560cd7eb62bc (patch)
tree3e13fd8e4472a3dece8e6691df794f87bfe3e59d /src/server/scripts/EasternKingdoms
parentca07f30d0359bf5a6eecba8b9cc68702eca4071b (diff)
parent9c417ff931a98a2ba35b30e76f8967c7f841e868 (diff)
Merge branch 'master' of github.com:joschiwald/TrinityCore into spellscripts
Conflicts: src/server/game/Entities/Unit/Unit.cpp src/server/game/Spells/Auras/SpellAuraEffects.cpp src/server/game/Spells/Spell.cpp src/server/game/Spells/SpellEffects.cpp src/server/scripts/Spells/spell_paladin.cpp
Diffstat (limited to 'src/server/scripts/EasternKingdoms')
-rw-r--r--src/server/scripts/EasternKingdoms/BlackrockSpire/blackrock_spire.h39
-rw-r--r--src/server/scripts/EasternKingdoms/BlackrockSpire/boss_pyroguard_emberseer.cpp39
-rw-r--r--src/server/scripts/EasternKingdoms/BlackrockSpire/instance_blackrock_spire.cpp77
-rw-r--r--src/server/scripts/EasternKingdoms/undercity.cpp6
4 files changed, 152 insertions, 9 deletions
diff --git a/src/server/scripts/EasternKingdoms/BlackrockSpire/blackrock_spire.h b/src/server/scripts/EasternKingdoms/BlackrockSpire/blackrock_spire.h
index e51c6b9130d..0af2af948d3 100644
--- a/src/server/scripts/EasternKingdoms/BlackrockSpire/blackrock_spire.h
+++ b/src/server/scripts/EasternKingdoms/BlackrockSpire/blackrock_spire.h
@@ -33,7 +33,8 @@ enum Data
DATA_WARCHIEF_REND_BLACKHAND,
DATA_GYTH,
DATA_THE_BEAST,
- DATA_GENERAL_DRAKKISATH
+ DATA_GENERAL_DRAKKISATH,
+ DATA_DRAGONSPIRE_ROOM,
};
enum Npc
{
@@ -51,17 +52,51 @@ enum Npc
NPC_GYTH = 10339,
NPC_THE_BEAST = 10430,
NPC_GENERAL_DRAKKISATH = 10363,
+ NPC_BLACKHAND_DREADWEAVER = 9817,
+ NPC_BLACKHAND_SUMMONER = 9818,
+ NPC_BLACKHAND_VETERAN = 9819,
};
enum AdditionalData
{
SPELL_SUMMON_ROOKERY_WHELP = 15745,
MAX_ENCOUNTER = 14,
+ MAX_DRAGONSPIRE_HALL_RUNES = 7,
+ EVENT_PYROGUARD_EMBERSEER = 4884,
+ AREATRIGGER_ENTER_UBRS = 2046,
+ AREATRIGGER_STADIUM = 2026,
};
enum GameObjects
{
- GO_WHELP_SPAWNER = 175622, //trap spawned by go id 175124
+ GO_WHELP_SPAWNER = 175622, // trap spawned by go id 175124
+
+ // Doors
+ GO_EMBERSEER_IN = 175244, // First door to Pyroguard Emberseer
+ GO_DOORS = 175705, // Second door to Pyroguard Emberseer
+ GO_EMBERSEER_OUT = 175153, // Door after Pyroguard Emberseer event
+ GO_GYTH_ENTRY_DOOR = 164726,
+ GO_GYTH_COMBAT_DOOR = 175185,
+ GO_GYTH_EXIT_DOOR = 175186,
+ GO_DRAKKISATH_DOOR_1 = 175946,
+ GO_DRAKKISATH_DOOR_2 = 175947,
+
+ // Runes
+ GO_ROOM_1_RUNE = 175197,
+ GO_ROOM_2_RUNE = 175199,
+ GO_ROOM_3_RUNE = 175195,
+ GO_ROOM_4_RUNE = 175200,
+ GO_ROOM_5_RUNE = 175198,
+ GO_ROOM_6_RUNE = 175196,
+ GO_ROOM_7_RUNE = 175194,
+
+ GO_EMBERSEER_RUNE_1 = 175266,
+ GO_EMBERSEER_RUNE_2 = 175267,
+ GO_EMBERSEER_RUNE_3 = 175268,
+ GO_EMBERSEER_RUNE_4 = 175269,
+ GO_EMBERSEER_RUNE_5 = 175270,
+ GO_EMBERSEER_RUNE_6 = 175271,
+ GO_EMBERSEER_RUNE_7 = 175272,
};
#endif
diff --git a/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_pyroguard_emberseer.cpp b/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_pyroguard_emberseer.cpp
index 411b800cd03..0279f3e2834 100644
--- a/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_pyroguard_emberseer.cpp
+++ b/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_pyroguard_emberseer.cpp
@@ -20,11 +20,24 @@
#include "ScriptedCreature.h"
#include "blackrock_spire.h"
+enum Text
+{
+ EMOTE_ONE_STACK = 0,
+ EMOTE_TEN_STACK = 1,
+ EMOTE_FREE_OF_BONDS = 2,
+ YELL_FREE_OF_BONDS = 3,
+};
+
enum Spells
{
- SPELL_FIRENOVA = 23462,
- SPELL_FLAMEBUFFET = 23341,
- SPELL_PYROBLAST = 17274,
+ SPELL_ENCAGED_EMBERSEER = 15282, // Self on spawn
+ SPELL_FIRE_SHIELD_TRIGGER = 13377, // Self on spawn missing from 335 dbc
+ SPELL_FREEZE_ANIM = 16245, // Self on event start
+ SPELL_EMBERSEER_GROWING = 16048, // Self on event start
+ SPELL_EMBERSEER_FULL_STRENGTH = 16047, // Emberseer Full Strength
+ SPELL_FIRENOVA = 23462, // Combat
+ SPELL_FLAMEBUFFET = 23341, // Combat
+ SPELL_PYROBLAST = 17274, // Combat
};
enum Events
@@ -51,6 +64,12 @@ public:
void Reset()
{
+ if(instance->GetBossState(DATA_PYROGAURD_EMBERSEER) == IN_PROGRESS)
+ OpenDoors(false);
+ instance->SetBossState(DATA_PYROGAURD_EMBERSEER,NOT_STARTED);
+ // respawn any dead Blackhand Incarcerators
+ DoCast(me, SPELL_ENCAGED_EMBERSEER);
+ //DoCast(me, SPELL_FIRE_SHIELD_TRIGGER);
_Reset();
}
@@ -64,12 +83,26 @@ public:
void JustDied(Unit* /*killer*/)
{
+ instance->SetBossState(DATA_PYROGAURD_EMBERSEER,DONE);
+ OpenDoors(true);
_JustDied();
}
+ void OpenDoors(bool Boss_Killed)
+ {
+ if (GameObject* door1 = me->GetMap()->GetGameObject(instance->GetData64(GO_EMBERSEER_IN)))
+ door1->SetGoState(GO_STATE_ACTIVE);
+ if (GameObject* door2 = me->GetMap()->GetGameObject(instance->GetData64(GO_DOORS)))
+ door2->SetGoState(GO_STATE_ACTIVE);
+ if (Boss_Killed)
+ if (GameObject* door3 = me->GetMap()->GetGameObject(instance->GetData64(GO_EMBERSEER_OUT)))
+ door3->SetGoState(GO_STATE_ACTIVE);
+ }
+
void UpdateAI(uint32 const diff)
{
if (!UpdateVictim())
+
return;
events.Update(diff);
diff --git a/src/server/scripts/EasternKingdoms/BlackrockSpire/instance_blackrock_spire.cpp b/src/server/scripts/EasternKingdoms/BlackrockSpire/instance_blackrock_spire.cpp
index ff97984fa09..fdb73fe1196 100644
--- a/src/server/scripts/EasternKingdoms/BlackrockSpire/instance_blackrock_spire.cpp
+++ b/src/server/scripts/EasternKingdoms/BlackrockSpire/instance_blackrock_spire.cpp
@@ -49,6 +49,12 @@ public:
uint64 Gyth;
uint64 TheBeast;
uint64 GeneralDrakkisath;
+ uint64 go_emberseerin;
+ uint64 go_doors;
+ uint64 go_emberseerout;
+ uint64 go_roomrunes[MAX_DRAGONSPIRE_HALL_RUNES];
+ uint8 Runemaxprotectors[MAX_DRAGONSPIRE_HALL_RUNES];
+ uint8 Runeprotectorsdead[MAX_DRAGONSPIRE_HALL_RUNES];
void Initialize()
{
@@ -67,6 +73,9 @@ public:
Gyth = 0;
TheBeast = 0;
GeneralDrakkisath = 0;
+ go_emberseerin = 0;
+ go_doors = 0;
+ go_emberseerout = 0;
}
bool IsEncounterInProgress() const
@@ -125,7 +134,11 @@ public:
case NPC_GENERAL_DRAKKISATH:
GeneralDrakkisath = creature->GetGUID();
break;
- }
+ case NPC_BLACKHAND_DREADWEAVER:
+ case NPC_BLACKHAND_SUMMONER:
+ case NPC_BLACKHAND_VETERAN:
+ break;
+ }
}
void OnGameObjectCreate(GameObject* go)
@@ -135,6 +148,36 @@ public:
case GO_WHELP_SPAWNER:
go->CastSpell(NULL, SPELL_SUMMON_ROOKERY_WHELP);
break;
+ case GO_EMBERSEER_IN:
+ go_emberseerin = go->GetGUID();
+ break;
+ case GO_DOORS:
+ go_doors = go->GetGUID();
+ break;
+ case GO_EMBERSEER_OUT:
+ go_emberseerout = go->GetGUID();
+ break;
+ case GO_ROOM_1_RUNE:
+ go_roomrunes[0] = go->GetGUID();
+ break;
+ case GO_ROOM_2_RUNE:
+ go_roomrunes[1] = go->GetGUID();
+ break;
+ case GO_ROOM_3_RUNE:
+ go_roomrunes[2] = go->GetGUID();
+ break;
+ case GO_ROOM_4_RUNE:
+ go_roomrunes[3] = go->GetGUID();
+ break;
+ case GO_ROOM_5_RUNE:
+ go_roomrunes[4] = go->GetGUID();
+ break;
+ case GO_ROOM_6_RUNE:
+ go_roomrunes[5] = go->GetGUID();
+ break;
+ case GO_ROOM_7_RUNE:
+ go_roomrunes[6] = go->GetGUID();
+ break;
}
}
@@ -167,6 +210,18 @@ public:
return true;
}
+ void ProcessEvent(WorldObject* /*gameObject*/, uint32 eventId)
+ {
+ switch (eventId)
+ {
+ case EVENT_PYROGUARD_EMBERSEER:
+ SetBossState(DATA_PYROGAURD_EMBERSEER,IN_PROGRESS);
+ break;
+ default:
+ break;
+ }
+ }
+
uint64 GetData64(uint32 type)
{
switch (type)
@@ -199,6 +254,26 @@ public:
return TheBeast;
case DATA_GENERAL_DRAKKISATH:
return GeneralDrakkisath;
+ case GO_EMBERSEER_IN:
+ return go_emberseerin;
+ case GO_DOORS:
+ return go_doors;
+ case GO_EMBERSEER_OUT:
+ return go_emberseerout;
+ case GO_ROOM_1_RUNE:
+ return go_roomrunes[0];
+ case GO_ROOM_2_RUNE:
+ return go_roomrunes[1];
+ case GO_ROOM_3_RUNE:
+ return go_roomrunes[2];
+ case GO_ROOM_4_RUNE:
+ return go_roomrunes[3];
+ case GO_ROOM_5_RUNE:
+ return go_roomrunes[4];
+ case GO_ROOM_6_RUNE:
+ return go_roomrunes[5];
+ case GO_ROOM_7_RUNE:
+ return go_roomrunes[6];
}
return 0;
diff --git a/src/server/scripts/EasternKingdoms/undercity.cpp b/src/server/scripts/EasternKingdoms/undercity.cpp
index d5896812007..a9b627ded34 100644
--- a/src/server/scripts/EasternKingdoms/undercity.cpp
+++ b/src/server/scripts/EasternKingdoms/undercity.cpp
@@ -184,7 +184,7 @@ public:
{
if (Unit* victim = me->getVictim())
{
- DoCast(me->getVictim(), SPELL_BLACK_ARROW);
+ DoCast(victim, SPELL_BLACK_ARROW);
BlackArrowTimer = 15000 + rand()%5000;
}
} else BlackArrowTimer -= diff;
@@ -193,7 +193,7 @@ public:
{
if (Unit* victim = me->getVictim())
{
- DoCast(me->getVictim(), SPELL_SHOT);
+ DoCast(victim, SPELL_SHOT);
ShotTimer = 8000 + rand()%2000;
}
} else ShotTimer -= diff;
@@ -202,7 +202,7 @@ public:
{
if (Unit* victim = me->getVictim())
{
- DoCast(me->getVictim(), SPELL_MULTI_SHOT);
+ DoCast(victim, SPELL_MULTI_SHOT);
MultiShotTimer = 10000 + rand()%3000;
}
} else MultiShotTimer -= diff;