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

Public Member Functions

 npc_highlord_darion_mograineAI (Creature *creature)
 
void DoAction (int32 param) override
 
uint32 GetData (uint32 type) const override
 
void SendUpdateWorldState (uint32 id, uint32 state)
 
void SendInitialWorldStates ()
 
void JustSummoned (Creature *cr) override
 
void SummonedCreatureDies (Creature *creature, Unit *) override
 
void JustDied (Unit *) override
 
void FinishFight ()
 
void JustEngagedWith (Unit *) override
 Called for reaction when initially engaged. More...
 
void Reset () override
 
void JustRespawned () override
 
CreatureGetEntryFromSummons (uint32 entry)
 
void MovementInform (uint32 type, uint32 point) override
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith() More...
 
- 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) More...
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith() More...
 
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. More...
 
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
 
- 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. More...
 
void Talk (uint8 id, Milliseconds delay)
 
 CreatureAI (Creature *creature)
 
 ~CreatureAI () override
 
void MoveCircleChecks ()
 
void MoveBackwardsChecks ()
 
void MoveInLineOfSight_Safe (Unit *who)
 == Reactions At ================================= More...
 
void TriggerAlert (Unit const *who) const
 
virtual bool CanRespawn ()
 
virtual void EnterEvadeMode (EvadeReason why=EVADE_REASON_OTHER)
 
virtual void JustEngagedWith (Unit *)
 Called for reaction when initially engaged. More...
 
virtual void JustDied (Unit *)
 
virtual void KilledUnit (Unit *)
 
virtual void JustSummoned (Creature *)
 
virtual void IsSummonedBy (WorldObject *)
 
virtual void SummonedCreatureDespawn (Creature *)
 
virtual void SummonedCreatureDies (Creature *, Unit *)
 
virtual void SummonedCreatureDespawnAll ()
 
virtual void SummonedCreatureEvade (Creature *)
 
virtual void SpellHit (Unit *, SpellInfo const *)
 
virtual void SpellHitTarget (Unit *, SpellInfo const *)
 
virtual void AttackedBy (Unit *)
 
virtual bool IsEscorted ()
 
virtual void JustRespawned ()
 
virtual void MovementInform (uint32, uint32)
 
virtual void PathEndReached (uint32)
 
void OnCharmed (bool apply) override
 Called when unit is charmed. More...
 
virtual void JustReachedHome ()
 
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 ================== More...
 
virtual void PassengerBoarded (Unit *, int8, bool)
 == Fields ======================================= More...
 
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 AttackStart (Unit *)
 
virtual void UpdateAI (uint32)=0
 Use to start attacking a target. Called just before JustEngagedWith() More...
 
virtual void InitializeAI ()
 
virtual void Reset ()
 
virtual void OnCharmed (bool apply)=0
 Called when unit is charmed. More...
 
virtual void DoAction (int32)
 
virtual uint32 GetData (uint32) const
 
virtual void SetData (uint32, uint32)
 
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: More...
 
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. More...
 
virtual void JustExitedCombat ()
 Called when the unit leaves combat. More...
 
virtual void DamageDealt (Unit *, uint32 &, DamageEffectType)
 Called at any Damage to any victim (before damage apply) More...
 
virtual void DamageTaken (Unit *, uint32 &, DamageEffectType, SpellSchoolMask)
 Called at any Damage from any attacker (before damage apply) More...
 
virtual void HealReceived (Unit *, uint32 &)
 Called when the creature receives heal. More...
 
virtual void OnPowerUpdate (Powers, int32, int32, uint32)
 Called when the creature power updates. More...
 
virtual void HealDone (Unit *, uint32 &)
 Called when the unit heals. More...
 
virtual void OnCalculateMeleeDamageReceived (uint32 &, Unit *)
 Called during damage calculations. More...
 
virtual void OnCalculateSpellDamageReceived (int32 &, Unit *)
 
virtual void OnCalculatePeriodicTickReceived (uint32 &, Unit *)
 Called during calculation when receiving periodic healing or damage (DoT or HoT) More...
 
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. More...
 
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. More...
 
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. More...
 
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. More...
 
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
 

Public Attributes

EventMap events
 
SummonList summons
 
uint32 startTimeRemaining
 
uint32 defendersRemaining
 
uint32 scourgeRemaining
 
uint8 battleStarted
 
bool resetExecuted
 
- Public Attributes inherited from ScriptedAI
Creatureme
 

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 ()
 
- Static Public Attributes inherited from UnitAI
static AISpellInfoTypeAISpellInfo
 
- 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 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

◆ npc_highlord_darion_mograineAI()

npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::npc_highlord_darion_mograineAI ( Creature creature)
inline
367 : ScriptedAI(creature), summons(me)
368 {
370 me->SetCorpseDelay(3 * 60);
371 me->SetRespawnTime(3 * 60);
372 resetExecuted = false;
373 }
@ ENCOUNTER_STATE_NONE
Definition: chapter5.cpp:208
Definition: ScriptedCreature.h:190
Creature * me
Definition: ScriptedCreature.h:280
void SetRespawnTime(uint32 respawn)
Definition: Creature.cpp:3762
void SetCorpseDelay(uint32 delay)
Definition: Creature.h:73
SummonList summons
Definition: chapter5.cpp:376

References battleStarted, ENCOUNTER_STATE_NONE, ScriptedAI::me, resetExecuted, Creature::SetCorpseDelay(), and Creature::SetRespawnTime().

Member Function Documentation

◆ DoAction()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::DoAction ( int32  param)
inlineoverridevirtual

Reimplemented from UnitAI.

384 {
385 if (param == ACTION_START_EVENT && !startTimeRemaining && events.Empty())
386 {
388
392
394
395 events.Reset();
396 events.ScheduleEvent(EVENT_START_COUNTDOWN_1, 60s);
397 events.ScheduleEvent(EVENT_START_COUNTDOWN_2, 120s);
398 events.ScheduleEvent(EVENT_START_COUNTDOWN_3, 180s);
399 events.ScheduleEvent(EVENT_START_COUNTDOWN_4, 240s);
400 events.ScheduleEvent(EVENT_START_COUNTDOWN_5, 300s);
401 events.ScheduleEvent(EVENT_START_COUNTDOWN_6, 308s);
402 events.ScheduleEvent(EVENT_START_COUNTDOWN_7, 312s);
403 events.ScheduleEvent(EVENT_START_COUNTDOWN_8, 316s);
404 events.ScheduleEvent(EVENT_START_COUNTDOWN_9, 320s);
405 events.ScheduleEvent(EVENT_START_COUNTDOWN_10, 324s);
406 events.ScheduleEvent(EVENT_START_COUNTDOWN_11, 332s);
407 events.ScheduleEvent(EVENT_START_COUNTDOWN_12, 335s);
408 events.ScheduleEvent(EVENT_START_COUNTDOWN_13, 337s + 500ms);
409 events.ScheduleEvent(EVENT_START_COUNTDOWN_14, 345s);
410 }
411 }
@ EVENT_START_COUNTDOWN_3
Definition: chapter5.cpp:106
@ EVENT_START_COUNTDOWN_2
Definition: chapter5.cpp:105
@ EVENT_START_COUNTDOWN_7
Definition: chapter5.cpp:110
@ EVENT_START_COUNTDOWN_6
Definition: chapter5.cpp:109
@ ACTION_START_EVENT
Definition: chapter5.cpp:193
@ EVENT_START_COUNTDOWN_5
Definition: chapter5.cpp:108
@ EVENT_START_COUNTDOWN_10
Definition: chapter5.cpp:113
@ ENCOUNTER_TOTAL_SCOURGE
Definition: chapter5.cpp:199
@ EVENT_START_COUNTDOWN_13
Definition: chapter5.cpp:116
@ EVENT_START_COUNTDOWN_4
Definition: chapter5.cpp:107
@ EVENT_START_COUNTDOWN_8
Definition: chapter5.cpp:111
@ EVENT_START_COUNTDOWN_12
Definition: chapter5.cpp:115
@ EVENT_START_COUNTDOWN_11
Definition: chapter5.cpp:114
@ EVENT_START_COUNTDOWN_14
Definition: chapter5.cpp:117
@ EVENT_START_COUNTDOWN_1
Definition: chapter5.cpp:104
@ ENCOUNTER_TOTAL_DEFENDERS
Definition: chapter5.cpp:198
@ EVENT_START_COUNTDOWN_9
Definition: chapter5.cpp:112
@ ENCOUNTER_START_TIME
Definition: chapter5.cpp:197
@ SAY_LIGHT_OF_DAWN01
Definition: chapter5.cpp:27
Talk
Definition: hyjal.cpp:82
events
Definition: boss_sartura.cpp:43
void SendInitialWorldStates()
Definition: chapter5.cpp:443

