AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
boss_pyroguard_emberseer::boss_pyroguard_emberseerAI Struct Reference
Inheritance diagram for boss_pyroguard_emberseer::boss_pyroguard_emberseerAI:
BossAI ScriptedAI CreatureAI UnitAI

Public Member Functions

 boss_pyroguard_emberseerAI (Creature *creature)
 
void Reset () override
 
void SetData (uint32, uint32 data) override
 
void JustEngagedWith (Unit *) override
 Called for reaction when initially engaged.
 
void JustDied (Unit *) override
 
void SpellHit (Unit *, SpellInfo const *spell) override
 
void OpenDoors (bool Boss_Killed)
 
void UpdateRunes (GOState state)
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith()
 
- Public Member Functions inherited from BossAI
 BossAI (Creature *creature, uint32 bossId)
 
 ~BossAI () override
 
bool CanRespawn () override
 
void DamageTaken (Unit *attacker, uint32 &damage, DamageEffectType damagetype, SpellSchoolMask damageSchoolMask) override
 Called at any Damage from any attacker (before damage apply)
 
void JustSummoned (Creature *summon) override
 
void SummonedCreatureDespawn (Creature *summon) override
 
void SummonedCreatureDespawnAll () override
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith()
 
void ScheduleHealthCheckEvent (uint32 healthPct, std::function< void()> exec)
 Executes a function once the creature reaches the defined health point percent.
 
void ScheduleHealthCheckEvent (std::initializer_list< uint8 > healthPct, std::function< void()> exec)
 
void ScheduleEnrageTimer (uint32 spellId, Milliseconds timer, uint8 textId=0)
 
virtual void ExecuteEvent (uint32)
 
virtual void ScheduleTasks ()
 
void Reset () override
 
void JustEngagedWith (Unit *) override
 Called for reaction when initially engaged.
 
void EnterEvadeMode (EvadeReason why=EVADE_REASON_OTHER) override
 
void JustDied (Unit *) override
 
void JustReachedHome () override
 
- Public Member Functions inherited from ScriptedAI
 ScriptedAI (Creature *creature)
 
 ~ScriptedAI () override
 
void AttackStartNoMove (Unit *target)
 
void DamageTaken (Unit *, uint32 &, DamageEffectType, SpellSchoolMask) override
 Called at any Damage from any attacker (before damage apply)
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith()
 
void JustDied (Unit *) override
 
void KilledUnit (Unit *) override
 
void JustSummoned (Creature *) override
 
void SummonedCreatureDespawn (Creature *) override
 
void SpellHit (Unit *, SpellInfo const *) override
 
void SpellHitTarget (Unit *, SpellInfo const *) override
 
void MovementInform (uint32, uint32) override
 
void OnPossess (bool)
 
bool IsInRoom (const Position *pos, Axis axis, bool above)
 
void Reset () override
 
void JustEngagedWith (Unit *) override
 Called for reaction when initially engaged.
 
void AttackStart (Unit *) override
 
void DoStartMovement (Unit *target, float distance=0.0f, float angle=0.0f)
 
void DoStartNoMovement (Unit *target)
 
void DoStopAttack ()
 
void DoCastSpell (Unit *target, SpellInfo const *spellInfo, bool triggered=false)
 
void DoPlaySoundToSet (WorldObject *source, uint32 soundId)
 
void DoPlayMusic (uint32 soundId, bool zone)
 
void DoAddThreat (Unit *unit, float amount)
 
void DoModifyThreatByPercent (Unit *unit, int32 pct)
 
void DoResetThreat (Unit *unit)
 
void DoResetThreatList ()
 
float DoGetThreat (Unit *unit)
 
void DoTeleportPlayer (Unit *unit, float x, float y, float z, float o)
 
void DoTeleportPlayer (Unit *unit, Position pos)
 
void DoTeleportAll (float x, float y, float z, float o)
 
UnitDoSelectLowestHpFriendly (float range, uint32 minHPDiff=1)
 
std::list< Creature * > DoFindFriendlyCC (float range)
 
std::list< Creature * > DoFindFriendlyMissingBuff (float range, uint32 spellId)
 
