TrinityCore
boss_illucia_barov.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/*
19Name: Boss_Illucia_Barov
20%Complete: 100
21Comment:
22Category: Scholomance
23*/
24
25#include "ScriptMgr.h"
26#include "scholomance.h"
27#include "ScriptedCreature.h"
28
30{
32 SPELL_DOMINATE = 7645, // UNUSED YET added for documentation
33 SPELL_FEAR = 12542,
35 SPELL_SILENCE = 12528
36};
37
39{
43 EVENT_FEAR = 4
44};
45
47{
48 public: boss_illucia_barov() : CreatureScript("boss_illucia_barov") { }
49
51 {
53
54 void JustEngagedWith(Unit* who) override
55 {
61 }
62
63 void UpdateAI(uint32 diff) override
64 {
65 if (!UpdateVictim())
66 return;
67
68 events.Update(diff);
69
71 return;
72
73 while (uint32 eventId = events.ExecuteEvent())
74 {
75 switch (eventId)
76 {
80 break;
84 break;
85 case EVENT_SILENCE:
88 break;
89 case EVENT_FEAR:
92 break;
93 default:
94 break;
95 }
96
98 return;
99 }
100 }
101 };
102
103 CreatureAI* GetAI(Creature* creature) const override
104 {
105 return GetScholomanceAI<boss_illuciabarovAI>(creature);
106 }
107};
108
110{
111 new boss_illucia_barov();
112}
uint32_t uint32
Definition: Define.h:142
Spells
Definition: PlayerAI.cpp:32
@ UNIT_STATE_CASTING
Definition: Unit.h:270
@ SPELL_SILENCE
@ SPELL_SHADOWSHOCK
@ SPELL_FEAR
@ SPELL_DOMINATE
@ SPELL_CURSEOFAGONY
void AddSC_boss_illuciabarov()
@ EVENT_CURSEOFAGONY
@ EVENT_FEAR
@ EVENT_SHADOWSHOCK
@ EVENT_SILENCE
void JustEngagedWith(Unit *who) override
EventMap events
bool UpdateVictim()
Definition: CreatureAI.cpp:245
Creature *const me
Definition: CreatureAI.h:61
uint32 ExecuteEvent()
Definition: EventMap.cpp:73
void Update(uint32 time)
Definition: EventMap.h:56
void ScheduleEvent(uint32 eventId, Milliseconds time, uint32 group=0, uint8 phase=0)
Definition: EventMap.cpp:36
SpellCastResult DoCastVictim(uint32 spellId, CastSpellExtraArgs const &args={})
Definition: UnitAI.cpp:180
Unit * SelectTarget(SelectTargetMethod targetType, uint32 offset=0, float dist=0.0f, bool playerOnly=false, bool withTank=true, int32 aura=0)
Definition: UnitAI.cpp:79
SpellCastResult DoCast(uint32 spellId)
Definition: UnitAI.cpp:89
Definition: Unit.h:627
bool HasUnitState(const uint32 f) const
Definition: Unit.h:732
CreatureAI * GetAI(Creature *creature) const override
@ DATA_LADYILLUCIABAROV
Definition: scholomance.h:30