Scripts: Reorder file names in Commands/CMakeList file and cosmetic changes in all scripts
This commit is contained in:
+21
-21
@@ -107,7 +107,7 @@ public:
|
||||
|
||||
struct boss_fathomlord_karathressAI : public ScriptedAI
|
||||
{
|
||||
boss_fathomlord_karathressAI(Creature *c) : ScriptedAI(c)
|
||||
boss_fathomlord_karathressAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
Advisors[0] = 0;
|
||||
@@ -185,7 +185,7 @@ public:
|
||||
Advisors[2] = pInstance->GetData64(DATA_CARIBDIS);
|
||||
}
|
||||
|
||||
void StartEvent(Unit *who)
|
||||
void StartEvent(Unit* who)
|
||||
{
|
||||
if (!pInstance)
|
||||
return;
|
||||
@@ -225,7 +225,7 @@ public:
|
||||
//Only if not incombat check if the event is started
|
||||
if (!me->isInCombat() && pInstance && pInstance->GetData(DATA_KARATHRESSEVENT))
|
||||
{
|
||||
Unit *pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
Unit* pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
|
||||
if (pTarget)
|
||||
{
|
||||
@@ -249,7 +249,7 @@ public:
|
||||
if (CataclysmicBolt_Timer <= diff)
|
||||
{
|
||||
//select a random unit other than the main tank
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1);
|
||||
|
||||
//if there aren't other units, cast on the tank
|
||||
if (!pTarget)
|
||||
@@ -317,7 +317,7 @@ public:
|
||||
|
||||
struct boss_fathomguard_sharkkisAI : public ScriptedAI
|
||||
{
|
||||
boss_fathomguard_sharkkisAI(Creature *c) : ScriptedAI(c)
|
||||
boss_fathomguard_sharkkisAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -342,7 +342,7 @@ public:
|
||||
|
||||
pet = false;
|
||||
|
||||
Creature *Pet = Unit::GetCreature(*me, SummonedPet);
|
||||
Creature* Pet = Unit::GetCreature(*me, SummonedPet);
|
||||
if (Pet && Pet->isAlive())
|
||||
{
|
||||
Pet->DealDamage(Pet, Pet->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
|
||||
@@ -358,7 +358,7 @@ public:
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
Creature *Karathress = NULL;
|
||||
Creature* Karathress = NULL;
|
||||
Karathress = (Unit::GetCreature((*me), pInstance->GetData64(DATA_KARATHRESS)));
|
||||
|
||||
if (Karathress)
|
||||
@@ -381,7 +381,7 @@ public:
|
||||
//Only if not incombat check if the event is started
|
||||
if (!me->isInCombat() && pInstance && pInstance->GetData(DATA_KARATHRESSEVENT))
|
||||
{
|
||||
Unit *pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
Unit* pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
|
||||
if (pTarget)
|
||||
{
|
||||
@@ -418,7 +418,7 @@ public:
|
||||
if (TheBeastWithin_Timer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_THE_BEAST_WITHIN);
|
||||
Creature *Pet = Unit::GetCreature(*me, SummonedPet);
|
||||
Creature* Pet = Unit::GetCreature(*me, SummonedPet);
|
||||
if (Pet && Pet->isAlive())
|
||||
{
|
||||
Pet->CastSpell(Pet, SPELL_PET_ENRAGE, true);
|
||||
@@ -443,8 +443,8 @@ public:
|
||||
pet_id = CREATURE_FATHOM_SPOREBAT;
|
||||
}
|
||||
//DoCast(me, spell_id, true);
|
||||
Creature *Pet = DoSpawnCreature(pet_id, 0, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Creature* Pet = DoSpawnCreature(pet_id, 0, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (Pet && pTarget)
|
||||
{
|
||||
Pet->AI()->AttackStart(pTarget);
|
||||
@@ -471,7 +471,7 @@ public:
|
||||
|
||||
struct boss_fathomguard_tidalvessAI : public ScriptedAI
|
||||
{
|
||||
boss_fathomguard_tidalvessAI(Creature *c) : ScriptedAI(c)
|
||||
boss_fathomguard_tidalvessAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -498,7 +498,7 @@ public:
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
Creature *Karathress = NULL;
|
||||
Creature* Karathress = NULL;
|
||||
Karathress = (Unit::GetCreature((*me), pInstance->GetData64(DATA_KARATHRESS)));
|
||||
|
||||
if (Karathress)
|
||||
@@ -522,7 +522,7 @@ public:
|
||||
//Only if not incombat check if the event is started
|
||||
if (!me->isInCombat() && pInstance && pInstance->GetData(DATA_KARATHRESSEVENT))
|
||||
{
|
||||
Unit *pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
Unit* pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
|
||||
if (pTarget)
|
||||
{
|
||||
@@ -557,7 +557,7 @@ public:
|
||||
if (Spitfire_Timer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_SPITFIRE_TOTEM);
|
||||
Unit *SpitfireTotem = Unit::GetUnit(*me, CREATURE_SPITFIRE_TOTEM);
|
||||
Unit* SpitfireTotem = Unit::GetUnit(*me, CREATURE_SPITFIRE_TOTEM);
|
||||
if (SpitfireTotem)
|
||||
{
|
||||
CAST_CRE(SpitfireTotem)->AI()->AttackStart(me->getVictim());
|
||||
@@ -598,7 +598,7 @@ public:
|
||||
|
||||
struct boss_fathomguard_caribdisAI : public ScriptedAI
|
||||
{
|
||||
boss_fathomguard_caribdisAI(Creature *c) : ScriptedAI(c)
|
||||
boss_fathomguard_caribdisAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -625,7 +625,7 @@ public:
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
Creature *Karathress = NULL;
|
||||
Creature* Karathress = NULL;
|
||||
Karathress = (Unit::GetCreature((*me), pInstance->GetData64(DATA_KARATHRESS)));
|
||||
|
||||
if (Karathress)
|
||||
@@ -648,7 +648,7 @@ public:
|
||||
//Only if not incombat check if the event is started
|
||||
if (!me->isInCombat() && pInstance && pInstance->GetData(DATA_KARATHRESSEVENT))
|
||||
{
|
||||
Unit *pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
Unit* pTarget = Unit::GetUnit((*me), pInstance->GetData64(DATA_KARATHRESSEVENT_STARTER));
|
||||
|
||||
if (pTarget)
|
||||
{
|
||||
@@ -688,14 +688,14 @@ public:
|
||||
{
|
||||
//DoCast(me, SPELL_SUMMON_CYCLONE); // Doesn't work
|
||||
Cyclone_Timer = 30000+rand()%10000;
|
||||
Creature *Cyclone = me->SummonCreature(CREATURE_CYCLONE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), float(rand()%5), TEMPSUMMON_TIMED_DESPAWN, 15000);
|
||||
Creature* Cyclone = me->SummonCreature(CREATURE_CYCLONE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), float(rand()%5), TEMPSUMMON_TIMED_DESPAWN, 15000);
|
||||
if (Cyclone)
|
||||
{
|
||||
CAST_CRE(Cyclone)->SetFloatValue(OBJECT_FIELD_SCALE_X, 3.0f);
|
||||
Cyclone->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
Cyclone->setFaction(me->getFaction());
|
||||
Cyclone->CastSpell(Cyclone, SPELL_CYCLONE_CYCLONE, true);
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
{
|
||||
Cyclone->AI()->AttackStart(pTarget);
|
||||
@@ -707,7 +707,7 @@ public:
|
||||
if (Heal_Timer <= diff)
|
||||
{
|
||||
// It can be cast on any of the mobs
|
||||
Unit *pUnit = NULL;
|
||||
Unit* pUnit = NULL;
|
||||
|
||||
while (pUnit == NULL || !pUnit->isAlive())
|
||||
{
|
||||
|
||||
+4
-4
@@ -88,7 +88,7 @@ public:
|
||||
|
||||
struct boss_hydross_the_unstableAI : public ScriptedAI
|
||||
{
|
||||
boss_hydross_the_unstableAI(Creature *c) : ScriptedAI(c), Summons(me)
|
||||
boss_hydross_the_unstableAI(Creature* c) : ScriptedAI(c), Summons(me)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -202,7 +202,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void SummonedCreatureDespawn(Creature *summon)
|
||||
void SummonedCreatureDespawn(Creature* summon)
|
||||
{
|
||||
Summons.Despawn(summon);
|
||||
}
|
||||
@@ -262,7 +262,7 @@ public:
|
||||
//VileSludge_Timer
|
||||
if (VileSludge_Timer <= diff)
|
||||
{
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
DoCast(pTarget, SPELL_VILE_SLUDGE);
|
||||
|
||||
@@ -329,7 +329,7 @@ public:
|
||||
//WaterTomb_Timer
|
||||
if (WaterTomb_Timer <= diff)
|
||||
{
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true);
|
||||
if (pTarget)
|
||||
DoCast(pTarget, SPELL_WATER_TOMB);
|
||||
|
||||
|
||||
@@ -145,7 +145,7 @@ public:
|
||||
|
||||
struct boss_lady_vashjAI : public ScriptedAI
|
||||
{
|
||||
boss_lady_vashjAI (Creature *c) : ScriptedAI(c)
|
||||
boss_lady_vashjAI (Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
Intro = false;
|
||||
@@ -201,7 +201,7 @@ public:
|
||||
JustCreated = false;
|
||||
} else CanAttack = true;
|
||||
|
||||
Unit *remo;
|
||||
Unit* remo;
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
{
|
||||
remo = Unit::GetUnit(*me, ShieldGeneratorChannel[i]);
|
||||
@@ -270,7 +270,7 @@ public:
|
||||
AttackStart(who);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit *who)
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
{
|
||||
if (!Intro)
|
||||
{
|
||||
@@ -363,7 +363,7 @@ public:
|
||||
{
|
||||
//Static Charge
|
||||
//Used on random people (only 1 person at any given time) in Phases 1 and 3, it's a debuff doing 2775 to 3225 Nature damage to the target and everybody in about 5 yards around it, every 1 seconds for 30 seconds. It can be removed by Cloak of Shadows, Iceblock, Divine Shield, etc, but not by Cleanse or Dispel Magic.
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 200, true);
|
||||
|
||||
if (pTarget && !pTarget->HasAura(SPELL_STATIC_CHARGE_TRIGGER))
|
||||
@@ -404,7 +404,7 @@ public:
|
||||
me->GetMotionMaster()->Clear();
|
||||
DoTeleportTo(MIDDLE_X, MIDDLE_Y, MIDDLE_Z);
|
||||
|
||||
Creature *pCreature;
|
||||
Creature* pCreature;
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
{
|
||||
pCreature = me->SummonCreature(SHIED_GENERATOR_CHANNEL, ShieldGeneratorChannelPos[i][0], ShieldGeneratorChannelPos[i][1], ShieldGeneratorChannelPos[i][2], ShieldGeneratorChannelPos[i][3], TEMPSUMMON_CORPSE_DESPAWN, 0);
|
||||
@@ -420,12 +420,12 @@ public:
|
||||
//SummonSporebat_Timer
|
||||
if (SummonSporebat_Timer <= diff)
|
||||
{
|
||||
Creature *Sporebat = NULL;
|
||||
Creature* Sporebat = NULL;
|
||||
Sporebat = me->SummonCreature(TOXIC_SPOREBAT, SPOREBAT_X, SPOREBAT_Y, SPOREBAT_Z, SPOREBAT_O, TEMPSUMMON_CORPSE_DESPAWN, 0);
|
||||
|
||||
if (Sporebat)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
Sporebat->AI()->AttackStart(pTarget);
|
||||
@@ -450,7 +450,7 @@ public:
|
||||
if (Check_Timer <= diff)
|
||||
{
|
||||
bool InMeleeRange = false;
|
||||
Unit *pTarget;
|
||||
Unit* pTarget;
|
||||
std::list<HostileReference *> t_list = me->getThreatManager().getThreatList();
|
||||
for (std::list<HostileReference *>::const_iterator itr = t_list.begin(); itr!= t_list.end(); ++itr)
|
||||
{
|
||||
@@ -478,7 +478,7 @@ public:
|
||||
{
|
||||
//Forked Lightning
|
||||
//Used constantly in Phase 2, it shoots out completely randomly targeted bolts of lightning which hit everybody in a roughtly 60 degree cone in front of Vashj for 2313-2687 nature damage.
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
|
||||
if (!pTarget)
|
||||
@@ -519,7 +519,7 @@ public:
|
||||
CoilfangElite = me->SummonCreature(COILFANG_ELITE, CoilfangElitePos[pos][0], CoilfangElitePos[pos][1], CoilfangElitePos[pos][2], CoilfangElitePos[pos][3], TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
if (CoilfangElite)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
CoilfangElite->AI()->AttackStart(pTarget);
|
||||
@@ -537,7 +537,7 @@ public:
|
||||
CoilfangStrider = me->SummonCreature(COILFANG_STRIDER, CoilfangStriderPos[pos][0], CoilfangStriderPos[pos][1], CoilfangStriderPos[pos][2], CoilfangStriderPos[pos][3], TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
if (CoilfangStrider)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
CoilfangStrider->AI()->AttackStart(pTarget);
|
||||
@@ -587,7 +587,7 @@ public:
|
||||
|
||||
struct mob_enchanted_elementalAI : public ScriptedAI
|
||||
{
|
||||
mob_enchanted_elementalAI(Creature *c) : ScriptedAI(c)
|
||||
mob_enchanted_elementalAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -660,7 +660,7 @@ public:
|
||||
if (me->IsWithinDist3d(MIDDLE_X, MIDDLE_Y, MIDDLE_Z, 3))
|
||||
DoCast(me, SPELL_SURGE);
|
||||
}
|
||||
if (Creature *Vashj = Unit::GetCreature(*me, VashjGUID))
|
||||
if (Creature* Vashj = Unit::GetCreature(*me, VashjGUID))
|
||||
{
|
||||
if (!Vashj->isInCombat() || CAST_AI(boss_lady_vashj::boss_lady_vashjAI, Vashj->AI())->Phase != 2 || Vashj->isDead())
|
||||
{
|
||||
@@ -689,7 +689,7 @@ public:
|
||||
|
||||
struct mob_tainted_elementalAI : public ScriptedAI
|
||||
{
|
||||
mob_tainted_elementalAI(Creature *c) : ScriptedAI(c)
|
||||
mob_tainted_elementalAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -709,7 +709,7 @@ public:
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
Creature *Vashj = NULL;
|
||||
Creature* Vashj = NULL;
|
||||
Vashj = (Unit::GetCreature((*me), pInstance->GetData64(DATA_LADYVASHJ)));
|
||||
|
||||
if (Vashj)
|
||||
@@ -727,7 +727,7 @@ public:
|
||||
//PoisonBolt_Timer
|
||||
if (PoisonBolt_Timer <= diff)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
|
||||
if (pTarget && pTarget->IsWithinDistInMap(me, 30))
|
||||
@@ -764,7 +764,7 @@ public:
|
||||
|
||||
struct mob_toxic_sporebatAI : public ScriptedAI
|
||||
{
|
||||
mob_toxic_sporebatAI(Creature *c) : ScriptedAI(c)
|
||||
mob_toxic_sporebatAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
EnterEvadeMode();
|
||||
@@ -819,7 +819,7 @@ public:
|
||||
//toxic spores
|
||||
if (bolt_timer <= diff)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (pTarget)
|
||||
{
|
||||
@@ -840,7 +840,7 @@ public:
|
||||
if (pInstance)
|
||||
{
|
||||
//check if vashj is death
|
||||
Unit *Vashj = NULL;
|
||||
Unit* Vashj = NULL;
|
||||
Vashj = Unit::GetUnit((*me), pInstance->GetData64(DATA_LADYVASHJ));
|
||||
if (!Vashj || (Vashj && !Vashj->isAlive()) || (Vashj && CAST_AI(boss_lady_vashj::boss_lady_vashjAI, CAST_CRE(Vashj)->AI())->Phase != 3))
|
||||
{
|
||||
@@ -922,7 +922,7 @@ public:
|
||||
|
||||
struct mob_shield_generator_channelAI : public ScriptedAI
|
||||
{
|
||||
mob_shield_generator_channelAI(Creature *c) : ScriptedAI(c)
|
||||
mob_shield_generator_channelAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -950,7 +950,7 @@ public:
|
||||
|
||||
if (Check_Timer <= diff)
|
||||
{
|
||||
Unit *Vashj = NULL;
|
||||
Unit* Vashj = NULL;
|
||||
Vashj = Unit::GetUnit((*me), pInstance->GetData64(DATA_LADYVASHJ));
|
||||
|
||||
if (Vashj && Vashj->isAlive())
|
||||
@@ -984,7 +984,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
Creature *Vashj = NULL;
|
||||
Creature* Vashj = NULL;
|
||||
Vashj = (Unit::GetCreature((*pPlayer), pInstance->GetData64(DATA_LADYVASHJ)));
|
||||
if (Vashj && (CAST_AI(boss_lady_vashj::boss_lady_vashjAI, Vashj->AI())->Phase == 2))
|
||||
{
|
||||
@@ -1021,7 +1021,7 @@ public:
|
||||
}
|
||||
|
||||
//get and remove channel
|
||||
Unit *Channel = NULL;
|
||||
Unit* Channel = NULL;
|
||||
Channel = Unit::GetCreature(*Vashj, CAST_AI(boss_lady_vashj::boss_lady_vashjAI, Vashj->AI())->ShieldGeneratorChannel[channel_identifier]);
|
||||
if (Channel)
|
||||
{
|
||||
|
||||
+16
-16
@@ -79,7 +79,7 @@ public:
|
||||
|
||||
struct mob_inner_demonAI : public ScriptedAI
|
||||
{
|
||||
mob_inner_demonAI(Creature *c) : ScriptedAI(c)
|
||||
mob_inner_demonAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
victimGUID = 0;
|
||||
}
|
||||
@@ -101,7 +101,7 @@ public:
|
||||
pUnit->RemoveAurasDueToSpell(SPELL_INSIDIOUS_WHISPER);
|
||||
}
|
||||
|
||||
void DamageTaken(Unit *done_by, uint32 &damage)
|
||||
void DamageTaken(Unit* done_by, uint32 &damage)
|
||||
{
|
||||
if (done_by->GetGUID() != victimGUID && done_by->GetGUID() != me->GetGUID())
|
||||
{
|
||||
@@ -170,7 +170,7 @@ public:
|
||||
|
||||
struct boss_leotheras_the_blindAI : public ScriptedAI
|
||||
{
|
||||
boss_leotheras_the_blindAI(Creature *c) : ScriptedAI(c)
|
||||
boss_leotheras_the_blindAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
c->GetPosition(x, y, z);
|
||||
pInstance = c->GetInstanceScript();
|
||||
@@ -233,7 +233,7 @@ public:
|
||||
{
|
||||
for (uint8 i = 0; i < 3; ++i)
|
||||
{
|
||||
if (Creature *add = Unit::GetCreature(*me, SpellBinderGUID[i]))
|
||||
if (Creature* add = Unit::GetCreature(*me, SpellBinderGUID[i]))
|
||||
add->DisappearAndDie();
|
||||
|
||||
float nx = x;
|
||||
@@ -248,7 +248,7 @@ public:
|
||||
|
||||
}
|
||||
}
|
||||
void MoveInLineOfSight(Unit *who)
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
{
|
||||
if (me->HasAura(AURA_BANISH))
|
||||
return;
|
||||
@@ -282,7 +282,7 @@ public:
|
||||
uint8 AliveChannelers = 0;
|
||||
for (uint8 i = 0; i < 3; ++i)
|
||||
{
|
||||
Unit *add = Unit::GetUnit(*me, SpellBinderGUID[i]);
|
||||
Unit* add = Unit::GetUnit(*me, SpellBinderGUID[i]);
|
||||
if (add && add->isAlive())
|
||||
++AliveChannelers;
|
||||
}
|
||||
@@ -420,7 +420,7 @@ public:
|
||||
{
|
||||
if (Whirlwind_Timer <= diff)
|
||||
{
|
||||
Unit *newTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Unit* newTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (newTarget)
|
||||
{
|
||||
DoResetThreat();
|
||||
@@ -508,15 +508,15 @@ public:
|
||||
if (InnerDemons_Timer <= diff)
|
||||
{
|
||||
std::list<HostileReference *>& ThreatList = me->getThreatManager().getThreatList();
|
||||
std::vector<Unit *> TargetList;
|
||||
std::vector<Unit* > TargetList;
|
||||
for (std::list<HostileReference *>::const_iterator itr = ThreatList.begin(); itr != ThreatList.end(); ++itr)
|
||||
{
|
||||
Unit *tempTarget = Unit::GetUnit(*me, (*itr)->getUnitGuid());
|
||||
Unit* tempTarget = Unit::GetUnit(*me, (*itr)->getUnitGuid());
|
||||
if (tempTarget && tempTarget->GetTypeId() == TYPEID_PLAYER && tempTarget->GetGUID() != me->getVictim()->GetGUID() && TargetList.size()<5)
|
||||
TargetList.push_back(tempTarget);
|
||||
}
|
||||
//SpellEntry *spell = GET_SPELL(SPELL_INSIDIOUS_WHISPER);
|
||||
for (std::vector<Unit *>::const_iterator itr = TargetList.begin(); itr != TargetList.end(); ++itr)
|
||||
for (std::vector<Unit* >::const_iterator itr = TargetList.begin(); itr != TargetList.end(); ++itr)
|
||||
{
|
||||
if ((*itr) && (*itr)->isAlive())
|
||||
{
|
||||
@@ -566,7 +566,7 @@ public:
|
||||
//at this point he divides himself in two parts
|
||||
CastConsumingMadness();
|
||||
DespawnDemon();
|
||||
Creature *Copy = NULL;
|
||||
Creature* Copy = NULL;
|
||||
Copy = DoSpawnCreature(DEMON_FORM, 0, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 6000);
|
||||
if (Copy)
|
||||
{
|
||||
@@ -600,7 +600,7 @@ public:
|
||||
|
||||
struct boss_leotheras_the_blind_demonformAI : public ScriptedAI
|
||||
{
|
||||
boss_leotheras_the_blind_demonformAI(Creature *c) : ScriptedAI(c) {}
|
||||
boss_leotheras_the_blind_demonformAI(Creature* c) : ScriptedAI(c) {}
|
||||
|
||||
uint32 ChaosBlast_Timer;
|
||||
bool DealDamage;
|
||||
@@ -673,7 +673,7 @@ public:
|
||||
|
||||
struct mob_greyheart_spellbinderAI : public ScriptedAI
|
||||
{
|
||||
mob_greyheart_spellbinderAI(Creature *c) : ScriptedAI(c)
|
||||
mob_greyheart_spellbinderAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
leotherasGUID = 0;
|
||||
@@ -697,7 +697,7 @@ public:
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData64(DATA_LEOTHERAS_EVENT_STARTER, 0);
|
||||
Creature *leotheras = Unit::GetCreature(*me, leotherasGUID);
|
||||
Creature* leotheras = Unit::GetCreature(*me, leotherasGUID);
|
||||
if (leotheras && leotheras->isAlive())
|
||||
CAST_AI(boss_leotheras_the_blind::boss_leotheras_the_blindAI, leotheras->AI())->CheckChannelers(/*false*/);
|
||||
}
|
||||
@@ -722,7 +722,7 @@ public:
|
||||
{
|
||||
if (leotherasGUID)
|
||||
{
|
||||
Creature *leotheras = Unit::GetCreature(*me, leotherasGUID);
|
||||
Creature* leotheras = Unit::GetCreature(*me, leotherasGUID);
|
||||
if (leotheras && leotheras->isAlive())
|
||||
DoCast(leotheras, BANISH_BEAM);
|
||||
}
|
||||
@@ -759,7 +759,7 @@ public:
|
||||
|
||||
if (Mindblast_Timer <= diff)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
|
||||
if (pTarget)DoCast(pTarget, SPELL_MINDBLAST);
|
||||
|
||||
@@ -78,7 +78,7 @@ public:
|
||||
|
||||
struct boss_the_lurker_belowAI : public Scripted_NoMovementAI
|
||||
{
|
||||
boss_the_lurker_belowAI(Creature *c) : Scripted_NoMovementAI(c), Summons(me)
|
||||
boss_the_lurker_belowAI(Creature* c) : Scripted_NoMovementAI(c), Summons(me)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SPOUT_ANIM);
|
||||
@@ -164,7 +164,7 @@ public:
|
||||
Scripted_NoMovementAI::EnterCombat(who);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit *who)
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
{
|
||||
if (!CanStartEvent)//boss is invisible, don't attack
|
||||
return;
|
||||
@@ -299,7 +299,7 @@ public:
|
||||
|
||||
if (GeyserTimer <= diff)
|
||||
{
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1);
|
||||
if (!pTarget && me->getVictim())
|
||||
pTarget = me->getVictim();
|
||||
if (pTarget)
|
||||
@@ -311,7 +311,7 @@ public:
|
||||
{
|
||||
if (WaterboltTimer <= diff)
|
||||
{
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
if (!pTarget && me->getVictim())
|
||||
pTarget = me->getVictim();
|
||||
if (pTarget)
|
||||
@@ -408,7 +408,7 @@ public:
|
||||
|
||||
struct mob_coilfang_ambusherAI : public Scripted_NoMovementAI
|
||||
{
|
||||
mob_coilfang_ambusherAI(Creature *c) : Scripted_NoMovementAI(c)
|
||||
mob_coilfang_ambusherAI(Creature* c) : Scripted_NoMovementAI(c)
|
||||
{
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SHOOT);
|
||||
if (TempSpell)
|
||||
@@ -430,7 +430,7 @@ public:
|
||||
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit *who)
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
{
|
||||
if (!who || me->getVictim()) return;
|
||||
|
||||
@@ -453,7 +453,7 @@ public:
|
||||
|
||||
if (ShootBowTimer <= diff)
|
||||
{
|
||||
Unit *pTarget = NULL;
|
||||
Unit* pTarget = NULL;
|
||||
pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
int bp0 = 1100;
|
||||
if (pTarget)
|
||||
|
||||
+5
-5
@@ -89,7 +89,7 @@ public:
|
||||
|
||||
struct boss_morogrim_tidewalkerAI : public ScriptedAI
|
||||
{
|
||||
boss_morogrim_tidewalkerAI(Creature *c) : ScriptedAI(c)
|
||||
boss_morogrim_tidewalkerAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -187,7 +187,7 @@ public:
|
||||
|
||||
for (uint8 i = 0; i < 10; ++i)
|
||||
{
|
||||
Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0);
|
||||
Creature* Murloc = me->SummonCreature(NPC_TIDEWALKER_LURKER, MurlocCords[i][0], MurlocCords[i][1], MurlocCords[i][2], MurlocCords[i][3], TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 10000);
|
||||
if (pTarget && Murloc)
|
||||
Murloc->AI()->AttackStart(pTarget);
|
||||
@@ -211,7 +211,7 @@ public:
|
||||
if (WateryGrave_Timer <= diff)
|
||||
{
|
||||
//Teleport 4 players under the waterfalls
|
||||
Unit *pTarget;
|
||||
Unit* pTarget;
|
||||
std::set<uint64> list;
|
||||
std::set<uint64>::const_iterator itr;
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
@@ -296,7 +296,7 @@ public:
|
||||
|
||||
struct mob_water_globuleAI : public ScriptedAI
|
||||
{
|
||||
mob_water_globuleAI(Creature *c) : ScriptedAI(c) {}
|
||||
mob_water_globuleAI(Creature* c) : ScriptedAI(c) {}
|
||||
|
||||
uint32 Check_Timer;
|
||||
|
||||
@@ -311,7 +311,7 @@ public:
|
||||
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
|
||||
void MoveInLineOfSight(Unit *who)
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
{
|
||||
if (!who || me->getVictim())
|
||||
return;
|
||||
|
||||
+7
-7
@@ -58,7 +58,7 @@ public:
|
||||
|
||||
struct boss_thespiaAI : public ScriptedAI
|
||||
{
|
||||
boss_thespiaAI(Creature *c) : ScriptedAI(c)
|
||||
boss_thespiaAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -108,12 +108,12 @@ public:
|
||||
//LightningCloud_Timer
|
||||
if (LightningCloud_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_LIGHTNING_CLOUD);
|
||||
|
||||
//cast twice in Heroic mode
|
||||
if (IsHeroic())
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_LIGHTNING_CLOUD);
|
||||
|
||||
LightningCloud_Timer = 15000+rand()%10000;
|
||||
@@ -122,7 +122,7 @@ public:
|
||||
//LungBurst_Timer
|
||||
if (LungBurst_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_LUNG_BURST);
|
||||
LungBurst_Timer = 7000+rand()%5000;
|
||||
} else LungBurst_Timer -=diff;
|
||||
@@ -130,12 +130,12 @@ public:
|
||||
//EnvelopingWinds_Timer
|
||||
if (EnvelopingWinds_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_ENVELOPING_WINDS);
|
||||
|
||||
//cast twice in Heroic mode
|
||||
if (IsHeroic())
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_ENVELOPING_WINDS);
|
||||
EnvelopingWinds_Timer = 10000+rand()%5000;
|
||||
} else EnvelopingWinds_Timer -=diff;
|
||||
@@ -158,7 +158,7 @@ public:
|
||||
|
||||
struct mob_coilfang_waterelementalAI : public ScriptedAI
|
||||
{
|
||||
mob_coilfang_waterelementalAI(Creature *c) : ScriptedAI(c) {}
|
||||
mob_coilfang_waterelementalAI(Creature* c) : ScriptedAI(c) {}
|
||||
|
||||
uint32 WaterBoltVolley_Timer;
|
||||
|
||||
|
||||
+3
-3
@@ -60,7 +60,7 @@ public:
|
||||
|
||||
struct boss_mekgineer_steamriggerAI : public ScriptedAI
|
||||
{
|
||||
boss_mekgineer_steamriggerAI(Creature *c) : ScriptedAI(c)
|
||||
boss_mekgineer_steamriggerAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -137,7 +137,7 @@ public:
|
||||
|
||||
if (Saw_Blade_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
DoCast(pTarget, SPELL_SAW_BLADE);
|
||||
else
|
||||
DoCast(me->getVictim(), SPELL_SAW_BLADE);
|
||||
@@ -204,7 +204,7 @@ public:
|
||||
|
||||
struct mob_steamrigger_mechanicAI : public ScriptedAI
|
||||
{
|
||||
mob_steamrigger_mechanicAI(Creature *c) : ScriptedAI(c)
|
||||
mob_steamrigger_mechanicAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ public:
|
||||
|
||||
struct mob_naga_distillerAI : public ScriptedAI
|
||||
{
|
||||
mob_naga_distillerAI(Creature *c) : ScriptedAI(c)
|
||||
mob_naga_distillerAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -112,7 +112,7 @@ public:
|
||||
|
||||
struct boss_warlord_kalithreshAI : public ScriptedAI
|
||||
{
|
||||
boss_warlord_kalithreshAI(Creature *c) : ScriptedAI(c)
|
||||
boss_warlord_kalithreshAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
@@ -191,7 +191,7 @@ public:
|
||||
//Impale_Timer
|
||||
if (Impale_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_IMPALE);
|
||||
|
||||
Impale_Timer = 7500+rand()%5000;
|
||||
|
||||
@@ -40,7 +40,7 @@ public:
|
||||
|
||||
struct boss_hungarfenAI : public ScriptedAI
|
||||
{
|
||||
boss_hungarfenAI(Creature *c) : ScriptedAI(c)
|
||||
boss_hungarfenAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ public:
|
||||
|
||||
if (Mushroom_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
me->SummonCreature(17990, pTarget->GetPositionX()+(rand()%8), pTarget->GetPositionY()+(rand()%8), pTarget->GetPositionZ(), float(rand()%5), TEMPSUMMON_TIMED_DESPAWN, 22000);
|
||||
else
|
||||
me->SummonCreature(17990, me->GetPositionX()+(rand()%8), me->GetPositionY()+(rand()%8), me->GetPositionZ(), float(rand()%5), TEMPSUMMON_TIMED_DESPAWN, 22000);
|
||||
@@ -85,7 +85,7 @@ public:
|
||||
|
||||
if (AcidGeyser_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_ACID_GEYSER);
|
||||
AcidGeyser_Timer = 10000+rand()%7500;
|
||||
} else AcidGeyser_Timer -= diff;
|
||||
@@ -112,7 +112,7 @@ public:
|
||||
|
||||
struct mob_underbog_mushroomAI : public ScriptedAI
|
||||
{
|
||||
mob_underbog_mushroomAI(Creature *c) : ScriptedAI(c) {}
|
||||
mob_underbog_mushroomAI(Creature* c) : ScriptedAI(c) {}
|
||||
|
||||
bool Stop;
|
||||
uint32 Grow_Timer;
|
||||
|
||||
@@ -47,7 +47,7 @@ public:
|
||||
|
||||
struct boss_the_black_stalkerAI : public ScriptedAI
|
||||
{
|
||||
boss_the_black_stalkerAI(Creature *c) : ScriptedAI(c)
|
||||
boss_the_black_stalkerAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -75,12 +75,12 @@ public:
|
||||
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
|
||||
void JustSummoned(Creature *summon)
|
||||
void JustSummoned(Creature* summon)
|
||||
{
|
||||
if (summon && summon->GetEntry() == ENTRY_SPORE_STRIDER)
|
||||
{
|
||||
Striders.push_back(summon->GetGUID());
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
summon->AI()->AttackStart(pTarget);
|
||||
else
|
||||
if (me->getVictim())
|
||||
@@ -91,7 +91,7 @@ public:
|
||||
void JustDied(Unit* /*who*/)
|
||||
{
|
||||
for (std::list<uint64>::const_iterator i = Striders.begin(); i != Striders.end(); ++i)
|
||||
if (Creature *strider = Unit::GetCreature(*me, *i))
|
||||
if (Creature* strider = Unit::GetCreature(*me, *i))
|
||||
strider->DisappearAndDie();
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ public:
|
||||
{
|
||||
if (LevitatedTarget_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = Unit::GetUnit(*me, LevitatedTarget))
|
||||
if (Unit* pTarget = Unit::GetUnit(*me, LevitatedTarget))
|
||||
{
|
||||
if (!pTarget->HasAura(SPELL_LEVITATE))
|
||||
{
|
||||
@@ -150,7 +150,7 @@ public:
|
||||
}
|
||||
if (Levitate_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 1))
|
||||
{
|
||||
DoCast(pTarget, SPELL_LEVITATE);
|
||||
LevitatedTarget = pTarget->GetGUID();
|
||||
@@ -163,7 +163,7 @@ public:
|
||||
// Chain Lightning
|
||||
if (ChainLightning_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_CHAIN_LIGHTNING);
|
||||
ChainLightning_Timer = 7000;
|
||||
} else ChainLightning_Timer -= diff;
|
||||
@@ -171,7 +171,7 @@ public:
|
||||
// Static Charge
|
||||
if (StaticCharge_Timer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 30, true))
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 30, true))
|
||||
DoCast(pTarget, SPELL_STATIC_CHARGE);
|
||||
StaticCharge_Timer = 10000;
|
||||
} else StaticCharge_Timer -= diff;
|
||||
|
||||
Reference in New Issue
Block a user