TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
npc_arthas::npc_arthasAI Struct Reference

Public Member Functions

 npc_arthasAI (Creature *creature)
 
void Initialize ()
 
void Reset () override
 
void AttackStart (Unit *who) override
 
void EnterCombat (Unit *) override
 
void JustDied (Unit *) override
 
void SpawnTimeRift (uint32 timeRiftID, ObjectGuid *guidVector)
 
void SpawnWaveGroup (uint32 waveID, ObjectGuid *guidVector)
 
void SetHoldState (bool bOnHold)
 
void JumpToNextStep (uint32 uiTimer)
 
void WaypointReached (uint32 waypointId) override
 
void UpdateAI (uint32 diff) override
 
- Public Member Functions inherited from npc_escortAI
 npc_escortAI (Creature *creature)
 
 ~npc_escortAI ()
 
void MoveInLineOfSight (Unit *who) override
 
void JustRespawned () override
 
void ReturnToLastPoint ()
 
void EnterEvadeMode (EvadeReason=EVADE_REASON_OTHER) override
 
virtual void UpdateEscortAI (uint32 diff)
 
void MovementInform (uint32, uint32) override
 
void AddWaypoint (uint32 id, float x, float y, float z, uint32 waitTime=0)
 
bool SetNextWaypoint (uint32 pointId, float x, float y, float z, float orientation)
 
bool SetNextWaypoint (uint32 pointId, bool setPosition=true, bool resetWaypointsOnFail=true)
 
bool GetWaypointPosition (uint32 pointId, float &x, float &y, float &z)
 
virtual void WaypointStart (uint32)
 
void Start (bool isActiveAttacker=true, bool run=false, ObjectGuid playerGUID=ObjectGuid::Empty, Quest const *quest=NULL, bool instantRespawn=false, bool canLoopPath=false, bool resetWaypoints=true)
 
void SetRun (bool on=true)
 
void SetEscortPaused (bool on)
 
bool HasEscortState (uint32 escortState)
 
virtual bool IsEscorted () const override
 
void SetMaxPlayerDistance (float newMax)
 
float GetMaxPlayerDistance () const
 
void SetDespawnAtEnd (bool despawn)
 
void SetDespawnAtFar (bool despawn)
 
bool GetAttack () const
 
void SetCanAttack (bool attack)
 
ObjectGuid GetEventStarterGUID () const
 
- Public Member Functions inherited from ScriptedAI
 ScriptedAI (Creature *creature)
 
virtual ~ScriptedAI ()
 
void AttackStartNoMove (Unit *target)
 
void DamageTaken (Unit *, uint32 &) 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 OnPossess (bool)
 
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 DoResetThreat ()
 
float DoGetThreat (Unit *unit)
 
void DoModifyThreatPercent (Unit *unit, int32 pct)
 
void DoTeleportTo (float x, float y, float z, uint32 time=0)
 
void DoTeleportTo (float const pos[4])
 
void DoTeleportPlayer (Unit *unit, float x, float y, float z, float o)
 
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 HealthBelowPct (uint32 pct) const
 
bool HealthAbovePct (uint32 pct) const
 
SpellInfo constSelectSpell (Unit *target, uint32 school, uint32 mechanic, SelectTargetType targets, 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)
 
void SetCombatMovement (bool allowMovement)
 
bool IsCombatMovementAllowed () 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
 
- Public Member Functions inherited from CreatureAI
void Talk (uint8 id, WorldObject const *whisperTarget=nullptr)
 
 CreatureAI (Creature *creature)
 
virtual ~CreatureAI ()
 
void MoveInLineOfSight_Safe (Unit *who)
 == Reactions At ================================= More...
 
void TriggerAlert (Unit const *who) const
 
virtual bool CanRespawn ()
 
virtual void IsSummonedBy (Unit *)
 
virtual void SummonedCreatureDies (Creature *, Unit *)
 
virtual void AttackedBy (Unit *)
 
void OnCharmed (bool apply) override
 
virtual void JustReachedHome ()
 
void DoZoneInCombat (Creature *creature=NULL, float maxRangeToNearestTarget=50.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 void OnSpellClick (Unit *, bool &)
 
virtual bool CanSeeAlways (WorldObject const *)
 
int32 VisualizeBoundary (uint32 duration, Unit *owner=nullptr, bool fill=false) const
 
virtual bool CheckInRoom ()
 
CreatureBoundary constGetBoundary () const
 
- 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 SetData (uint32, uint32)
 
virtual void SetGUID (ObjectGuid, int32=0)
 
virtual ObjectGuid GetGUID (int32=0) const
 
UnitSelectTarget (SelectAggroTarget targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, int32 aura=0)
 
template<class PREDICATE >
UnitSelectTarget (SelectAggroTarget targetType, uint32 position, PREDICATE const &predicate)
 
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectAggroTarget targetType, float dist=0.0f, bool playerOnly=false, int32 aura=0)
 
template<class PREDICATE >
void SelectTargetList (std::list< Unit * > &targetList, PREDICATE const &predicate, uint32 maxTargets, SelectAggroTarget targetType)
 
virtual void DamageDealt (Unit *, uint32 &, DamageEffectType)
 
virtual void HealReceived (Unit *, uint32 &)
 
virtual void HealDone (Unit *, uint32 &)
 
virtual void SpellInterrupted (uint32, uint32)
 
void AttackStartCaster (Unit *victim, float dist)
 
void DoCast (uint32 spellId)
 
void DoCast (Unit *victim, uint32 spellId, bool triggered=false)
 
void DoCastVictim (uint32 spellId, bool triggered=false)
 
void DoCastAOE (uint32 spellId, bool triggered=false)
 
void DoMeleeAttackIfReady ()
 
bool DoSpellAttackIfReady (uint32 spellId)
 
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 sQuestReward (Player *, Quest const *, uint32)
 
virtual bool sOnDummyEffect (Unit *, uint32, SpellEffIndex)
 
virtual void sOnGameEvent (bool, uint16)
 

Public Attributes

InstanceScriptinstance
 
bool bStepping
 
uint32 step
 
uint32 phaseTimer
 
uint32 gossipStep
 
uint32 bossEvent
 
uint32 wave
 
uint32 WavesCounter
 
ObjectGuid utherGUID
 
ObjectGuid jainaGUID
 
ObjectGuid citymenGUID [2]
 
ObjectGuid waveGUID [ENCOUNTER_WAVES_MAX_SPAWNS]
 
ObjectGuid infiniteDraconianGUID [ENCOUNTER_DRACONIAN_NUMBER]
 
ObjectGuid stalkerGUID
 
ObjectGuid bossGUID
 
ObjectGuid epochGUID
 
ObjectGuid malganisGUID
 
ObjectGuid infiniteGUID
 
uint32 exorcismTimer
 
- Public Attributes inherited from ScriptedAI
bool IsFleeing
 

Additional Inherited Members

- Public Types inherited from CreatureAI
enum  EvadeReason { EVADE_REASON_NO_HOSTILES, EVADE_REASON_BOUNDARY, EVADE_REASON_SEQUENCE_BREAK, EVADE_REASON_OTHER }
 
- Static Public Member Functions inherited from UnitAI
static void FillAISpellInfo ()
 
- Static Public Attributes inherited from UnitAI
static AISpellInfoTypeAISpellInfo
 
- Protected Member Functions inherited from npc_escortAI
PlayerGetPlayerForEscort ()
 
- 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)
 
bool CheckBoundary (Position const *who=nullptr) const
 
void SetBoundary (CreatureBoundary const *boundary)
 
bool _EnterEvadeMode (EvadeReason why=EVADE_REASON_OTHER)
 
- Protected Attributes inherited from CreatureAI
Creature *const me
 
CreatureBoundary const_boundary
 
- Protected Attributes inherited from UnitAI
Unit *const me
 

Constructor & Destructor Documentation

npc_arthas::npc_arthasAI::npc_arthasAI ( Creature creature)
inline
351  : npc_escortAI(creature)
352  {
353  Initialize();
354  instance = creature->GetInstanceScript();
355  bStepping = false;
356  step = 0;
357  gossipStep = 0;
358  bossEvent = 0;
359  WavesCounter = 0;
360  }
npc_escortAI(Creature *creature)
Definition: ScriptedEscortAI.cpp:37
InstanceScript * GetInstanceScript()
Definition: Object.cpp:1540
uint32 step
Definition: culling_of_stratholme.cpp:390
bool bStepping
Definition: culling_of_stratholme.cpp:389
uint32 WavesCounter
Definition: culling_of_stratholme.cpp:395
uint32 bossEvent
Definition: culling_of_stratholme.cpp:393
uint32 gossipStep
Definition: culling_of_stratholme.cpp:392
InstanceScript * instance
Definition: culling_of_stratholme.cpp:387
void Initialize()
Definition: culling_of_stratholme.cpp:362

+ Here is the call graph for this function:

Member Function Documentation

void npc_arthas::npc_arthasAI::AttackStart ( Unit who)
inlineoverridevirtual

Reimplemented from npc_escortAI.

425  {
428  }
void AttackStart(Unit *who) override
Definition: ScriptedEscortAI.cpp:53
Definition: Unit.h:681
Definition: UpdateFields.h:109
bool HasFlag(uint16 index, uint32 flag) const
Definition: Object.cpp:1239

+ Here is the call graph for this function:

void npc_arthas::npc_arthasAI::EnterCombat ( Unit )
inlineoverridevirtual

Reimplemented from ScriptedAI.

431  {
433  }
Creature *const me
Definition: CreatureAI.h:71
void DoCast(uint32 spellId)
Definition: UnitAI.cpp:101
Definition: culling_of_stratholme.cpp:136

+ Here is the call graph for this function:

void npc_arthas::npc_arthasAI::Initialize ( void  )
inline
363  {
364  utherGUID.Clear();
365  jainaGUID.Clear();
366 
367  for (uint8 i = 0; i < 2; ++i)
368  citymenGUID[i].Clear();
369 
370  for (uint8 i = 0; i < ENCOUNTER_WAVES_MAX_SPAWNS; ++i)
371  waveGUID[i].Clear();
372 
373  for (uint8 i = 0; i < ENCOUNTER_DRACONIAN_NUMBER; ++i)
374  infiniteDraconianGUID[i].Clear();
375 
376  stalkerGUID.Clear();
377  bossGUID.Clear();
378  epochGUID.Clear();
381 
382  phaseTimer = 1000;
383  exorcismTimer = 7300;
384  wave = 0;
385  }
uint32 phaseTimer
Definition: culling_of_stratholme.cpp:391
Definition: culling_of_stratholme.cpp:156
ObjectGuid waveGUID[ENCOUNTER_WAVES_MAX_SPAWNS]
Definition: culling_of_stratholme.cpp:400
ObjectGuid stalkerGUID
Definition: culling_of_stratholme.cpp:402
Definition: culling_of_stratholme.cpp:155
ObjectGuid jainaGUID
Definition: culling_of_stratholme.cpp:398
ObjectGuid bossGUID
Definition: culling_of_stratholme.cpp:404
ObjectGuid infiniteGUID
Definition: culling_of_stratholme.cpp:407
uint32 wave
Definition: culling_of_stratholme.cpp:394
ObjectGuid epochGUID
Definition: culling_of_stratholme.cpp:405
ObjectGuid citymenGUID[2]
Definition: culling_of_stratholme.cpp:399
uint32 exorcismTimer
Definition: culling_of_stratholme.cpp:409
void Clear()
Definition: ObjectGuid.h:215
uint8_t uint8
Definition: Define.h:152
ObjectGuid infiniteDraconianGUID[ENCOUNTER_DRACONIAN_NUMBER]
Definition: culling_of_stratholme.cpp:401
ObjectGuid malganisGUID
Definition: culling_of_stratholme.cpp:406
ObjectGuid utherGUID
Definition: culling_of_stratholme.cpp:397

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void npc_arthas::npc_arthasAI::JumpToNextStep ( uint32  uiTimer)
inline
477  {
478  phaseTimer = uiTimer;
479  ++step;
480  }
uint32 phaseTimer
Definition: culling_of_stratholme.cpp:391
uint32 step
Definition: culling_of_stratholme.cpp:390

+ Here is the caller graph for this function:

void npc_arthas::npc_arthasAI::JustDied ( Unit )
inlineoverridevirtual

Reimplemented from npc_escortAI.

436  {
438  }
Definition: InstanceScript.h:60
Definition: culling_of_stratholme.h:27
virtual bool SetBossState(uint32 id, EncounterState state)
Definition: InstanceScript.cpp:273
InstanceScript * instance
Definition: culling_of_stratholme.cpp:387

+ Here is the call graph for this function:

void npc_arthas::npc_arthasAI::Reset ( )
inlineoverridevirtual

Reimplemented from ScriptedAI.

