AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
npc_pet_mage_mirror_image Struct Reference
Inheritance diagram for npc_pet_mage_mirror_image:
CasterAI CombatAI CreatureAI UnitAI

Public Member Functions

 npc_pet_mage_mirror_image (Creature *creature)
 
void InitializeAI () override
 
void EnterEvadeMode (EvadeReason) override
 
void MySelectNextTarget ()
 
void Reset () override
 
void UpdateAI (uint32 diff) override
 Use to start attacking a target. Called just before JustEngagedWith()
 
- Public Member Functions inherited from CasterAI
 CasterAI (Creature *c)
 
void AttackStart (Unit *victim) override
 
void JustEngagedWith (Unit *) override
 Called for reaction when initially engaged.
 
- Public Member Functions inherited from CombatAI
 CombatAI (Creature *c)
 
void JustEngagedWith (Unit *who) override
 Called for reaction when initially engaged.
 
void JustDied (Unit *killer) override
 
- Public Member Functions inherited from CreatureAI
void Talk (uint8 id, WorldObject const *whisperTarget=nullptr, Milliseconds delay=0ms)
 Causes the creature to talk/say the text assigned to their entry in the creature_text database table.
 
void Talk (uint8 id, Milliseconds delay)
 
WorldObjectGetSummoner () const
 Returns the summoner creature/object, if the creature is a temporary summon.
 
 CreatureAI (Creature *creature)
 
 ~CreatureAI () override
 
bool IsEngaged () const
 Check if creature is currently engaged in combat.
 
void MoveCircleChecks ()
 
void MoveBackwardsChecks ()
 
void MoveInLineOfSight_Safe (Unit *who)
 == Reactions At =================================
 
void TriggerAlert (Unit const *who) const
 
virtual bool CanRespawn ()
 
void JustEnteredCombat (Unit *who) override
 Called when the unit enters combat.
 
virtual void JustStartedThreateningMe (Unit *who)
 
void EngagementStart (Unit *who)
 
void EngagementOver ()
 
void JustExitedCombat () override
 Called when the unit leaves combat.
 
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 OnSpellStart (SpellInfo const *)
 
virtual void OnSpellCast (SpellInfo const *)
 
virtual void OnSpellFailed (SpellInfo const *)
 
virtual void OnChannelFinished (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.
 
virtual void JustReachedHome ()
 
void DoZoneInCombat (Creature *creature=nullptr, float maxRangeToNearestTarget=250.0f)
 
virtual void ReceiveEmote (Player *, uint32)
 
virtual void OwnerAttackedBy (Unit *attacker)
 
virtual void OwnerAttacked (Unit *target)
 
void OnOwnerCombatInteraction (Unit *target)
 
virtual void CorpseRemoved (uint32 &)
 == Triggered Actions Requested ==================
 
virtual void PassengerBoarded (Unit *, int8, bool)
 == Fields =======================================
 
virtual bool BeforeSpellClick (Unit *)
 
virtual void OnSpellClick (Unit *, bool &)
 
virtual bool CanSeeAlways (WorldObject const *)
 
virtual bool CanBeSeen (Player const *)
 
virtual bool CanAlwaysBeDetectable (WorldObject const *)
 
virtual void PetStopAttack ()
 
int32 VisualizeBoundary (uint32 duration, Unit *owner=nullptr, bool fill=false, bool checkZ=false) const
 
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)
 
virtual void DistancingStarted ()
 
virtual void DistancingEnded ()
 
- Public Member Functions inherited from UnitAI
 UnitAI (Unit *unit)
 
virtual ~UnitAI ()
 
virtual bool CanAIAttack (Unit const *) const
 
virtual void DoAction (int32)
 
virtual uint32 GetData (uint32) const
 
virtual void SetData (uint32, uint32)
 
virtual void SetGUID (ObjectGuid const &, int32=0)
 
virtual ObjectGuid GetGUID (int32=0) const
 
