AzeorthCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
npc_anachronos_the_ancient::npc_anachronos_the_ancientAI Struct Reference
Inheritance diagram for npc_anachronos_the_ancient::npc_anachronos_the_ancientAI:
ScriptedAI CreatureAI UnitAI

Public Member Functions

 npc_anachronos_the_ancientAI (Creature *creature)
 
void Reset () override
 
void HandleAnimation ()
 
void UpdateAI (uint32 diff) override
 
- Public Member Functions inherited from ScriptedAI
 ScriptedAI (Creature *creature)
 
 ~ScriptedAI () override
 
void AttackStartNoMove (Unit *target)
 
void DamageTaken (Unit *, uint32 &, DamageEffectType, SpellSchoolMask) override
 
void UpdateAI (uint32 diff) override
 
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 EnterCombat (Unit *) override
 
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)
 Cast Spell. More...
 
void DoPlaySoundToSet (WorldObject *source, uint32 soundId)
 Play sound. More...
 
void DoPlayMusic (uint32 soundId, bool zone)
 
void DoResetThreat ()
 Reset Threat. More...
 
float DoGetThreat (Unit *unit)
 
void DoModifyThreatPercent (Unit *unit, int32 pct)
 Modify Unit Threat. More...
 
void DoTeleportPlayer (Unit *unit, float x, float y, float z, float o)
 Teleport player. More...
 
void DoTeleportAll (float x, float y, float z, float o)
 Teleport all. More...
 
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 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)
 
void SetCombatMovement (bool allowMovement)
 Set Combat Movement. More...
 
bool IsCombatMovementAllowed () const
 
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)
 
 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 EnterCombat (Unit *)
 
virtual void JustDied (Unit *)
 
virtual void KilledUnit (Unit *)
 
virtual void JustSummoned (Creature *)
 
virtual void IsSummonedBy (Unit *)
 
virtual void SummonedCreatureDespawn (Creature *)
 
virtual void SummonedCreatureDies (Creature *, Unit *)
 
virtual void SummonedCreatureDespawnAll ()
 
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
 
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 *)
 
- 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
 
virtual void InitializeAI ()
 
virtual void Reset ()
 
virtual void OnCharmed (bool apply)=0
 
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, int32 aura=0)
 
template<class PREDICATE >
UnitSelectTarget (SelectTargetMethod targetType, uint32 position, PREDICATE const &predicate)
 
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectTargetMethod 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, SelectTargetMethod targetType)
 
virtual void DamageDealt (Unit *, uint32 &, DamageEffectType)
 
virtual void DamageTaken (Unit *, uint32 &, DamageEffectType, SpellSchoolMask)
 
virtual void HealReceived (Unit *, uint32 &)
 
virtual void HealDone (Unit *, uint32 &)
 
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)
 
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)
 
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)
 
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

uint32 AnimationTimer
 
uint8 AnimationCount
 
ObjectGuid AnachronosQuestTriggerGUID
 
ObjectGuid MerithraGUID
 
ObjectGuid ArygosGUID
 
ObjectGuid CaelestraszGUID
 
ObjectGuid FandralGUID
 
ObjectGuid PlayerGUID
 
bool eventEnd
 
- Public Attributes inherited from ScriptedAI
Creatureme
 
bool IsFleeing
 

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
 
CreatureBoundary const * _boundary
 
bool _negateBoundary
 
- Protected Attributes inherited from UnitAI
Unit *const me
 

Detailed Description

Constructor & Destructor Documentation

◆ npc_anachronos_the_ancientAI()

npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::npc_anachronos_the_ancientAI ( Creature creature)
inline
309: ScriptedAI(creature) { }
Definition: ScriptedCreature.h:177

Member Function Documentation

◆ HandleAnimation()

void npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::HandleAnimation ( )
inline
338 {
340
341 if (!player)
342 {
343 return;
344 }
345
346 Creature* Fandral = player->FindNearestCreature(C_FANDRAL_STAGHELM, 100.0f);
347 Creature* Arygos = player->FindNearestCreature(C_ARYGOS, 100.0f);
348 Creature* Caelestrasz = player->FindNearestCreature(C_CAELESTRASZ, 100.0f);
349 Creature* Merithra = player->FindNearestCreature(C_MERITHRA, 100.0f);
350
351 if (!Fandral || !Arygos || !Caelestrasz || !Merithra)
352 return;
353
355 if (!eventEnd)
356 {
357 switch (AnimationCount)
358 {
359 case 0:
360 Talk(ANACHRONOS_SAY_1, Fandral);
361 break;
362 case 1:
363 Fandral->SetTarget(me->GetGUID());
364 Fandral->AI()->Talk(FANDRAL_SAY_1, me);
365 break;
366 case 2:
367 Fandral->SetTarget();
368 Merithra->AI()->Talk(MERITHRA_EMOTE_1);
369 break;
370 case 3:
371 Merithra->AI()->Talk(MERITHRA_SAY_1);
372 break;
373 case 4:
374 Arygos->AI()->Talk(ARYGOS_EMOTE_1);
375 break;
376 case 5:
377 Caelestrasz->SetTarget(Fandral->GetGUID());
378 Caelestrasz->AI()->Talk(CAELESTRASZ_SAY_1);
379 break;
380 case 6:
381 Merithra->AI()->Talk(MERITHRA_SAY_2);
382 break;
383 case 7:
384 Caelestrasz->SetTarget();
385 Merithra->GetMotionMaster()->MoveCharge(-8065, 1530, 2.61f, 10);
386 break;
387 case 8:
388 Merithra->AI()->Talk(MERITHRA_YELL_1);
389 break;
390 case 9:
391 Merithra->CastSpell(Merithra, 25105, true);
392 break;
393 case 10:
395 Merithra->SetDisableGravity(true);
396 Merithra->GetMotionMaster()->MoveCharge(-8065, 1530, 6.61f, 3);
397 break;
398 case 11:
399 Merithra->CastSpell(Merithra, 24818, false);
400 break;
401 case 12:
402 Merithra->GetMotionMaster()->MoveCharge(-8100, 1530, 50, 42);
403 break;
404 case 13:
405 break;
406 case 14:
407 Arygos->AI()->Talk(ARYGOS_SAY_1);
408 Merithra->SetVisible(false);
409 break;
410 case 15:
411 Arygos->GetMotionMaster()->MoveCharge(-8065, 1530, 2.61f, 10);
412 Merithra->GetMotionMaster()->MoveCharge(-8034.535f, 1535.14f, 2.61f, 42);
413 break;
414 case 16:
415 Arygos->AI()->Talk(ARYGOS_YELL_1);
416 break;
417 case 17:
418 Arygos->CastSpell(Arygos, 25107, true);
419 break;
420 case 18:
422 Arygos->SetDisableGravity(true);
423 Arygos->GetMotionMaster()->MoveCharge(-8065, 1530, 6.61f, 42);
424 break;
425 case 19:
426 Arygos->CastSpell(Arygos, 50505, false);
427 break;
428 case 20:
429 Arygos->GetMotionMaster()->MoveCharge(-8095, 1530, 50, 42);
430 break;
431 case 21:
432 break;
433 case 22:
434 Caelestrasz->AI()->Talk(CAELESTRASZ_SAY_2, Fandral);
435 break;
436 case 23:
437 Caelestrasz->GetMotionMaster()->MoveCharge(-8065, 1530, 2.61f, 10);
438 Arygos->SetVisible(false);
439 Arygos->GetMotionMaster()->MoveCharge(-8034.535f, 1535.14f, 2.61f, 10);
440 break;
441 case 24:
442 Caelestrasz->AI()->Talk(CAELESTRASZ_YELL_1);
443 break;
444 case 25:
445 Caelestrasz->CastSpell(Caelestrasz, 25106, true);
446 break;
447 case 26:
448 Caelestrasz->HandleEmoteCommand(254);
449 Caelestrasz->SetDisableGravity(true);
450 Caelestrasz->GetMotionMaster()->MoveCharge(-8065, 1530, 7.61f, 4);
451 break;
452 case 27:
453 Caelestrasz->CastSpell(Caelestrasz, 54293, false);
454 break;
455 case 28:
456 Talk(ANACHRONOS_SAY_2, Fandral);
457 break;
458 case 29:
459 Caelestrasz->GetMotionMaster()->MoveCharge(-8095, 1530, 50, 42);
460 Fandral->AI()->Talk(FANDRAL_SAY_2);
461 break;
462 case 30:
463 break;
464 case 31:
465 Talk(ANACHRONOS_SAY_3, Fandral);
466 break;
467 case 32:
468 Caelestrasz->SetVisible(false);
469 Caelestrasz->GetMotionMaster()->MoveCharge(-8034.535f, 1535.14f, 2.61f, 42);
470 Fandral->GetMotionMaster()->MoveCharge(-8108, 1529, 2.77f, 8);
471 me->GetMotionMaster()->MoveCharge(-8113, 1525, 2.77f, 8);
472 break;//both run to the gate
473 case 33:
475 Caelestrasz->GetMotionMaster()->MoveCharge(-8050, 1473, 65, 15);
476 break; //Text: sands will stop
477 case 34:
478 DoCast(player, 23017, true);//Arcane Channeling
479 break;
480 case 35:
481 me->CastSpell(-8088, 1520.43f, 2.67f, 25158, true);
482 break;
483 case 36:
484 DoCast(player, 25159, true);
485 break;
486 case 37:
487 me->SummonGameObject(GO_GATE_OF_AHN_QIRAJ, -8130, 1525, 17.5f, 0, 0, 0, 0, 0, 0);
488 break;
489 case 38:
490 DoCast(player, 25166, true);
491 me->SummonGameObject(GO_GLYPH_OF_AHN_QIRAJ, -8130, 1525, 17.5f, 0, 0, 0, 0, 0, 0);
492 break;
493 case 39:
494 Talk(ANACHRONOS_SAY_5, Fandral);
495 break;
496 case 40:
497 Fandral->CastSpell(me, 25167, true);
498 break;
499 case 41:
500 Fandral->SummonGameObject(GO_ROOTS_OF_AHN_QIRAJ, -8130, 1525, 17.5f, 0, 0, 0, 0, 0, 0);
501 Fandral->AI()->Talk(FANDRAL_SAY_3);
502 break;
503 case 42:
504 me->CastStop();
505 Fandral->AI()->Talk(FANDRAL_EMOTE_1);
506 break;
507 case 43:
508 Fandral->CastStop();
509 break;
510 case 44:
512 break;
513 case 45:
515 break;
516 case 46:
518 me->GetMotionMaster()->MoveCharge(-8110, 1527, 2.77f, 4);
519 break;
520 case 47:
522 break;
523 case 48:
524 Fandral->AI()->Talk(FANDRAL_SAY_4, me);
525 break;
526 case 49:
527 Fandral->AI()->Talk(FANDRAL_SAY_5, me);
528 break;
529 case 50:
530 Fandral->AI()->Talk(FANDRAL_EMOTE_2);
531 Fandral->CastSpell(-8127, 1525, 17.5f, 33806, true);
532 break;
533 case 51:
534 {
535 std::list<Creature*> constructList;
536
537 me->GetCreatureListWithEntryInGrid(constructList, 15423, 100.0f);
538 me->GetCreatureListWithEntryInGrid(constructList, 15424, 100.0f);
539 me->GetCreatureListWithEntryInGrid(constructList, 15414, 100.0f);
540 me->GetCreatureListWithEntryInGrid(constructList, 15422, 100.0f);
541
542 if (!constructList.empty())
543 {
544 for (std::list<Creature*>::const_iterator itr = constructList.begin(); itr != constructList.end(); ++itr)
545 {
546 (*itr)->RemoveFromWorld();
547 }
548 }
549
550 break;
551 }
552 case 52:
553 Fandral->GetMotionMaster()->MoveCharge(-8028.75f, 1538.795f, 2.61f, 4);
555 break;
556 case 53:
557 Fandral->AI()->Talk(FANDRAL_SAY_6);
558 break;
559 case 54:
561 break;
562 case 55:
563 //Fandral should not dispear atm.
564 //Fandral->SetVisible(false);
565 break;
566 case 56:
568 me->GetMotionMaster()->MoveCharge(-8116, 1522, 3.65f, 4);
569 break;
570 case 57:
571 me->GetMotionMaster()->MoveCharge(-8116.7f, 1527, 3.7f, 4);
572 break;
573 case 58:
574 me->GetMotionMaster()->MoveCharge(-8112.67f, 1529.9f, 2.86f, 4);
575 break;
576 case 59:
577 me->GetMotionMaster()->MoveCharge(-8117.99f, 1532.24f, 3.94f, 4);
578 break;
579 case 60:
580 Talk(ANACHRONOS_SAY_10, player);
581 me->GetMotionMaster()->MoveCharge(-8113.46f, 1524.16f, 2.89f, 4);
582 break;
583 case 61:
584 me->GetMotionMaster()->MoveCharge(-8057.1f, 1470.32f, 2.61f, 6);
585 if (player->IsInRange(me, 0, 15))
587 break;
588 case 62:
589 me->SetDisplayId(15500);
590 break;
591 case 63:
593 me->SetDisableGravity(true);
594 break;
595 case 64:
596 me->GetMotionMaster()->MoveCharge(-8000, 1400, 150, 9);
597 break;
598 case 65:
599 me->SetVisible(false);
600 if (Creature* AnachronosQuestTrigger = (ObjectAccessor::GetCreature(*me, AnachronosQuestTriggerGUID)))
601 {
603 AnachronosQuestTrigger->AI()->EnterEvadeMode();
604 eventEnd = true;
605 }
606 break;
607 }
608 }
610 }
static QuestCinematic EventAnim[]
Definition: zone_silithus.cpp:119
@ ANACHRONOS_EMOTE_3
Definition: zone_silithus.cpp:67
@ ANACHRONOS_SAY_3
Definition: zone_silithus.cpp:57
@ GO_GATE_OF_AHN_QIRAJ
Definition: zone_silithus.cpp:91
@ FANDRAL_SAY_6
Definition: zone_silithus.cpp:74
@ ANACHRONOS_EMOTE_2
Definition: zone_silithus.cpp:66
@ ANACHRONOS_SAY_6
Definition: zone_silithus.cpp:60
@ ANACHRONOS_SAY_9
Definition: zone_silithus.cpp:63
@ ANACHRONOS_SAY_7
Definition: zone_silithus.cpp:61
@ CAELESTRASZ_YELL_1
Definition: zone_silithus.cpp:80
@ ANACHRONOS_SAY_5
Definition: zone_silithus.cpp:59
@ MERITHRA_SAY_2
Definition: zone_silithus.cpp:87
@ ANACHRONOS_EMOTE_1
Definition: zone_silithus.cpp:65
@ ANACHRONOS_SAY_8
Definition: zone_silithus.cpp:62
@ FANDRAL_EMOTE_2
Definition: zone_silithus.cpp:76
@ C_ARYGOS
Definition: zone_silithus.cpp:51
@ ARYGOS_YELL_1
Definition: zone_silithus.cpp:83
@ FANDRAL_SAY_3
Definition: zone_silithus.cpp:71
@ ARYGOS_SAY_1
Definition: zone_silithus.cpp:82
@ FANDRAL_SAY_1
Definition: zone_silithus.cpp:69
@ C_CAELESTRASZ
Definition: zone_silithus.cpp:53
@ MERITHRA_SAY_1
Definition: zone_silithus.cpp:86
@ GO_ROOTS_OF_AHN_QIRAJ
Definition: zone_silithus.cpp:93
@ ANACHRONOS_SAY_1
Definition: zone_silithus.cpp:55
@ QUEST_A_PAWN_ON_THE_ETERNAL_BOARD
Definition: zone_silithus.cpp:47
@ ANACHRONOS_SAY_4
Definition: zone_silithus.cpp:58
@ C_FANDRAL_STAGHELM
Definition: zone_silithus.cpp:50
@ FANDRAL_SAY_5
Definition: zone_silithus.cpp:73
@ FANDRAL_SAY_2
Definition: zone_silithus.cpp:70
@ ANACHRONOS_SAY_2
Definition: zone_silithus.cpp:56
@ ARYGOS_EMOTE_1
Definition: zone_silithus.cpp:84
@ CAELESTRASZ_SAY_1
Definition: zone_silithus.cpp:78
@ FANDRAL_SAY_4
Definition: zone_silithus.cpp:72
@ C_MERITHRA
Definition: zone_silithus.cpp:52
@ FANDRAL_EMOTE_1
Definition: zone_silithus.cpp:75
@ GO_GLYPH_OF_AHN_QIRAJ
Definition: zone_silithus.cpp:92
@ MERITHRA_EMOTE_1
Definition: zone_silithus.cpp:89
@ ANACHRONOS_SAY_10
Definition: zone_silithus.cpp:64
@ CAELESTRASZ_SAY_2
Definition: zone_silithus.cpp:79
@ MERITHRA_YELL_1
Definition: zone_silithus.cpp:88
Talk
Definition: boss_fathomlord_karathress.cpp:23
@ EMOTE_ONESHOT_LIFTOFF
Definition: SharedDefines.h:1932
Creature * GetCreature(WorldObject const &u, ObjectGuid const guid)
Definition: ObjectAccessor.cpp:215
Player * GetPlayer(Map const *, ObjectGuid const guid)
Definition: ObjectAccessor.cpp:225
SpellCastResult DoCast(uint32 spellId)
Definition: UnitAI.cpp:178
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
Definition: CreatureAI.cpp:58
Creature * me
Definition: ScriptedCreature.h:267
Definition: Creature.h:46
void SetDisplayId(uint32 modelId) override
Change creature DisplayID temporarly.
Definition: Creature.cpp:3510
bool SetDisableGravity(bool disable, bool packetOnly=false, bool updateAnimationTier=true) override
Definition: Creature.cpp:3197
void SetTarget(ObjectGuid guid=ObjectGuid::Empty) override
Definition: Creature.cpp:3529
CreatureAI * AI() const
Definition: Creature.h:134
static ObjectGuid GetGUID(Object const *o)
Definition: Object.h:106
void GetCreatureListWithEntryInGrid(std::list< Creature * > &lList, uint32 uiEntry, float fMaxSearchRange) const
Definition: Object.cpp:2448
Creature * FindNearestCreature(uint32 entry, float range, bool alive=true) const
Definition: Object.cpp:2394
bool IsInRange(WorldObject const *obj, float minRange, float maxRange, bool is3D=true) const
Definition: Object.cpp:1406
GameObject * SummonGameObject(uint32 entry, float x, float y, float z, float ang, float rotation0, float rotation1, float rotation2, float rotation3, uint32 respawnTime, bool checkTransport=true, GOSummonType summonType=GO_SUMMON_TIMED_OR_CORPSE_DESPAWN)
Definition: Object.cpp:2317
Definition: Player.h:1046
void GroupEventHappens(uint32 questId, WorldObject const *pEventObject)
Definition: PlayerQuest.cpp:1795
void SetVisible(bool x)
Definition: Unit.cpp:14973
MotionMaster * GetMotionMaster()
Definition: Unit.h:2530
void CastStop(uint32 except_spellid=0, bool withInstant=true)
Definition: Unit.cpp:1409
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:1428
void HandleEmoteCommand(uint32 emoteId)
Definition: Unit.cpp:2345
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)
Definition: MotionMaster.cpp:586
uint32 Timer
Definition: zone_silithus.cpp:115
uint32 AnimationTimer
Definition: zone_silithus.cpp:311
uint8 AnimationCount
Definition: zone_silithus.cpp:312
ObjectGuid PlayerGUID
Definition: zone_silithus.cpp:319
ObjectGuid AnachronosQuestTriggerGUID
Definition: zone_silithus.cpp:314
bool eventEnd
Definition: zone_silithus.cpp:320