References ACTION_START_EVENT, defendersRemaining, ENCOUNTER_START_TIME, ENCOUNTER_TOTAL_DEFENDERS, ENCOUNTER_TOTAL_SCOURGE, EVENT_START_COUNTDOWN_1, EVENT_START_COUNTDOWN_10, EVENT_START_COUNTDOWN_11, EVENT_START_COUNTDOWN_12, EVENT_START_COUNTDOWN_13, EVENT_START_COUNTDOWN_14, EVENT_START_COUNTDOWN_2, EVENT_START_COUNTDOWN_3, EVENT_START_COUNTDOWN_4, EVENT_START_COUNTDOWN_5, EVENT_START_COUNTDOWN_6, EVENT_START_COUNTDOWN_7, EVENT_START_COUNTDOWN_8, EVENT_START_COUNTDOWN_9, SAY_LIGHT_OF_DAWN01, scourgeRemaining, SendInitialWorldStates(), and startTimeRemaining.

◆ FinishFight()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::FinishFight ( )
inline
505 {
507 {
508 tirion->LoadEquipment(0, true);
509 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN25);
510 events.Reset();
511 events.ScheduleEvent(EVENT_FINISH_FIGHT_1, 10s);
512 events.ScheduleEvent(EVENT_FINISH_FIGHT_2, 20s);
513 events.ScheduleEvent(EVENT_FINISH_FIGHT_3, 22s);
514 events.ScheduleEvent(EVENT_FINISH_FIGHT_4, 23s);
515 events.ScheduleEvent(EVENT_FINISH_FIGHT_5, 24s);
516
517 tirion->SummonGameObject(GO_HOLY_LIGHTNING, 2254.84f, -5298.75f, 82.168f, 1.134f, 0, 0, 0.537102f, 0.843517f, 20);
518 tirion->SummonGameObject(GO_HOLY_LIGHTNING, 2296.24f, -5296.44f, 81.9964f, 5.3398f, 0, 0, 0.454395f, -0.8908f, 20);
519 tirion->SummonGameObject(GO_HOLY_LIGHTNING, 2314.29f, -5261.78f, 83.1349f, 3.05822f, 0, 0, 0.999131f, 0.0416735f, 20);
520 tirion->SummonGameObject(GO_HOLY_LIGHTNING, 2278.43f, -5270.14f, 81.7247f, 0.70988f, 0, 0, 0.347534f, 0.937667f, 20);
521 }
522 }
@ TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN
Definition: Object.h:46
@ GO_HOLY_LIGHTNING
Definition: chapter5.cpp:245
const Position LightOfDawnPos[]
Definition: chapter5.cpp:280
@ EVENT_FINISH_FIGHT_2
Definition: chapter5.cpp:126
@ EVENT_FINISH_FIGHT_4
Definition: chapter5.cpp:128
@ EVENT_FINISH_FIGHT_5
Definition: chapter5.cpp:129
@ EVENT_FINISH_FIGHT_3
Definition: chapter5.cpp:127
@ EVENT_FINISH_FIGHT_1
Definition: chapter5.cpp:125
@ SAY_LIGHT_OF_DAWN25
Definition: chapter5.cpp:36
@ NPC_HIGHLORD_TIRION_FORDRING
Definition: chapter5.cpp:237
Definition: Creature.h:46
TempSummon * SummonCreature(uint32 id, const Position &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0, SummonPropertiesEntry const *properties=nullptr, bool visibleBySummonerOnly=false) const
Definition: Object.cpp:2355

References EVENT_FINISH_FIGHT_1, EVENT_FINISH_FIGHT_2, EVENT_FINISH_FIGHT_3, EVENT_FINISH_FIGHT_4, EVENT_FINISH_FIGHT_5, GO_HOLY_LIGHTNING, LightOfDawnPos, ScriptedAI::me, NPC_HIGHLORD_TIRION_FORDRING, SAY_LIGHT_OF_DAWN25, WorldObject::SummonCreature(), and TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN.

Referenced by SummonedCreatureDies().

◆ GetData()

uint32 npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::GetData ( uint32  type) const
inlineoverridevirtual

Reimplemented from UnitAI.

414 {
415 switch (type)
416 {
418 return defendersRemaining;
420 return scourgeRemaining;
422 return me->IsAlive() && (startTimeRemaining || battleStarted);
424 return me->IsAlive() && startTimeRemaining;
426 return startTimeRemaining;
429 }
430 return 0;
431 }
@ WORLD_STATE_COUNTDOWN_TIME
Definition: chapter5.cpp:205
@ WORLD_STATE_COUNTDOWN_ENABLE
Definition: chapter5.cpp:204
@ WORLD_STATE_SCOURGE_COUNT
Definition: chapter5.cpp:202
@ WORLD_STATE_DEFENDERS_COUNT
Definition: chapter5.cpp:201
@ WORLD_STATE_SOLDIERS_ENABLE
Definition: chapter5.cpp:203
@ WORLD_STATE_EVENT_BEGIN_ENABLE
Definition: chapter5.cpp:206
bool IsAlive() const
Definition: Unit.h:1204

References battleStarted, defendersRemaining, Unit::IsAlive(), ScriptedAI::me, scourgeRemaining, startTimeRemaining, WORLD_STATE_COUNTDOWN_ENABLE, WORLD_STATE_COUNTDOWN_TIME, WORLD_STATE_DEFENDERS_COUNT, WORLD_STATE_EVENT_BEGIN_ENABLE, WORLD_STATE_SCOURGE_COUNT, and WORLD_STATE_SOLDIERS_ENABLE.

Referenced by SendInitialWorldStates(), and SummonedCreatureDies().

◆ GetEntryFromSummons()

Creature * npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::GetEntryFromSummons ( uint32  entry)
inline
567 {
568 for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr)
569 if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
570 if (summon->GetEntry() == entry)
571 return summon;
572 return nullptr;
573 }
Creature * GetCreature(WorldObject const &u, ObjectGuid const guid)
Definition: ObjectAccessor.cpp:213
iterator begin()
Definition: ScriptedCreature.h:48
StorageType::const_iterator const_iterator
Definition: ScriptedCreature.h:37
iterator end()
Definition: ScriptedCreature.h:58

References SummonList::begin(), SummonList::end(), ObjectAccessor::GetCreature(), ScriptedAI::me, and summons.

Referenced by UpdateAI().

◆ JustDied()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::JustDied ( Unit )
inlineoverridevirtual

Reimplemented from ScriptedAI.

498 {
500 me->SetCorpseDelay(3 * 60);
501 me->SetRespawnTime(3 * 60);
502 }
void DespawnAll(uint32 delay=0)
Definition: ScriptedCreature.cpp:71

References SummonList::DespawnAll(), ScriptedAI::me, Creature::SetCorpseDelay(), Creature::SetRespawnTime(), and summons.

◆ JustEngagedWith()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::JustEngagedWith ( Unit )
inlineoverridevirtual

Called for reaction when initially engaged.

Reimplemented from ScriptedAI.

525 {
527 return;
528
529 events.RescheduleEvent(EVENT_SPELL_ANTI_MAGIC_ZONE, 15000);
530 events.RescheduleEvent(EVENT_SPELL_DEATH_STRIKE, 8000);
531 events.RescheduleEvent(EVENT_SPELL_DEATH_EMBRACE, 5000);
532 events.RescheduleEvent(EVENT_SPELL_UNHOLY_BLIGHT, 10000);
533 events.RescheduleEvent(EVENT_SPELL_TALK, 10000);
534 }
@ ENCOUNTER_STATE_FIGHT
Definition: chapter5.cpp:209
@ EVENT_SPELL_ANTI_MAGIC_ZONE
Definition: chapter5.cpp:119
@ EVENT_SPELL_UNHOLY_BLIGHT
Definition: chapter5.cpp:122
@ EVENT_SPELL_DEATH_STRIKE
Definition: chapter5.cpp:120
@ EVENT_SPELL_TALK
Definition: chapter5.cpp:123
@ EVENT_SPELL_DEATH_EMBRACE
Definition: chapter5.cpp:121

References battleStarted, ENCOUNTER_STATE_FIGHT, EVENT_SPELL_ANTI_MAGIC_ZONE, EVENT_SPELL_DEATH_EMBRACE, EVENT_SPELL_DEATH_STRIKE, EVENT_SPELL_TALK, and EVENT_SPELL_UNHOLY_BLIGHT.

◆ JustRespawned()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::JustRespawned ( )
inlineoverridevirtual

Reimplemented from CreatureAI.

546 {
547 events.Reset();
549
550 me->SetImmuneToAll(true);
553 me->SetVisible(true);
554 me->setActive(true);
555 me->SetWalk(false);
556
561
564 }
@ UNIT_STAND_STATE_STAND
Definition: UnitDefines.h:32
@ UNIT_NPC_FLAG_GOSSIP
Definition: UnitDefines.h:294
@ UNIT_NPC_FLAG_QUESTGIVER
Definition: UnitDefines.h:295
bool SetWalk(bool enable) override
Enable or disable the creature's walk mode by removing: MOVEMENTFLAG_WALKING. Infom also the client.
Definition: Creature.cpp:3178
void setActive(bool isActiveObject)
Definition: Object.cpp:1085
void SummonCreatureGroup(uint8 group, std::list< TempSummon * > *list=nullptr)
Definition: Object.cpp:2432
void SetVisible(bool x)
Definition: Unit.cpp:14189
void ReplaceAllNpcFlags(NPCFlags flags)
Definition: Unit.h:697
void SetStandState(uint8 state)
Definition: Unit.cpp:16682
void SetImmuneToAll(bool apply, bool keepCombat=false)
Definition: Unit.h:810

