295 bool raidHasQuest = targets.end() != std::find_if(targets.begin(), targets.end(), [questId](
WorldObject* worldObject)
297 if (Player* player = worldObject->ToPlayer())
298 if (player->GetQuestStatus(questId) == QUEST_STATUS_INCOMPLETE)
std::chrono::seconds Seconds
Seconds shorthand typedef.
std::chrono::milliseconds Milliseconds
Milliseconds shorthand typedef.
@ ENCOUNTER_FRAME_DISENGAGE
#define RegisterSpellScript(spell_script)
@ TARGET_UNIT_SRC_AREA_ENTRY
@ TARGET_UNIT_SRC_AREA_ENEMY
@ TARGET_UNIT_NEARBY_ENTRY
#define SpellObjectTargetSelectFn(F, I, N)
#define SpellEffectFn(F, I, N)
#define SpellObjectAreaTargetSelectFn(F, I, N)
InstanceScript *const instance
void JustEngagedWith(Unit *who) override
void JustDied(Unit *) override
void _DespawnAtEvade(Seconds delayToRespawn=30s, Creature *who=nullptr)
virtual void JustDied(Unit *)
virtual void EnterEvadeMode(EvadeReason why=EvadeReason::Other)
bool _EnterEvadeMode(EvadeReason why=EvadeReason::Other)
void SetCanMelee(bool canMelee, bool fleeFromMelee=false)
void DespawnOrUnsummon(Milliseconds timeToDespawn=0s, Seconds forceRespawnTime=0s)
Unit * SelectNearestTarget(float dist=0, bool playerOnly=false) const
bool Execute(uint64, uint32) override
bool Execute(uint64, uint32) override
void AddEventAtOffset(BasicEvent *event, Milliseconds offset)
void SendEncounterUnit(EncounterFrameType type, Unit const *unit, Optional< int32 > param1={}, Optional< int32 > param2={})
void MoveFollow(Unit *target, float dist, ChaseAngle angle, Optional< Milliseconds > duration={}, MovementSlot slot=MOTION_SLOT_ACTIVE)
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
Unit * GetHitUnit() const
HookList< EffectHandler > OnEffectHitTarget
HookList< ObjectTargetSelectHandler > OnObjectTargetSelect
SpellInfo const * GetSpellInfo() const
HookList< ObjectAreaTargetSelectHandler > OnObjectAreaTargetSelect
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)
TaskScheduler & SetValidator(P &&predicate)
Sets a validator which is asked if tasks are allowed to be executed.
bool DoSpellAttackIfReady(uint32 spellId)
SpellCastResult DoCastAOE(uint32 spellId, CastSpellExtraArgs const &args={})
Vehicle * GetVehicle() const
MotionMaster * GetMotionMaster()
void AddUnitState(uint32 f)
Unit * GetCharmerOrOwner() const
virtual float GetFollowAngle() const
bool HasUnitState(const uint32 f) const
Vehicle * GetVehicleKit() const
void Reset(bool evading=false)
Reapplies immunities and reinstalls accessories. Only has effect for creatures.
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
bool Validate(SpellInfo const *) override
void HandleScript(SpellEffIndex)
void FilterTargets(std::list< WorldObject * > &targets)
void SetTarget(WorldObject *&target)
void CheckQuestStatus(std::list< WorldObject * > &targets)
@ SPELL_FIERY_TORMENT_DAMAGE
@ SPELL_SMOULDERING_QUEST_CHECK_A
@ SPELL_SMOULDERING_QUEST_CHECK_H
#define RegisterFirelandsAI(AI)
void AddThreat(Unit *victim, float amount, Unit *who=nullptr)
void JustEngagedWith(Unit *target) override
void JustDied(Unit *killer) override
void EnterEvadeMode(EvadeReason why) override
void EnterEvadeMode(EvadeReason why) override
void JustEngagedWith(Unit *) override
void UpdateAI(uint32 diff) override
void JustDied(Unit *killer) override
npc_firelands_flame_archon(Creature *creature)
void UpdateAI(uint32) override
npc_firelands_magmakin(Creature *creature)
void IsSummonedBy(WorldObject *) override
void UpdateAI(uint32 diff) override
npc_firelands_molten_flamefather(Creature *creature)
void SummonedCreatureDies(Creature *summon, Unit *) override
void EnterEvadeMode(EvadeReason why) override
void JustDied(Unit *killer) override
void JustEngagedWith(Unit *) override
void JustSummoned(Creature *summon) override