PlayerGetPlayerAtMinimumRange (float minRange)
 
CreatureDoSpawnCreature (uint32 entry, float offsetX, float offsetY, float offsetZ, float angle, uint32 type, uint32 despawntime)
 
bool IsUniqueTimedEventDone (uint32 id) const
 
void SetUniqueTimedEventDone (uint32 id)
 
void ResetUniqueTimedEvent (uint32 id)
 
void ClearUniqueTimedEventsDone ()
 
void ScheduleTimedEvent (Milliseconds timerMin, Milliseconds timerMax, std::function< void()> exec, Milliseconds repeatMin, Milliseconds repeatMax=0s, uint32 uniqueId=0)
 
void ScheduleTimedEvent (Milliseconds timerMax, std::function< void()> exec, Milliseconds repeatMin, Milliseconds repeatMax=0s, uint32 uniqueId=0)
 
void ScheduleUniqueTimedEvent (Milliseconds timer, std::function< void()> exec, uint32 uniqueId)
 
bool HealthBelowPct (uint32 pct) const
 
bool HealthAbovePct (uint32 pct) const
 
SpellInfo const * SelectSpell (Unit *target, uint32 school, uint32 mechanic, SelectTargetType targets, uint32 powerCostMin, uint32 powerCostMax, float rangeMin, float rangeMax, SelectEffect effect)
 
void SetEquipmentSlots (bool loadDefault, int32 mainHand=EQUIP_NO_CHANGE, int32 offHand=EQUIP_NO_CHANGE, int32 ranged=EQUIP_NO_CHANGE)
 
virtual bool CheckEvadeIfOutOfCombatArea () const
 
bool IsHeroic () const
 
Difficulty GetDifficulty () const
 
bool Is25ManRaid () const
 
template<class T >
const T & DUNGEON_MODE (const T &normal5, const T &heroic10) const
 
template<class T >
const T & RAID_MODE (const T &normal10, const T &normal25) const
 
template<class T >
const T & RAID_MODE (const T &normal10, const T &normal25, const T &heroic10, const T &heroic25) const
 
PlayerSelectTargetFromPlayerList (float maxdist, uint32 excludeAura=0, bool mustBeInLOS=false) const
 
void SetInvincibility (bool apply)
 
bool IsInvincible () const
 
void SetAutoAttackAllowed (bool allow)
 
bool IsAutoAttackAllowed () const
 
- Public Member Functions inherited from CreatureAI
void Talk (uint8 id, WorldObject const *whisperTarget=nullptr, Milliseconds delay=0s)
 Causes the creature to talk/say the text assigned to their entry in the creature_text database table.
 
void Talk (uint8 id, Milliseconds delay)
 
WorldObjectGetSummoner () const
 Returns the summoner creature/object, if the creature is a temporary summon.
 
 CreatureAI (Creature *creature)
 
 ~CreatureAI () override
 
void MoveCircleChecks ()
 
void MoveBackwardsChecks ()
 
void MoveInLineOfSight_Safe (Unit *who)
 == Reactions At =================================
 
void TriggerAlert (Unit const *who) const
 
virtual void IsSummonedBy (WorldObject *)
 
virtual void SummonedCreatureDies (Creature *, Unit *)
 
virtual void SummonedCreatureEvade (Creature *)
 
virtual void AttackedBy (Unit *)
 
virtual bool IsEscorted ()
 
virtual void JustRespawned ()
 
virtual void PathEndReached (uint32)
 
void OnCharmed (bool apply) override
 Called when unit is charmed.
 
void DoZoneInCombat (Creature *creature=nullptr, float maxRangeToNearestTarget=250.0f)
 
virtual void ReceiveEmote (Player *, uint32)
 
virtual void OwnerAttackedBy (Unit *)
 
virtual void OwnerAttacked (Unit *)
 
virtual void CorpseRemoved (uint32 &)
 == Triggered Actions Requested ==================
 
virtual void PassengerBoarded (Unit *, int8, bool)
 == Fields =======================================
 
virtual bool BeforeSpellClick (Unit *)
 
virtual void OnSpellClick (Unit *, bool &)
 