References Creature::AI(), ANACHRONOS_EMOTE_1, ANACHRONOS_EMOTE_2, ANACHRONOS_EMOTE_3, ANACHRONOS_SAY_1, ANACHRONOS_SAY_10, ANACHRONOS_SAY_2, ANACHRONOS_SAY_3, ANACHRONOS_SAY_4, ANACHRONOS_SAY_5, ANACHRONOS_SAY_6, ANACHRONOS_SAY_7, ANACHRONOS_SAY_8, ANACHRONOS_SAY_9, AnachronosQuestTriggerGUID, AnimationCount, AnimationTimer, ARYGOS_EMOTE_1, ARYGOS_SAY_1, ARYGOS_YELL_1, C_ARYGOS, C_CAELESTRASZ, C_FANDRAL_STAGHELM, C_MERITHRA, CAELESTRASZ_SAY_1, CAELESTRASZ_SAY_2, CAELESTRASZ_YELL_1, Unit::CastSpell(), Unit::CastStop(), UnitAI::DoCast(), EMOTE_ONESHOT_LIFTOFF, EventAnim, eventEnd, FANDRAL_EMOTE_1, FANDRAL_EMOTE_2, FANDRAL_SAY_1, FANDRAL_SAY_2, FANDRAL_SAY_3, FANDRAL_SAY_4, FANDRAL_SAY_5, FANDRAL_SAY_6, WorldObject::FindNearestCreature(), ObjectAccessor::GetCreature(), WorldObject::GetCreatureListWithEntryInGrid(), Object::GetGUID(), Unit::GetMotionMaster(), ObjectAccessor::GetPlayer(), GO_GATE_OF_AHN_QIRAJ, GO_GLYPH_OF_AHN_QIRAJ, GO_ROOTS_OF_AHN_QIRAJ, Player::GroupEventHappens(), Unit::HandleEmoteCommand(), WorldObject::IsInRange(), ScriptedAI::me, MERITHRA_EMOTE_1, MERITHRA_SAY_1, MERITHRA_SAY_2, MERITHRA_YELL_1, MotionMaster::MoveCharge(), PlayerGUID, QUEST_A_PAWN_ON_THE_ETERNAL_BOARD, Creature::SetDisableGravity(), Creature::SetDisplayId(), Creature::SetTarget(), Unit::SetVisible(), WorldObject::SummonGameObject(), CreatureAI::Talk(), and QuestCinematic::Timer.

