152 summon->
SetHealth(midnight->GetHealth());
175 Unit* target =
nullptr;
176 std::vector<Unit*> target_list;
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.
void AddSC_boss_attumen()
@ SPELL_SUMMON_ATTUMEN_MOUNTED
@ SPELL_INTANGIBLE_PRESENCE
ObjectGuid const & GetGUID() const
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, Optional< ChaseAngle > angle={}, Optional< Milliseconds > duration={}, bool ignoreTargetWalk=false, MovementSlot slot=MOTION_SLOT_ACTIVE, Scripting::v2::ActionResultSetter< MovementStopReason > &&scriptResult={})
TaskContext & Repeat(TaskScheduler::duration_t duration)
TaskScheduler & CancelAll()
TaskScheduler & Schedule(duration_t time, task_handler_t task)
TaskScheduler & Update()
Update the scheduler to the current time.
Trinity::IteratorPair< ThreatListIterator, std::nullptr_t > GetUnsortedThreatList() const
SpellCastResult DoCastSelf(uint32 spellId, CastSpellExtraArgs const &args={})
virtual void SetGUID(ObjectGuid const &guid, int32 id)
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)
SpellCastResult DoCastAOE(uint32 spellId, CastSpellExtraArgs const &args={})
SpellCastResult DoCast(uint32 spellId)
void SetHealth(uint64 val)
ThreatManager & GetThreatManager()
MotionMaster * GetMotionMaster()
bool HealthBelowPctDamaged(float pct, uint32 damage) const
void RemoveAllAttackers()
bool IsWithinDist2d(float x, float y, float dist) const
bool IsWithinDist(WorldObject const *obj, float dist2compare, bool is3D=true, bool incOwnRadius=true, bool incTargetRadius=true) 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) -> std::add_const_t< decltype(*std::ranges::begin(container))> &
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)