virtual bool CanSeeAlways (WorldObject const *)
 
virtual bool CanBeSeen (Player const *)
 
virtual bool CanAlwaysBeDetectable (WorldObject const *)
 
virtual void PetStopAttack ()
 
virtual bool CheckInRoom ()
 
CreatureBoundary const * GetBoundary () const
 
void SetBoundary (CreatureBoundary const *boundary, bool negativeBoundaries=false)
 
bool IsInBoundary (Position const *who=nullptr) const
 
virtual void CalculateThreat (Unit *, float &, SpellInfo const *)
 
virtual bool OnTeleportUnreacheablePlayer (Player *)
 
virtual void OnAuraRemove (AuraApplication *, AuraRemoveMode)
 
- Public Member Functions inherited from UnitAI
 UnitAI (Unit *unit)
 
virtual ~UnitAI ()
 
virtual bool CanAIAttack (Unit const *) const
 
virtual void InitializeAI ()
 
virtual void DoAction (int32)
 
virtual uint32 GetData (uint32) const
 
virtual void SetGUID (ObjectGuid, int32=0)
 
virtual ObjectGuid GetGUID (int32=0) const
 
UnitSelectTarget (SelectTargetMethod targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
 
template<class PREDICATE >
UnitSelectTarget (SelectTargetMethod targetType, uint32 position, PREDICATE const &predicate)
 
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectTargetMethod targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
 Select the best (up to) <num> targets (in <targetType> order) from the threat list that fulfill the following:
 
template<class PREDICATE >
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectTargetMethod targetType, uint32 position, PREDICATE const &predicate)
 
virtual void JustEnteredCombat (Unit *)
 Called when the unit enters combat.
 
virtual void JustExitedCombat ()
 Called when the unit leaves combat.
 
virtual void DamageDealt (Unit *, uint32 &, DamageEffectType, SpellSchoolMask)
 Called at any Damage to any victim (before damage apply)
 
virtual void HealReceived (Unit *, uint32 &)
 Called when the creature receives heal.
 
virtual void OnPowerUpdate (Powers, int32, int32, uint32)
 Called when the creature power updates.
 
virtual void HealDone (Unit *, uint32 &)
 Called when the unit heals.
 
virtual void OnCalculateMeleeDamageReceived (uint32 &, Unit *)
 Called during damage calculations.
 
virtual void OnCalculateSpellDamageReceived (int32 &, Unit *)
 
virtual void OnCalculatePeriodicTickReceived (uint32 &, Unit *)
 Called during calculation when receiving periodic healing or damage (DoT or HoT)
 
void AttackStartCaster (Unit *victim, float dist)
 
SpellCastResult DoAddAuraToAllHostilePlayers (uint32 spellid)
 
SpellCastResult DoCast (uint32 spellId)
 