UnitSelectTarget (SelectTargetMethod targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
 
template<class PREDICATE >
UnitSelectTarget (SelectTargetMethod targetType, uint32 position, PREDICATE const &predicate)
 
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectTargetMethod targetType, uint32 position=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
 Select the best (up to) <num> targets (in <targetType> order) from the threat list that fulfill the following:
 
template<class PREDICATE >
void SelectTargetList (std::list< Unit * > &targetList, uint32 num, SelectTargetMethod targetType, uint32 position, PREDICATE const &predicate)
 
virtual void EvadeTimerExpired ()
 Called when evade timer expires (target unreachable for too long)
 
virtual void DamageDealt (Unit *, uint32 &, DamageEffectType, SpellSchoolMask)
 Called at any Damage to any victim (before damage apply)
 
virtual void DamageTaken (Unit *, uint32 &, DamageEffectType, SpellSchoolMask)
 Called at any Damage from any attacker (before damage apply)
 
virtual void HealReceived (Unit *, uint32 &)
 Called when the creature receives heal.
 
virtual void OnPowerUpdate (Powers, int32, int32, uint32)
 Called when the creature power updates.
 
virtual void HealDone (Unit *, uint32 &)
 Called when the unit heals.
 
virtual void OnCalculateMeleeDamageReceived (uint32 &, Unit *)
 Called during damage calculations.
 
virtual void OnCalculateSpellDamageReceived (int32 &, Unit *)
 
virtual void OnCalculatePeriodicTickReceived (uint32 &, Unit *)
 Called during calculation when receiving periodic healing or damage (DoT or HoT)
 
void AttackStartCaster (Unit *victim, float dist)
 
SpellCastResult DoAddAuraToAllHostilePlayers (uint32 spellid)
 
SpellCastResult DoCast (uint32 spellId)
 
SpellCastResult DoCast (Unit *victim, uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastSelf (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastToAllHostilePlayers (uint32 spellid, bool triggered=false)
 To specify the caster as target if the spell is self-cast.
 
SpellCastResult DoCastVictim (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastAOE (uint32 spellId, bool triggered=false)
 
SpellCastResult DoCastRandomTarget (uint32 spellId, uint32 threatTablePosition=0, float dist=0.0f, bool playerOnly=true, bool triggered=false, bool withTank=true)
 Cast the spell on a random unit from the threat list.
 
SpellCastResult DoCastMaxThreat (uint32 spellId, uint32 threatTablePosition=0, float dist=0.0f, bool playerOnly=true, bool triggered=false)
 Cast spell on the top threat target, which may not be the current victim.
 
float DoGetSpellMaxRange (uint32 spellId, bool positive=false)
 
void DoMeleeAttackIfReady ()
 
bool DoSpellAttackIfReady (uint32 spell)
 
void DoSpellAttackToRandomTargetIfReady (uint32 spell, uint32 threatTablePosition=0, float dist=0.f, bool playerOnly=true)
 
virtual void SummonMovementInform (Creature *, uint32, uint32)
 Called when a summon reaches a waypoint or point movement finished.
 
virtual void sGossipHello (Player *)
 
virtual void sGossipSelect (Player *, uint32, uint32)
 
virtual void sGossipSelectCode (Player *, uint32, uint32, char const *)
 
virtual void sQuestAccept (Player *, Quest const *)
 
virtual void sQuestSelect (Player *, Quest const *)
 
virtual void sQuestComplete (Player *, Quest const *)
 
virtual void sQuestReward (Player *, Quest const *, uint32)
 
virtual void sOnGameEvent (bool, uint16)
 
virtual std::string GetDebugInfo () const
 

Public Attributes

uint32 selectionTimer
 
ObjectGuid _ebonGargoyleGUID
 
uint32 checktarget
 
uint32 dist = urand(1, 5)
 
bool _delayAttack
 

Additional Inherited Members

- 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 CombatAI
static int32 Permissible (Creature const *)
 
- 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 CombatAI
EventMap events
 
SpellVct spells
 
- Protected Attributes inherited from CreatureAI
Creature *const me
 
EventMap events
 
TaskScheduler scheduler
 
CreatureBoundary const * _boundary
 
bool _negateBoundary
 
bool _isEngaged
 
- Protected Attributes inherited from UnitAI
Unit *const me
 

Detailed Description

Constructor & Destructor Documentation

◆ npc_pet_mage_mirror_image()

npc_pet_mage_mirror_image::npc_pet_mage_mirror_image ( Creature creature)
inline
59: CasterAI(creature) { }
Definition CombatAI.h:58

Member Function Documentation

◆ EnterEvadeMode()

void npc_pet_mage_mirror_image::EnterEvadeMode ( EvadeReason  )
inlineoverridevirtual

Reimplemented from CreatureAI.

144 {
145 if (me->IsInEvadeMode() || !me->IsAlive())
146 return;
147
148 Unit* owner = me->GetCharmerOrOwner();
149
150 me->CombatStop(true);
151 if (owner && !me->HasUnitState(UNIT_STATE_FOLLOW))
152 {
153 me->GetMotionMaster()->Clear(false);
155 }
156 }
@ MOTION_SLOT_ACTIVE
Definition MotionMaster.h:65
constexpr float PET_FOLLOW_DIST
Definition PetDefines.h:206
@ UNIT_STATE_FOLLOW
Definition UnitDefines.h:182
Creature *const me
Definition CreatureAI.h:71
bool IsInEvadeMode() const
Definition Creature.h:138
void MoveFollow(Unit *target, float dist, float angle, MovementSlot slot=MOTION_SLOT_ACTIVE, bool inheritWalkState=true, bool inheritSpeed=true)
The unit will follow this target. Doesn't work with UNIT_FLAG_DISABLE_MOVE.
Definition MotionMaster.cpp:447
void Clear(bool reset=true)
Definition MotionMaster.h:193
Definition Unit.h:664
MotionMaster * GetMotionMaster()
Definition Unit.h:1753
bool IsAlive() const
Definition Unit.h:1788
Unit * GetCharmerOrOwner() const
Definition Unit.h:1286
virtual float GetFollowAngle() const
Definition Unit.h:1890
bool HasUnitState(const uint32 f) const
Definition Unit.h:736
void CombatStop(bool includingCast=false, bool mutualPvP=true)
Definition Unit.cpp:7406

References MotionMaster::Clear(), Unit::CombatStop(), Unit::GetCharmerOrOwner(), Unit::GetFollowAngle(), Unit::GetMotionMaster(), Unit::HasUnitState(), Unit::IsAlive(), Creature::IsInEvadeMode(), CreatureAI::me, MOTION_SLOT_ACTIVE, MotionMaster::MoveFollow(), PET_FOLLOW_DIST, and UNIT_STATE_FOLLOW.

Referenced by MySelectNextTarget().

◆ InitializeAI()

void npc_pet_mage_mirror_image::InitializeAI ( )
inlineoverridevirtual

Reimplemented from CasterAI.

68 {
70
71 _delayAttack = true;
73 {
74 _delayAttack = false;
75 }, 1200ms);
76
77 Unit* owner = me->GetOwner();
78 if (!owner)
79 return;
80
81 // Clone Me!
82 owner->CastSpell(me, SPELL_MAGE_CLONE_ME, true);
83
84 // xinef: Glyph of Mirror Image (4th copy)
85 float angle = 0.0f;
87 {
89 angle = 0.5f * M_PI;
90 break;
92 angle = M_PI;
93 break;
95 angle = 1.5f * M_PI;
96 break;
97 }
98
99 ((Minion*)me)->SetFollowAngle(angle);
100 if (owner->IsInCombat())
101 me->NearTeleportTo(me->GetPositionX() + cos(angle)*dist, me->GetPositionY() + std::sin(angle)*dist, me->GetPositionZ(), me->GetOrientation(), false, false, false, false);
102 else
104
106
107 // Xinef: Inherit Master's Threat List (not yet implemented)
108 //owner->CastSpell((Unit*)nullptr, SPELL_MAGE_MASTERS_THREAT_LIST, true);
109 for (auto const& pair : owner->GetThreatMgr().GetThreatenedByMeList())
110 {
111 if (Unit* unit = pair.second->GetOwner())
112 unit->GetThreatMgr().AddThreat(me, pair.second->GetThreat());
113 }
114
116
117 // Xinef: copy caster auras
118 Unit::VisibleAuraMap const* visibleAuraMap = owner->GetVisibleAuras();
119 for (Unit::VisibleAuraMap::const_iterator itr = visibleAuraMap->begin(); itr != visibleAuraMap->end(); ++itr)
120 if (Aura* visAura = itr->second->GetBase())
121 {
122 // Ebon Gargoyle
123 if (visAura->GetId() == 49206 && me->GetUInt32Value(UNIT_CREATED_BY_SPELL) == SPELL_SUMMON_MIRROR_IMAGE1)
124 {
125 if (Unit* gargoyle = visAura->GetCaster())
126 _ebonGargoyleGUID = gargoyle->GetGUID();
127 continue;
128 }
129 SpellScriptsBounds bounds = sObjectMgr->GetSpellScriptsBounds(visAura->GetId());
130 if (bounds.first != bounds.second)
131 continue;
132 std::vector<int32> const* spellTriggered = sSpellMgr->GetSpellLinked(visAura->GetId() + SPELL_LINK_AURA);
133 if (!spellTriggered || !spellTriggered->empty())
134 continue;
135 if (Aura* newAura = me->AddAura(visAura->GetId(), me))
136 newAura->SetDuration(visAura->GetDuration());
137 }
138
139 me->m_Events.AddEventAtOffset(new DeathEvent(*me), 29500ms);
140 }
std::pair< SpellScriptsContainer::iterator, SpellScriptsContainer::iterator > SpellScriptsBounds
Definition ObjectMgr.h:389
#define sObjectMgr
Definition ObjectMgr.h:1699
#define sSpellMgr
Definition SpellMgr.h:815
@ SPELL_LINK_AURA
Definition SpellMgr.h:98
@ REACT_DEFENSIVE
Definition Unit.h:567
@ UNIT_CREATED_BY_SPELL
Definition UpdateFields.h:138
Definition SpellAuras.h:87
void InitializeAI() override
Definition CombatAI.cpp:110
void SetReactState(ReactStates state)
A creature can have 3 ReactStates : Agressive, Passive, Neutral.
Definition Creature.h:99
Definition pet_mage.cpp:43
void AddEventAtOffset(BasicEvent *event, Milliseconds offset, uint8 eventGroup=0)
Definition EventProcessor.h:108
Definition TemporarySummon.h:87
void Clear()
Definition ObjectGuid.h:138
uint32 GetUInt32Value(uint16 index) const
Definition Object.cpp:294
ThreatManager & GetThreatMgr()
Definition UnitAI.cpp:380
Unit * GetOwner() const
Definition Unit.cpp:7619
Aura * AddAura(uint32 spellId, Unit *target)
Definition Unit.cpp:15048
std::map< uint8, AuraApplication * > VisibleAuraMap
Definition Unit.h:687
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:1294
VisibleAuraMap const * GetVisibleAuras()
Definition Unit.h:1539
void NearTeleportTo(Position &pos, bool casting=false, bool vehicleTeleport=false, bool withPet=false, bool removeTransport=false)
Definition Unit.cpp:15875
bool IsInCombat() const
Definition Unit.h:935
EventProcessor m_Events
Definition Object.h:735
@ SPELL_MAGE_CLONE_ME
Definition pet_mage.cpp:33
@ SPELL_SUMMON_MIRROR_IMAGE1
Definition pet_mage.cpp:36
@ SPELL_SUMMON_MIRROR_IMAGE3
Definition pet_mage.cpp:38
@ SPELL_SUMMON_MIRROR_IMAGE2
Definition pet_mage.cpp:37
float GetPositionZ() const
Definition Position.h:123
float GetOrientation() const
Definition Position.h:124
float GetPositionX() const
Definition Position.h:121
float GetPositionY() const
Definition Position.h:122
uint32 dist
Definition pet_mage.cpp:64
ObjectGuid _ebonGargoyleGUID
Definition pet_mage.cpp:62
bool _delayAttack
Definition pet_mage.cpp:65

References _delayAttack, _ebonGargoyleGUID, Unit::AddAura(), EventProcessor::AddEventAtOffset(), Unit::CastSpell(), ObjectGuid::Clear(), dist, Unit::GetFollowAngle(), Unit::GetMotionMaster(), Position::GetOrientation(), Unit::GetOwner(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), ThreatManager::GetThreatenedByMeList(), Unit::GetThreatMgr(), Object::GetUInt32Value(), Unit::GetVisibleAuras(), CasterAI::InitializeAI(), Unit::IsInCombat(), WorldObject::m_Events, CreatureAI::me, MOTION_SLOT_ACTIVE, MotionMaster::MoveFollow(), Unit::NearTeleportTo(), PET_FOLLOW_DIST, REACT_DEFENSIVE, Creature::SetReactState(), sObjectMgr, SPELL_LINK_AURA, SPELL_MAGE_CLONE_ME, SPELL_SUMMON_MIRROR_IMAGE1, SPELL_SUMMON_MIRROR_IMAGE2, SPELL_SUMMON_MIRROR_IMAGE3, sSpellMgr, and UNIT_CREATED_BY_SPELL.

◆ MySelectNextTarget()

void npc_pet_mage_mirror_image::MySelectNextTarget ( )
inline
159 {
161 {
163 if (gargoyle && gargoyle->GetAI())
164 gargoyle->GetAI()->AttackStart(me);
166 }
167 Unit* owner = me->GetOwner();
168 if (owner && owner->IsPlayer())
169 {
170 Unit* selection = owner->ToPlayer()->GetSelectedUnit();
171
172 if (selection && me->CanSeeOrDetect(selection))
173 {
175 me->AddThreat(selection, 1000000.0f);
176
177 if (owner->IsInCombat())
178 AttackStart(selection);
179 }
180
181 if (!owner->IsInCombat() && !me->GetVictim())
183 }
184 }
void AttackStart(Unit *victim) override
Definition CombatAI.h:62
@ EVADE_REASON_OTHER
Definition CreatureAI.h:92
bool IsPlayer() const
Definition Object.h:201
Player * ToPlayer()
Definition Object.h:202
Unit * GetSelectedUnit() const
Definition Player.cpp:11453
void ResetAllThreat()
Definition ThreatManager.cpp:554
virtual void AttackStart(Unit *)
Definition UnitAI.cpp:28
void AddThreat(Unit *victim, float fThreat, SpellSchoolMask schoolMask=SPELL_SCHOOL_MASK_NORMAL, SpellInfo const *threatSpell=nullptr)
Definition Unit.cpp:11371
Unit * GetVictim() const
Definition Unit.h:903
ThreatManager & GetThreatMgr()
Definition Unit.h:951
UnitAI * GetAI()
Definition Unit.h:693
bool CanSeeOrDetect(WorldObject const *obj, bool ignoreStealth=false, bool distanceCheck=false, bool checkAlert=false) const
Definition Object.cpp:1750
Unit * GetUnit(WorldObject const &, ObjectGuid const &guid)
Definition ObjectAccessor.cpp:199
void EnterEvadeMode(EvadeReason) override
Definition pet_mage.cpp:143

References _ebonGargoyleGUID, Unit::AddThreat(), UnitAI::AttackStart(), CasterAI::AttackStart(), WorldObject::CanSeeOrDetect(), ObjectGuid::Clear(), EnterEvadeMode(), CreatureAI::EVADE_REASON_OTHER, Unit::GetAI(), Unit::GetOwner(), Player::GetSelectedUnit(), Unit::GetThreatMgr(), ObjectAccessor::GetUnit(), Unit::GetVictim(), Unit::IsInCombat(), Object::IsPlayer(), CreatureAI::me, ThreatManager::ResetAllThreat(), and Object::ToPlayer().

Referenced by UpdateAI().

◆ Reset()

void npc_pet_mage_mirror_image::Reset ( )
inlineoverridevirtual

Reimplemented from CombatAI.

187 {
188 selectionTimer = 0;
189 checktarget = 0;
190 }
uint32 checktarget
Definition pet_mage.cpp:63
uint32 selectionTimer
Definition pet_mage.cpp:61

References checktarget, and selectionTimer.

◆ UpdateAI()

void npc_pet_mage_mirror_image::UpdateAI ( uint32  )
inlineoverridevirtual

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

Reimplemented from CasterAI.

193 {
194 if (_delayAttack)
195 return;
196
197 events.Update(diff);
198
199 if (!me->IsInCombat() || !me->GetVictim())
200 {
202 return;
203 }
204
205 checktarget += diff;
206
207 if (checktarget >= 1000)
208 {
210 {
213 return;
214 }
215 }
216
218 return;
219
220 if (uint32 spellId = events.ExecuteEvent())
221 {
222 events.RescheduleEvent(spellId, spellId == 59637 ? 6500ms : 2500ms);
223 me->CastSpell(me->GetVictim(), spellId, false);
224 }
225 }
std::uint32_t uint32
Definition Define.h:107
@ UNIT_STATE_CASTING
Definition UnitDefines.h:188
events
Definition boss_sartura.cpp:43
bool HasBreakableByDamageCrowdControlAura(Unit *excludeCasterChannel=nullptr) const
Definition Unit.cpp:904
void InterruptNonMeleeSpells(bool withDelayed, uint32 spellid=0, bool withInstant=true, bool bySelf=false)
Definition Unit.cpp:4251
void MySelectNextTarget()
Definition pet_mage.cpp:158

References _delayAttack, WorldObject::CanSeeOrDetect(), Unit::CastSpell(), checktarget, Unit::GetVictim(), Unit::HasBreakableByDamageCrowdControlAura(), Unit::HasUnitState(), Unit::InterruptNonMeleeSpells(), Unit::IsAlive(), Unit::IsInCombat(), CreatureAI::me, MySelectNextTarget(), and UNIT_STATE_CASTING.

Member Data Documentation

◆ _delayAttack

bool npc_pet_mage_mirror_image::_delayAttack

Referenced by InitializeAI(), and UpdateAI().

◆ _ebonGargoyleGUID

ObjectGuid npc_pet_mage_mirror_image::_ebonGargoyleGUID

Referenced by InitializeAI(), and MySelectNextTarget().

◆ checktarget

uint32 npc_pet_mage_mirror_image::checktarget

Referenced by Reset(), and UpdateAI().

◆ dist

uint32 npc_pet_mage_mirror_image::dist = urand(1, 5)

Referenced by InitializeAI().

◆ selectionTimer

uint32 npc_pet_mage_mirror_image::selectionTimer

Referenced by Reset().


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