TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Creature.h File Reference
#include "Common.h"
#include "Unit.h"
#include "UpdateMask.h"
#include "ItemTemplate.h"
#include "LootMgr.h"
#include "DatabaseEnv.h"
#include "Cell.h"
#include <list>
+ Include dependency graph for Creature.h:

Go to the source code of this file.

Classes

struct  CreatureTemplate
 
struct  CreatureBaseStats
 
struct  CreatureLocale
 
struct  GossipMenuItemsLocale
 
struct  PointOfInterestLocale
 
struct  EquipmentInfo
 
struct  CreatureData
 
struct  CreatureModelInfo
 
struct  CreatureAddon
 
struct  VendorItem
 
struct  VendorItemData
 
struct  VendorItemCount
 
struct  TrainerSpell
 
struct  TrainerSpellData
 
class  Creature
 
class  AssistDelayEvent
 
class  ForcedDespawnDelayEvent
 

Macros

#define CREATURE_FLAG_EXTRA_DB_ALLOWED
 
#define CREATURE_REGEN_INTERVAL   2 * IN_MILLISECONDS
 
#define MAX_KILL_CREDIT   2
 
#define MAX_CREATURE_MODELS   4
 
#define MAX_CREATURE_NAMES   4
 
#define CREATURE_MAX_SPELLS   8
 
#define MAX_CREATURE_DIFFICULTIES   3
 
#define MAX_TRAINERSPELL_ABILITY_REQS   3
 
#define CREATURE_Z_ATTACK_RANGE   3
 
#define MAX_VENDOR_ITEMS   150
 

Typedefs

typedef std::vector< uint32CreatureQuestItemList
 
typedef std::unordered_map
< uint32,
CreatureQuestItemList
CreatureQuestItemMap
 
typedef std::unordered_map
< uint32, CreatureTemplate
CreatureTemplateContainer
 
typedef std::unordered_map
< uint16, CreatureBaseStats
CreatureBaseStatsContainer
 
typedef std::unordered_map
< uint8, EquipmentInfo
EquipmentInfoContainerInternal
 
typedef std::unordered_map
< uint32,
EquipmentInfoContainerInternal
EquipmentInfoContainer
 
typedef std::unordered_map
< uint16, CreatureModelInfo
CreatureModelContainer
 
typedef std::unordered_map
< ObjectGuid::LowType,
CreatureAddon
CreatureAddonContainer
 
typedef std::unordered_map
< uint32, CreatureAddon
CreatureTemplateAddonContainer
 
typedef std::vector< VendorItem * > VendorItemList
 
typedef std::list
< VendorItemCount
VendorItemCounts
 
typedef std::unordered_map
< uint32, TrainerSpell
TrainerSpellMap
 
typedef std::map< uint32, time_t > CreatureSpellCooldowns
 
typedef std::vector< uint8CreatureTextRepeatIds
 
typedef std::unordered_map
< uint8, CreatureTextRepeatIds
CreatureTextRepeatGroup
 

Enumerations

enum  CreatureFlagsExtra {
  CREATURE_FLAG_EXTRA_INSTANCE_BIND = 0x00000001, CREATURE_FLAG_EXTRA_CIVILIAN = 0x00000002, CREATURE_FLAG_EXTRA_NO_PARRY = 0x00000004, CREATURE_FLAG_EXTRA_NO_PARRY_HASTEN = 0x00000008,
  CREATURE_FLAG_EXTRA_NO_BLOCK = 0x00000010, CREATURE_FLAG_EXTRA_NO_CRUSH = 0x00000020, CREATURE_FLAG_EXTRA_NO_XP_AT_KILL = 0x00000040, CREATURE_FLAG_EXTRA_TRIGGER = 0x00000080,
  CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, CREATURE_FLAG_EXTRA_GUARD = 0x00008000, CREATURE_FLAG_EXTRA_NO_CRIT = 0x00020000,
  CREATURE_FLAG_EXTRA_NO_SKILLGAIN = 0x00040000, CREATURE_FLAG_EXTRA_TAUNT_DIMINISH = 0x00080000, CREATURE_FLAG_EXTRA_ALL_DIMINISH = 0x00100000, CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ = 0x00200000,
  CREATURE_FLAG_EXTRA_DUNGEON_BOSS = 0x10000000, CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING = 0x20000000, CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK = 0x40000000
}
 