SpellCastResult DoCast (Unit *victim, uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastSelf (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastToAllHostilePlayers (uint32 spellid, bool triggered=false)
 To specify the caster as target if the spell is self-cast.
 
SpellCastResult DoCastVictim (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastAOE (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastRandomTarget (uint32 spellId, uint32 threatTablePosition=0, float dist=0.0f, bool playerOnly=true, bool triggered=false, bool withTank=true)
 Cast the spell on a random unit from the threat list.
 
SpellCastResult DoCastMaxThreat (uint32 spellId, uint32 threatTablePosition=0, float dist=0.0f, bool playerOnly=true, bool triggered=false)
 Cast spell on the top threat target, which may not be the current victim.
 
float DoGetSpellMaxRange (uint32 spellId, bool positive=false)
 
void DoMeleeAttackIfReady ()
 
bool DoSpellAttackIfReady (uint32 spell)
 
void DoSpellAttackToRandomTargetIfReady (uint32 spell, uint32 threatTablePosition=0, float dist=0.f, bool playerOnly=true)
 
virtual void SummonMovementInform (Creature *, uint32, uint32)
 Called when a summon reaches a waypoint or point movement finished.
 
virtual void sGossipHello (Player *)
 
virtual void sGossipSelect (Player *, uint32, uint32)
 
virtual void sGossipSelectCode (Player *, uint32, uint32, char const *)
 
virtual void sQuestAccept (Player *, Quest const *)
 
virtual void sQuestSelect (Player *, Quest const *)
 
virtual void sQuestComplete (Player *, Quest const *)
 
virtual void sQuestReward (Player *, Quest const *, uint32)
 
virtual void sOnGameEvent (bool, uint16)
 
virtual std::string GetDebugInfo () const
 

Additional Inherited Members

- Public Types inherited from ScriptedAI
enum class  Axis {
  AXIS_X ,
  AXIS_Y
}
 
- Public Types inherited from CreatureAI
enum  EvadeReason {
  EVADE_REASON_NO_HOSTILES ,
  EVADE_REASON_BOUNDARY ,
  EVADE_REASON_SEQUENCE_BREAK ,
  EVADE_REASON_NO_PATH ,
  EVADE_REASON_OTHER
}
 
- Static Public Member Functions inherited from CreatureAI
static bool IsInBounds (CreatureBoundary const &boundary, Position const *who)
 
- Static Public Member Functions inherited from UnitAI
static void FillAISpellInfo ()
 
- Public Attributes inherited from BossAI
float callForHelpRange
 
InstanceScript *const instance
 
- Public Attributes inherited from ScriptedAI
Creatureme
 
- Static Public Attributes inherited from UnitAI
static AISpellInfoTypeAISpellInfo
 
- Protected Member Functions inherited from BossAI
void _Reset ()
 
void _JustEngagedWith ()
 
void _JustDied ()
 
void _JustReachedHome ()
 
void _EnterEvadeMode (EvadeReason why=EVADE_REASON_OTHER)
 
void TeleportCheaters ()
 
- Protected Member Functions inherited from CreatureAI
bool UpdateVictim ()
 
bool UpdateVictimWithGaze ()
 
void SetGazeOn (Unit *target)
 
CreatureDoSummon (uint32 entry, Position const &pos, uint32 despawnTime=30000, TempSummonType summonType=TEMPSUMMON_CORPSE_TIMED_DESPAWN)
 
CreatureDoSummon (uint32 entry, WorldObject *obj, float radius=5.0f, uint32 despawnTime=30000, TempSummonType summonType=TEMPSUMMON_CORPSE_TIMED_DESPAWN)
 
CreatureDoSummonFlyer (uint32 entry, WorldObject *obj, float flightZ, float radius=5.0f, uint32 despawnTime=30000, TempSummonType summonType=TEMPSUMMON_CORPSE_TIMED_DESPAWN)
 
virtual void MoveInLineOfSight (Unit *)
 
bool _EnterEvadeMode (EvadeReason why=EVADE_REASON_OTHER)
 
- Protected Attributes inherited from BossAI
SummonList summons
 
- Protected Attributes inherited from CreatureAI
Creature *const me
 
EventMap events
 
TaskScheduler scheduler
 
CreatureBoundary const * _boundary
 
bool _negateBoundary
 
- Protected Attributes inherited from UnitAI
Unit *const me
 

Detailed Description

Constructor & Destructor Documentation

◆ boss_pyroguard_emberseerAI()

boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::boss_pyroguard_emberseerAI ( Creature creature)
inline
78: BossAI(creature, DATA_PYROGAURD_EMBERSEER) { }
@ DATA_PYROGAURD_EMBERSEER
Definition blackrock_spire.h:40
Definition ScriptedCreature.h:467

Member Function Documentation

◆ JustDied()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::JustDied ( Unit )
inlineoverridevirtual

Reimplemented from CreatureAI.

133 {
134 // Activate all the runes
136 // Opens all 3 doors
137 OpenDoors(true);
138 // Complete encounter
140 }
@ GO_STATE_READY
Definition GameObjectData.h:690
@ DONE
Definition InstanceScript.h:61
InstanceScript *const instance
Definition ScriptedCreature.h:474
virtual bool SetBossState(uint32 id, EncounterState state)
Definition InstanceScript.cpp:385
void OpenDoors(bool Boss_Killed)
Definition boss_pyroguard_emberseer.cpp:167
void UpdateRunes(GOState state)
Definition boss_pyroguard_emberseer.cpp:181

References DATA_PYROGAURD_EMBERSEER, DONE, GO_STATE_READY, BossAI::instance, OpenDoors(), InstanceScript::SetBossState(), and UpdateRunes().

◆ JustEngagedWith()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::JustEngagedWith ( Unit )
inlineoverridevirtual

Called for reaction when initially engaged.

Reimplemented from CreatureAI.

125 {
126 // ### TODO Check combat timing ###
127 events.ScheduleEvent(EVENT_FIRENOVA, 6s);
128 events.ScheduleEvent(EVENT_FLAMEBUFFET, 3s);
129 events.ScheduleEvent(EVENT_PYROBLAST, 14s);
130 }
@ EVENT_PYROBLAST
Definition boss_pyroguard_emberseer.cpp:63
@ EVENT_FIRENOVA
Definition boss_pyroguard_emberseer.cpp:61
@ EVENT_FLAMEBUFFET
Definition boss_pyroguard_emberseer.cpp:62
events
Definition boss_sartura.cpp:43

References EVENT_FIRENOVA, EVENT_FLAMEBUFFET, and EVENT_PYROBLAST.

◆ OpenDoors()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::OpenDoors ( bool  Boss_Killed)
inline
168 {
169 // These two doors reopen on reset or boss kill
171 door1->SetGoState(GO_STATE_ACTIVE);
173 door2->SetGoState(GO_STATE_ACTIVE);
174
175 // This door opens on boss kill
176 if (Boss_Killed)
178 door3->SetGoState(GO_STATE_ACTIVE);
179 }
@ GO_STATE_ACTIVE
Definition GameObjectData.h:689
@ GO_EMBERSEER_IN
Definition blackrock_spire.h:113
@ GO_EMBERSEER_OUT
Definition blackrock_spire.h:115
@ GO_DOORS
Definition blackrock_spire.h:114
Definition GameObject.h:120
ObjectGuid GetGuidData(uint32 type) const override
Definition InstanceScript.cpp:110
GameObject * GetGameObject(ObjectGuid const guid)
Definition Map.cpp:2503
Map * GetMap() const
Definition Object.h:536
Creature * me
Definition ScriptedCreature.h:280

References Map::GetGameObject(), InstanceScript::GetGuidData(), WorldObject::GetMap(), GO_DOORS, GO_EMBERSEER_IN, GO_EMBERSEER_OUT, GO_STATE_ACTIVE, BossAI::instance, and ScriptedAI::me.

Referenced by JustDied(), and Reset().

◆ Reset()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::Reset ( )
inlineoverridevirtual

Reimplemented from UnitAI.

81 {
83 me->SetImmuneToPC(true);
84 events.Reset();
85 // Apply auras on spawn and reset
86 // DoCast(me, SPELL_FIRE_SHIELD_TRIGGER); // Need to find this in old DBC if possible
90 events.ScheduleEvent(EVENT_RESPAWN, 5s);
91 // Hack for missing trigger spell
92 events.ScheduleEvent(EVENT_FIRE_SHIELD, 3s);
93
94 // Open doors on reset
96 OpenDoors(false); // Opens 2 entrance doors
97 }
@ IN_PROGRESS
Definition InstanceScript.h:59
@ UNIT_FLAG_NOT_SELECTABLE
Definition UnitDefines.h:275
@ SPELL_EMBERSEER_FULL_STRENGTH
Definition boss_pyroguard_emberseer.cpp:41
@ SPELL_EMBERSEER_GROWING_TRIGGER
Definition boss_pyroguard_emberseer.cpp:40
@ SPELL_EMBERSEER_GROWING
Definition boss_pyroguard_emberseer.cpp:39
@ EVENT_RESPAWN
Definition boss_pyroguard_emberseer.cpp:56
@ EVENT_FIRE_SHIELD
Definition boss_pyroguard_emberseer.cpp:65
EncounterState GetBossState(uint32 id) const
Definition InstanceScript.h:242
void RemoveAura(AuraApplicationMap::iterator &i, AuraRemoveMode mode=AURA_REMOVE_BY_DEFAULT)
Definition Unit.cpp:4808
void SetUnitFlag(UnitFlags flags)
UnitFlags available in UnitDefines.h.
Definition Unit.h:719
void SetImmuneToPC(bool apply, bool keepCombat=false)
Definition Unit.cpp:13653

References DATA_PYROGAURD_EMBERSEER, EVENT_FIRE_SHIELD, EVENT_RESPAWN, InstanceScript::GetBossState(), IN_PROGRESS, BossAI::instance, ScriptedAI::me, OpenDoors(), Unit::RemoveAura(), Unit::SetImmuneToPC(), Unit::SetUnitFlag(), SPELL_EMBERSEER_FULL_STRENGTH, SPELL_EMBERSEER_GROWING, SPELL_EMBERSEER_GROWING_TRIGGER, and UNIT_FLAG_NOT_SELECTABLE.

Referenced by SetData().

◆ SetData()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::SetData ( uint32  ,
uint32  data 
)
inlineoverridevirtual

Reimplemented from UnitAI.

100 {
101 switch (data)
102 {
103 case 1:
104 events.ScheduleEvent(EVENT_PRE_FIGHT_1, 2s);
106 break;
107 case 2:
108 // Close these two doors on Blackhand Incarcerators aggro
110 if (door1->GetGoState() == GO_STATE_ACTIVE)
111 door1->SetGoState(GO_STATE_READY);
113 if (door2->GetGoState() == GO_STATE_ACTIVE)
114 door2->SetGoState(GO_STATE_READY);
115 break;
116 case 3:
117 Reset();
118 break;
119 default:
120 break;
121 }
122 }
@ EVENT_PRE_FIGHT_1
Definition boss_pyroguard_emberseer.cpp:58
void Reset() override
Definition boss_pyroguard_emberseer.cpp:80

References DATA_PYROGAURD_EMBERSEER, EVENT_PRE_FIGHT_1, Map::GetGameObject(), InstanceScript::GetGuidData(), WorldObject::GetMap(), GO_DOORS, GO_EMBERSEER_IN, GO_STATE_ACTIVE, GO_STATE_READY, IN_PROGRESS, BossAI::instance, ScriptedAI::me, Reset(), and InstanceScript::SetBossState().

◆ SpellHit()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::SpellHit ( Unit ,
SpellInfo const *  spell 
)
inlineoverridevirtual

Reimplemented from CreatureAI.

143 {
144 if (spell->Id == SPELL_ENCAGE_EMBERSEER)
145 {
148 }
149
150 if (spell->Id == SPELL_EMBERSEER_GROWING_TRIGGER)
151 {
154
156 {
157 events.CancelEvent(EVENT_FIRE_SHIELD); // temporarily cancel fire shield to keep it from interrupting combat start
158
159 // Schedule out the pre-combat scene
160 events.ScheduleEvent(EVENT_PRE_ENTER_COMBAT_1, 0s);
161 events.ScheduleEvent(EVENT_PRE_ENTER_COMBAT_2, 2s);
162 events.ScheduleEvent(EVENT_ENTER_COMBAT, 5s);
163 }
164 }
165 }
@ SPELL_ENCAGE_EMBERSEER
Definition boss_pyroguard_emberseer.cpp:46
@ SPELL_ENCAGED_EMBERSEER
Definition boss_pyroguard_emberseer.cpp:35
@ EMOTE_TEN_STACK
Definition boss_pyroguard_emberseer.cpp:28
@ EVENT_PRE_ENTER_COMBAT_1
Definition boss_pyroguard_emberseer.cpp:66
@ EVENT_PRE_ENTER_COMBAT_2
Definition boss_pyroguard_emberseer.cpp:67
@ EVENT_ENTER_COMBAT
Definition boss_pyroguard_emberseer.cpp:68
uint32 GetAuraCount(uint32 spellId) const
Definition Unit.cpp:5714
SpellCastResult CastSpell(SpellCastTargets const &targets, SpellInfo const *spellInfo, CustomSpellValues const *value, TriggerCastFlags triggerFlags=TRIGGERED_NONE, Item *castItem=nullptr, AuraEffect const *triggeredByAura=nullptr, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition Unit.cpp:1178
Talk
Definition hyjal.cpp:82

References Unit::CastSpell(), EMOTE_TEN_STACK, EVENT_ENTER_COMBAT, EVENT_FIRE_SHIELD, EVENT_PRE_ENTER_COMBAT_1, EVENT_PRE_ENTER_COMBAT_2, Unit::GetAuraCount(), SpellInfo::Id, ScriptedAI::me, SPELL_EMBERSEER_GROWING_TRIGGER, SPELL_ENCAGE_EMBERSEER, and SPELL_ENCAGED_EMBERSEER.

◆ UpdateAI()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::UpdateAI ( uint32  )
inlineoverridevirtual

Use to start attacking a target. Called just before JustEngagedWith()

Implements UnitAI.

201 {
202 if (!UpdateVictim())
203 {
204 events.Update(diff);
205
206 while (uint32 eventId = events.ExecuteEvent())
207 {
208 switch (eventId)
209 {
210 case EVENT_RESPAWN:
211 {
212 // Respawn all Blackhand Incarcerators
213 std::list<Creature*> creatureList;
215 for (std::list<Creature*>::iterator itr = creatureList.begin(); itr != creatureList.end(); ++itr)
216 if (Creature* creature = *itr)
217 {
218 if (!creature->IsAlive())
219 creature->Respawn();
220
221 creature->AI()->SetData(1, 2);
222 }
225 break;
226 }
228 {
229 // Set data on all Blackhand Incarcerators
230 std::list<Creature*> creatureList;
232 for (std::list<Creature*>::iterator itr = creatureList.begin(); itr != creatureList.end(); ++itr)
233 {
234 if (Creature* creature = *itr)
235 creature->AI()->SetData(1, 1);
236 }
237 events.ScheduleEvent(EVENT_PRE_FIGHT_2, 2s);
238 break;
239 }
244 break;
246 // #### Spell isn't doing any damage ??? ####
248 events.ScheduleEvent(EVENT_FIRE_SHIELD, 3s);
249 break;
255 break;
258 break;
261 me->SetImmuneToPC(false);
263 // re-enable fire shield
264 events.ScheduleEvent(EVENT_FIRE_SHIELD, 0s);
265 break;
266 default:
267 break;
268 }
269 }
270 return;
271 }
272
273 events.Update(diff);
274
275 while (uint32 eventId = events.ExecuteEvent())
276 {
277 switch (eventId)
278 {
281 events.ScheduleEvent(EVENT_FIRE_SHIELD, 3s);
282 break;
283 case EVENT_FIRENOVA:
285 events.ScheduleEvent(EVENT_FIRENOVA, 6s);
286 break;
289 events.ScheduleEvent(EVENT_FLAMEBUFFET, 14s);
290 break;
291 case EVENT_PYROBLAST:
293 events.ScheduleEvent(EVENT_PYROBLAST, 15s);
294 break;
295 default:
296 break;
297 }
298 }
300 }
std::uint32_t uint32
Definition Define.h:107
@ NOT_STARTED
Definition InstanceScript.h:58
void GetCreatureListWithEntryInGrid(std::list< Creature * > &list, WorldObject *source, uint32 entry, float maxSearchRange)
Definition ScriptedCreature.cpp:875
@ NPC_BLACKHAND_INCARCERATOR
Definition blackrock_spire.h:79
@ SPELL_FREEZE_ANIM
Definition boss_pyroguard_emberseer.cpp:38
@ SPELL_FIRE_SHIELD
Definition boss_pyroguard_emberseer.cpp:37
@ SPELL_FLAMEBUFFET
Definition boss_pyroguard_emberseer.cpp:43
@ SPELL_FIRENOVA
Definition boss_pyroguard_emberseer.cpp:42
@ SPELL_PYROBLAST
Definition boss_pyroguard_emberseer.cpp:44
@ YELL_FREE_OF_BONDS
Definition boss_pyroguard_emberseer.cpp:30
@ EMOTE_FREE_OF_BONDS
Definition boss_pyroguard_emberseer.cpp:29
@ EMOTE_ONE_STACK
Definition boss_pyroguard_emberseer.cpp:27
@ EVENT_PRE_FIGHT_2
Definition boss_pyroguard_emberseer.cpp:59
bool UpdateVictim()
Definition CreatureAI.cpp:280
void DoZoneInCombat(Creature *creature=nullptr, float maxRangeToNearestTarget=250.0f)
Definition CreatureAI.cpp:106
Definition Creature.h:43
SpellCastResult DoCastRandomTarget(uint32 spellId, uint32 threatTablePosition=0, float dist=0.0f, bool playerOnly=true, bool triggered=false, bool withTank=true)
Cast the spell on a random unit from the threat list.
Definition UnitAI.cpp:259
void DoMeleeAttackIfReady()
Definition UnitAI.cpp:39
SpellCastResult DoCast(uint32 spellId)
Definition UnitAI.cpp:177
Aura * AddAura(uint32 spellId, Unit *target)
Definition Unit.cpp:18915
void RemoveUnitFlag(UnitFlags flags)
UnitFlags available in UnitDefines.h.
Definition Unit.h:720

References Unit::AddAura(), Unit::CastSpell(), DATA_PYROGAURD_EMBERSEER, UnitAI::DoCast(), UnitAI::DoCastRandomTarget(), UnitAI::DoMeleeAttackIfReady(), CreatureAI::DoZoneInCombat(), EMOTE_FREE_OF_BONDS, EMOTE_ONE_STACK, EVENT_ENTER_COMBAT, EVENT_FIRE_SHIELD, EVENT_FIRENOVA, EVENT_FLAMEBUFFET, EVENT_PRE_ENTER_COMBAT_1, EVENT_PRE_ENTER_COMBAT_2, EVENT_PRE_FIGHT_1, EVENT_PRE_FIGHT_2, EVENT_PYROBLAST, EVENT_RESPAWN, GetCreatureListWithEntryInGrid(), BossAI::instance, ScriptedAI::me, NOT_STARTED, NPC_BLACKHAND_INCARCERATOR, Unit::RemoveAura(), Unit::RemoveUnitFlag(), InstanceScript::SetBossState(), Unit::SetImmuneToPC(), SPELL_EMBERSEER_FULL_STRENGTH, SPELL_EMBERSEER_GROWING, SPELL_ENCAGED_EMBERSEER, SPELL_FIRE_SHIELD, SPELL_FIRENOVA, SPELL_FLAMEBUFFET, SPELL_FREEZE_ANIM, SPELL_PYROBLAST, UNIT_FLAG_NOT_SELECTABLE, CreatureAI::UpdateVictim(), and YELL_FREE_OF_BONDS.

◆ UpdateRunes()

void boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::UpdateRunes ( GOState  state)
inline
182 {
183 // update all runes
185 rune1->SetGoState(state);
187 rune2->SetGoState(state);
189 rune3->SetGoState(state);
191 rune4->SetGoState(state);
193 rune5->SetGoState(state);
195 rune6->SetGoState(state);
197 rune7->SetGoState(state);
198 }
@ GO_EMBERSEER_RUNE_3
Definition blackrock_spire.h:132
@ GO_EMBERSEER_RUNE_7
Definition blackrock_spire.h:136
@ GO_EMBERSEER_RUNE_4
Definition blackrock_spire.h:133
@ GO_EMBERSEER_RUNE_2
Definition blackrock_spire.h:131
@ GO_EMBERSEER_RUNE_1
Definition blackrock_spire.h:130
@ GO_EMBERSEER_RUNE_5
Definition blackrock_spire.h:134
@ GO_EMBERSEER_RUNE_6
Definition blackrock_spire.h:135

References Map::GetGameObject(), InstanceScript::GetGuidData(), WorldObject::GetMap(), GO_EMBERSEER_RUNE_1, GO_EMBERSEER_RUNE_2, GO_EMBERSEER_RUNE_3, GO_EMBERSEER_RUNE_4, GO_EMBERSEER_RUNE_5, GO_EMBERSEER_RUNE_6, GO_EMBERSEER_RUNE_7, BossAI::instance, and ScriptedAI::me.

Referenced by JustDied().


The documentation for this struct was generated from the following file: