TrinityCore
boss_akilzon.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 "ScriptMgr.h"
19#include "ScriptedCreature.h"
20#include "zulaman.h"
21
22enum Says
23{
30 SAY_DEATH = 6
31};
32
34{
35 public:
36 boss_akilzon() : CreatureScript("boss_akilzon") { }
37
38 struct boss_akilzonAI : public BossAI
39 {
40 boss_akilzonAI(Creature* creature) : BossAI(creature, DATA_AKILZON) { }
41
42 void Reset() override
43 {
44 _Reset();
45 }
46
47 void JustEngagedWith(Unit* who) override
48 {
51 }
52
53 void JustDied(Unit* /*killer*/) override
54 {
56 _JustDied();
57 }
58
59 void KilledUnit(Unit* who) override
60 {
61 if (who->GetTypeId() == TYPEID_PLAYER)
63 }
64
65 void UpdateAI(uint32 diff) override
66 {
67 if (!UpdateVictim())
68 return;
69
70 events.Update(diff);
71
73 return;
74 /*
75 while (uint32 eventId = events.ExecuteEvent())
76 {
77 switch (eventId)
78 {
79 default:
80 break;
81 }
82 }
83 */
84 }
85 };
86
87 CreatureAI* GetAI(Creature* creature) const override
88 {
89 return GetZulAmanAI<boss_akilzonAI>(creature);
90 }
91};
92
94{
95 new boss_akilzon();
96}
uint32_t uint32
Definition: Define.h:142
@ TYPEID_PLAYER
Definition: ObjectGuid.h:41
@ UNIT_STATE_CASTING
Definition: Unit.h:270
@ SAY_DEATH
@ SAY_PLAYER_KILL
@ SAY_AGGRO
@ SAY_SUMMON_EAGLE
@ EMOTE_ELECTRICAL_STORM
@ SAY_BERSERK
@ SAY_SUMMON_BIRDS
void AddSC_boss_akilzon()
Says
void JustEngagedWith(Unit *who) override
EventMap events
void _JustDied()
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 Update(uint32 time)
Definition: EventMap.h:56
TypeID GetTypeId() const
Definition: Object.h:173
Definition: Unit.h:627
bool HasUnitState(const uint32 f) const
Definition: Unit.h:732
CreatureAI * GetAI(Creature *creature) const override
void UpdateAI(uint32 diff) override
boss_akilzonAI(Creature *creature)
void KilledUnit(Unit *who) override
void JustDied(Unit *) override
void JustEngagedWith(Unit *who) override
@ DATA_AKILZON
Definition: zulaman.h:30