References battleStarted, defendersRemaining, SummonList::DespawnAll(), ENCOUNTER_STATE_NONE, ScriptedAI::me, Unit::ReplaceAllNpcFlags(), scourgeRemaining, SendInitialWorldStates(), WorldObject::setActive(), Unit::SetImmuneToAll(), Unit::SetStandState(), Unit::SetVisible(), Creature::SetWalk(), startTimeRemaining, WorldObject::SummonCreatureGroup(), summons, UNIT_NPC_FLAG_GOSSIP, UNIT_NPC_FLAG_QUESTGIVER, and UNIT_STAND_STATE_STAND.

Referenced by Reset().

◆ JustSummoned()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::JustSummoned ( Creature cr)
inlineoverridevirtual

Reimplemented from ScriptedAI.

454 {
455 summons.Summon(cr);
456
458 {
460 if (Unit* target = cr->SelectNearbyTarget(nullptr, 10.0f))
461 if (target->IsCreature())
462 target->GetMotionMaster()->MoveCharge(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), me->GetSpeed(MOVE_RUN));
464 }
465
467 {
469 cr->SetImmuneToAll(true);
472 }
473 }
uint32 urand(uint32 min, uint32 max)
Definition: Random.cpp:44
@ REACT_PASSIVE
Definition: Unit.h:548
@ MOVE_RUN
Definition: UnitDefines.h:329
@ UNIT_NPC_EMOTESTATE
Definition: UpdateFields.h:140
const Position LightOfDawnFightPos[]
Definition: chapter5.cpp:300
@ ENCOUNTER_STATE_OUTRO
Definition: chapter5.cpp:210
@ NPC_DEFENDER_OF_THE_LIGHT
Definition: chapter5.cpp:216
@ EMOTE_STATE_READY1H
Definition: SharedDefines.h:1966
void Summon(Creature const *summon)
Definition: ScriptedCreature.h:88
void SetReactState(ReactStates state)
A creature can have 3 ReactStates : Agressive, Passive, Neutral.
Definition: Creature.h:97
uint32 GetEntry() const
Definition: Object.h:112
Definition: Position.h:28
float GetPositionZ() const
Definition: Position.h:119
float GetPositionX() const
Definition: Position.h:117
float GetPositionY() const
Definition: Position.h:118
Definition: Unit.h:630
float GetSpeed(UnitMoveType mtype) const
Definition: Unit.cpp:14378
Unit * SelectNearbyTarget(Unit *exclude=nullptr, float dist=NOMINAL_MELEE_RANGE) const
Definition: Unit.cpp:16940
MotionMaster * GetMotionMaster()
Definition: Unit.h:1601
void SetUInt32Value(uint16 index, uint32 value)
Definition: Unit.cpp:21256
void HandleEmoteCommand(uint32 emoteId)
Definition: Unit.cpp:1984
bool IsInCombat() const
Definition: Unit.h:820
void MoveCharge(float x, float y, float z, float speed=SPEED_CHARGE, uint32 id=EVENT_CHARGE, const Movement::PointsArray *path=nullptr, bool generatePath=false, float orientation=0.0f, ObjectGuid targetGUID=ObjectGuid::Empty)
The unit will charge the target. Doesn't work with UNIT_FLAG_DISABLE_MOVE.
Definition: MotionMaster.cpp:667

References battleStarted, EMOTE_STATE_READY1H, ENCOUNTER_STATE_FIGHT, ENCOUNTER_STATE_OUTRO, Object::GetEntry(), Unit::GetMotionMaster(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), Unit::GetSpeed(), Unit::HandleEmoteCommand(), Unit::IsInCombat(), LightOfDawnFightPos, ScriptedAI::me, MOVE_RUN, MotionMaster::MoveCharge(), NPC_DEFENDER_OF_THE_LIGHT, NPC_HIGHLORD_TIRION_FORDRING, REACT_PASSIVE, Unit::SelectNearbyTarget(), Unit::SetImmuneToAll(), Creature::SetReactState(), Unit::SetUInt32Value(), SummonList::Summon(), summons, UNIT_NPC_EMOTESTATE, and urand().

◆ MovementInform()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::MovementInform ( uint32  type,
uint32  point 
)
inlineoverridevirtual

Reimplemented from ScriptedAI.

576 {
577 if (type == POINT_MOTION_TYPE && point == 2)
578 {
581 events.Reset();
582
583 events.ScheduleEvent(EVENT_OUTRO_SCENE_1, 2s);
584 events.ScheduleEvent(EVENT_OUTRO_SCENE_2, 19s);
585 events.ScheduleEvent(EVENT_OUTRO_SCENE_3, 38s);
586 events.ScheduleEvent(EVENT_OUTRO_SCENE_4, 50s);
587 events.ScheduleEvent(EVENT_OUTRO_SCENE_5, 62s);
588 events.ScheduleEvent(EVENT_OUTRO_SCENE_6, 68s);
589 events.ScheduleEvent(EVENT_OUTRO_SCENE_7, 71s);
590 events.ScheduleEvent(EVENT_OUTRO_SCENE_8, 72s);
591 events.ScheduleEvent(EVENT_OUTRO_SCENE_9, 74s);
592 events.ScheduleEvent(EVENT_OUTRO_SCENE_10, 77s);
593 events.ScheduleEvent(EVENT_OUTRO_SCENE_11, 79s);
594 events.ScheduleEvent(EVENT_OUTRO_SCENE_12, 82s);
595 events.ScheduleEvent(EVENT_OUTRO_SCENE_13, 85s);
596 events.ScheduleEvent(EVENT_OUTRO_SCENE_14, 92s);
597 events.ScheduleEvent(EVENT_OUTRO_SCENE_15, 98s);
598 events.ScheduleEvent(EVENT_OUTRO_SCENE_16, 105s);
599 events.ScheduleEvent(EVENT_OUTRO_SCENE_17, 120s);
600 events.ScheduleEvent(EVENT_OUTRO_SCENE_18, 131s);
601 events.ScheduleEvent(EVENT_OUTRO_SCENE_19, 158s);
602 }
603 }
@ POINT_MOTION_TYPE
Definition: MotionMaster.h:46
@ SPELL_THE_LIGHT_OF_DAWN
Definition: chapter5.cpp:264
@ EVENT_OUTRO_SCENE_19
Definition: chapter5.cpp:149
@ EVENT_OUTRO_SCENE_5
Definition: chapter5.cpp:135
@ EVENT_OUTRO_SCENE_7
Definition: chapter5.cpp:137
@ EVENT_OUTRO_SCENE_15
Definition: chapter5.cpp:145
@ EVENT_OUTRO_SCENE_18
Definition: chapter5.cpp:148
@ EVENT_OUTRO_SCENE_1
Definition: chapter5.cpp:131
@ EVENT_OUTRO_SCENE_3
Definition: chapter5.cpp:133
@ EVENT_OUTRO_SCENE_13
Definition: chapter5.cpp:143
@ EVENT_OUTRO_SCENE_11
Definition: chapter5.cpp:141
@ EVENT_OUTRO_SCENE_8
Definition: chapter5.cpp:138
@ EVENT_OUTRO_SCENE_12
Definition: chapter5.cpp:142
@ EVENT_OUTRO_SCENE_14
Definition: chapter5.cpp:144
@ EVENT_OUTRO_SCENE_2
Definition: chapter5.cpp:132
@ EVENT_OUTRO_SCENE_17
Definition: chapter5.cpp:147
@ EVENT_OUTRO_SCENE_6
Definition: chapter5.cpp:136
@ EVENT_OUTRO_SCENE_10
Definition: chapter5.cpp:140
@ EVENT_OUTRO_SCENE_4
Definition: chapter5.cpp:134
@ EVENT_OUTRO_SCENE_9
Definition: chapter5.cpp:139
@ EVENT_OUTRO_SCENE_16
Definition: chapter5.cpp:146
@ EMOTE_LIGHT_OF_DAWN05
Definition: chapter5.cpp:85
void RemoveAurasDueToSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, uint8 reqEffMask=0, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition: Unit.cpp:4891

References EMOTE_LIGHT_OF_DAWN05, EVENT_OUTRO_SCENE_1, EVENT_OUTRO_SCENE_10, EVENT_OUTRO_SCENE_11, EVENT_OUTRO_SCENE_12, EVENT_OUTRO_SCENE_13, EVENT_OUTRO_SCENE_14, EVENT_OUTRO_SCENE_15, EVENT_OUTRO_SCENE_16, EVENT_OUTRO_SCENE_17, EVENT_OUTRO_SCENE_18, EVENT_OUTRO_SCENE_19, EVENT_OUTRO_SCENE_2, EVENT_OUTRO_SCENE_3, EVENT_OUTRO_SCENE_4, EVENT_OUTRO_SCENE_5, EVENT_OUTRO_SCENE_6, EVENT_OUTRO_SCENE_7, EVENT_OUTRO_SCENE_8, EVENT_OUTRO_SCENE_9, ScriptedAI::me, POINT_MOTION_TYPE, Unit::RemoveAurasDueToSpell(), and SPELL_THE_LIGHT_OF_DAWN.

◆ Reset()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::Reset ( )
inlineoverridevirtual

Reimplemented from ScriptedAI.

537 {
538 if (resetExecuted)
539 return;
540
541 resetExecuted = true;
543 }
void JustRespawned() override
Definition: chapter5.cpp:545

References JustRespawned(), and resetExecuted.

◆ SendInitialWorldStates()

◆ SendUpdateWorldState()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::SendUpdateWorldState ( uint32  id,
uint32  state 
)
inline
434 {
435 Map::PlayerList const& players = me->GetMap()->GetPlayers();
436 if (!players.IsEmpty())
437 for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr)
438 if (Player* player = itr->GetSource())
439 if (player->GetPhaseMask() & 128) // Xinef: client skips players without chapter 5 aura anyway, speedup
440 player->SendUpdateWorldState(id, state);
441 }
bool IsEmpty() const
Definition: LinkedList.h:97
Definition: LinkedList.h:139
Map * GetMap() const
Definition: Object.h:531
Definition: Player.h:1064
PlayerList const & GetPlayers() const
Definition: Map.h:486
Definition: MapRefMgr.h:26
iterator begin()
Definition: MapRefMgr.h:36
iterator end()
Definition: MapRefMgr.h:37

References MapRefMgr::begin(), MapRefMgr::end(), WorldObject::GetMap(), Map::GetPlayers(), LinkedListHead::IsEmpty(), and ScriptedAI::me.

Referenced by SendInitialWorldStates(), SummonedCreatureDies(), and UpdateAI().

◆ SummonedCreatureDies()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::SummonedCreatureDies ( Creature creature,
Unit  
)
inlineoverridevirtual

Reimplemented from CreatureAI.

476 {
477 // Refill Armies and update counters
479 return;
480
481 me->m_Events.AddEvent(new DelayedSummonEvent(me, creature->GetEntry(), *creature), me->m_Events.CalculateTime(3000));
482 if (creature->GetEntry() >= NPC_RAMPAGING_ABOMINATION)
483 {
486 }
487 else
488 {
491
492 if (defendersRemaining == 200)
493 FinishFight();
494 }
495 }
@ NPC_RAMPAGING_ABOMINATION
Definition: chapter5.cpp:226
void AddEvent(BasicEvent *Event, uint64 e_time, bool set_addtime=true)
Definition: EventProcessor.h:103
uint64 CalculateTime(uint64 t_offset) const
Definition: EventProcessor.cpp:159
EventProcessor m_Events
Definition: Unit.h:1792
Definition: chapter5.cpp:315

References EventProcessor::AddEvent(), battleStarted, EventProcessor::CalculateTime(), defendersRemaining, ENCOUNTER_STATE_FIGHT, FinishFight(), GetData(), Object::GetEntry(), Unit::m_Events, ScriptedAI::me, NPC_RAMPAGING_ABOMINATION, scourgeRemaining, SendUpdateWorldState(), WORLD_STATE_DEFENDERS_COUNT, and WORLD_STATE_SCOURGE_COUNT.

◆ UpdateAI()

void npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::UpdateAI ( uint32  )
inlineoverridevirtual

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

Reimplemented from ScriptedAI.

606 {
607 events.Update(diff);
608 uint32 eventId = events.ExecuteEvent();
609
610 switch (eventId)
611 {
614 break;
617 break;
620 break;
624 break;
628 Talk(SAY_LIGHT_OF_DAWN04); // Wrong order in DB!
632 break;
638 if (eventId == EVENT_START_COUNTDOWN_6)
639 {
642 }
643 else
646 break;
649 break;
652 break;
654 {
655 uint8 first = 1;
656 for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr)
657 {
658 if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
659 {
660 Position pos = LightOfDawnPos[first];
661 summon->SetHomePosition(pos);
662 summon->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), true, false);
663 }
664 first = first == 0 ? 1 : 0;
665 }
666 Position pos = LightOfDawnPos[first];
667 me->SetHomePosition(pos);
668 me->SetWalk(false);
669 me->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), true, true);
671 break;
672 }
674 me->SetImmuneToAll(false);
676 return;
680 break;
682 {
688
690 {
691 orbaz->SetReactState(REACT_PASSIVE);
692 orbaz->AI()->Talk(EMOTE_LIGHT_OF_DAWN04);
693 orbaz->GetMotionMaster()->MovePoint(2, LightOfDawnPos[2], true, true);
694 orbaz->DespawnOrUnsummon(7000);
695 }
696
697 for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr)
698 if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
699 {
700 summon->CombatStop(true);
701 summon->GetThreatMgr().ClearAllThreat();
702 summon->SetImmuneToAll(true);
703 summon->SetReactState(REACT_PASSIVE);
704 summon->GetMotionMaster()->Clear(false);
705 }
706 me->CombatStop(true);
708 me->SetImmuneToAll(true);
710 me->GetMotionMaster()->Clear(false);
711
712 // Position main stars
714
715 me->SummonCreature(NPC_DEFENDER_OF_THE_LIGHT, 2276.66f, -5273.60f, 81.86f, 5.14f, TEMPSUMMON_CORPSE_DESPAWN);
716 me->SummonCreature(NPC_DEFENDER_OF_THE_LIGHT, 2272.11f, -5279.08f, 82.01f, 5.69f, TEMPSUMMON_CORPSE_DESPAWN);
717 me->SummonCreature(NPC_DEFENDER_OF_THE_LIGHT, 2285.11f, -5276.73f, 82.08f, 4.23f, TEMPSUMMON_CORPSE_DESPAWN);
718 me->SummonCreature(NPC_DEFENDER_OF_THE_LIGHT, 2290.06f, -5286.41f, 82.51f, 3.16f, TEMPSUMMON_CORPSE_DESPAWN);
719 break;
720 }
723 {
724 koltira->SetWalk(true);
725 koltira->SetHomePosition(*koltira);
726 koltira->CastSpell(koltira, SPELL_THE_LIGHT_OF_DAWN, false);
727 koltira->GetMotionMaster()->MoveCharge(LightOfDawnPos[3].GetPositionX(), LightOfDawnPos[3].GetPositionY(), LightOfDawnPos[3].GetPositionZ(), 4.0f, 2);
728 }
729 break;
732 {
733 thassarin->SetWalk(true);
734 thassarin->SetHomePosition(*thassarin);
735 thassarin->CastSpell(thassarin, SPELL_THE_LIGHT_OF_DAWN, false);
736 thassarin->GetMotionMaster()->MoveCharge(LightOfDawnPos[4].GetPositionX(), LightOfDawnPos[4].GetPositionY(), LightOfDawnPos[4].GetPositionZ(), 4.0f, 2);
737 }
738 break;
740 me->SetWalk(true);
744 me->GetMotionMaster()->MoveCharge(LightOfDawnPos[5].GetPositionX(), LightOfDawnPos[5].GetPositionY(), LightOfDawnPos[5].GetPositionZ(), 4.0f, 2);
745
747 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN26);
748 break;
751 me->SetFacingTo(4.8f);
753 break;
756 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN28);
757 break;
760 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN29);
761 break;
764 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN30);
765 break;
769 break;
772 {
773 alex->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE);
774 alex->GetMotionMaster()->MovePoint(0, LightOfDawnPos[8].GetPositionX(), LightOfDawnPos[8].GetPositionY(), LightOfDawnPos[8].GetPositionZ());
775 alex->CastSpell(alex, SPELL_ALEXANDROS_MOGRAINE_SPAWN, true);
776 //alex->AI()->Talk(EMOTE_LIGHT_OF_DAWN06);
777 }
778 break;
781 {
782 alex->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE);
783 alex->AI()->Talk(SAY_LIGHT_OF_DAWN32);
784 me->SetFacingToObject(alex);
785 }
786 break;
789 break;
793 break;
796 {
797 darion->AI()->Talk(SAY_LIGHT_OF_DAWN35);
798 darion->SetWalk(false);
799 }
800 break;
803 {
804 //darion->AI()->Talk(EMOTE_LIGHT_OF_DAWN07);
805 darion->GetMotionMaster()->MovePoint(0, LightOfDawnPos[10].GetPositionX(), LightOfDawnPos[10].GetPositionY(), LightOfDawnPos[10].GetPositionZ());
806 }
807 break;
810 darion->AI()->Talk(EMOTE_LIGHT_OF_DAWN08);
811 break;
814 darion->AI()->Talk(SAY_LIGHT_OF_DAWN36);
815 break;
818 alex->AI()->Talk(SAY_LIGHT_OF_DAWN37);
819 break;
822 darion->AI()->Talk(SAY_LIGHT_OF_DAWN38);
823 break;
826 alex->AI()->Talk(SAY_LIGHT_OF_DAWN39);
827
829 tirion->GetMotionMaster()->MovePoint(0, LightOfDawnPos[11].GetPositionX(), LightOfDawnPos[11].GetPositionY(), LightOfDawnPos[11].GetPositionZ());
830 break;
833 darion->AI()->Talk(SAY_LIGHT_OF_DAWN40);
834 break;
837 alex->AI()->Talk(SAY_LIGHT_OF_DAWN41);
838
840 darion->DespawnOrUnsummon(3000);
841 break;
844 alex->AI()->Talk(SAY_LIGHT_OF_DAWN42);
845
846 events.Reset();
847 events.ScheduleEvent(EVENT_OUTRO_SCENE_20, 4s);
848 events.ScheduleEvent(EVENT_OUTRO_SCENE_21, 4s + 500ms);
849 events.ScheduleEvent(EVENT_OUTRO_SCENE_22, 7s);
850 events.ScheduleEvent(EVENT_OUTRO_SCENE_23, 9s);
851 events.ScheduleEvent(EVENT_OUTRO_SCENE_24, 14s);
852 events.ScheduleEvent(EVENT_OUTRO_SCENE_25, 21s + 200ms);
853 events.ScheduleEvent(EVENT_OUTRO_SCENE_26, 22s + 500ms);
854 events.ScheduleEvent(EVENT_OUTRO_SCENE_27, 24s);
855 events.ScheduleEvent(EVENT_OUTRO_SCENE_28, 28s);
856 events.ScheduleEvent(EVENT_OUTRO_SCENE_29, 34s);
857 events.ScheduleEvent(EVENT_OUTRO_SCENE_30, 36s);
858 events.ScheduleEvent(EVENT_OUTRO_SCENE_31, 51s);
859 events.ScheduleEvent(EVENT_OUTRO_SCENE_32, 68s);
860 events.ScheduleEvent(EVENT_OUTRO_SCENE_33, 73s);
861 events.ScheduleEvent(EVENT_OUTRO_SCENE_34, 76s);
862 events.ScheduleEvent(EVENT_OUTRO_SCENE_35, 77s);
863 events.ScheduleEvent(EVENT_OUTRO_SCENE_36, 81s);
864 break;
867 lk->AI()->Talk(SAY_LIGHT_OF_DAWN43);
868 break;
871 lk->CastSpell(lk, SPELL_ICEBOUND_VISAGE, true);
872 break;
875 {
876 lk->AI()->Talk(SAY_LIGHT_OF_DAWN45);
878 {
879 alex->RemoveAllAuras();
880 lk->CastSpell(alex, SPELL_SOUL_FEAST_ALEX, false);
881 }
882 }
883 break;
886 {
887 alex->DespawnOrUnsummon(5000);
888 alex->SetVisible(false);
889 }
890 break;
894 break;
897 lk->GetMotionMaster()->MovePoint(0, LightOfDawnPos[13].GetPositionX(), LightOfDawnPos[13].GetPositionY(), LightOfDawnPos[13].GetPositionZ());
898 break;
901 break;
904 {
905 lk->AI()->Talk(SAY_LIGHT_OF_DAWN46);
906 lk->CastSpell(me, SPELL_REBUKE, false);
907 }
908 break;
912 {
913 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN47);
915 tirion->SetFacingToObject(lk);
916 }
917 break;
920 {
921 lk->HandleEmoteCommand(EMOTE_ONESHOT_LAUGH);
922 lk->PlayDirectSound(14820);
923 }
924 break;
927 lk->AI()->Talk(SAY_LIGHT_OF_DAWN48);
928 break;
931 lk->AI()->Talk(SAY_LIGHT_OF_DAWN49);
932 break;
935 {
937 {
938 lk->CastSpell(lk, SPELL_SOUL_FEAST_TIRION, false);
939 tirion->AI()->Talk(EMOTE_LIGHT_OF_DAWN12);
940 }
941
942 for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr)
943 if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
944 if (summon->GetEntry() <= NPC_RIMBLAT_EARTHSHATTER && summon->GetEntry() != NPC_HIGHLORD_TIRION_FORDRING)
945 {
946 float o = lk->GetAngle(summon);
947 summon->GetMotionMaster()->MovePoint(3, lk->GetPositionX() + 2.0f * cos(o), lk->GetPositionY() + 2.0f * std::sin(o), lk->GetPositionZ());
948 summon->ToTempSummon()->SetTempSummonType(TEMPSUMMON_MANUAL_DESPAWN);
949 }
950 }
951 break;
954 {
955 lk->AI()->Talk(SAY_LIGHT_OF_DAWN51);
956 lk->CastSpell(lk, SPELL_APOCALYPSE, true);
957 }
958 break;
960 for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr)
961 if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
962 if (summon->GetEntry() <= NPC_RIMBLAT_EARTHSHATTER && summon->GetEntry() != NPC_HIGHLORD_TIRION_FORDRING)
963 Unit::Kill(summon, summon);
964 break;
967 break;
972 me->SetFacingToObject(tirion);
973
974 events.Reset();
975 events.ScheduleEvent(EVENT_OUTRO_SCENE_37, 1s);
976 events.ScheduleEvent(EVENT_OUTRO_SCENE_38, 5s);
977 events.ScheduleEvent(EVENT_OUTRO_SCENE_39, 7s);
978 events.ScheduleEvent(EVENT_OUTRO_SCENE_40, 9s);
979 events.ScheduleEvent(EVENT_OUTRO_SCENE_41, 13s);
980 events.ScheduleEvent(EVENT_OUTRO_SCENE_42, 16s);
981 events.ScheduleEvent(EVENT_OUTRO_SCENE_43, 17s);
982 events.ScheduleEvent(EVENT_OUTRO_SCENE_44, 19s);
983 events.ScheduleEvent(EVENT_OUTRO_SCENE_45, 25s);
984 events.ScheduleEvent(EVENT_OUTRO_SCENE_46, 32s);
985 events.ScheduleEvent(EVENT_OUTRO_SCENE_47, 42s);
986 events.ScheduleEvent(EVENT_OUTRO_SCENE_48, 52s);
987 events.ScheduleEvent(EVENT_OUTRO_SCENE_49, 54s);
988 events.ScheduleEvent(EVENT_OUTRO_SCENE_50, 58s);
989 events.ScheduleEvent(EVENT_OUTRO_SCENE_51, 65s);
990 events.ScheduleEvent(EVENT_OUTRO_SCENE_52, 70s);
991 events.ScheduleEvent(EVENT_OUTRO_SCENE_53, 84s);
992 break;
996 break;
999 {
1000 tirion->RemoveAllAuras();
1001 tirion->CastSpell(me, SPELL_REBIRTH_OF_THE_ASHBRINGER, true);
1002 tirion->SummonGameObject(GO_LIGHT_OF_DAWN, tirion->GetPositionX(), tirion->GetPositionY(), tirion->GetPositionZ(), tirion->GetOrientation(), 0, 0, 0, 0, 180);
1003 tirion->LoadEquipment(1, true);
1004 }
1006 break;
1009 {
1010 tirion->RemoveAllAuras();
1011 tirion->HandleEmoteCommand(EMOTE_ONESHOT_ROAR);
1012 }
1013 break;
1016 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN54);
1017 break;
1020 lk->AI()->Talk(SAY_LIGHT_OF_DAWN55);
1021 break;
1024 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN56);
1025 break;
1028 {
1029 tirion->CastSpell(tirion, SPELL_TIRION_CHARGE, true);
1030 tirion->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_READY2H);
1031 tirion->SetImmuneToAll(true);
1032 }
1033 break;
1036 lk->AI()->Talk(SAY_LIGHT_OF_DAWN57);
1037 break;
1040 lk->AI()->Talk(SAY_LIGHT_OF_DAWN58);
1041 break;
1044 lk->AI()->Talk(SAY_LIGHT_OF_DAWN59);
1045 break;
1048 {
1049 lk->CastSpell(lk, SPELL_EXIT_TELEPORT_VISUAL, true);
1050 lk->DespawnOrUnsummon(1500);
1051 }
1052
1054 {
1055 float o = me->GetAngle(tirion);
1056 tirion->GetMotionMaster()->MovePoint(4, me->GetPositionX() + 2.0f * cos(o), me->GetPositionY() + 2.0f * std::sin(o), me->GetPositionZ(), false);
1057 tirion->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE);
1058 tirion->SetFaction(FACTION_FRIENDLY);
1059 }
1060 break;
1063 tirion->CastSpell(me, SPELL_LAY_ON_HANDS, false);
1065 break;
1068 {
1069 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN60);
1070 tirion->SetWalk(true);
1071 }
1072 break;
1075 tirion->GetMotionMaster()->MovePoint(4, LightOfDawnPos[14].GetPositionX(), LightOfDawnPos[14].GetPositionY(), LightOfDawnPos[14].GetPositionZ());
1076 break;
1079 tirion->GetMotionMaster()->MovePoint(4, LightOfDawnPos[15].GetPositionX(), LightOfDawnPos[15].GetPositionY(), LightOfDawnPos[15].GetPositionZ());
1080 break;
1083 {
1084 tirion->SetFacingToObject(me);
1085 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN61);
1086 }
1087 break;
1090 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN62);
1091
1092 events.Reset();
1093 events.ScheduleEvent(EVENT_OUTRO_SCENE_54, 6s);
1094 events.ScheduleEvent(EVENT_OUTRO_SCENE_55, 14s);
1095 events.ScheduleEvent(EVENT_OUTRO_SCENE_56, 27s);
1096 events.ScheduleEvent(EVENT_OUTRO_SCENE_57, 37s);
1097 events.ScheduleEvent(EVENT_OUTRO_SCENE_58, 44s);
1098 events.ScheduleEvent(EVENT_OUTRO_SCENE_59, 50s);
1099 events.ScheduleEvent(EVENT_OUTRO_SCENE_60, 63s);
1100 events.ScheduleEvent(EVENT_OUTRO_SCENE_61, 150s);
1101 break;
1104 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN63);
1105 break;
1108 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN64);
1109 break;
1112 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN65);
1113 break;
1116 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN66);
1117 break;
1120 tirion->AI()->Talk(SAY_LIGHT_OF_DAWN67);
1121 break;
1125 break;
1127 {
1128 Map::PlayerList const& PlayerList = me->GetMap()->GetPlayers();
1129 if (!PlayerList.IsEmpty())
1130 {
1131 for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
1132 if (i->GetSource()->IsAlive() && me->IsWithinDistInMap(i->GetSource(), 100))
1133 i->GetSource()->CastSpell(i->GetSource(), SPELL_THE_LIGHT_OF_DAWN_Q, false);
1134 }
1136 break;
1137 }
1141 events.Reset();
1142 return;
1143 }
1144
1146 return;
1147
1148 if (!UpdateVictim())
1149 return;
1150
1151 switch (eventId)
1152 {
1155 events.RescheduleEvent(eventId, 25s, 30s);
1156 break;
1159 events.RescheduleEvent(eventId, 5s, 10s);
1160 break;
1163 events.RescheduleEvent(eventId, 15s, 20s);
1164 break;
1167 events.RescheduleEvent(eventId, 60s);
1168 break;
1169 case EVENT_SPELL_TALK:
1171 events.RescheduleEvent(eventId, 15s, 20s);
1172 break;
1173 }
1174
1176 }
std::uint8_t uint8
Definition: Define.h:109
std::uint32_t uint32
Definition: Define.h:107
@ EQUIP_UNEQUIP
Definition: CreatureAI.h:67
@ UNIT_STAND_STATE_DEAD
Definition: UnitDefines.h:39
@ UNIT_STAND_STATE_KNEEL
Definition: UnitDefines.h:40
@ UNIT_NPC_FLAG_NONE
Definition: UnitDefines.h:293
@ UNIT_FLAG_NOT_SELECTABLE
Definition: UnitDefines.h:254
@ UNIT_VIRTUAL_ITEM_SLOT_ID
Definition: UpdateFields.h:116
@ TEMPSUMMON_MANUAL_DESPAWN
Definition: Object.h:52
@ TEMPSUMMON_CORPSE_DESPAWN
Definition: Object.h:49
@ GO_LIGHT_OF_DAWN
Definition: chapter5.cpp:246
@ SPELL_TIRION_CHARGE
Definition: chapter5.cpp:274
@ SPELL_DEATH_EMBRACE
Definition: chapter5.cpp:259
@ SPELL_MOGRAINE_CHARGE
Definition: chapter5.cpp:268
@ SPELL_DEATH_STRIKE
Definition: chapter5.cpp:258
@ SPELL_THE_MIGHT_OF_MOGRAINE
Definition: chapter5.cpp:254
@ SPELL_SOUL_FEAST_TIRION
Definition: chapter5.cpp:270
@ SPELL_UNHOLY_BLIGHT
Definition: chapter5.cpp:261
@ SPELL_ICEBOUND_VISAGE
Definition: chapter5.cpp:266
@ SPELL_EXIT_TELEPORT_VISUAL
Definition: chapter5.cpp:275
@ SPELL_CAMERA_SHAKE_INIT
Definition: chapter5.cpp:252
@ SPELL_APOCALYPSE
Definition: chapter5.cpp:271
@ SPELL_ANTI_MAGIC_ZONE1
Definition: chapter5.cpp:257
@ SPELL_CAMERA_SHAKE
Definition: chapter5.cpp:253
@ SPELL_LAY_ON_HANDS
Definition: chapter5.cpp:276
@ SPELL_THROW_ASHBRINGER
Definition: chapter5.cpp:272
@ SPELL_SOUL_FEAST_ALEX
Definition: chapter5.cpp:267
@ SPELL_REBIRTH_OF_THE_ASHBRINGER
Definition: chapter5.cpp:273
@ SPELL_THE_LIGHT_OF_DAWN_Q
Definition: chapter5.cpp:277
@ SPELL_ALEXANDROS_MOGRAINE_SPAWN
Definition: chapter5.cpp:265
@ SPELL_REBUKE
Definition: chapter5.cpp:269
@ EVENT_OUTRO_SCENE_38
Definition: chapter5.cpp:168
@ EVENT_OUTRO_SCENE_23
Definition: chapter5.cpp:153
@ EVENT_OUTRO_SCENE_25
Definition: chapter5.cpp:155
@ EVENT_OUTRO_SCENE_30
Definition: chapter5.cpp:160
@ EVENT_OUTRO_SCENE_32
Definition: chapter5.cpp:162
@ EVENT_OUTRO_SCENE_60
Definition: chapter5.cpp:190
@ EVENT_OUTRO_SCENE_35
Definition: chapter5.cpp:165
@ EVENT_OUTRO_SCENE_55
Definition: chapter5.cpp:185
@ EVENT_OUTRO_SCENE_24
Definition: chapter5.cpp:154
@ EVENT_OUTRO_SCENE_61
Definition: chapter5.cpp:191
@ EVENT_OUTRO_SCENE_59
Definition: chapter5.cpp:189
@ EVENT_OUTRO_SCENE_40
Definition: chapter5.cpp:170
@ EVENT_OUTRO_SCENE_51
Definition: chapter5.cpp:181
@ EVENT_OUTRO_SCENE_36
Definition: chapter5.cpp:166
@ EVENT_OUTRO_SCENE_21
Definition: chapter5.cpp:151
@ EVENT_OUTRO_SCENE_48
Definition: chapter5.cpp:178
@ EVENT_OUTRO_SCENE_34
Definition: chapter5.cpp:164
@ EVENT_OUTRO_SCENE_29
Definition: chapter5.cpp:159
@ EVENT_OUTRO_SCENE_33
Definition: chapter5.cpp:163
@ EVENT_OUTRO_SCENE_57
Definition: chapter5.cpp:187
@ EVENT_OUTRO_SCENE_43
Definition: chapter5.cpp:173
@ ACTION_POSITION_NPCS
Definition: chapter5.cpp:195
@ EVENT_OUTRO_SCENE_47
Definition: chapter5.cpp:177
@ EVENT_OUTRO_SCENE_31
Definition: chapter5.cpp:161
@ EVENT_OUTRO_SCENE_58
Definition: chapter5.cpp:188
@ EVENT_OUTRO_SCENE_46
Definition: chapter5.cpp:176
@ EVENT_OUTRO_SCENE_52
Definition: chapter5.cpp:182
@ EVENT_OUTRO_SCENE_20
Definition: chapter5.cpp:150
@ EVENT_OUTRO_SCENE_26
Definition: chapter5.cpp:156
@ ACTION_PLAY_EMOTE
Definition: chapter5.cpp:194
@ EVENT_OUTRO_SCENE_22
Definition: chapter5.cpp:152
@ EVENT_OUTRO_SCENE_37
Definition: chapter5.cpp:167
@ EVENT_OUTRO_SCENE_56
Definition: chapter5.cpp:186
@ EVENT_OUTRO_SCENE_45
Definition: chapter5.cpp:175
@ EVENT_OUTRO_SCENE_54
Definition: chapter5.cpp:184
@ EVENT_OUTRO_SCENE_44
Definition: chapter5.cpp:174
@ EVENT_OUTRO_SCENE_49
Definition: chapter5.cpp:179
@ EVENT_OUTRO_SCENE_53
Definition: chapter5.cpp:183
@ EVENT_OUTRO_SCENE_27
Definition: chapter5.cpp:157
@ EVENT_OUTRO_SCENE_28
Definition: chapter5.cpp:158
@ EVENT_OUTRO_SCENE_42
Definition: chapter5.cpp:172
@ EVENT_OUTRO_SCENE_41
Definition: chapter5.cpp:171
@ EVENT_OUTRO_SCENE_39
Definition: chapter5.cpp:169
@ EVENT_OUTRO_SCENE_50
Definition: chapter5.cpp:180
@ SAY_LIGHT_OF_DAWN27
Definition: chapter5.cpp:38
@ SAY_LIGHT_OF_DAWN59
Definition: chapter5.cpp:70
@ SAY_LIGHT_OF_DAWN53
Definition: chapter5.cpp:64
@ SAY_LIGHT_OF_DAWN38
Definition: chapter5.cpp:49
@ SAY_LIGHT_OF_DAWN49
Definition: chapter5.cpp:60
@ SAY_LIGHT_OF_DAWN32
Definition: chapter5.cpp:43
@ SAY_LIGHT_OF_DAWN52
Definition: chapter5.cpp:63
@ SAY_LIGHT_OF_DAWN37
Definition: chapter5.cpp:48
@ SAY_LIGHT_OF_DAWN09
Definition: chapter5.cpp:35
@ SAY_LIGHT_OF_DAWN42
Definition: chapter5.cpp:53
@ SAY_LIGHT_OF_DAWN02
Definition: chapter5.cpp:28
@ SAY_LIGHT_OF_DAWN04
Definition: chapter5.cpp:30
@ SAY_LIGHT_OF_DAWN67
Definition: chapter5.cpp:78
@ EMOTE_LIGHT_OF_DAWN08
Definition: chapter5.cpp:88
@ SAY_LIGHT_OF_DAWN29
Definition: chapter5.cpp:40
@ SAY_LIGHT_OF_DAWN56
Definition: chapter5.cpp:67
@ SAY_LIGHT_OF_DAWN61
Definition: chapter5.cpp:72
@ SAY_LIGHT_OF_DAWN47
Definition: chapter5.cpp:58
@ SAY_LIGHT_OF_DAWN54
Definition: chapter5.cpp:65
@ SAY_LIGHT_OF_DAWN26
Definition: chapter5.cpp:37
@ SAY_LIGHT_OF_DAWN06
Definition: chapter5.cpp:32
@ SAY_LIGHT_OF_DAWN41
Definition: chapter5.cpp:52
@ SAY_LIGHT_OF_DAWN68
Definition: chapter5.cpp:79
@ SAY_LIGHT_OF_DAWN31
Definition: chapter5.cpp:42
@ SAY_LIGHT_OF_DAWN64
Definition: chapter5.cpp:75
@ SAY_LIGHT_OF_DAWN58
Definition: chapter5.cpp:69
@ SAY_LIGHT_OF_DAWN44
Definition: chapter5.cpp:55
@ SAY_LIGHT_OF_DAWN46
Definition: chapter5.cpp:57
@ EMOTE_LIGHT_OF_DAWN04
Definition: chapter5.cpp:84
@ SAY_LIGHT_OF_DAWN35
Definition: chapter5.cpp:46
@ SAY_LIGHT_OF_DAWN62
Definition: chapter5.cpp:73
@ SAY_LIGHT_OF_DAWN65
Definition: chapter5.cpp:76
@ SAY_LIGHT_OF_DAWN28
Definition: chapter5.cpp:39
@ SAY_LIGHT_OF_DAWN34
Definition: chapter5.cpp:45
@ SAY_LIGHT_OF_DAWN33
Definition: chapter5.cpp:44
@ SAY_LIGHT_OF_DAWN40
Definition: chapter5.cpp:51
@ SAY_LIGHT_OF_DAWN55
Definition: chapter5.cpp:66
@ SAY_LIGHT_OF_DAWN30
Definition: chapter5.cpp:41
@ SAY_LIGHT_OF_DAWN45
Definition: chapter5.cpp:56
@ SAY_LIGHT_OF_DAWN57
Definition: chapter5.cpp:68
@ SAY_LIGHT_OF_DAWN43
Definition: chapter5.cpp:54
@ SAY_LIGHT_OF_DAWN36
Definition: chapter5.cpp:47
@ SAY_LIGHT_OF_DAWN48
Definition: chapter5.cpp:59
@ EMOTE_LIGHT_OF_DAWN12
Definition: chapter5.cpp:92
@ SAY_LIGHT_OF_DAWN60
Definition: chapter5.cpp:71
@ SAY_LIGHT_OF_DAWN39
Definition: chapter5.cpp:50
@ SAY_LIGHT_OF_DAWN51
Definition: chapter5.cpp:62
@ SAY_LIGHT_OF_DAWN05
Definition: chapter5.cpp:31
@ SAY_LIGHT_OF_DAWN66
Definition: chapter5.cpp:77
@ SAY_LIGHT_OF_DAWN63
Definition: chapter5.cpp:74
@ NPC_THE_LICH_KING
Definition: chapter5.cpp:240
@ NPC_FLESH_BEHEMOTH
Definition: chapter5.cpp:229
@ NPC_ORBAZ_BLOODBANE
Definition: chapter5.cpp:233
@ NPC_DARION_MOGRAINE
Definition: chapter5.cpp:239
@ NPC_ACHERUS_GHOUL
Definition: chapter5.cpp:227
@ NPC_WARRIOR_OF_THE_FROZEN_WASTES
Definition: chapter5.cpp:228
@ NPC_THASSARIAN
Definition: chapter5.cpp:234
@ NPC_RIMBLAT_EARTHSHATTER
Definition: chapter5.cpp:223
@ NPC_HIGHLORD_ALEXANDROS_MOGRAINE
Definition: chapter5.cpp:238
@ NPC_KOLTIRA_DEATHWEAVER
Definition: chapter5.cpp:232
@ EMOTE_ONESHOT_LAUGH
Definition: SharedDefines.h:1903
@ EMOTE_ONESHOT_ROAR
Definition: SharedDefines.h:1907
@ EMOTE_STATE_READY2H
Definition: SharedDefines.h:1970
@ EMOTE_ONESHOT_NONE
Definition: SharedDefines.h:1894
@ FACTION_FRIENDLY
Definition: SharedDefines.h:201
void DoMeleeAttackIfReady()
Definition: UnitAI.cpp:39
SpellCastResult DoCastVictim(uint32 spellId, bool triggered=false)
Definition: UnitAI.cpp:240
SpellCastResult DoCast(uint32 spellId)
Definition: UnitAI.cpp:177
bool UpdateVictim()
Definition: CreatureAI.cpp:269
void DespawnEntry(uint32 entry)
Definition: ScriptedCreature.cpp:54
void DoAction(int32 info, uint16 max=0)
Definition: ScriptedCreature.h:102
void ClearAllThreat()
Definition: ThreatMgr.cpp:417
void SetHomePosition(float x, float y, float z, float o)
Definition: Creature.h:337
void DespawnOrUnsummon(Milliseconds msTimeToDespawn, Seconds forcedRespawnTimer)
Definition: Creature.cpp:2173
bool IsWithinDistInMap(WorldObject const *obj, float dist2compare, bool is3D=true, bool useBoundingRadius=true) const
Definition: Object.cpp:1321
float GetOrientation() const
Definition: Position.h:120
float GetAngle(const Position *pos) const
Definition: Position.cpp:77
void SetFacingTo(float ori)
Definition: Unit.cpp:20483
void CombatStop(bool includingCast=false)
Definition: Unit.cpp:10398
static void Kill(Unit *killer, Unit *victim, bool durabilityLoss=true, WeaponAttackType attackType=BASE_ATTACK, SpellInfo const *spellProto=nullptr, Spell const *spell=nullptr)
Definition: Unit.cpp:17658
void SetFacingToObject(WorldObject *object)
Definition: Unit.cpp:20493
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:1168
void RemoveAllAuras()
Definition: Unit.cpp:5290
ThreatMgr & GetThreatMgr()
Definition: Unit.h:839
void MovePoint(uint32 id, const Position &pos, bool generatePath=true, bool forceDestination=true)
Definition: MotionMaster.h:211
void Clear(bool reset=true)
Definition: MotionMaster.h:165
Creature * GetEntryFromSummons(uint32 entry)
Definition: chapter5.cpp:566

