193 switch(spellInfo->
Id)
258 std::vector<Unit*> blizzards;
262 blizzards.push_back(temp);
265 return newTarget->GetGUID();
346 std::list<Unit*> targets;
348 for (
Unit* target : targets)
361 if (pTarget->IsAlive())
542 _block = block->GetGUID();
568 blizzard->CastSpell(
nullptr, blizzard->m_spells[0],
TRIGGERED_NONE);
575 blizzard->GetMotionMaster()->MoveFollow(newTarget, 0.1f, 0.0f);
579 blizzard->GetMotionMaster()->MoveFollow(target, 0.1f, 0.0f);
596 creature->DespawnOrUnsummon();
611 target->DespawnOrUnsummon();
std::chrono::seconds Seconds
Seconds shorthand typedef.
std::chrono::milliseconds Milliseconds
Milliseconds shorthand typedef.
std::chrono::minutes Minutes
Minutes shorthand typedef.
@ TEMPSUMMON_TIMED_DESPAWN
std::vector< ObjectGuid > GuidVector
Milliseconds randtime(Milliseconds min, Milliseconds max)
#define RegisterSpellScript(spell_script)
@ SPELL_SCHOOL_MASK_FROST
@ SPELL_EFFECT_SCRIPT_EFFECT
@ AURA_EFFECT_HANDLE_REAL
@ SPELL_AURA_PERIODIC_TRIGGER_SPELL
@ TRIGGERED_NONE
Not triggered.
#define SpellEffectFn(F, I, N)
#define AuraEffectPeriodicFn(F, I, N)
#define AuraEffectApplyFn(F, I, N, M)
#define AuraEffectRemoveFn(F, I, N, M)
@ UNIT_FLAG_NON_ATTACKABLE
std::map< ObjectGuid, ObjectGuid > IceBlockMap
@ SPELL_FROST_BREATH_ANTICHEAT
@ SPELL_WING_BUFFET_PERIODIC
@ SPELL_WING_BUFFET_DESPAWN_PERIODIC
@ SPELL_SUMMON_WING_BUFFET
void AddSC_boss_sapphiron()
HookList< EffectApplyHandler > AfterEffectRemove
HookList< EffectPeriodicHandler > OnEffectPeriodic
HookList< EffectApplyHandler > AfterEffectApply
bool operator()(Unit *unit) const
BlizzardTargetSelector(std::vector< Unit * > const &blizzards)
std::vector< Unit * > const & _blizzards
InstanceScript *const instance
void JustEngagedWith(Unit *who) override
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
void SetCanMelee(bool canMelee, bool fleeFromMelee=false)
uint32 m_spells[MAX_CREATURE_SPELLS]
void GetHomePosition(float &x, float &y, float &z, float &ori) const
void SetReactState(ReactStates st)
void Repeat(Milliseconds time)
void ScheduleEvent(uint32 eventId, Milliseconds time, uint32 group=0, uint8 phase=0)
bool IsInPhase(uint8 phase) const
void SetPhase(uint8 phase)
void SetRespawnTime(int32 respawn)
void DoRemoveAurasDueToSpellOnPlayers(uint32 spell, bool includePets=false, bool includeControlled=false)
virtual ObjectGuid GetGuidData(uint32 type) const override
EncounterState GetBossState(uint32 id) const
void MovePoint(uint32 id, Position const &pos, bool generatePath=true, Optional< float > finalOrient={}, Optional< float > speed={}, MovementWalkRunSpeedSelectionMode speedSelectionMode=MovementWalkRunSpeedSelectionMode::Default, Optional< float > closeEnoughDistance={})
void MoveFollow(Unit *target, float dist, ChaseAngle angle, Optional< Milliseconds > duration={}, MovementSlot slot=MOTION_SLOT_ACTIVE)
static ObjectGuid const Empty
static Creature * ToCreature(Object *o)
static Unit * ToUnit(Object *o)
static ObjectGuid GetGUID(Object const *o)
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
Creature * GetHitCreature() const
Unit * GetHitUnit() const
HookList< EffectHandler > OnEffectHitTarget
TaskContext & Repeat(std::chrono::duration< Rep, Period > duration)
TaskScheduler & Schedule(std::chrono::duration< Rep, Period > time, task_handler_t task)
TaskScheduler & Update(success_t const &callback=nullptr)
Creature * GetSummonerCreatureBase() const
SpellCastResult DoCastSelf(uint32 spellId, CastSpellExtraArgs const &args={})
virtual void InitializeAI()
virtual uint32 GetData(uint32) const
SpellCastResult DoCastVictim(uint32 spellId, CastSpellExtraArgs const &args={})
void SelectTargetList(std::list< Unit * > &targetList, uint32 num, SelectTargetMethod targetType, uint32 offset=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
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 ApplySpellImmune(uint32 spellId, SpellImmunity op, uint32 type, bool apply)
MotionMaster * GetMotionMaster()
bool SetHover(bool enable, bool updateAnimTier=true)
TempSummon * ToTempSummon()
void HandleEmoteCommand(Emote emoteId, Player *target=nullptr, Trinity::IteratorPair< int32 const * > spellVisualKitIds={}, int32 sequenceVariation=0)
void SetUnitFlag(UnitFlags flags)
int32 GetResistance(SpellSchools school) const
void RemoveUnitFlag(UnitFlags flags)
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
virtual uint32 GetData(uint32) const
virtual void SetData(uint32, uint32)
bool OnCheck(Player *, Unit *target) override
achievement_the_hundred_club()
void HandlePeriodic(AuraEffect const *)
void HandleScriptEffect(SpellEffIndex)
void HandleRemove(AuraEffect const *, AuraEffectHandleModes)
void HandlePeriodic(AuraEffect const *)
void HandleApply(AuraEffect const *, AuraEffectHandleModes)
void HandleDummy(SpellEffIndex)
bool Validate(SpellInfo const *) override
void PeriodicTick(AuraEffect const *)
TC_GAME_API Unit * GetUnit(WorldObject const &, ObjectGuid const &guid)
TC_GAME_API GameObject * GetGameObject(WorldObject const &u, ObjectGuid const &guid)
TC_GAME_API Player * GetPlayer(Map const *, ObjectGuid const &guid)
TC_GAME_API Creature * GetCreature(WorldObject const &u, ObjectGuid const &guid)
#define RegisterNaxxramasGameObjectAI(ai_name)
@ DATA_HAD_SAPPHIRON_BIRTH
#define RegisterNaxxramasCreatureAI(ai_name)
constexpr void GetPosition(float &x, float &y) const
bool HealthAbovePct(uint32 pct) const
T const & RAID_MODE(T const &normal10, T const &normal25) const
void JustEngagedWith(Unit *who) override
void JustDied(Unit *) override
ObjectGuid GetGUID(int32 data) const override
void DamageTaken(Unit *, uint32 &damage, DamageEffectType, SpellInfo const *) override
boss_sapphiron(Creature *creature)
void EnterPhaseGround(bool initial)
void MovementInform(uint32, uint32 id) override
void InitializeAI() override
uint32 GetData(uint32 data) const override
void UpdateAI(uint32 diff) override
GuidVector _iceboltTargets
void DoAction(int32 param) override
void SpellHitTarget(WorldObject *target, SpellInfo const *spellInfo) override
InstanceScript * instance
go_sapphiron_birth(GameObject *go)
void OnLootStateChanged(uint32 state, Unit *who) override
void SetGUID(ObjectGuid const &guid, int32 id) override
ObjectGuid GetGUID(int32 data) const override
npc_sapphiron_blizzard(Creature *creature)
void UpdateAI(uint32 diff) override
void InitializeAI() override
void JustAppeared() override
npc_sapphiron_wing_buffet(Creature *creature)