enum  InhabitTypeValues { INHABIT_GROUND = 1, INHABIT_WATER = 2, INHABIT_AIR = 4, INHABIT_ANYWHERE = INHABIT_GROUND | INHABIT_WATER | INHABIT_AIR }
 
enum  ChatType {
  CHAT_TYPE_SAY = 0, CHAT_TYPE_YELL = 1, CHAT_TYPE_TEXT_EMOTE = 2, CHAT_TYPE_BOSS_EMOTE = 3,
  CHAT_TYPE_WHISPER = 4, CHAT_TYPE_BOSS_WHISPER = 5, CHAT_TYPE_ZONE_YELL = 6, CHAT_TYPE_END = 255
}
 

Macro Definition Documentation

#define CREATURE_FLAG_EXTRA_DB_ALLOWED
Value:
Definition: Creature.h:42
Definition: Creature.h:54
Definition: Creature.h:50
Definition: Creature.h:56
Definition: Creature.h:47
Definition: Creature.h:44
Definition: Creature.h:46
Definition: Creature.h:45
Definition: Creature.h:51
Definition: Creature.h:53
Definition: Creature.h:48
Definition: Creature.h:55
Definition: Creature.h:52
Definition: Creature.h:49
Definition: Creature.h:43
#define CREATURE_MAX_SPELLS   8
#define CREATURE_REGEN_INTERVAL   2 * IN_MILLISECONDS
#define CREATURE_Z_ATTACK_RANGE   3
#define MAX_CREATURE_DIFFICULTIES   3
#define MAX_CREATURE_MODELS   4
#define MAX_CREATURE_NAMES   4
#define MAX_KILL_CREDIT   2
#define MAX_TRAINERSPELL_ABILITY_REQS   3
#define MAX_VENDOR_ITEMS   150

Typedef Documentation

typedef std::unordered_map<uint16, CreatureBaseStats> CreatureBaseStatsContainer
typedef std::unordered_map<uint16, CreatureModelInfo> CreatureModelContainer
typedef std::vector<uint32> CreatureQuestItemList
typedef std::unordered_map<uint32, CreatureQuestItemList> CreatureQuestItemMap
typedef std::map<uint32, time_t> CreatureSpellCooldowns
typedef std::unordered_map<uint32, CreatureAddon> CreatureTemplateAddonContainer
typedef std::unordered_map<uint32, CreatureTemplate> CreatureTemplateContainer
typedef std::unordered_map<uint8, CreatureTextRepeatIds> CreatureTextRepeatGroup
typedef std::vector<uint8> CreatureTextRepeatIds
typedef std::unordered_map<uint8, EquipmentInfo> EquipmentInfoContainerInternal
typedef std::unordered_map<uint32 , TrainerSpell> TrainerSpellMap
typedef std::list<VendorItemCount> VendorItemCounts
typedef std::vector<VendorItem*> VendorItemList

Enumeration Type Documentation