412  {
413  Initialize();
414 
416 
417  bStepping = true;
418  step = 0;
421  gossipStep = 0;
422  }
Definition: Unit.h:735
uint32 step
Definition: culling_of_stratholme.cpp:390
void SetFlag(uint16 index, uint32 newFlag)
Definition: Object.cpp:1199
Creature *const me
Definition: CreatureAI.h:71
Definition: culling_of_stratholme.h:27
bool bStepping
Definition: culling_of_stratholme.cpp:389
Definition: InstanceScript.h:58
uint32 bossEvent
Definition: culling_of_stratholme.cpp:393
virtual bool SetBossState(uint32 id, EncounterState state)
Definition: InstanceScript.cpp:273
Definition: UpdateFields.h:135
Definition: culling_of_stratholme.h:28
uint32 gossipStep
Definition: culling_of_stratholme.cpp:392
InstanceScript * instance
Definition: culling_of_stratholme.cpp:387
void Initialize()
Definition: culling_of_stratholme.cpp:362

+ Here is the call graph for this function:

void npc_arthas::npc_arthasAI::SetHoldState ( bool  bOnHold)
inline
472  {
473  SetEscortPaused(bOnHold);
474  }
void SetEscortPaused(bool on)
Definition: ScriptedEscortAI.cpp:507

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void npc_arthas::npc_arthasAI::SpawnTimeRift ( uint32  timeRiftID,
ObjectGuid guidVector 
)
inline
441  {
442  me->SummonCreature((uint32)RiftAndSpawnsLocations[timeRiftID][0], RiftAndSpawnsLocations[timeRiftID][1], RiftAndSpawnsLocations[timeRiftID][2], RiftAndSpawnsLocations[timeRiftID][3], RiftAndSpawnsLocations[timeRiftID][4], TEMPSUMMON_TIMED_DESPAWN, 11000);
443 
444  for (uint32 i = timeRiftID+1; i < ENCOUNTER_CHRONO_SPAWNS; ++i)
445  {
446  if ((uint32)RiftAndSpawnsLocations[i][0] == NPC_TIME_RIFT) break;
448  {
449  guidVector[i-timeRiftID-1] = temp->GetGUID();
451  temp->SetReactState(REACT_PASSIVE);
452  temp->GetMotionMaster()->MovePoint(0, RiftAndSpawnsLocations[i][1], RiftAndSpawnsLocations[i][2], RiftAndSpawnsLocations[i][3]);
454  epochGUID = temp->GetGUID();
455  }
456  }
457  }
Definition: culling_of_stratholme.cpp:157
Definition: Unit.h:1129
Definition: culling_of_stratholme.h:57
Definition: Creature.h:467
Definition: Unit.h:681
Creature *const me
Definition: CreatureAI.h:71
ObjectGuid epochGUID
Definition: culling_of_stratholme.cpp:405
Definition: Object.h:56
uint32_t uint32
Definition: Define.h:150
float RiftAndSpawnsLocations[ENCOUNTER_CHRONO_SPAWNS][5]
Definition: culling_of_stratholme.cpp:222
Definition: Unit.h:682
Definition: UpdateFields.h:109
Definition: culling_of_stratholme.h:46
TempSummon * SummonCreature(uint32 id, Position const &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0) const
Definition: Object.cpp:2346
Definition: Object.h:54

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void npc_arthas::npc_arthasAI::SpawnWaveGroup ( uint32  waveID,
ObjectGuid guidVector 
)
inline
460  {
461  for (uint32 i = 0; i < ENCOUNTER_WAVES_MAX_SPAWNS; ++i)
462  {
463  if ((uint32)WavesLocations[waveID][i][0] == 0) break;
464  if (Creature* temp = me->SummonCreature((uint32)WavesLocations[waveID][i][0], WavesLocations[waveID][i][1], WavesLocations[waveID][i][2], WavesLocations[waveID][i][3], WavesLocations[waveID][i][4], TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 900000))
465  {
466  guidVector[i] = temp->GetGUID();
467  }
468  }
469  }
Definition: culling_of_stratholme.cpp:155
Definition: Creature.h:467
float WavesLocations[ENCOUNTER_WAVES_NUMBER][ENCOUNTER_WAVES_MAX_SPAWNS][5]
Definition: culling_of_stratholme.cpp:161
Creature *const me
Definition: CreatureAI.h:71
uint32_t uint32
Definition: Define.h:150
TempSummon * SummonCreature(uint32 id, Position const &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0) const
Definition: Object.cpp:2346
Definition: Object.h:54

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void npc_arthas::npc_arthasAI::UpdateAI ( uint32  diff)
inlineoverridevirtual

Reimplemented from npc_escortAI.

