aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBlaymoira <none@none>2008-12-14 20:08:10 +0100
committerBlaymoira <none@none>2008-12-14 20:08:10 +0100
commitb8b60792aae2f8d544d1c9290331ef8fab0c96de (patch)
tree1f0df04feec700262233c7a853f3cbcd56fb588d /src
parent7097ffe6dc326362a4d51b4c4453d6ca7ba928c8 (diff)
*Implemented Scalding Water in Lurker script
*Changed c->GetInstanceData in eredar twins script *33504 not affected by any healing bonus patch provided by eumario --HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp20
-rw-r--r--src/game/Unit.cpp2
3 files changed, 39 insertions, 4 deletions
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
index 8be276954c0..a4bd3b99a2a 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
@@ -17,7 +17,7 @@
/* ScriptData
SDName: boss_the_lurker_below
SD%Complete: 80
-SDComment: Scalding Water other things.
+SDComment: Other things.
SDCategory: The Lurker Below
EndScriptData */
@@ -35,6 +35,7 @@ EndScriptData */
#define SPELL_WATERBOLT 37138
#define SPELL_SUBMERGE 37550
#define SPELL_EMERGE 20568
+#define SPELL_SCALDINGWATER 37284
#define EMOTE_SPOUT "takes a deep breath."
@@ -237,6 +238,24 @@ struct TRINITY_DLL_DECL boss_the_lurker_belowAI : public Scripted_NoMovementAI
if (!m_creature->SelectHostilTarget() /*|| !m_creature->getVictim()*/ )//rotate resets target
return;
+ //Check if players in water and if in water cast spell
+ Map *map = m_creature->GetMap();
+ if (map->IsDungeon() && pInstance->GetData(DATA_THELURKERBELOWEVENT) == IN_PROGRESS)
+ {
+ Map::PlayerList const &PlayerList = map->GetPlayers();
+
+ if (PlayerList.isEmpty())
+ return;
+
+ for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
+ {
+ if (i->getSource()->isAlive() && i->getSource()->IsInWater() && !i->getSource()->HasAura(SPELL_SCALDINGWATER, 0))
+ i->getSource()->CastSpell(i->getSource(), SPELL_SCALDINGWATER, true);
+ else if(!i->getSource()->IsInWater())
+ i->getSource()->RemoveAurasDueToSpell(SPELL_SCALDINGWATER);
+ }
+ }
+
Rotate(diff);//always check rotate things
if(!Submerged)
{
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
index 875da760ca1..2f45ffe27cf 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
@@ -1,3 +1,19 @@
+/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+* This program is free software; you can redistribute it and/or modify
+* it under the terms of the GNU General Public License as published by
+* the Free Software Foundation; either version 2 of the License, or
+* (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+*/
+
/* ScriptData
SDName: Boss_Eredar_Twins
SD%Complete: 100
@@ -80,7 +96,7 @@ struct TRINITY_DLL_DECL boss_sacrolashAI : public ScriptedAI
{
boss_sacrolashAI(Creature *c) : ScriptedAI(c)
{
- pInstance = (c->GetInstanceData()) ? ((ScriptedInstance*)c->GetInstanceData()) : NULL;
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
Reset();
}
@@ -345,7 +361,7 @@ struct TRINITY_DLL_DECL boss_alythessAI : public Scripted_NoMovementAI
{
boss_alythessAI(Creature *c) : Scripted_NoMovementAI(c)
{
- pInstance = (c->GetInstanceData()) ? ((ScriptedInstance*)c->GetInstanceData()) : NULL;
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
Reset();
IntroStepCounter = 10;
}
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index c01412ce5c7..414c0afa836 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -9060,7 +9060,7 @@ uint32 Unit::SpellHealingBonus(SpellEntry const *spellProto, uint32 healamount,
if (spellProto->Id == 15290 || spellProto->Id == 39373 ||
spellProto->Id == 33778 || spellProto->Id == 379 ||
spellProto->Id == 38395 || spellProto->Id == 40972 ||
- spellProto->Id == 22845)
+ spellProto->Id == 22845 || spellProto->Id == 33504)
return healamount;
int32 AdvertisedBenefit = SpellBaseHealingBonus(GetSpellSchoolMask(spellProto));