Referenced by UpdateAI().

◆ Reset()

void npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::Reset ( )
inlineoverridevirtual

Reimplemented from ScriptedAI.

323 {
324 AnimationTimer = 1500;
325 AnimationCount = 0;
332 eventEnd = false;
333
335 }
@ UNIT_FLAG_NON_ATTACKABLE
Definition: Unit.h:449
void Clear()
Definition: ObjectGuid.h:140
void SetUnitFlag(UnitFlags flags)
Definition: Unit.h:1479
ObjectGuid FandralGUID
Definition: zone_silithus.cpp:318
ObjectGuid ArygosGUID
Definition: zone_silithus.cpp:316
ObjectGuid CaelestraszGUID
Definition: zone_silithus.cpp:317
ObjectGuid MerithraGUID
Definition: zone_silithus.cpp:315

References AnachronosQuestTriggerGUID, AnimationCount, AnimationTimer, ArygosGUID, CaelestraszGUID, ObjectGuid::Clear(), eventEnd, FandralGUID, ScriptedAI::me, MerithraGUID, PlayerGUID, Unit::SetUnitFlag(), and UNIT_FLAG_NON_ATTACKABLE.

◆ UpdateAI()

void npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::UpdateAI ( uint32  diff)
inlineoverridevirtual

Reimplemented from ScriptedAI.