601  {
603 
604  if (bStepping)
605  {
606  if (phaseTimer <= diff)
607  {
608  switch (step)
609  {
610  //After reset
611  case 0:
612  {
613  Unit* jaina = GetClosestCreatureWithEntry(me, NPC_JAINA, 50.0f);
614  if (!jaina)
615  jaina = me->SummonCreature(NPC_JAINA, 1895.48f, 1292.66f, 143.706f, 0.023475f, TEMPSUMMON_DEAD_DESPAWN, 180000);
616  if (jaina)
617  jainaGUID = jaina->GetGUID();
618  bStepping = false;
619  JumpToNextStep(0);
620  break;
621  }
622  //After waypoint 0
623  case 1:
624  me->SetWalk(false);
625  if (Unit* uther = me->SummonCreature(NPC_UTHER, 1794.357f, 1272.183f, 140.558f, 1.37f, TEMPSUMMON_DEAD_DESPAWN, 180000))
626  {
627  utherGUID = uther->GetGUID();
628  uther->SetWalk(false);
629  uther->GetMotionMaster()->MovePoint(0, 1897.018f, 1287.487f, 143.481f);
630  uther->SetTarget(me->GetGUID());
632  }
633  JumpToNextStep(17000);
634  break;
635  case 2:
637  JumpToNextStep(2000);
638  break;
639  case 3:
641  {
642  uther->AI()->Talk(SAY_PHASE102);
643  }
644  JumpToNextStep(8000);
645  break;
646  case 4:
647  SetEscortPaused(false);
648  bStepping = false;
649  SetRun(false);
651  JumpToNextStep(0);
652  break;
653  //After waypoint 1
654  case 5:
656  jaina->SetTarget(me->GetGUID());
658  JumpToNextStep(10000);
659  break;
660  case 6:
662  uther->AI()->Talk(SAY_PHASE105);
663  JumpToNextStep(1000);
664  break;
665  case 7:
667  JumpToNextStep(4000);
668  break;
669  case 8:
671  uther->AI()->Talk(SAY_PHASE107);
672  JumpToNextStep(6000);
673  break;
674  case 9:
676  JumpToNextStep(4000);
677  break;
678  case 10:
680  uther->AI()->Talk(SAY_PHASE109);
681  JumpToNextStep(8000);
682  break;
683  case 11:
685  JumpToNextStep(4000);
686  break;
687  case 12:
689  uther->AI()->Talk(SAY_PHASE111);
690  JumpToNextStep(4000);
691  break;
692  case 13:
694  JumpToNextStep(11000);
695  break;
696  case 14:
698  jaina->AI()->Talk(SAY_PHASE113);
699  JumpToNextStep(3000);
700  break;
701  case 15:
703  JumpToNextStep(9000);
704  break;
705  case 16:
707  uther->AI()->Talk(SAY_PHASE115);
708  JumpToNextStep(4000);
709  break;
710  case 17:
712  {
713  uther->SetWalk(true);
714  uther->GetMotionMaster()->MovePoint(0, 1794.357f, 1272.183f, 140.558f);
715  }
716  JumpToNextStep(1000);
717  break;
718  case 18:
720  {
722  jaina->SetWalk(true);
723  jaina->GetMotionMaster()->MovePoint(0, 1794.357f, 1272.183f, 140.558f);
724  }
725  JumpToNextStep(1000);
726  break;
727  case 19:
729  JumpToNextStep(1000);
730  break;
731  case 20:
733  jaina->AI()->Talk(SAY_PHASE117);
734  JumpToNextStep(3000);
735  break;
736  case 21:
737  SetEscortPaused(false);
738  bStepping = false;
740  JumpToNextStep(0);
741  break;
742  //After waypoint 3
743  case 22:
746  JumpToNextStep(10000);
747  break;
748  case 23:
749  SetEscortPaused(false);
750  bStepping = false;
751  SetRun(true);
752 
754  jaina->DisappearAndDie();
755 
757  uther->DisappearAndDie();
758 
760  JumpToNextStep(0);
761  break;
762  //After Gossip 1 (waypoint 8)
763  case 24:
764  if (Unit* pStalker = me->SummonCreature(NPC_INVIS_TARGET, 2026.469f, 1287.088f, 143.596f, 1.37f, TEMPSUMMON_TIMED_DESPAWN, 14000))
765  {
766  stalkerGUID = pStalker->GetGUID();
768  }
769 
771 
772  JumpToNextStep(1000);
773  break;
774  case 25:
776  JumpToNextStep(12000);
777  break;
778  case 26:
779  SetEscortPaused(false);
780  bStepping = false;
781  SetRun(false);
783  JumpToNextStep(0);
784  break;
785  //After waypoint 9
786  case 27:
787  me->SetTarget(citymenGUID[0]);
788  if (Creature* cityman = ObjectAccessor::GetCreature(*me, citymenGUID[0]))
789  {
790  cityman->SetTarget(me->GetGUID());
791  cityman->SetWalk(true);
792  cityman->GetMotionMaster()->MovePoint(0, 2088.625f, 1279.191f, 140.743f);
793  }
794  JumpToNextStep(2000);
795  break;
796  case 28:
797  if (Creature* cityman = ObjectAccessor::GetCreature(*me, citymenGUID[0]))
798  cityman->AI()->Talk(SAY_PHASE202);
799  JumpToNextStep(4000);
800  break;
801  case 29:
802  SetEscortPaused(false);
803  bStepping = false;
805  JumpToNextStep(0);
806  break;
807  //After waypoint 10
808  case 30:
809  me->HandleEmoteCommand(37);
810  JumpToNextStep(1000);
811  break;
812  case 31:
813  SetEscortPaused(false);
814  bStepping = false;
815  if (Creature* cityman1 = ObjectAccessor::GetCreature(*me, citymenGUID[1]))
816  {
817  cityman1->AI()->Talk(SAY_PHASE204);
818  cityman1->SetTarget(me->GetGUID());
819  if (Creature* cityman0 = ObjectAccessor::GetCreature(*me, citymenGUID[0]))
820  cityman0->KillSelf();
821  me->SetTarget(citymenGUID[1]);
822  }
823  JumpToNextStep(0);
824  break;
825  //After waypoint 11
826  case 32:
827  me->HandleEmoteCommand(37);
828  JumpToNextStep(1000);
829  break;
830  case 33:
831  if (Creature* cityman1 = ObjectAccessor::GetCreature(*me, citymenGUID[1]))
832  cityman1->KillSelf();
833  JumpToNextStep(1000);
834  break;
835  case 34:
836  if (Unit* pStalker = me->SummonCreature(NPC_INVIS_TARGET, 2081.447f, 1287.770f, 141.3241f, 1.37f, TEMPSUMMON_TIMED_DESPAWN, 10000))
837  {
838  stalkerGUID = pStalker->GetGUID();
840  }
842  JumpToNextStep(3000);
843  break;
844  case 35:
845  if (Unit* pStalkerM = me->SummonCreature(NPC_INVIS_TARGET, 2117.349f, 1288.624f, 136.271f, 1.37f, TEMPSUMMON_TIMED_DESPAWN, 60000))
846  {
847  stalkerGUID = pStalkerM->GetGUID();
849  }
850  JumpToNextStep(1000);
851  break;
852  case 36:
853  if (Creature* malganis = me->SummonCreature(NPC_MAL_GANIS, 2117.349f, 1288.624f, 136.271f, 1.37f, TEMPSUMMON_TIMED_DESPAWN, 60000))
854  {
856  malganis->CastSpell(pStalkerM, 63793, false);
857 
858  malganisGUID = malganis->GetGUID();
859  malganis->AI()->Talk(SAY_PHASE206);
860  malganis->SetTarget(me->GetGUID());
861  malganis->SetReactState(REACT_PASSIVE);
862  }
863  JumpToNextStep(11000);
864  break;
865  case 37:
867  {
868  Creature* pZombie = GetClosestCreatureWithEntry(malganis, NPC_CITY_MAN, 100.0f);
869  if (!pZombie)
870  pZombie = GetClosestCreatureWithEntry(malganis, NPC_CITY_MAN2, 100.0f);
871  if (pZombie)
872  pZombie->UpdateEntry(NPC_ZOMBIE);
873  else //There's no one else to transform
874  step++;
875  }
876  else
877  step++;
878  phaseTimer = 500;
879  break;
880  case 38:
882  malganis->AI()->Talk(SAY_PHASE207);
883  JumpToNextStep(17000);
884  break;
885  case 39:
887  malganis->SetVisible(false);
889  JumpToNextStep(7000);
890  break;
891  case 40:
892  if (Unit* pStalker = me->SummonCreature(NPC_INVIS_TARGET, 2081.447f, 1287.770f, 141.3241f, 1.37f, TEMPSUMMON_TIMED_DESPAWN, 10000))
893  {
894  stalkerGUID = pStalker->GetGUID();
896  }
898 
901 
903  JumpToNextStep(5000);
904  break;
905  // Summon wave groups - start the Infinite Corruptor timer
906  case 41:
907  case 43:
908  case 45:
909  case 47:
910  case 51:
911  case 53:
912  case 55:
913  case 57:
916 
918  {
920  wave++;
921  WavesCounter++;
923  }
924  JumpToNextStep(500);
925  break;
926  case 42: //Wait group to die
927  case 44:
928  case 46:
929  case 48:
930  case 52:
931  case 54:
932  case 56:
933  case 58:
935  {
936  uint32 mobCounter = 0;
937  uint32 deadCounter = 0;
938  for (uint8 i = 0; i < ENCOUNTER_WAVES_MAX_SPAWNS; ++i)
939  {
940  if (waveGUID[i].IsEmpty())
941  break;
942  ++mobCounter;
944  if (!temp || temp->isDead())
945  ++deadCounter;
946  }
947 
948  if (mobCounter <= deadCounter) //If group is dead
949  JumpToNextStep(1000);
950  else
951  phaseTimer = 1000;
952  }
953  else
954  JumpToNextStep(500);
955  break;
956  case 49: //Summon Boss
957  case 59:
959  {
960  WavesCounter++;
962  uint32 uiBossID = 0;
963  if (bossEvent == DATA_MEATHOOK)
964  uiBossID = NPC_MEATHOOK;
965  else if (bossEvent == DATA_SALRAMM)
966  uiBossID = NPC_SALRAMM;
967 
968  if (Unit* pBoss = me->SummonCreature(uiBossID, 2232.19f, 1331.933f, 126.662f, 3.15f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 900000))
969  {
970  bossGUID = pBoss->GetGUID();
971  pBoss->SetWalk(true);
972  pBoss->GetMotionMaster()->MovePoint(0, 2194.110f, 1332.00f, 130.00f);
973  }
974  }
975  JumpToNextStep(30000);
976  break;
977  case 50: //Wait Boss death
978  case 60:
980  {
981  JumpToNextStep(1000);
982  if (bossEvent == DATA_MEATHOOK)
984  else if (bossEvent == DATA_SALRAMM)
985  {
986  SetHoldState(false);
987  bStepping = false;
989  }
990  }
991  else if (instance->GetBossState(bossEvent) == FAIL)
993  else
994  phaseTimer = 10000;
995  break;
996  //After Gossip 2 (waypoint 22)
997  case 61:
1000  disguised0->SetTarget(me->GetGUID());
1002  disguised1->SetTarget(me->GetGUID());
1004  disguised2->SetTarget(me->GetGUID());
1005  JumpToNextStep(1000);
1006  break;
1007  case 62:
1009  disguised0->AI()->Talk(SAY_PHASE302);
1010  JumpToNextStep(7000);
1011  break;
1012  case 63:
1013  Talk(SAY_PHASE303);
1014  SetHoldState(false);
1015  bStepping = false;
1016  JumpToNextStep(0);
1017  break;
1018  //After waypoint 23
1019  case 64:
1020  me->HandleEmoteCommand(54);
1021  JumpToNextStep(1000);
1022  break;
1023  case 65:
1025  disguised0->HandleEmoteCommand(11);
1026  JumpToNextStep(1000);
1027  break;
1028  case 66:
1029  Talk(SAY_PHASE304);
1030  JumpToNextStep(2000);
1031  break;
1032  case 67:
1034  disguised0->AI()->Talk(SAY_PHASE305);
1035  JumpToNextStep(1000);
1036  break;
1037  case 68:
1039  {
1040  disguised2->UpdateEntry(NPC_INFINITE_HUNTER);
1041  //Make them unattackable
1043  disguised2->SetReactState(REACT_PASSIVE);
1044  }
1045  JumpToNextStep(2000);
1046  break;
1047  case 69:
1049  {
1050  disguised1->UpdateEntry(NPC_INFINITE_AGENT);
1051  //Make them unattackable
1053  disguised1->SetReactState(REACT_PASSIVE);
1054  }
1055  JumpToNextStep(2000);
1056  break;
1057  case 70:
1059  {
1060  disguised0->UpdateEntry(NPC_INFINITE_ADVERSARY);
1061  //Make them unattackable
1063  disguised0->SetReactState(REACT_PASSIVE);
1064  }
1065  JumpToNextStep(2000);
1066  break;
1067  case 71:
1068  //After waypoint 26, 29, 31
1069  case 73:
1070  case 75:
1071  case 77:
1072  //Make cratures attackable
1073  for (uint32 i = 0; i< ENCOUNTER_DRACONIAN_NUMBER; ++i)
1075  {
1077  temp->SetReactState(REACT_AGGRESSIVE);
1078  }
1079  JumpToNextStep(5000);
1080  break;
1081  case 72:
1082  case 74:
1083  case 76:
1084  if (me->IsInCombat())
1085  phaseTimer = 1000;
1086  else
1087  {
1088  if (step == 72)
1089  Talk(SAY_PHASE308);
1090  if (step == 74)
1091  Talk(SAY_PHASE308);
1092  if (step == 76)
1093  Talk(SAY_PHASE310);
1094  SetHoldState(false);
1095  bStepping = false;
1096  SetRun(true);
1097  JumpToNextStep(2000);
1098  }
1099  break;
1100  case 78:
1101  if (me->IsInCombat())
1102  phaseTimer = 1000;
1103  else
1104  {
1105  Talk(SAY_PHASE312);
1106  JumpToNextStep(5000);
1107  }
1108  break;
1109  case 79:
1110  Talk(SAY_PHASE313);
1111  JumpToNextStep(1000);
1112  break;
1113  case 80:
1115  {
1116  SpawnTimeRift(17, &epochGUID);
1118  epoch->AI()->Talk(SAY_PHASE314);
1120  }
1121  JumpToNextStep(18000);
1122  break;
1123  case 81:
1125  Talk(SAY_PHASE315);
1126  JumpToNextStep(6000);
1127  break;
1128  case 82:
1130  {
1132  {
1133  //Make Epoch attackable
1135  epoch->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
1136  epoch->SetReactState(REACT_AGGRESSIVE);
1137  }
1138 
1139  }
1140  JumpToNextStep(1000);
1141  break;
1142  case 83:
1144  {
1145  gossipStep = 3;
1147  bStepping = false;
1149  JumpToNextStep(15000);
1150  }
1151  else if (instance->GetBossState(DATA_EPOCH) == FAIL)
1153  else
1154  phaseTimer = 10000;
1155  break;
1156  //After Gossip 4
1157  case 84:
1158  Talk(SAY_PHASE404);
1159  SetHoldState(false);
1160  bStepping = false;
1161  break;
1162  //After Gossip 5
1163  case 85:
1164  Talk(SAY_PHASE501);
1165  if (Creature* malganis = me->SummonCreature(NPC_MAL_GANIS, 2296.665f, 1502.362f, 128.362f, 4.961f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 900000))
1166  {
1167  malganisGUID = malganis->GetGUID();
1168  malganis->SetReactState(REACT_PASSIVE);
1169  }
1171  gate->SetGoState(GO_STATE_ACTIVE);
1172  SetHoldState(false);
1173  bStepping = false;
1174  JumpToNextStep(0);
1175  break;
1176  //After waypoint 55
1177  case 86:
1178  Talk(SAY_PHASE502);
1179  JumpToNextStep(6000);
1181  break;
1182  case 87:
1184  {
1186  malganis->SetReactState(REACT_AGGRESSIVE);
1187  }
1188  JumpToNextStep(1000);
1189  break;
1190  case 88:
1192  {
1193  SetHoldState(false);
1194  JumpToNextStep(1000);
1195  }
1196  else if (instance->GetBossState(DATA_MAL_GANIS) == FAIL)
1198  else
1199  phaseTimer = 10000;
1200  break;
1201  //After waypoint 56
1202  case 89:
1203  SetRun(true);
1205  Talk(SAY_PHASE503);
1206  JumpToNextStep(7000);
1207  break;
1208  case 90:
1209  instance->SetBossState(DATA_ARTHAS, DONE); //Rewards: Achiev & Chest ;D
1211  Talk(SAY_PHASE504);
1212  bStepping = false;
1213  break;
1214  }
1215  } else phaseTimer -= diff;
1216  }
1217 
1218  //Battling skills
1219  if (!me->GetVictim())
1220  return;
1221 
1222  if (exorcismTimer < diff)
1223  {
1224  if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0))
1225  DoCast(target, SPELL_EXORCISM_N);
1226  exorcismTimer = 7300;
1227  } else exorcismTimer -= diff;
1228 
1229  if (HealthBelowPct(40))
1231 
1233  }
Definition: Unit.h:679
Definition: culling_of_stratholme.cpp:60
Definition: culling_of_stratholme.cpp:36
uint32 phaseTimer
Definition: culling_of_stratholme.cpp:391
Definition: culling_of_stratholme.cpp:156
void SpawnWaveGroup(uint32 waveID, ObjectGuid *guidVector)
Definition: culling_of_stratholme.cpp:459
Definition: culling_of_stratholme.cpp:46
Definition: Unit.h:735
ObjectGuid waveGUID[ENCOUNTER_WAVES_MAX_SPAWNS]
Definition: culling_of_stratholme.cpp:400
Definition: culling_of_stratholme.cpp:114
Definition: culling_of_stratholme.cpp:39
Definition: culling_of_stratholme.h:31
static ObjectGuid const Empty
Definition: ObjectGuid.h:196
ObjectGuid stalkerGUID
Definition: culling_of_stratholme.cpp:402
Definition: culling_of_stratholme.h:50
Definition: Unit.h:674
Definition: Unit.h:1131
Definition: culling_of_stratholme.cpp:155
Definition: culling_of_stratholme.cpp:89
Definition: culling_of_stratholme.cpp:106
Definition: culling_of_stratholme.h:36
ObjectGuid jainaGUID
Definition: culling_of_stratholme.cpp:398
Definition: culling_of_stratholme.cpp:81
Definition: Unit.h:1129
TC_GAME_API Creature * GetClosestCreatureWithEntry(WorldObject *source, uint32 entry, float maxSearchRange, bool alive)
Definition: ScriptedCreature.cpp:611
bool HealthBelowPct(uint32 pct) const
Definition: ScriptedCreature.h:247
ObjectGuid bossGUID
Definition: culling_of_stratholme.cpp:404
Definition: culling_of_stratholme.cpp:77
Definition: culling_of_stratholme.h:47
Definition: culling_of_stratholme.cpp:40
virtual uint32 GetData(uint32) const
Definition: ZoneScript.h:51
MotionMaster * GetMotionMaster()
Definition: Unit.h:2101
bool IsInCombat() const
Definition: Unit.h:1584
Definition: culling_of_stratholme.cpp:58
Definition: Unit.h:1130
Definition: culling_of_stratholme.cpp:45
Definition: inflate.h:49
Definition: culling_of_stratholme.cpp:102
Definition: culling_of_stratholme.cpp:74
Definition: culling_of_stratholme.cpp:128
uint32 step
Definition: culling_of_stratholme.cpp:390
Definition: culling_of_stratholme.cpp:76
bool IsHeroic() const
Definition: ScriptedCreature.h:268
Definition: Creature.h:467
virtual void Talk(std::string const &text, ChatMsg msgType, Language language, float textRange, WorldObject const *target)
Definition: Unit.cpp:16385
Definition: culling_of_stratholme.h:39
Definition: Object.h:60
void EnterEvadeMode(EvadeReason=EVADE_REASON_OTHER) override
Definition: ScriptedEscortAI.cpp:187
Definition: culling_of_stratholme.cpp:87
void SetFlag(uint16 index, uint32 newFlag)
Definition: Object.cpp:1199
Definition: InstanceScript.h:60
Definition: culling_of_stratholme.cpp:112
Definition: culling_of_stratholme.cpp:37
Definition: Unit.h:681
Definition: culling_of_stratholme.cpp:127
Definition: culling_of_stratholme.cpp:105
Definition: culling_of_stratholme.cpp:68
Definition: Unit.h:688
Definition: culling_of_stratholme.cpp:35
Creature *const me
Definition: CreatureAI.h:71
void JumpToNextStep(uint32 uiTimer)
Definition: culling_of_stratholme.cpp:476
void MovePoint(uint32 id, Position const &pos, bool generatePath=true)
Definition: MotionMaster.h:172
Definition: culling_of_stratholme.cpp:139
virtual ObjectGuid GetGuidData(uint32 type) const override
Definition: InstanceScript.cpp:93
Definition: culling_of_stratholme.cpp:34
Definition: culling_of_stratholme.cpp:61
Definition: culling_of_stratholme.h:27
uint32 wave
Definition: culling_of_stratholme.cpp:394
Definition: UnitAI.h:35
ObjectGuid epochGUID
Definition: culling_of_stratholme.cpp:405
Definition: culling_of_stratholme.cpp:75
Definition: culling_of_stratholme.cpp:32
Definition: culling_of_stratholme.cpp:53
Definition: InstanceScript.h:59
bool bStepping
Definition: culling_of_stratholme.cpp:389
Unit * GetVictim() const
Definition: Unit.h:1379
void UpdateAI(uint32 diff) override
Definition: ScriptedEscortAI.cpp:227
Definition: culling_of_stratholme.cpp:92
Definition: Object.h:56
virtual void SetData(uint32, uint32)
Definition: ZoneScript.h:52
Definition: culling_of_stratholme.cpp:52
Definition: InstanceScript.h:58
uint32 WavesCounter
Definition: culling_of_stratholme.cpp:395
Unit * SelectTarget(SelectAggroTarget targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, int32 aura=0)
Definition: UnitAI.cpp:91
Definition: culling_of_stratholme.h:77
uint32_t uint32
Definition: Define.h:150
Definition: culling_of_stratholme.h:51
void DoCast(uint32 spellId)
Definition: UnitAI.cpp:101
Definition: GameObject.h:880
uint32 bossEvent
Definition: culling_of_stratholme.cpp:393
Definition: culling_of_stratholme.h:44
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
Definition: CreatureAI.cpp:42
void SpawnTimeRift(uint32 timeRiftID, ObjectGuid *guidVector)
Definition: culling_of_stratholme.cpp:440
Definition: culling_of_stratholme.h:30
Definition: culling_of_stratholme.cpp:96
ObjectGuid citymenGUID[2]
Definition: culling_of_stratholme.cpp:399
virtual bool SetBossState(uint32 id, EncounterState state)
Definition: InstanceScript.cpp:273
Definition: culling_of_stratholme.h:29
TC_GAME_API Creature * GetCreature(WorldObject const &u, ObjectGuid const &guid)
Definition: ObjectAccessor.cpp:174
void SetRun(bool on=true)
Definition: ScriptedEscortAI.cpp:417
Definition: GameObject.h:822
Definition: culling_of_stratholme.cpp:47
Definition: culling_of_stratholme.cpp:31
uint32 exorcismTimer
Definition: culling_of_stratholme.cpp:409
Definition: culling_of_stratholme.cpp:95
void RemoveFlag(uint16 index, uint32 oldFlag)
Definition: Object.cpp:1214
Definition: Unit.h:682
Definition: culling_of_stratholme.h:45
Definition: culling_of_stratholme.cpp:56
void DoUpdateWorldState(uint32 worldstateId, uint32 worldstateValue)
Definition: InstanceScript.cpp:473
ObjectGuid const & GetGUID() const
Definition: Object.h:105
Definition: culling_of_stratholme.cpp:62
bool isDead() const
Definition: Unit.h:1694
Definition: culling_of_stratholme.cpp:80
void SetEscortPaused(bool on)
Definition: ScriptedEscortAI.cpp:507
Definition: culling_of_stratholme.cpp:44
Definition: UpdateFields.h:109
Definition: culling_of_stratholme.cpp:84
virtual void SetTarget(ObjectGuid const &)=0
Definition: culling_of_stratholme.cpp:137
TC_GAME_API GameObject * GetGameObject(WorldObject const &u, ObjectGuid const &guid)
Definition: ObjectAccessor.cpp:143
Definition: culling_of_stratholme.cpp:38
Definition: culling_of_stratholme.cpp:88
bool SetWalk(bool enable)
Definition: Unit.cpp:15800
Definition: culling_of_stratholme.cpp:33
Definition: culling_of_stratholme.cpp:99
void DoMeleeAttackIfReady()
Definition: UnitAI.cpp:49
uint8_t uint8
Definition: Define.h:152
Definition: culling_of_stratholme.cpp:90
void HandleEmoteCommand(uint32 anim_id)
Definition: Unit.cpp:1444
Definition: UpdateFields.h:135
Definition: culling_of_stratholme.h:28
Definition: culling_of_stratholme.cpp:111
Definition: culling_of_stratholme.cpp:91
uint32 gossipStep
Definition: culling_of_stratholme.cpp:392
InstanceScript * instance
Definition: culling_of_stratholme.cpp:387
EncounterState GetBossState(uint32 id) const
Definition: InstanceScript.h:227
Definition: culling_of_stratholme.cpp:123
Definition: Unit.h:1305
bool UpdateEntry(uint32 entry, CreatureData const *data=nullptr)
Definition: Creature.cpp:407
void SetReactState(ReactStates st)
Definition: Creature.h:502
ObjectGuid infiniteDraconianGUID[ENCOUNTER_DRACONIAN_NUMBER]
Definition: culling_of_stratholme.cpp:401
Definition: culling_of_stratholme.cpp:113
Definition: culling_of_stratholme.h:35
ObjectGuid malganisGUID
Definition: culling_of_stratholme.cpp:406
void SetTarget(ObjectGuid const &guid) override
Definition: Creature.cpp:2675
TempSummon * SummonCreature(uint32 id, Position const &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0) const
Definition: Object.cpp:2346
void SetHoldState(bool bOnHold)
Definition: culling_of_stratholme.cpp:471
ObjectGuid utherGUID
Definition: culling_of_stratholme.cpp:397
Definition: culling_of_stratholme.cpp:43
Definition: Object.h:54

