152 summon->
SetHealth(midnight->GetHealth());
175 Unit* target =
nullptr;
176 std::vector<Unit*> target_list;
180 target = ref->GetVictim();
181 if (target && !target->IsWithinDist(me, 8.00f, false) && target->IsWithinDist(me, 25.0f, false))
182 target_list.push_back(target);
187 if (!target_list.empty())
206 midnight->KillSelf();
237 midnight->AttackStop();
238 midnight->RemoveAllAttackers();
240 midnight->GetMotionMaster()->MoveFollow(
me, 2.0f, 0.0f);
255 DoCastAOE(SPELL_SUMMON_ATTUMEN_MOUNTED);
256 me->SetVisible(false);
257 me->GetMotionMaster()->Clear();
258 midnight->SetVisible(false);
262 midnight->GetMotionMaster()->MoveFollow(me, 2.0f, 0.0f);
263 me->GetMotionMaster()->MoveFollow(midnight, 2.0f, 0.0f);
279 return GetKarazhanAI<boss_attumenAI>(creature);
380 return GetKarazhanAI<boss_midnightAI>(creature);
std::chrono::seconds Seconds
Seconds shorthand typedef.
if(posix_memalign(&__mallocedMemory, __align, __size)) return NULL
void AddSC_boss_attumen()
@ SPELL_SUMMON_ATTUMEN_MOUNTED
@ SPELL_INTANGIBLE_PRESENCE
void JustEngagedWith(Unit *who) override
void JustSummoned(Creature *summon) override
void _DespawnAtEvade(Seconds delayToRespawn=30s, Creature *who=nullptr)
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
void AttackStart(Unit *victim) override
== Triggered Actions Requested ==================
void SetReactState(ReactStates st)
void DespawnOrUnsummon(Milliseconds timeToDespawn=0s, Seconds forceRespawnTime=0s)
void MoveFollow(Unit *target, float dist, ChaseAngle angle, Optional< Milliseconds > duration={}, MovementSlot slot=MOTION_SLOT_ACTIVE)
static ObjectGuid GetGUID(Object const *o)
TaskContext & Repeat(std::chrono::duration< Rep, Period > duration)
TaskScheduler & CancelAll()
TaskScheduler & Schedule(std::chrono::duration< Rep, Period > time, task_handler_t task)
TaskScheduler & Update(success_t const &callback=nullptr)
Trinity::IteratorPair< ThreatListIterator, std::nullptr_t > GetUnsortedThreatList() const
SpellCastResult DoCastSelf(uint32 spellId, CastSpellExtraArgs const &args={})
SpellCastResult DoCastVictim(uint32 spellId, CastSpellExtraArgs const &args={})
Unit * SelectTarget(SelectTargetMethod targetType, uint32 offset=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
virtual void SetGUID(ObjectGuid const &, int32=0)
SpellCastResult DoCastAOE(uint32 spellId, CastSpellExtraArgs const &args={})
SpellCastResult DoCast(uint32 spellId)
void SetHealth(uint64 val)
ThreatManager & GetThreatManager()
MotionMaster * GetMotionMaster()
void RemoveAllAttackers()
bool HealthBelowPctDamaged(int32 pct, uint32 damage) const
bool IsWithinDist2d(float x, float y, float dist) const
CreatureAI * GetAI(Creature *creature) const override
CreatureAI * GetAI(Creature *creature) const override
TC_GAME_API Unit * GetUnit(WorldObject const &, ObjectGuid const &guid)
TC_GAME_API Creature * GetCreature(WorldObject const &u, ObjectGuid const &guid)
auto SelectRandomContainerElement(C const &container) -> typename std::add_const< decltype(*std::begin(container))>::type &
void KilledUnit(Unit *) override
void SpellHit(WorldObject *, SpellInfo const *spellInfo) override
void SetGUID(ObjectGuid const &guid, int32 id) override
void DamageTaken(Unit *, uint32 &damage, DamageEffectType, SpellInfo const *) override
boss_attumenAI(Creature *creature)
void IsSummonedBy(WorldObject *summoner) override
void EnterEvadeMode(EvadeReason) override
void JustDied(Unit *) override
void ScheduleTasks() override
void JustSummoned(Creature *summon) override
void UpdateAI(uint32 diff) override
void DamageTaken(Unit *, uint32 &damage, DamageEffectType, SpellInfo const *) override
void JustSummoned(Creature *summon) override
void UpdateAI(uint32 diff) override
void JustEngagedWith(Unit *who) override
void EnterEvadeMode(EvadeReason) override
void KilledUnit(Unit *) override
boss_midnightAI(Creature *creature)