enum ChatType
Enumerator
CHAT_TYPE_SAY 
CHAT_TYPE_YELL 
CHAT_TYPE_TEXT_EMOTE 
CHAT_TYPE_BOSS_EMOTE 
CHAT_TYPE_WHISPER 
CHAT_TYPE_BOSS_WHISPER 
CHAT_TYPE_ZONE_YELL 
CHAT_TYPE_END 
339 {
340  CHAT_TYPE_SAY = 0,
341  CHAT_TYPE_YELL = 1,
344  CHAT_TYPE_WHISPER = 4,
347  CHAT_TYPE_END = 255
348 };
Definition: Creature.h:341
Definition: Creature.h:343
Definition: Creature.h:345
Definition: Creature.h:340
Definition: Creature.h:347
Definition: Creature.h:342
Definition: Creature.h:346
Definition: Creature.h:344
Enumerator
CREATURE_FLAG_EXTRA_INSTANCE_BIND 
CREATURE_FLAG_EXTRA_CIVILIAN 
CREATURE_FLAG_EXTRA_NO_PARRY 
CREATURE_FLAG_EXTRA_NO_PARRY_HASTEN 
CREATURE_FLAG_EXTRA_NO_BLOCK 
CREATURE_FLAG_EXTRA_NO_CRUSH 
CREATURE_FLAG_EXTRA_NO_XP_AT_KILL 
CREATURE_FLAG_EXTRA_TRIGGER 
CREATURE_FLAG_EXTRA_NO_TAUNT 
CREATURE_FLAG_EXTRA_WORLDEVENT 
CREATURE_FLAG_EXTRA_GUARD 
CREATURE_FLAG_EXTRA_NO_CRIT 
CREATURE_FLAG_EXTRA_NO_SKILLGAIN 
CREATURE_FLAG_EXTRA_TAUNT_DIMINISH 
CREATURE_FLAG_EXTRA_ALL_DIMINISH 
CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ 
CREATURE_FLAG_EXTRA_DUNGEON_BOSS 
CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING 
CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK 
41 {
42  CREATURE_FLAG_EXTRA_INSTANCE_BIND = 0x00000001, // creature kill bind instance with killer and killer's group
43  CREATURE_FLAG_EXTRA_CIVILIAN = 0x00000002, // not aggro (ignore faction/reputation hostility)
44  CREATURE_FLAG_EXTRA_NO_PARRY = 0x00000004, // creature can't parry
45  CREATURE_FLAG_EXTRA_NO_PARRY_HASTEN = 0x00000008, // creature can't counter-attack at parry
46  CREATURE_FLAG_EXTRA_NO_BLOCK = 0x00000010, // creature can't block
47  CREATURE_FLAG_EXTRA_NO_CRUSH = 0x00000020, // creature can't do crush attacks
48  CREATURE_FLAG_EXTRA_NO_XP_AT_KILL = 0x00000040, // creature kill not provide XP
49  CREATURE_FLAG_EXTRA_TRIGGER = 0x00000080, // trigger creature
50  CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, // creature is immune to taunt auras and effect attack me
51  CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, // custom flag for world event creatures (left room for merging)
52  CREATURE_FLAG_EXTRA_GUARD = 0x00008000, // Creature is guard
53  CREATURE_FLAG_EXTRA_NO_CRIT = 0x00020000, // creature can't do critical strikes
54  CREATURE_FLAG_EXTRA_NO_SKILLGAIN = 0x00040000, // creature won't increase weapon skills
55  CREATURE_FLAG_EXTRA_TAUNT_DIMINISH = 0x00080000, // Taunt is a subject to diminishing returns on this creautre
56  CREATURE_FLAG_EXTRA_ALL_DIMINISH = 0x00100000, // creature is subject to all diminishing returns as player are
57  CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ = 0x00200000, // creature does not need to take player damage for kill credit
58  CREATURE_FLAG_EXTRA_DUNGEON_BOSS = 0x10000000, // creature is a dungeon boss (SET DYNAMICALLY, DO NOT ADD IN DB)
59  CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING = 0x20000000, // creature ignore pathfinding
60  CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK = 0x40000000 // creature is immune to knockback effects
61 };
Definition: Creature.h:42
Definition: Creature.h:54
Definition: Creature.h:50
Definition: Creature.h:56
Definition: Creature.h:47
Definition: Creature.h:44
Definition: Creature.h:46
Definition: Creature.h:45
Definition: Creature.h:51
Definition: Creature.h:53
Definition: Creature.h:48
Definition: Creature.h:55
Definition: Creature.h:52
Definition: Creature.h:58
Definition: Creature.h:49
Definition: Creature.h:43
Enumerator
INHABIT_GROUND 
INHABIT_WATER 
INHABIT_AIR 
INHABIT_ANYWHERE 
330 {
331  INHABIT_GROUND = 1,
332  INHABIT_WATER = 2,
333  INHABIT_AIR = 4,
335 };
Definition: Creature.h:332
Definition: Creature.h:334
Definition: Creature.h:333
Definition: Creature.h:331