+ Here is the call graph for this function:

void npc_arthas::npc_arthasAI::WaypointReached ( uint32  waypointId)
inlineoverridevirtual

Implements npc_escortAI.

483  {
484  switch (waypointId)
485  {
486  case 0:
487  case 1:
488  case 3:
489  case 9:
490  case 10:
491  case 11:
492  case 22:
493  case 23:
494  case 55:
495  case 56:
496  SetHoldState(true);
497  bStepping = true;
498  break;
499  case 7:
500  if (Unit* cityman0 = me->FindNearestCreature(NPC_CITY_MAN, 160.0f))
501  citymenGUID[0] = cityman0->GetGUID();
502  if (Unit* cityman1 = me->FindNearestCreature(NPC_CITY_MAN2, 160.0f))
503  citymenGUID[1] = cityman1->GetGUID();
504  break;
505  case 8:
506  gossipStep = 1;
508  SetHoldState(true);
509  break;
510  case 12:
511  SetRun(true);
513  if (Unit* disguised0 = me->SummonCreature(NPC_CITY_MAN3, 2398.14f, 1207.81f, 134.04f, 5.155249f, TEMPSUMMON_DEAD_DESPAWN, 180000))
514  {
515  infiniteDraconianGUID[0] = disguised0->GetGUID();
516  if (Unit* disguised1 = me->SummonCreature(NPC_CITY_MAN4, 2403.22f, 1205.54f, 134.04f, 3.311264f, TEMPSUMMON_DEAD_DESPAWN, 180000))
517  {
518  infiniteDraconianGUID[1] = disguised1->GetGUID();
519 
520  if (Unit* disguised2 = me->SummonCreature(NPC_CITY_MAN, 2400.82f, 1201.69f, 134.01f, 1.534082f, TEMPSUMMON_DEAD_DESPAWN, 180000))
521  {
522  infiniteDraconianGUID[2] = disguised2->GetGUID();
523  disguised0->SetTarget(infiniteDraconianGUID[1]);
524  disguised1->SetTarget(infiniteDraconianGUID[0]);
525  disguised2->SetTarget(infiniteDraconianGUID[1]);
526  }
527  }
528  }
529  break;
530  case 20:
531  gossipStep = 2;
533  SetRun(false);
534  SetHoldState(true);
535  break;
536  case 21:
538  break;
539  case 26:
540  SetRun(false);
543  SetHoldState(true);
544  bStepping = true;
545  break;
546  case 29:
547  SetRun(false);
551  SetHoldState(true);
552  bStepping = true;
553  break;
554  case 31:
555  SetRun(false);
559  SetHoldState(true);
560  bStepping = true;
561  break;
562  case 32:
564  break;
565  case 34:
567  break;
568  case 35:
570  break;
571  case 36:
573  gate->SetGoState(GO_STATE_ACTIVE);
574  break;
575  case 45:
576  SetRun(true);
577  gossipStep = 4;
579  SetHoldState(true);
580  break;
581  case 48:
582  SetRun(false);
584  break;
585  case 49:
586  SetRun(true);
588  break;
589  case 50:
591  break;
592  case 51:
593  gossipStep = 5;
595  SetHoldState(true);
596  break;
597  }
598  }
Definition: Unit.h:735
Definition: culling_of_stratholme.cpp:129
Definition: culling_of_stratholme.cpp:66
Definition: culling_of_stratholme.cpp:65
Definition: culling_of_stratholme.cpp:128
Definition: culling_of_stratholme.cpp:67
Definition: culling_of_stratholme.cpp:57
Definition: Object.h:60
Creature * FindNearestCreature(uint32 entry, float range, bool alive=true) const
Definition: Object.cpp:2443
void SetFlag(uint16 index, uint32 newFlag)
Definition: Object.cpp:1199
Definition: culling_of_stratholme.cpp:127
Creature *const me
Definition: CreatureAI.h:71
virtual ObjectGuid GetGuidData(uint32 type) const override
Definition: InstanceScript.cpp:93
Definition: culling_of_stratholme.cpp:69
Definition: culling_of_stratholme.cpp:130
bool bStepping
Definition: culling_of_stratholme.cpp:389
Definition: culling_of_stratholme.cpp:55
Definition: GameObject.h:880
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
Definition: CreatureAI.cpp:42
void SpawnTimeRift(uint32 timeRiftID, ObjectGuid *guidVector)
Definition: culling_of_stratholme.cpp:440
ObjectGuid citymenGUID[2]
Definition: culling_of_stratholme.cpp:399
Definition: culling_of_stratholme.cpp:70
Definition: culling_of_stratholme.h:34
void SetRun(bool on=true)
Definition: ScriptedEscortAI.cpp:417
Definition: GameObject.h:822
Definition: culling_of_stratholme.cpp:71
TC_GAME_API GameObject * GetGameObject(WorldObject const &u, ObjectGuid const &guid)
Definition: ObjectAccessor.cpp:143
Definition: culling_of_stratholme.cpp:59
Definition: UpdateFields.h:135
uint32 gossipStep
Definition: culling_of_stratholme.cpp:392
InstanceScript * instance
Definition: culling_of_stratholme.cpp:387
Definition: culling_of_stratholme.cpp:51
Definition: Unit.h:1305
Definition: culling_of_stratholme.cpp:48
ObjectGuid infiniteDraconianGUID[ENCOUNTER_DRACONIAN_NUMBER]
Definition: culling_of_stratholme.cpp:401
TempSummon * SummonCreature(uint32 id, Position const &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0) const
Definition: Object.cpp:2346
void SetHoldState(bool bOnHold)
Definition: culling_of_stratholme.cpp:471

