TrinityCore
BattlePets Namespace Reference

Classes

struct  BattlePet
 
class  BattlePetMgr
 

Enumerations

enum  BattlePetMisc {
  DEFAULT_MAX_BATTLE_PETS_PER_SPECIES = 3, BATTLE_PET_CAGE_ITEM_ID = 82800, SPELL_VISUAL_UNCAGE_PET = 222, SPELL_BATTLE_PET_TRAINING = 125610,
  SPELL_REVIVE_BATTLE_PETS = 125439, SPELL_SUMMON_BATTLE_PET = 118301
}
 
enum  BattlePetBreedQuality : uint8 {
  BattlePetBreedQuality::Poor = 0, BattlePetBreedQuality::Common = 1, BattlePetBreedQuality::Uncommon = 2, BattlePetBreedQuality::Rare = 3,
  BattlePetBreedQuality::Epic = 4, BattlePetBreedQuality::Legendary = 5, BattlePetBreedQuality::Count
}
 
enum  BattlePetDbFlags : uint16 {
  BattlePetDbFlags::None = 0x000, BattlePetDbFlags::Favorite = 0x001, BattlePetDbFlags::Converted = 0x002, BattlePetDbFlags::Revoked = 0x004,
  BattlePetDbFlags::LockedForConvert = 0x008, BattlePetDbFlags::Ability0Selection = 0x010, BattlePetDbFlags::Ability1Selection = 0x020, BattlePetDbFlags::Ability2Selection = 0x040,
  BattlePetDbFlags::FanfareNeeded = 0x080, BattlePetDbFlags::DisplayOverridden = 0x100
}
 
enum  BattlePetError : uint8 { BattlePetError::CantHaveMorePetsOfType = 3, BattlePetError::CantHaveMorePets = 4, BattlePetError::TooHighLevelToUncage = 7 }
 
enum  BattlePetSlot : uint8 { BattlePetSlot::Slot0 = 0, BattlePetSlot::Slot1 = 1, BattlePetSlot::Slot2 = 2, BattlePetSlot::Count }
 
enum  BattlePetXpSource : uint8 { BattlePetXpSource::PetBattle = 0, BattlePetXpSource::SpellEffect = 1, BattlePetXpSource::Count }
 
enum  FlagsControlType { FLAGS_CONTROL_TYPE_APPLY = 1, FLAGS_CONTROL_TYPE_REMOVE = 2 }
 
enum  BattlePetState {
  STATE_MAX_HEALTH_BONUS = 2, STATE_INTERNAL_INITIAL_LEVEL = 17, STATE_STAT_POWER = 18, STATE_STAT_STAMINA = 19,
  STATE_STAT_SPEED = 20, STATE_MOD_DAMAGE_DEALT_PERCENT = 23, STATE_GENDER = 78, STATE_COSMETIC_WATER_BUBBLED = 85,
  STATE_SPECIAL_IS_COCKROACH = 93, STATE_COSMETIC_FLY_TIER = 128, STATE_COSMETIC_BIGGLESWORTH = 144, STATE_PASSIVE_ELITE = 153,
  STATE_PASSIVE_BOSS = 162, STATE_COSMETIC_TREASURE_GOBLIN = 176, STATE_START_WITH_BUFF = 183, STATE_START_WITH_BUFF_2 = 184,
  STATE_COSMETIC_SPECTRAL_BLUE = 196
}
 
enum  BattlePetSaveInfo { BATTLE_PET_UNCHANGED = 0, BATTLE_PET_CHANGED = 1, BATTLE_PET_NEW = 2, BATTLE_PET_REMOVED = 3 }
 

Functions

 DEFINE_ENUM_FLAG (BattlePetDbFlags)
 

Variables

static constexpr uint16 MAX_BATTLE_PET_LEVEL = 25
 
static constexpr Milliseconds REVIVE_BATTLE_PETS_COOLDOWN = 180s
 

Enumeration Type Documentation

◆ BattlePetBreedQuality

Enumerator
Poor 
Common 
Uncommon 
Rare 
Epic 
Legendary 
Count 
44  : uint8
45 {
46  Poor = 0,
47  Common = 1,
48  Uncommon = 2,
49  Rare = 3,
50  Epic = 4,
51  Legendary = 5,
52 
53  Count
54 };
size_t Count(ContainerMapList< SPECIFIC_TYPE > const &elements, SPECIFIC_TYPE *)
Definition: TypeContainerFunctions.h:156
uint8_t uint8
Definition: Define.h:145

◆ BattlePetDbFlags

Enumerator
None 
Favorite 
Converted 
Revoked 
LockedForConvert 
Ability0Selection 
Ability1Selection 
Ability2Selection 
FanfareNeeded 
DisplayOverridden 

◆ BattlePetError

Enumerator
CantHaveMorePetsOfType 
CantHaveMorePets 
TooHighLevelToUncage 
72  : uint8
73 {
74  CantHaveMorePetsOfType = 3, // You can't have any more pets of that type.
75  CantHaveMorePets = 4, // You can't have any more pets.
76  TooHighLevelToUncage = 7 // This pet is too high level for you to uncage.
77 };
uint8_t uint8
Definition: Define.h:145

