TrinityCore
BossInfo Struct Reference

#include <InstanceScript.h>

Public Member Functions

 BossInfo ()
 
DungeonEncounterEntry const * GetDungeonEncounterForDifficulty (Difficulty difficulty) const
 

Public Attributes

EncounterState state
 
std::array< GuidSet, static_cast< uint8 >(EncounterDoorBehavior::Max)> door
 
GuidSet minion
 
CreatureBoundary boundary
 
std::array< DungeonEncounterEntry const *, MAX_DUNGEON_ENCOUNTERS_PER_BOSSDungeonEncounters
 

Detailed Description

Definition at line 133 of file InstanceScript.h.

Constructor & Destructor Documentation

◆ BossInfo()

BossInfo::BossInfo ( )
inline

Definition at line 135 of file InstanceScript.h.

135: state(TO_BE_DECIDED) { DungeonEncounters.fill(nullptr); }
@ TO_BE_DECIDED
EncounterState state
std::array< DungeonEncounterEntry const *, MAX_DUNGEON_ENCOUNTERS_PER_BOSS > DungeonEncounters

Member Function Documentation

◆ GetDungeonEncounterForDifficulty()

DungeonEncounterEntry const * BossInfo::GetDungeonEncounterForDifficulty ( Difficulty  difficulty) const

Definition at line 57 of file InstanceScript.cpp.

58{
59 auto itr = std::find_if(DungeonEncounters.begin(), DungeonEncounters.end(), [difficulty](DungeonEncounterEntry const* dungeonEncounter)
60 {
61 return dungeonEncounter && (dungeonEncounter->DifficultyID == 0 || Difficulty(dungeonEncounter->DifficultyID) == difficulty);
62 });
63
64 return itr != DungeonEncounters.end() ? *itr : nullptr;
65}
+ Here is the caller graph for this function:

Member Data Documentation

◆ boundary

CreatureBoundary BossInfo::boundary

Definition at line 142 of file InstanceScript.h.

◆ door

std::array<GuidSet, static_cast<uint8>(EncounterDoorBehavior::Max)> BossInfo::door

Definition at line 140 of file InstanceScript.h.

◆ DungeonEncounters

std::array<DungeonEncounterEntry const*, MAX_DUNGEON_ENCOUNTERS_PER_BOSS> BossInfo::DungeonEncounters

Definition at line 143 of file InstanceScript.h.

◆ minion

GuidSet BossInfo::minion

Definition at line 141 of file InstanceScript.h.

◆ state

EncounterState BossInfo::state

Definition at line 139 of file InstanceScript.h.


The documentation for this struct was generated from the following files: