aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorVincent-Michael <none@trinitycore.contrib>2011-06-23 21:24:20 +0200
committerLopin <davca.hr@seznam.cz>2011-06-23 21:24:20 +0200
commit36d6ca471115b101ffb62d7cd4b994ba3b6347fd (patch)
tree94e59c1c304cb9a511183cafeab94d01b0b96886 /src
parent327c5d65bd889b0e44f7630c5d2226b83b63c97a (diff)
Scripts/Ulduar: Fixed Sentinel Blast affecting whole instance and small typo in a script
Diffstat (limited to 'src')
-rw-r--r--src/server/scripts/Northrend/Ulduar/ulduar/boss_auriaya.cpp41
1 files changed, 35 insertions, 6 deletions
diff --git a/src/server/scripts/Northrend/Ulduar/ulduar/boss_auriaya.cpp b/src/server/scripts/Northrend/Ulduar/ulduar/boss_auriaya.cpp
index ee0dd85519c..051fd1ad5f7 100644
--- a/src/server/scripts/Northrend/Ulduar/ulduar/boss_auriaya.cpp
+++ b/src/server/scripts/Northrend/Ulduar/ulduar/boss_auriaya.cpp
@@ -113,7 +113,7 @@ class boss_auriaya : public CreatureScript
{
_Reset();
DefenderGUID = 0;
- defenderLifes = 8;
+ defenderLives = 8;
crazyCatLady = true;
nineLives = false;
}
@@ -165,8 +165,8 @@ class boss_auriaya : public CreatureScript
SetData(DATA_CRAZY_CAT_LADY, 0);
break;
case ACTION_RESPAWN_DEFENDER:
- --defenderLifes;
- if (!defenderLifes)
+ --defenderLives;
+ if (!defenderLives)
{
SetData(DATA_NINE_LIVES, 1);
break;
@@ -247,8 +247,8 @@ class boss_auriaya : public CreatureScript
if (Creature* Defender = ObjectAccessor::GetCreature(*me, DefenderGUID))
{
Defender->Respawn();
- if (defenderLifes)
- Defender->SetAuraStack(SPELL_FERAL_ESSENCE, Defender, defenderLifes);
+ if (defenderLives)
+ Defender->SetAuraStack(SPELL_FERAL_ESSENCE, Defender, defenderLives);
Defender->SetInCombatWithZone();
if (!Defender->isInCombat())
Defender->AI()->AttackStart(me->getVictim());
@@ -273,7 +273,7 @@ class boss_auriaya : public CreatureScript
private:
uint64 DefenderGUID;
- uint8 defenderLifes;
+ uint8 defenderLives;
bool crazyCatLady;
bool nineLives;
};
@@ -507,6 +507,34 @@ class spell_auriaya_strenght_of_the_pack : public SpellScriptLoader
}
};
+class spell_auriaya_sentinel_blast : public SpellScriptLoader
+{
+ public:
+ spell_auriaya_sentinel_blast() : SpellScriptLoader("spell_auriaya_sentinel_blast") { }
+
+ class spell_auriaya_sentinel_blast_SpellScript : public SpellScript
+ {
+ PrepareSpellScript(spell_auriaya_sentinel_blast_SpellScript);
+
+ void FilterTargets(std::list<Unit*>& unitList)
+ {
+ unitList.remove_if(PlayerOrPetCheck());
+ }
+
+ void Register()
+ {
+ OnUnitTargetSelect += SpellUnitTargetFn(spell_auriaya_sentinel_blast_SpellScript::FilterTargets, EFFECT_0, TARGET_UNIT_AREA_ENEMY_SRC);
+ OnUnitTargetSelect += SpellUnitTargetFn(spell_auriaya_sentinel_blast_SpellScript::FilterTargets, EFFECT_1, TARGET_UNIT_AREA_ENEMY_SRC);
+ }
+ };
+
+ SpellScript* GetSpellScript() const
+ {
+ return new spell_auriaya_sentinel_blast_SpellScript();
+ }
+};
+
+
class achievement_nine_lives : public AchievementCriteriaScript
{
public:
@@ -548,6 +576,7 @@ void AddSC_boss_auriaya()
new npc_feral_defender();
new npc_sanctum_sentry();
new spell_auriaya_strenght_of_the_pack();
+ new spell_auriaya_sentinel_blast();
new achievement_nine_lives();
new achievement_crazy_cat_lady();
}