612 {
613 if (AnimationTimer)
614 {
615 if (AnimationTimer <= diff)
617 else AnimationTimer -= diff;
618 }
619 if (AnimationCount < 65)
620 me->CombatStop();
621 if (AnimationCount == 65 || eventEnd)
623 }
virtual void EnterEvadeMode(EvadeReason why=EVADE_REASON_OTHER)
Definition: CreatureAI.cpp:195
void CombatStop(bool includingCast=false)
Definition: Unit.cpp:11245
void HandleAnimation()
Definition: zone_silithus.cpp:337

References AnimationCount, AnimationTimer, Unit::CombatStop(), CreatureAI::EnterEvadeMode(), eventEnd, HandleAnimation(), and ScriptedAI::me.

Member Data Documentation

◆ AnachronosQuestTriggerGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::AnachronosQuestTriggerGUID

Referenced by HandleAnimation(), and Reset().

◆ AnimationCount

uint8 npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::AnimationCount

Referenced by HandleAnimation(), Reset(), and UpdateAI().

◆ AnimationTimer

uint32 npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::AnimationTimer

Referenced by HandleAnimation(), Reset(), and UpdateAI().

◆ ArygosGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::ArygosGUID

Referenced by Reset().

◆ CaelestraszGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::CaelestraszGUID

Referenced by Reset().

◆ eventEnd

bool npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::eventEnd

Referenced by HandleAnimation(), Reset(), and UpdateAI().

◆ FandralGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::FandralGUID

Referenced by Reset().

◆ MerithraGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::MerithraGUID

Referenced by Reset().

◆ PlayerGUID

ObjectGuid npc_anachronos_the_ancient::npc_anachronos_the_ancientAI::PlayerGUID

Referenced by HandleAnimation(), and Reset().