+ Here is the call graph for this function:

Member Data Documentation

uint32 npc_arthas::npc_arthasAI::bossEvent
ObjectGuid npc_arthas::npc_arthasAI::bossGUID
bool npc_arthas::npc_arthasAI::bStepping
ObjectGuid npc_arthas::npc_arthasAI::citymenGUID[2]
ObjectGuid npc_arthas::npc_arthasAI::epochGUID
uint32 npc_arthas::npc_arthasAI::exorcismTimer
uint32 npc_arthas::npc_arthasAI::gossipStep
ObjectGuid npc_arthas::npc_arthasAI::infiniteDraconianGUID[ENCOUNTER_DRACONIAN_NUMBER]
ObjectGuid npc_arthas::npc_arthasAI::infiniteGUID
InstanceScript* npc_arthas::npc_arthasAI::instance
ObjectGuid npc_arthas::npc_arthasAI::jainaGUID
ObjectGuid npc_arthas::npc_arthasAI::malganisGUID
uint32 npc_arthas::npc_arthasAI::phaseTimer
ObjectGuid npc_arthas::npc_arthasAI::stalkerGUID
uint32 npc_arthas::npc_arthasAI::step
ObjectGuid npc_arthas::npc_arthasAI::utherGUID
uint32 npc_arthas::npc_arthasAI::wave
ObjectGuid npc_arthas::npc_arthasAI::waveGUID[ENCOUNTER_WAVES_MAX_SPAWNS]
uint32 npc_arthas::npc_arthasAI::WavesCounter

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