TrinityCore
boss_lord_marrowgar.cpp
Go to the documentation of this file.
1/*
2 * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the
6 * Free Software Foundation; either version 2 of the License, or (at your
7 * option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#include "icecrown_citadel.h"
19#include "InstanceScript.h"
20#include "Map.h"
21#include "MotionMaster.h"
22#include "MoveSplineInit.h"
23#include "ObjectAccessor.h"
24#include "Player.h"
26#include "ScriptedCreature.h"
27#include "ScriptMgr.h"
28#include "SpellAuras.h"
29#include "SpellScript.h"
30#include "TemporarySummon.h"
31
33{
42};
43
45{
46 // Lord Marrowgar
52
53 // Bone Spike
56
57 // Coldflame
60};
61
62uint32 const BoneSpikeSummonId[3] = {69062, 72669, 72670};
63
65{
74
77
79};
80
82{
85};
86
88{
90
91 // Manual marking for targets hit by Bone Slice as no aura exists for this purpose
92 // These units are the tanks in this encounter
93 // and should be immune to Bone Spike Graveyard
95 //DATA_SPIKE_IMMUNE_1, = 2, // Reserved & used
96 //DATA_SPIKE_IMMUNE_2, = 3, // Reserved & used
97
99};
100
102{
106
108{
109 public:
111
112 bool operator()(Unit* unit) const
113 {
114 if (unit->GetTypeId() != TYPEID_PLAYER)
115 return false;
116
117 if (unit->HasAura(SPELL_IMPALED))
118 return false;
119
120 // Check if it is one of the tanks soaking Bone Slice
121 for (uint32 i = 0; i < MAX_BONE_SPIKE_IMMUNE; ++i)
122 if (unit->GetGUID() == _ai->GetGUID(DATA_SPIKE_IMMUNE + i))
123 return false;
124
125 return true;
126 }
127
128 private:
130};
131
133{
135 {
136 _boneStormDuration = RAID_MODE(20s, 30s, 20s, 30s);
137 _baseSpeed = creature->GetSpeedRate(MOVE_RUN);
138 _coldflameLastPos.Relocate(creature);
139 _boneSlice = false;
140 }
141
142 void Reset() override
143 {
144 _Reset();
153 _boneSlice = false;
154 _boneSpikeImmune.clear();
155 }
156
157 void JustEngagedWith(Unit* /*who*/) override
158 {
160
161 me->setActive(true);
164 }
165
166 void JustDied(Unit* /*killer*/) override
167 {
169
170 _JustDied();
171 }
172
173 void JustReachedHome() override
174 {
178 }
179
180 void KilledUnit(Unit* victim) override
181 {
182 if (victim->GetTypeId() == TYPEID_PLAYER)
183 Talk(SAY_KILL);
184 }
185
186 void UpdateAI(uint32 diff) override
187 {
188 if (!UpdateVictim())
189 return;
190
191 events.Update(diff);
192
194 return;
195
196 while (uint32 eventId = events.ExecuteEvent())
197 {
198 switch (eventId)
199 {
204 break;
205 case EVENT_COLDFLAME:
210 else
213 break;
215 _boneSlice = false;
222 break;
224 if (Aura* pStorm = me->GetAura(SPELL_BONE_STORM))
225 pStorm->SetDuration(int32(_boneStormDuration.count()));
229 [[fallthrough]];
231 {
234 if (!unit)
235 unit = SelectTarget(SelectTargetMethod::Random, 0, 0.0f, true);
236 if (unit)
238 break;
239 }
241 if (MovementGenerator* movement = me->GetMotionMaster()->GetMovementGenerator([](MovementGenerator const* a) -> bool
242 {
243 if (a->GetMovementGeneratorType() == POINT_MOTION_TYPE)
244 {
245 PointMovementGenerator const* pointMovement = dynamic_cast<PointMovementGenerator const*>(a);
246 return pointMovement && pointMovement->GetId() == POINT_TARGET_BONESTORM_PLAYER;
247 }
248 return false;
249 }))
250 me->GetMotionMaster()->Remove(movement);
255 if (!IsHeroic())
257 break;
259 _boneSlice = true;
260 break;
261 case EVENT_ENRAGE:
262 DoCast(me, SPELL_BERSERK, true);
264 break;
265 }
266
268 return;
269 }
270
271 // We should not melee attack when storming
273 return;
274
275 // 10 seconds since encounter start Bone Slice replaces melee attacks
278 }
279
280 void MovementInform(uint32 type, uint32 id) override
281 {
283 return;
284
285 // lock movement
286 me->GetMotionMaster()->MoveIdle();
287 }
288
290 {
291 return &_coldflameLastPos;
292 }
293
294 ObjectGuid GetGUID(int32 type /*= 0 */) const override
295 {
296 switch (type)
297 {
299 return _coldflameTarget;
300 case DATA_SPIKE_IMMUNE + 0:
301 case DATA_SPIKE_IMMUNE + 1:
302 case DATA_SPIKE_IMMUNE + 2:
303 {
304 uint32 index = uint32(type - DATA_SPIKE_IMMUNE);
305 if (index < _boneSpikeImmune.size())
306 return _boneSpikeImmune[index];
307
308 break;
309 }
310 }
311
312 return ObjectGuid::Empty;
313 }
314
315 void SetGUID(ObjectGuid const& guid, int32 id) override
316 {
317 switch (id)
318 {
320 _coldflameTarget = guid;
321 break;
323 _boneSpikeImmune.push_back(guid);
324 break;
325 }
326 }
327
328 void DoAction(int32 action) override
329 {
330 switch (action)
331 {
333 _boneSpikeImmune.clear();
334 break;
336 if (me->IsAlive())
338 break;
339 default:
340 break;
341 }
342 }
343
344private:
351};
352
354
356{
357 npc_coldflame(Creature* creature) : ScriptedAI(creature) { }
358
359 void IsSummonedBy(WorldObject* ownerWO) override
360 {
361 Creature* owner = ownerWO->ToCreature();
362 if (!owner)
363 return;
364
365 Position pos;
366 if (MarrowgarAI* marrowgarAI = CAST_AI(MarrowgarAI, owner->GetAI()))
367 pos.Relocate(marrowgarAI->GetLastColdflamePosition());
368 else
369 pos.Relocate(owner);
370
371 if (owner->HasAura(SPELL_BONE_STORM))
372 {
373 float ang = pos.GetAbsoluteAngle(me);
374 me->SetOrientation(ang);
375 owner->GetNearPoint2D(nullptr, pos.m_positionX, pos.m_positionY, 5.0f - owner->GetCombatReach(), ang);
376 }
377 else
378 {
380 if (!target)
381 {
383 return;
384 }
385
386 float ang = pos.GetAbsoluteAngle(target);
387 me->SetOrientation(ang);
388 owner->GetNearPoint2D(nullptr, pos.m_positionX, pos.m_positionY, 15.0f - owner->GetCombatReach(), ang);
389 }
390
394 }
395
396 void UpdateAI(uint32 diff) override
397 {
398 _events.Update(diff);
399
401 {
402 Position newPos = me->GetNearPosition(5.0f, 0.0f);
406 }
407 }
408
409private:
411};
412
414{
415 npc_bone_spike(Creature* creature) : ScriptedAI(creature), _hasTrappedUnit(false)
416 {
417 ASSERT(creature->GetVehicleKit());
418
419 SetCombatMovement(false);
420 }
421
422 void JustDied(Unit* /*killer*/) override
423 {
424 if (TempSummon* summ = me->ToTempSummon())
425 if (Unit* trapped = summ->GetSummonerUnit())
426 trapped->RemoveAurasDueToSpell(SPELL_IMPALED);
427
429 }
430
431 void KilledUnit(Unit* victim) override
432 {
435 }
436
437 void IsSummonedBy(WorldObject* summonerWO) override
438 {
439 Unit* summoner = summonerWO->ToUnit();
440 if (!summoner)
441 return;
442 DoCast(summoner, SPELL_IMPALED);
443 summoner->CastSpell(me, SPELL_RIDE_VEHICLE, true);
445 _hasTrappedUnit = true;
446 }
447
448 void PassengerBoarded(Unit* passenger, int8 /*seat*/, bool apply) override
449 {
450 if (!apply)
451 return;
452
456 std::function<void(Movement::MoveSplineInit&)> initializer = [](Movement::MoveSplineInit& init)
457 {
458 init.DisableTransportPathTransformations();
459 init.MoveTo(-0.02206125f, -0.02132235f, 5.514783f, false);
460 };
461 passenger->GetMotionMaster()->LaunchMoveSpline(std::move(initializer), EVENT_VEHICLE_BOARD, MOTION_PRIORITY_HIGHEST);
462 }
463
464 void UpdateAI(uint32 diff) override
465 {
466 if (!_hasTrappedUnit)
467 return;
468
469 _events.Update(diff);
470
472 if (InstanceScript* instance = me->GetInstanceScript())
473 instance->SetData(DATA_BONED_ACHIEVEMENT, uint32(false));
474 }
475
476private:
479};
480
481// 69140 - Coldflame
483{
484 void SelectTarget(std::list<WorldObject*>& targets)
485 {
486 targets.clear();
487 // select any unit but not the tank
488 Unit* target = GetCaster()->GetAI()->SelectTarget(SelectTargetMethod::Random, 0, -GetCaster()->GetCombatReach(), true, false, -SPELL_IMPALED);
489 if (!target)
490 target = GetCaster()->GetAI()->SelectTarget(SelectTargetMethod::Random, 0, 0.0f, true); // or the tank if its solo
491 if (!target)
492 return;
493
495 targets.push_back(target);
496 }
497
499 {
500 PreventHitDefaultEffect(effIndex);
502 }
503
504 void Register() override
505 {
508 }
509};
510
511// 72705 - Coldflame (Bonestorm)
513{
515 {
516 PreventHitDefaultEffect(effIndex);
517 for (uint8 i = 0; i < 4; ++i)
519 }
520
521 void Register() override
522 {
524 }
525};
526
527// 69146, 70823, 70824, 70825 - Coldflame (Damage)
529{
530 bool CanBeAppliedOn(Unit* target)
531 {
532 if (target->HasAura(SPELL_IMPALED))
533 return false;
534
535 if (target->GetExactDist2d(GetOwner()) > GetEffectInfo(EFFECT_0).CalcRadius())
536 return false;
537
538 if (Aura* aur = target->GetAura(GetId()))
539 if (aur->GetOwner() != GetOwner())
540 return false;
541
542 return true;
543 }
544
545 void Register() override
546 {
548 }
549};
550
551// 69057, 70826, 72088, 72089 - Bone Spike Graveyard
553{
554 bool Validate(SpellInfo const* /*spell*/) override
555 {
557 }
558
559 bool Load() override
560 {
561 return GetCaster()->GetTypeId() == TYPEID_UNIT && GetCaster()->IsAIEnabled();
562 }
563
565 {
567 }
568
570 {
571 PreventHitDefaultEffect(effIndex);
572 if (Creature* marrowgar = GetCaster()->ToCreature())
573 {
574 CreatureAI* marrowgarAI = marrowgar->AI();
575 uint8 boneSpikeCount = uint8(GetCaster()->GetMap()->Is25ManRaid() ? 3 : 1);
576
577 std::list<Unit*> targets;
578 marrowgarAI->SelectTargetList(targets, boneSpikeCount, SelectTargetMethod::Random, 1, BoneSpikeTargetSelector(marrowgarAI));
579 if (targets.empty())
580 return;
581
582 uint32 i = 0;
583 for (std::list<Unit*>::const_iterator itr = targets.begin(); itr != targets.end(); ++itr, ++i)
584 {
585 Unit* target = *itr;
586 target->CastSpell(target, BoneSpikeSummonId[i], true);
587 if (!target->IsAlive()) // make sure we don't get any stuck spikes on dead targets
588 {
589 if (Aura* aura = target->GetAura(SPELL_IMPALED))
590 {
591 if (Creature* spike = ObjectAccessor::GetCreature(*target, aura->GetCasterGUID()))
592 spike->DespawnOrUnsummon();
593 aura->Remove();
594 }
595 }
596 }
597
598 marrowgarAI->Talk(SAY_BONESPIKE);
599 }
600 }
601
602 void Register() override
603 {
606 }
607};
608
609// 69075, 70834, 70835, 70836 - Bone Storm
611{
613 {
614 SetHitDamage(int32(GetHitDamage() / std::max(std::sqrt(GetHitUnit()->GetExactDist2d(GetCaster())), 1.0f)));
615 }
616
617 void Register() override
618 {
620 }
621};
622
623// 69055, 70814 - Bone Slice
625{
626public:
628 {
629 _targetCount = 0;
630 }
631
632private:
634 {
636 }
637
638 void CountTargets(std::list<WorldObject*>& targets)
639 {
640 _targetCount = std::min<uint32>(targets.size(), GetSpellInfo()->MaxAffectedTargets);
641 }
642
644 {
645 // Mark the unit as hit, even if the spell missed or was dodged/parried
647
648 if (!_targetCount)
649 return; // This spell can miss all targets
650
652 }
653
654 void Register() override
655 {
659 }
660
662};
663
665{
666 public:
667 at_lord_marrowgar_entrance() : OnlyOnceAreaTriggerScript("at_lord_marrowgar_entrance") { }
668
669 bool TryHandleOnce(Player* player, AreaTriggerEntry const* /*areaTrigger*/) override
670 {
671 if (InstanceScript* instance = player->GetInstanceScript())
672 if (Creature* lordMarrowgar = ObjectAccessor::GetCreature(*player, instance->GetGuidData(DATA_LORD_MARROWGAR)))
673 lordMarrowgar->AI()->DoAction(ACTION_TALK_ENTER_ZONE);
674
675 return true;
676 }
677
678};
679
681{
682 // Creatures
686
687 // Spells
694
695 // AreaTriggers
697}
Actions
uint8_t uint8
Definition: Define.h:144
int8_t int8
Definition: Define.h:140
int32_t int32
Definition: Define.h:138
uint32_t uint32
Definition: Define.h:142
std::chrono::milliseconds Milliseconds
Milliseconds shorthand typedef.
Definition: Duration.h:29
#define ASSERT
Definition: Errors.h:68
@ IN_PROGRESS
@ FAIL
@ MOTION_PRIORITY_HIGHEST
@ POINT_MOTION_TYPE
@ TYPEID_UNIT
Definition: ObjectGuid.h:40
@ TYPEID_PLAYER
Definition: ObjectGuid.h:41
std::vector< ObjectGuid > GuidVector
Definition: ObjectGuid.h:395
Spells
Definition: PlayerAI.cpp:32
@ SPELL_BERSERK
Definition: PlayerAI.cpp:371
#define RegisterSpellScript(spell_script)
Definition: ScriptMgr.h:1369
SpellEffIndex
Definition: SharedDefines.h:29
@ EFFECT_1
Definition: SharedDefines.h:31
@ EFFECT_0
Definition: SharedDefines.h:30
@ TARGET_UNIT_DEST_AREA_ENEMY
@ EVENT_VEHICLE_BOARD
@ SPELL_EFFECT_SCRIPT_EFFECT
@ SPELL_EFFECT_APPLY_AURA
SpellCastResult
@ SPELL_CAST_OK
@ SPELL_FAILED_NO_VALID_TARGETS
@ SPELL_FAILED_INTERRUPTED
#define SpellCheckCastFn(F)
Definition: SpellScript.h:830
#define SpellEffectFn(F, I, N)
Definition: SpellScript.h:842
#define SpellObjectAreaTargetSelectFn(F, I, N)
Definition: SpellScript.h:864
#define SpellCastFn(F)
Definition: SpellScript.h:825
#define SpellHitFn(F)
Definition: SpellScript.h:854
#define AuraCheckAreaTargetFn(F)
Definition: SpellScript.h:2008
#define CAST_AI(a, b)
Definition: UnitAI.h:28
@ MOVE_RUN
Definition: UnitDefines.h:118
@ CURRENT_MELEE_SPELL
Definition: Unit.h:589
@ UNIT_STATE_CASTING
Definition: Unit.h:270
@ ACTION_CLEAR_SPIKE_IMMUNITIES
@ ACTION_TALK_ENTER_ZONE
boss_lord_marrowgar MarrowgarAI
@ SPELL_COLDFLAME_BONE_STORM
@ SPELL_RIDE_VEHICLE
@ SPELL_COLDFLAME_SUMMON
@ SPELL_COLDFLAME_PASSIVE
@ SPELL_COLDFLAME_NORMAL
@ SPELL_BONE_SPIKE_GRAVEYARD
@ SPELL_IMPALED
@ SPELL_BONE_STORM
@ SPELL_BONE_SLICE
void AddSC_boss_lord_marrowgar()
@ POINT_TARGET_BONESTORM_PLAYER
@ POINT_TARGET_COLDFLAME
uint32 const BoneSpikeSummonId[3]
@ MAX_BONE_SPIKE_IMMUNE
@ DATA_COLDFLAME_GUID
@ DATA_SPIKE_IMMUNE
@ SAY_ENTER_ZONE
@ SAY_BONESPIKE
@ SAY_BONE_STORM
@ SAY_BERSERK
@ EMOTE_BONE_STORM
@ EVENT_COLDFLAME_TRIGGER
@ EVENT_FAIL_BONED
@ EVENT_WARN_BONE_STORM
@ EVENT_GROUP_SPECIAL
@ EVENT_ENRAGE
@ EVENT_BONE_STORM_END
@ EVENT_BONE_STORM_MOVE
@ EVENT_COLDFLAME
@ EVENT_BONE_SPIKE_GRAVEYARD
@ EVENT_BONE_STORM_BEGIN
@ EVENT_ENABLE_BONE_SLICE
WorldObject * GetOwner() const
SpellEffectInfo const & GetEffectInfo(SpellEffIndex effIndex) const
HookList< CheckAreaTargetHandler > DoCheckAreaTarget
Definition: SpellScript.h:2007
uint32 GetId() const
bool operator()(Unit *unit) const
InstanceScript *const instance
void _JustReachedHome()
EventMap events
void _JustDied()
void DoZoneInCombat()
Definition: CreatureAI.h:161
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr)
Definition: CreatureAI.cpp:56
bool UpdateVictim()
Definition: CreatureAI.cpp:245
Creature *const me
Definition: CreatureAI.h:61
void DespawnOrUnsummon(Milliseconds timeToDespawn=0s, Seconds forceRespawnTime=0s)
Definition: Creature.cpp:2415
uint32 ExecuteEvent()
Definition: EventMap.cpp:73
void Update(uint32 time)
Definition: EventMap.h:56
void DelayEvents(Milliseconds delay)
Definition: EventMap.cpp:96
void ScheduleEvent(uint32 eventId, Milliseconds time, uint32 group=0, uint8 phase=0)
Definition: EventMap.cpp:36
void CancelEvent(uint32 eventId)
Definition: EventMap.cpp:131
void RescheduleEvent(uint32 eventId, Milliseconds time, uint32 group=0, uint8 phase=0)
Definition: EventMap.cpp:52
virtual bool SetBossState(uint32 id, EncounterState state)
void LaunchMoveSpline(std::function< void(Movement::MoveSplineInit &init)> &&initializer, uint32 id=0, MovementGeneratorPriority priority=MOTION_PRIORITY_NORMAL, MovementGeneratorType type=EFFECT_MOTION_TYPE)
void MoveChase(Unit *target, Optional< ChaseRange > dist={}, Optional< ChaseAngle > angle={})
void MovePoint(uint32 id, Position const &pos, bool generatePath=true, Optional< float > finalOrient={}, Optional< float > speed={}, MovementWalkRunSpeedSelectionMode speedSelectionMode=MovementWalkRunSpeedSelectionMode::Default, Optional< float > closeEnoughDistance={})
MovementGenerator * GetMovementGenerator(std::function< bool(MovementGenerator const *)> const &filter, MovementSlot slot=MOTION_SLOT_ACTIVE) const
void Remove(MovementGenerator *movement, MovementSlot slot=MOTION_SLOT_ACTIVE)
static ObjectGuid const Empty
Definition: ObjectGuid.h:274
void Clear()
Definition: ObjectGuid.h:286
static Creature * ToCreature(Object *o)
Definition: Object.h:219
static Unit * ToUnit(Object *o)
Definition: Object.h:225
TypeID GetTypeId() const
Definition: Object.h:173
static ObjectGuid GetGUID(Object const *o)
Definition: Object.h:159
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
Definition: SpellScript.h:162
HookList< CheckCastHandler > OnCheckCast
Definition: SpellScript.h:829
int32 GetHitDamage() const
Unit * GetCaster() const
HookList< HitHandler > OnHit
Definition: SpellScript.h:850
void PreventHitDefaultEffect(SpellEffIndex effIndex)
Unit * GetHitUnit() const
int32 GetEffectValue() const
HookList< EffectHandler > OnEffectHitTarget
Definition: SpellScript.h:840
HookList< CastHandler > BeforeCast
Definition: SpellScript.h:820
void SetHitDamage(int32 damage)
SpellInfo const * GetSpellInfo() const
HookList< ObjectAreaTargetSelectHandler > OnObjectAreaTargetSelect
Definition: SpellScript.h:863
Definition: UnitAI.h:50
virtual void DoAction(int32)
Definition: UnitAI.h:72
SpellCastResult DoCastVictim(uint32 spellId, CastSpellExtraArgs const &args={})
Definition: UnitAI.cpp:180
virtual ObjectGuid GetGUID(int32=0) const
Definition: UnitAI.h:76
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)
Definition: UnitAI.cpp:84
Unit * SelectTarget(SelectTargetMethod targetType, uint32 offset=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
Definition: UnitAI.cpp:79
virtual void SetGUID(ObjectGuid const &, int32=0)
Definition: UnitAI.h:75
SpellCastResult DoCastAOE(uint32 spellId, CastSpellExtraArgs const &args={})
Definition: UnitAI.h:161
SpellCastResult DoCast(uint32 spellId)
Definition: UnitAI.cpp:89
Definition: Unit.h:627
void FinishSpell(CurrentSpellTypes spellType, SpellCastResult result=SPELL_CAST_OK)
Definition: Unit.cpp:3047
MotionMaster * GetMotionMaster()
Definition: Unit.h:1652
bool IsAlive() const
Definition: Unit.h:1164
float GetCombatReach() const override
Definition: Unit.h:694
TempSummon * ToTempSummon()
Definition: Unit.h:1756
UnitAI * GetAI() const
Definition: Unit.h:660
bool IsAIEnabled() const
Definition: Unit.h:658
Aura * GetAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4560
void NearTeleportTo(Position const &pos, bool casting=false)
Definition: Unit.cpp:12327
float GetSpeedRate(UnitMoveType mtype) const
Definition: Unit.h:1644
Unit * GetVictim() const
Definition: Unit.h:715
void SetSpeedRate(UnitMoveType mtype, float rate)
Definition: Unit.cpp:8525
bool HasUnitState(const uint32 f) const
Definition: Unit.h:732
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4664
Vehicle * GetVehicleKit() const
Definition: Unit.h:1711
void RemoveAurasDueToSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, uint32 reqEffMask=0, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition: Unit.cpp:3831
Spell * GetCurrentSpell(CurrentSpellTypes spellType) const
Definition: Unit.h:1442
InstanceScript * GetInstanceScript() const
Definition: Object.cpp:1042
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
Definition: Object.cpp:2896
void setActive(bool isActiveObject)
Definition: Object.cpp:922
Position GetNearPosition(float dist, float angle)
Definition: Object.cpp:3409
void GetNearPoint2D(WorldObject const *searcher, float &x, float &y, float distance, float absAngle) const
Definition: Object.cpp:3339
virtual void SetData(uint32, uint32)
Definition: ZoneScript.h:92
bool TryHandleOnce(Player *player, AreaTriggerEntry const *) override
void CountTargets(std::list< WorldObject * > &targets)
void HandleSpikes(SpellEffIndex effIndex)
bool Validate(SpellInfo const *) override
void HandleScriptEffect(SpellEffIndex effIndex)
void HandleScriptEffect(SpellEffIndex effIndex)
void SelectTarget(std::list< WorldObject * > &targets)
#define RegisterIcecrownCitadelCreatureAI(ai_name)
@ DATA_LORD_MARROWGAR
@ DATA_BONED_ACHIEVEMENT
MovementPoints
void apply(T *val)
Definition: ByteConverter.h:41
TC_GAME_API Player * GetPlayer(Map const *, ObjectGuid const &guid)
TC_GAME_API Creature * GetCreature(WorldObject const &u, ObjectGuid const &guid)
constexpr void SetOrientation(float orientation)
Definition: Position.h:71
constexpr float GetPositionX() const
Definition: Position.h:76
constexpr float GetPositionY() const
Definition: Position.h:77
float GetExactDist2d(const float x, const float y) const
Definition: Position.h:106
float m_positionX
Definition: Position.h:53
float m_positionY
Definition: Position.h:54
float GetAbsoluteAngle(float x, float y) const
Definition: Position.h:125
constexpr void Relocate(float x, float y)
Definition: Position.h:63
constexpr float GetOrientation() const
Definition: Position.h:79
constexpr float GetPositionZ() const
Definition: Position.h:78
bool IsHeroic() const
void SetCombatMovement(bool allowMovement)
T const & RAID_MODE(T const &normal10, T const &normal25) const
void SetGUID(ObjectGuid const &guid, int32 id) override
void JustEngagedWith(Unit *) override
Position const * GetLastColdflamePosition() const
void JustDied(Unit *) override
ObjectGuid GetGUID(int32 type) const override
void UpdateAI(uint32 diff) override
boss_lord_marrowgar(Creature *creature)
void MovementInform(uint32 type, uint32 id) override
void JustReachedHome() override
void DoAction(int32 action) override
void KilledUnit(Unit *victim) override
void JustDied(Unit *) override
npc_bone_spike(Creature *creature)
void UpdateAI(uint32 diff) override
void KilledUnit(Unit *victim) override
void IsSummonedBy(WorldObject *summonerWO) override
void PassengerBoarded(Unit *passenger, int8, bool apply) override
== Fields =======================================
void IsSummonedBy(WorldObject *ownerWO) override
npc_coldflame(Creature *creature)
void UpdateAI(uint32 diff) override