◆ BattlePetMisc

Enumerator
DEFAULT_MAX_BATTLE_PETS_PER_SPECIES 
BATTLE_PET_CAGE_ITEM_ID 
SPELL_VISUAL_UNCAGE_PET 
SPELL_BATTLE_PET_TRAINING 
SPELL_REVIVE_BATTLE_PETS 
SPELL_SUMMON_BATTLE_PET 
31 {
35 
37  SPELL_REVIVE_BATTLE_PETS = 125439,
39 };
Definition: BattlePetMgr.h:37
Definition: BattlePetMgr.h:38
Definition: BattlePetMgr.h:33
Definition: BattlePetMgr.h:36
Definition: BattlePetMgr.h:34

◆ BattlePetSaveInfo

Enumerator
BATTLE_PET_UNCHANGED 
BATTLE_PET_CHANGED 
BATTLE_PET_NEW 
BATTLE_PET_REMOVED 
130 {
132  BATTLE_PET_CHANGED = 1,
133  BATTLE_PET_NEW = 2,
135 };
Definition: BattlePetMgr.h:134
Definition: BattlePetMgr.h:133
Definition: BattlePetMgr.h:132
Definition: BattlePetMgr.h:131

◆ BattlePetSlot

Enumerator
Slot0 
Slot1 
Slot2 
Count 
79  : uint8
80 {
81  Slot0 = 0,
82  Slot1 = 1,
83  Slot2 = 2,
84 
85  Count
86 };
size_t Count(ContainerMapList< SPECIFIC_TYPE > const &elements, SPECIFIC_TYPE *)
Definition: TypeContainerFunctions.h:156
uint8_t uint8
Definition: Define.h:145

◆ BattlePetState

Enumerator
STATE_MAX_HEALTH_BONUS 
STATE_INTERNAL_INITIAL_LEVEL 
STATE_STAT_POWER 
STATE_STAT_STAMINA 
STATE_STAT_SPEED 
STATE_MOD_DAMAGE_DEALT_PERCENT 
STATE_GENDER 
STATE_COSMETIC_WATER_BUBBLED 
STATE_SPECIAL_IS_COCKROACH 
STATE_COSMETIC_FLY_TIER 
STATE_COSMETIC_BIGGLESWORTH 
STATE_PASSIVE_ELITE 
STATE_PASSIVE_BOSS 
STATE_COSMETIC_TREASURE_GOBLIN 
STATE_START_WITH_BUFF 
STATE_START_WITH_BUFF_2 
STATE_COSMETIC_SPECTRAL_BLUE 
107 {
110  STATE_STAT_POWER = 18,
111  STATE_STAT_STAMINA = 19,
112  STATE_STAT_SPEED = 20,
114  STATE_GENDER = 78, // 1 - male, 2 - female
119  STATE_PASSIVE_ELITE = 153,
120  STATE_PASSIVE_BOSS = 162,
122  // these are not in BattlePetState.db2 but are used in BattlePetSpeciesState.db2
123  STATE_START_WITH_BUFF = 183,
125  //
127 };
Definition: BattlePetMgr.h:109
Definition: BattlePetMgr.h:112
Definition: BattlePetMgr.h:110
Definition: BattlePetMgr.h:124
Definition: BattlePetMgr.h:117
Definition: BattlePetMgr.h:121
Definition: BattlePetMgr.h:111
Definition: BattlePetMgr.h:108
Definition: BattlePetMgr.h:113
Definition: BattlePetMgr.h:115
Definition: BattlePetMgr.h:118
Definition: BattlePetMgr.h:123
Definition: BattlePetMgr.h:120
Definition: BattlePetMgr.h:116
Definition: BattlePetMgr.h:119
Definition: BattlePetMgr.h:126
Definition: BattlePetMgr.h:114

◆ BattlePetXpSource

Enumerator
PetBattle 
SpellEffect 
Count 
88  : uint8
89 {
90  PetBattle = 0,
91  SpellEffect = 1,
92 
93  Count
94 };
size_t Count(ContainerMapList< SPECIFIC_TYPE > const &elements, SPECIFIC_TYPE *)
Definition: TypeContainerFunctions.h:156
uint8_t uint8
Definition: Define.h:145

◆ FlagsControlType

Enumerator
FLAGS_CONTROL_TYPE_APPLY 
FLAGS_CONTROL_TYPE_REMOVE 
98 {
101 };
Definition: BattlePetMgr.h:99
Definition: BattlePetMgr.h:100

Function Documentation

◆ DEFINE_ENUM_FLAG()

BattlePets::DEFINE_ENUM_FLAG ( BattlePetDbFlags  )

Variable Documentation

◆ MAX_BATTLE_PET_LEVEL

constexpr uint16 BattlePets::MAX_BATTLE_PET_LEVEL = 25
static

◆ REVIVE_BATTLE_PETS_COOLDOWN

constexpr Milliseconds BattlePets::REVIVE_BATTLE_PETS_COOLDOWN = 180s
static