References ACTION_PLAY_EMOTE, ACTION_POSITION_NPCS, battleStarted, SummonList::begin(), MapRefMgr::begin(), Unit::CastSpell(), MotionMaster::Clear(), ThreatMgr::ClearAllThreat(), Unit::CombatStop(), SummonList::DespawnAll(), SummonList::DespawnEntry(), Creature::DespawnOrUnsummon(), SummonList::DoAction(), UnitAI::DoCast(), UnitAI::DoCastVictim(), UnitAI::DoMeleeAttackIfReady(), EMOTE_LIGHT_OF_DAWN04, EMOTE_LIGHT_OF_DAWN08, EMOTE_LIGHT_OF_DAWN12, EMOTE_ONESHOT_LAUGH, EMOTE_ONESHOT_NONE, EMOTE_ONESHOT_ROAR, EMOTE_STATE_READY2H, ENCOUNTER_STATE_FIGHT, ENCOUNTER_STATE_OUTRO, SummonList::end(), MapRefMgr::end(), EQUIP_UNEQUIP, EVENT_FINISH_FIGHT_1, EVENT_FINISH_FIGHT_2, EVENT_FINISH_FIGHT_3, EVENT_FINISH_FIGHT_4, EVENT_FINISH_FIGHT_5, EVENT_OUTRO_SCENE_1, EVENT_OUTRO_SCENE_10, EVENT_OUTRO_SCENE_11, EVENT_OUTRO_SCENE_12, EVENT_OUTRO_SCENE_13, EVENT_OUTRO_SCENE_14, EVENT_OUTRO_SCENE_15, EVENT_OUTRO_SCENE_16, EVENT_OUTRO_SCENE_17, EVENT_OUTRO_SCENE_18, EVENT_OUTRO_SCENE_19, EVENT_OUTRO_SCENE_2, EVENT_OUTRO_SCENE_20, EVENT_OUTRO_SCENE_21, EVENT_OUTRO_SCENE_22, EVENT_OUTRO_SCENE_23, EVENT_OUTRO_SCENE_24, EVENT_OUTRO_SCENE_25, EVENT_OUTRO_SCENE_26, EVENT_OUTRO_SCENE_27, EVENT_OUTRO_SCENE_28, EVENT_OUTRO_SCENE_29, EVENT_OUTRO_SCENE_3, EVENT_OUTRO_SCENE_30, EVENT_OUTRO_SCENE_31, EVENT_OUTRO_SCENE_32, EVENT_OUTRO_SCENE_33, EVENT_OUTRO_SCENE_34, EVENT_OUTRO_SCENE_35, EVENT_OUTRO_SCENE_36, EVENT_OUTRO_SCENE_37, EVENT_OUTRO_SCENE_38, EVENT_OUTRO_SCENE_39, EVENT_OUTRO_SCENE_4, EVENT_OUTRO_SCENE_40, EVENT_OUTRO_SCENE_41, EVENT_OUTRO_SCENE_42, EVENT_OUTRO_SCENE_43, EVENT_OUTRO_SCENE_44, EVENT_OUTRO_SCENE_45, EVENT_OUTRO_SCENE_46, EVENT_OUTRO_SCENE_47, EVENT_OUTRO_SCENE_48, EVENT_OUTRO_SCENE_49, EVENT_OUTRO_SCENE_5, EVENT_OUTRO_SCENE_50, EVENT_OUTRO_SCENE_51, EVENT_OUTRO_SCENE_52, EVENT_OUTRO_SCENE_53, EVENT_OUTRO_SCENE_54, EVENT_OUTRO_SCENE_55, EVENT_OUTRO_SCENE_56, EVENT_OUTRO_SCENE_57, EVENT_OUTRO_SCENE_58, EVENT_OUTRO_SCENE_59, EVENT_OUTRO_SCENE_6, EVENT_OUTRO_SCENE_60, EVENT_OUTRO_SCENE_61, EVENT_OUTRO_SCENE_7, EVENT_OUTRO_SCENE_8, EVENT_OUTRO_SCENE_9, EVENT_SPELL_ANTI_MAGIC_ZONE, EVENT_SPELL_DEATH_EMBRACE, EVENT_SPELL_DEATH_STRIKE, EVENT_SPELL_TALK, EVENT_SPELL_UNHOLY_BLIGHT, EVENT_START_COUNTDOWN_1, EVENT_START_COUNTDOWN_10, EVENT_START_COUNTDOWN_11, EVENT_START_COUNTDOWN_12, EVENT_START_COUNTDOWN_13, EVENT_START_COUNTDOWN_14, EVENT_START_COUNTDOWN_2, EVENT_START_COUNTDOWN_3, EVENT_START_COUNTDOWN_4, EVENT_START_COUNTDOWN_5, EVENT_START_COUNTDOWN_6, EVENT_START_COUNTDOWN_7, EVENT_START_COUNTDOWN_8, EVENT_START_COUNTDOWN_9, FACTION_FRIENDLY, Position::GetAngle(), ObjectAccessor::GetCreature(), GetEntryFromSummons(), WorldObject::GetMap(), Unit::GetMotionMaster(), Position::GetOrientation(), Map::GetPlayers(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), Unit::GetThreatMgr(), GO_LIGHT_OF_DAWN, LinkedListHead::IsEmpty(), WorldObject::IsWithinDistInMap(), Unit::Kill(), LightOfDawnPos, ScriptedAI::me, MotionMaster::MoveCharge(), MotionMaster::MovePoint(), NPC_ACHERUS_GHOUL, NPC_DARION_MOGRAINE, NPC_DEFENDER_OF_THE_LIGHT, NPC_FLESH_BEHEMOTH, NPC_HIGHLORD_ALEXANDROS_MOGRAINE, NPC_HIGHLORD_TIRION_FORDRING, NPC_KOLTIRA_DEATHWEAVER, NPC_ORBAZ_BLOODBANE, NPC_RAMPAGING_ABOMINATION, NPC_RIMBLAT_EARTHSHATTER, NPC_THASSARIAN, NPC_THE_LICH_KING, NPC_WARRIOR_OF_THE_FROZEN_WASTES, REACT_PASSIVE, Unit::RemoveAllAuras(), Unit::ReplaceAllNpcFlags(), SAY_LIGHT_OF_DAWN02, SAY_LIGHT_OF_DAWN04, SAY_LIGHT_OF_DAWN05, SAY_LIGHT_OF_DAWN06, SAY_LIGHT_OF_DAWN09, SAY_LIGHT_OF_DAWN26, SAY_LIGHT_OF_DAWN27, SAY_LIGHT_OF_DAWN28, SAY_LIGHT_OF_DAWN29, SAY_LIGHT_OF_DAWN30, SAY_LIGHT_OF_DAWN31, SAY_LIGHT_OF_DAWN32, SAY_LIGHT_OF_DAWN33, SAY_LIGHT_OF_DAWN34, SAY_LIGHT_OF_DAWN35, SAY_LIGHT_OF_DAWN36, SAY_LIGHT_OF_DAWN37, SAY_LIGHT_OF_DAWN38, SAY_LIGHT_OF_DAWN39, SAY_LIGHT_OF_DAWN40, SAY_LIGHT_OF_DAWN41, SAY_LIGHT_OF_DAWN42, SAY_LIGHT_OF_DAWN43, SAY_LIGHT_OF_DAWN44, SAY_LIGHT_OF_DAWN45, SAY_LIGHT_OF_DAWN46, SAY_LIGHT_OF_DAWN47, SAY_LIGHT_OF_DAWN48, SAY_LIGHT_OF_DAWN49, SAY_LIGHT_OF_DAWN51, SAY_LIGHT_OF_DAWN52, SAY_LIGHT_OF_DAWN53, SAY_LIGHT_OF_DAWN54, SAY_LIGHT_OF_DAWN55, SAY_LIGHT_OF_DAWN56, SAY_LIGHT_OF_DAWN57, SAY_LIGHT_OF_DAWN58, SAY_LIGHT_OF_DAWN59, SAY_LIGHT_OF_DAWN60, SAY_LIGHT_OF_DAWN61, SAY_LIGHT_OF_DAWN62, SAY_LIGHT_OF_DAWN63, SAY_LIGHT_OF_DAWN64, SAY_LIGHT_OF_DAWN65, SAY_LIGHT_OF_DAWN66, SAY_LIGHT_OF_DAWN67, SAY_LIGHT_OF_DAWN68, SendUpdateWorldState(), Unit::SetFacingTo(), Unit::SetFacingToObject(), Creature::SetHomePosition(), Unit::SetImmuneToAll(), Creature::SetReactState(), Unit::SetStandState(), Unit::SetUInt32Value(), Creature::SetWalk(), SPELL_ALEXANDROS_MOGRAINE_SPAWN, SPELL_ANTI_MAGIC_ZONE1, SPELL_APOCALYPSE, SPELL_CAMERA_SHAKE, SPELL_CAMERA_SHAKE_INIT, SPELL_DEATH_EMBRACE, SPELL_DEATH_STRIKE, SPELL_EXIT_TELEPORT_VISUAL, SPELL_ICEBOUND_VISAGE, SPELL_LAY_ON_HANDS, SPELL_MOGRAINE_CHARGE, SPELL_REBIRTH_OF_THE_ASHBRINGER, SPELL_REBUKE, SPELL_SOUL_FEAST_ALEX, SPELL_SOUL_FEAST_TIRION, SPELL_THE_LIGHT_OF_DAWN, SPELL_THE_LIGHT_OF_DAWN_Q, SPELL_THE_MIGHT_OF_MOGRAINE, SPELL_THROW_ASHBRINGER, SPELL_TIRION_CHARGE, SPELL_UNHOLY_BLIGHT, WorldObject::SummonCreature(), WorldObject::SummonCreatureGroup(), summons, TEMPSUMMON_CORPSE_DESPAWN, TEMPSUMMON_MANUAL_DESPAWN, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, UNIT_FLAG_NOT_SELECTABLE, UNIT_NPC_EMOTESTATE, UNIT_NPC_FLAG_GOSSIP, UNIT_NPC_FLAG_NONE, UNIT_NPC_FLAG_QUESTGIVER, UNIT_STAND_STATE_DEAD, UNIT_STAND_STATE_KNEEL, UNIT_STAND_STATE_STAND, UNIT_VIRTUAL_ITEM_SLOT_ID, CreatureAI::UpdateVictim(), WORLD_STATE_COUNTDOWN_ENABLE, WORLD_STATE_COUNTDOWN_TIME, and WORLD_STATE_EVENT_BEGIN_ENABLE.

Member Data Documentation

◆ battleStarted

uint8 npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::battleStarted

◆ defendersRemaining

uint32 npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::defendersRemaining

◆ events

EventMap npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::events

◆ resetExecuted

bool npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::resetExecuted

◆ scourgeRemaining

uint32 npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::scourgeRemaining

◆ startTimeRemaining

uint32 npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::startTimeRemaining

Referenced by DoAction(), GetData(), and JustRespawned().

◆ summons

SummonList npc_highlord_darion_mograine::npc_highlord_darion_mograineAI::summons