TrinityCore
firelands.h
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#ifndef FIRELANDS_H_
19#define FIRELANDS_H_
20
21#include "CreatureAIImpl.h"
22#include "EventProcessor.h"
23#include "ScriptedCreature.h"
24
25class Creature;
26
27#define DataHeader "FL"
28#define FirelandsScriptName "instance_firelands"
29
31
33{
41};
42
44{
45 // Bosses
46 NPC_SHANNOX = 53691,
50 NPC_BALEROC = 53494,
52 NPC_RAGNAROS = 52409,
53
54 // Alysrazor
57 NPC_EGG_PILE = 53795,
61
62 // Baleroc
64 NPC_MAGMAKIN = 54144
65};
66
68{
69 GO_BALEROC_FIREWALL = 209066
70};
71
73{
76};
77
79{
82};
83
85{
86 public:
88
89 bool Execute(uint64 /*e_time*/, uint32 /*p_time*/) override;
90
91 private:
93};
94
96{
97 public:
98 DelayedSpellCastEvent(Creature* owner, Unit* target, uint32 spellId, bool triggered) : _owner(owner), _target(target), _spellId(spellId), _triggered(triggered) { }
99
100 bool Execute(uint64 /*e_time*/, uint32 /*p_time*/) override;
101
102 private:
107};
108
110{
111 public:
112 bool operator()(WorldObject* object) const
113 {
114 return object->GetTypeId() != TYPEID_PLAYER;
115 }
116};
117
119{
120 firelands_bossAI(Creature* creature, uint32 bossId) : BossAI(creature, bossId) { }
121
122 void JustEngagedWith(Unit* target) override;
123 void JustDied(Unit* killer) override;
124 void EnterEvadeMode(EvadeReason why) override;
125};
126
127template<typename AI>
128inline AI* GetFirelandsAI(Creature* creature)
129{
130 return GetInstanceAI<AI>(creature, FirelandsScriptName);
131}
132
133#define RegisterFirelandsAI(AI) RegisterCreatureAIWithFactory(AI, GetFirelandsAI)
134
135#endif // FIRELANDS_H_
uint64_t uint64
Definition: Define.h:141
uint32_t uint32
Definition: Define.h:142
@ TYPEID_PLAYER
Definition: ObjectGuid.h:41
EvadeReason
Definition: UnitAICommon.h:30
DelayedAttackStartEvent(Creature *owner)
Definition: firelands.h:87
bool Execute(uint64, uint32) override
Definition: firelands.cpp:44
bool Execute(uint64, uint32) override
Definition: firelands.cpp:50
DelayedSpellCastEvent(Creature *owner, Unit *target, uint32 spellId, bool triggered)
Definition: firelands.h:98
bool operator()(WorldObject *object) const
Definition: firelands.h:112
Definition: Unit.h:627
uint32 const EncounterCount
Definition: firelands.h:30
FLCreatureIds
Definition: firelands.h:44
@ NPC_LORD_RHYOLITH
Definition: firelands.h:47
@ NPC_RAGNAROS
Definition: firelands.h:52
@ NPC_HARBINGER_OF_FLAME
Definition: firelands.h:58
@ NPC_MAGMAKIN
Definition: firelands.h:64
@ NPC_SMOULDERING_HATCHLING
Definition: firelands.h:60
@ NPC_BLAZING_MONSTROSITY_RIGHT
Definition: firelands.h:56
@ NPC_MOLTEN_EGG_TRASH
Definition: firelands.h:59
@ NPC_MAJORDOMO_STAGHELM
Definition: firelands.h:51
@ NPC_MAGMA_CONDUIT
Definition: firelands.h:63
@ NPC_BETH_TILAC
Definition: firelands.h:48
@ NPC_BALEROC
Definition: firelands.h:50
@ NPC_EGG_PILE
Definition: firelands.h:57
@ NPC_ALYSRAZOR
Definition: firelands.h:49
@ NPC_BLAZING_MONSTROSITY_LEFT
Definition: firelands.h:55
@ NPC_SHANNOX
Definition: firelands.h:46
FirelandsQuests
Definition: firelands.h:79
@ QUEST_HEART_OF_FLAME_H
Definition: firelands.h:81
@ QUEST_HEART_OF_FLAME_A
Definition: firelands.h:80
AI * GetFirelandsAI(Creature *creature)
Definition: firelands.h:128
#define FirelandsScriptName
Definition: firelands.h:28
FirelandsSpells
Definition: firelands.h:73
@ SPELL_SMOULDERING_2
Definition: firelands.h:75
@ SPELL_SMOULDERING_1
Definition: firelands.h:74
GameobjectIds
Definition: firelands.h:68
@ GO_BALEROC_FIREWALL
Definition: firelands.h:69
FLDataTypes
Definition: firelands.h:33
@ DATA_BETH_TILAC
Definition: firelands.h:34
@ DATA_ALYSRAZOR
Definition: firelands.h:37
@ DATA_MAJORDOMO_STAGHELM
Definition: firelands.h:39
@ DATA_RAGNAROS
Definition: firelands.h:40
@ DATA_BALEROC
Definition: firelands.h:38
@ DATA_SHANNOX
Definition: firelands.h:36
@ DATA_LORD_RHYOLITH
Definition: firelands.h:35
firelands_bossAI(Creature *creature, uint32 bossId)
Definition: firelands.h:120
void JustEngagedWith(Unit *target) override
Definition: firelands.cpp:56
void JustDied(Unit *killer) override
Definition: firelands.cpp:62
void EnterEvadeMode(EvadeReason why) override
Definition: firelands.cpp:70