AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
InstanceScript Class Reference

#include "InstanceScript.h"

Inheritance diagram for InstanceScript:
ZoneScript instance_ahnkahet::instance_ahnkahet_InstanceScript instance_arcatraz::instance_arcatraz_InstanceMapScript instance_auchenai_crypts::instance_auchenai_crypts_InstanceMapScript instance_azjol_nerub::instance_azjol_nerub_InstanceScript instance_black_temple::instance_black_temple_InstanceMapScript instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript instance_blackrock_spire::instance_blackrock_spireMapScript instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript instance_blood_furnace::instance_blood_furnace_InstanceMapScript instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript instance_deadmines::instance_deadmines_InstanceMapScript instance_dire_maul::instance_dire_maul_InstanceMapScript instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript instance_forge_of_souls::instance_forge_of_souls_InstanceScript instance_gnomeregan::instance_gnomeregan_InstanceMapScript instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript instance_gundrak::instance_gundrak_InstanceMapScript instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript instance_hyjal::instance_mount_hyjal_InstanceMapScript instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript instance_karazhan::instance_karazhan_InstanceMapScript instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript instance_mana_tombs::instance_mana_tombs_InstanceMapScript instance_maraudon::instance_maraudon_InstanceMapScript instance_mechanar::instance_mechanar_InstanceMapScript instance_molten_core::instance_molten_core_InstanceMapScript instance_naxxramas::instance_naxxramas_InstanceMapScript instance_nexus::instance_nexus_InstanceMapScript instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript instance_oculus::instance_oculus_InstanceMapScript instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript instance_pit_of_saron::instance_pit_of_saron_InstanceScript instance_ragefire_chasm::instance_ragefire_chasm_InstanceMapScript instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript instance_razorfen_kraul::instance_razorfen_kraul_InstanceMapScript instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript instance_scholomance::instance_scholomance_InstanceMapScript instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript instance_shattered_halls::instance_shattered_halls_InstanceMapScript instance_steam_vault::instance_steam_vault_InstanceMapScript instance_stratholme::instance_stratholme_InstanceMapScript instance_sunken_temple::instance_sunken_temple_InstanceMapScript instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript instance_the_black_morass::instance_the_black_morass_InstanceMapScript instance_the_botanica::instance_the_botanica_InstanceMapScript instance_the_eye::instance_the_eye_InstanceMapScript instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript instance_the_stockade::instance_the_stockade_InstanceMapScript instance_the_underbog::instance_the_underbog_InstanceMapScript instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript instance_uldaman::instance_uldaman_InstanceMapScript instance_ulduar::instance_ulduar_InstanceMapScript instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript instance_violet_hold::instance_violet_hold_InstanceMapScript instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript instance_zulaman::instance_zulaman_InstanceMapScript instance_zulfarrak::instance_zulfarrak_InstanceMapScript instance_zulgurub::instance_zulgurub_InstanceMapScript

Public Member Functions

 InstanceScript (Map *map)
 
 ~InstanceScript () override
 
virtual void Initialize ()
 
virtual void Load (char const *data)
 
virtual void CreatureLooted (Creature *, LootType)
 
virtual std::string GetSaveData ()
 
void SaveToDB ()
 
virtual void Update (uint32)
 
virtual bool IsEncounterInProgress () const
 
void OnCreatureCreate (Creature *creature) override
 
void OnCreatureRemove (Creature *creature) override
 
void OnGameObjectCreate (GameObject *go) override
 
void OnGameObjectRemove (GameObject *go) override
 
ObjectGuid GetObjectGuid (uint32 type) const
 
ObjectGuid GetGuidData (uint32 type) const override
 
CreatureGetCreature (uint32 type)
 
GameObjectGetGameObject (uint32 type)
 
virtual void OnPlayerEnter (Player *)
 
virtual void OnPlayerAreaUpdate (Player *, uint32, uint32)
 
virtual void OnPlayerInWaterStateUpdate (Player *, bool)
 
void HandleGameObject (ObjectGuid guid, bool open, GameObject *go=nullptr)
 
void DoUseDoorOrButton (ObjectGuid guid, uint32 withRestoreTime=0, bool useAlternativeState=false)
 
void DoRespawnGameObject (ObjectGuid guid, uint32 timeToDespawn=MINUTE)
 
void DoRespawnCreature (ObjectGuid guid, bool force=false)
 
void DoRespawnCreature (uint32 type, bool force=false)
 
void DoUpdateWorldState (uint32 worldstateId, uint32 worldstateValue)
 
void DoSendNotifyToInstance (char const *format,...)
 
void DoUpdateAchievementCriteria (AchievementCriteriaTypes type, uint32 miscValue1=0, uint32 miscValue2=0, Unit *unit=nullptr)
 
void DoStartTimedAchievement (AchievementCriteriaTimedTypes type, uint32 entry)
 
void DoStopTimedAchievement (AchievementCriteriaTimedTypes type, uint32 entry)
 
void DoRemoveAurasDueToSpellOnPlayers (uint32 spell)
 
void DoCastSpellOnPlayers (uint32 spell)
 
void DoCastSpellOnPlayer (Player *player, uint32 spell, bool includePets, bool includeControlled)
 
bool ServerAllowsTwoSideGroups ()
 
virtual bool SetBossState (uint32 id, EncounterState state)
 
EncounterState GetBossState (uint32 id) const
 
CreatureBoundary const * GetBossBoundary (uint32 id) const
 
BossInfo const * GetBossInfo (uint32 id) const
 
uint32 GetPersistentData (uint32 index) const
 
void StorePersistentData (uint32 index, uint32 data)
 
virtual bool CheckAchievementCriteriaMeet (uint32, Player const *, Unit const *=nullptr, uint32=0)
 
virtual bool CheckRequiredBosses (uint32, Player const *=nullptr) const
 
void SetCompletedEncountersMask (uint32 newMask, bool save)
 
uint32 GetCompletedEncounterMask () const
 
void SendEncounterUnit (uint32 type, Unit *unit=nullptr, uint8 param1=0, uint8 param2=0)
 
virtual void FillInitialWorldStates (WorldPacket &)
 
uint32 GetEncounterCount () const
 
void MarkAreaTriggerDone (uint32 id)
 
void ResetAreaTriggerDone (uint32 id)
 
bool IsAreaTriggerDone (uint32 id) const
 
virtual void DoAction (int32)
 
void DoForAllMinions (uint32 id, std::function< void(Creature *)> exec)
 
void StoreGameObjectState (ObjectGuid::LowType spawnId, uint8 state)
 
uint8 GetStoredGameObjectState (ObjectGuid::LowType spawnId) const
 
void LoadInstanceSavedGameobjectStateData ()
 
bool IsBossDone (uint32 bossId) const
 
bool AllBossesDone () const
 
bool AllBossesDone (std::initializer_list< uint32 > bossIds) const
 
- Public Member Functions inherited from ZoneScript
 ZoneScript ()
 
virtual ~ZoneScript ()
 
virtual uint32 GetCreatureEntry (ObjectGuid::LowType, CreatureData const *data)
 
virtual uint32 GetGameObjectEntry (ObjectGuid::LowType, uint32 entry)
 
virtual void OnCreatureCreate (Creature *)
 
virtual void OnCreatureRemove (Creature *)
 
virtual void OnGameObjectCreate (GameObject *)
 
virtual void OnGameObjectRemove (GameObject *)
 
virtual void OnUnitDeath (Unit *)
 
virtual void OnCreatureEvade (Creature *)
 
virtual ObjectGuid GetGuidData (uint32) const
 
virtual void SetGuidData (uint32, ObjectGuid)
 
virtual uint64 GetData64 (uint32) const
 
virtual void SetData64 (uint32, uint64)
 
virtual uint32 GetData (uint32) const
 
virtual void SetData (uint32, uint32)
 
virtual void ProcessEvent (WorldObject *, uint32)
 

Static Public Member Functions

static std::string GetBossStateName (uint8 state)
 

Public Attributes

Mapinstance
 
TaskScheduler scheduler
 

Protected Member Functions

void SetHeaders (std::string const &dataHeaders)
 
void SetBossNumber (uint32 number)
 
void SetPersistentDataCount (uint32 number)
 
void LoadBossBoundaries (BossBoundaryData const &data)
 
void LoadDoorData (DoorData const *data)
 
void LoadMinionData (MinionData const *data)
 
void LoadObjectData (ObjectData const *creatureData, ObjectData const *gameObjectData)
 
void LoadSummonData (ObjectData const *data)
 
void SetSummoner (Creature *creature)
 
void AddObject (Creature *obj, bool add=true)
 
void RemoveObject (Creature *obj)
 
void AddObject (GameObject *obj, bool add=true)
 
void RemoveObject (GameObject *obj)
 
void AddObject (WorldObject *obj, uint32 type, bool add=true)
 
void RemoveObject (WorldObject *obj, uint32 type)
 
void AddDoor (GameObject *door, bool add=true)
 
void RemoveDoor (GameObject *door)
 
void AddMinion (Creature *minion, bool add=true)
 
void RemoveMinion (Creature *minion)
 
void UpdateDoorState (GameObject *door)
 
void UpdateMinionState (Creature *minion, EncounterState state)
 
bool ReadSaveDataHeaders (std::istringstream &data)
 
void ReadSaveDataBossStates (std::istringstream &data)
 
void ReadSavePersistentData (std::istringstream &data)
 
virtual void ReadSaveDataMore (std::istringstream &)
 
void WriteSaveDataHeaders (std::ostringstream &data)
 
void WriteSaveDataBossStates (std::ostringstream &data)
 
void WritePersistentData (std::ostringstream &data)
 
virtual void WriteSaveDataMore (std::ostringstream &)
 

Static Private Member Functions

static void LoadObjectData (ObjectData const *creatureData, ObjectInfoMap &objectInfo)
 

Private Attributes

std::vector< char > headers
 
std::vector< BossInfobosses
 
std::vector< uint32persistentData
 
DoorInfoMap doors
 
MinionInfoMap minions
 
ObjectInfoMap _creatureInfo
 
ObjectInfoMap _gameObjectInfo
 
ObjectInfoMap _summonInfo
 
ObjectGuidMap _objectGuids
 
ObjectStateMap _objectStateMap
 
uint32 completedEncounters
 
std::unordered_set< uint32_activatedAreaTriggers
 

Detailed Description

Constructor & Destructor Documentation

◆ InstanceScript()

InstanceScript::InstanceScript ( Map map)
inlineexplicit
144: instance(map), completedEncounters(0) {}
uint32 completedEncounters
Definition: InstanceScript.h:335
Map * instance
Definition: InstanceScript.h:148

◆ ~InstanceScript()

InstanceScript::~InstanceScript ( )
inlineoverride
146{}

Member Function Documentation

◆ AddDoor()

void InstanceScript::AddDoor ( GameObject door,
bool  add = true 
)
protected
320{
321 DoorInfoMapBounds range = doors.equal_range(door->GetEntry());
322 if (range.first == range.second)
323 return;
324
325 for (; range.first != range.second; ++range.first)
326 {
327 DoorInfo const& data = range.first->second;
328
329 if (add)
330 {
331 data.bossInfo->door[data.type].insert(door);
332 }
333 else
334 data.bossInfo->door[data.type].erase(door);
335 }
336
337 if (add)
338 UpdateDoorState(door);
339}
std::pair< DoorInfoMap::const_iterator, DoorInfoMap::const_iterator > DoorInfoMapBounds
Definition: InstanceScript.h:134
uint32 GetEntry() const
Definition: Object.h:115
DoorSet door[MAX_DOOR_TYPES]
Definition: InstanceScript.h:114
Definition: InstanceScript.h:120
BossInfo * bossInfo
Definition: InstanceScript.h:123
DoorType type
Definition: InstanceScript.h:124
DoorInfoMap doors
Definition: InstanceScript.h:328
void UpdateDoorState(GameObject *door)
Definition: InstanceScript.cpp:240

References DoorInfo::bossInfo, BossInfo::door, doors, Object::GetEntry(), DoorInfo::type, and UpdateDoorState().

Referenced by instance_gundrak::instance_gundrak_InstanceMapScript::OnGameObjectCreate(), instance_nexus::instance_nexus_InstanceMapScript::OnGameObjectCreate(), instance_mechanar::instance_mechanar_InstanceMapScript::OnGameObjectCreate(), OnGameObjectCreate(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::OnGameObjectCreate(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::OnGameObjectCreate(), instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript::OnGameObjectCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnGameObjectCreate(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::OnGameObjectCreate(), instance_arcatraz::instance_arcatraz_InstanceMapScript::OnGameObjectCreate(), and RemoveDoor().

◆ AddMinion()

void InstanceScript::AddMinion ( Creature minion,
bool  add = true 
)
protected
347{
348 MinionInfoMap::iterator itr = minions.find(minion->GetEntry());
349 if (itr == minions.end())
350 return;
351
352 if (add)
353 itr->second.bossInfo->minion.insert(minion);
354 else
355 itr->second.bossInfo->minion.erase(minion);
356}
MinionInfoMap minions
Definition: InstanceScript.h:329

References Object::GetEntry(), and minions.

Referenced by OnCreatureCreate(), instance_blackrock_spire::instance_blackrock_spireMapScript::OnCreatureCreate(), instance_molten_core::instance_molten_core_InstanceMapScript::OnCreatureCreate(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::OnCreatureCreate(), and RemoveMinion().

◆ AddObject() [1/3]

void InstanceScript::AddObject ( Creature obj,
bool  add = true 
)
protected
271{
272 ObjectInfoMap::const_iterator j = _creatureInfo.find(obj->GetEntry());
273 if (j != _creatureInfo.end())
274 {
275 AddObject(obj, j->second, add);
276 }
277}
ObjectInfoMap _creatureInfo
Definition: InstanceScript.h:330
void AddObject(Creature *obj, bool add=true)
Definition: InstanceScript.cpp:270

References _creatureInfo, AddObject(), and Object::GetEntry().

Referenced by AddObject(), OnCreatureCreate(), OnGameObjectCreate(), and RemoveObject().

◆ AddObject() [2/3]

void InstanceScript::AddObject ( GameObject obj,
bool  add = true 
)
protected
285{
286 ObjectInfoMap::const_iterator j = _gameObjectInfo.find(obj->GetEntry());
287 if (j != _gameObjectInfo.end())
288 {
289 AddObject(obj, j->second, add);
290 }
291}
ObjectInfoMap _gameObjectInfo
Definition: InstanceScript.h:331

References _gameObjectInfo, AddObject(), and Object::GetEntry().

◆ AddObject() [3/3]

void InstanceScript::AddObject ( WorldObject obj,
uint32  type,
bool  add = true 
)
protected
299{
300 if (add)
301 {
302 _objectGuids[type] = obj->GetGUID();
303 }
304 else
305 {
306 ObjectGuidMap::iterator i = _objectGuids.find(type);
307 if (i != _objectGuids.end() && i->second == obj->GetGUID())
308 {
309 _objectGuids.erase(i);
310 }
311 }
312}
static ObjectGuid GetGUID(Object const *o)
Definition: Object.h:112
ObjectGuidMap _objectGuids
Definition: InstanceScript.h:333

References _objectGuids, and Object::GetGUID().

◆ AllBossesDone() [1/2]

bool InstanceScript::AllBossesDone ( ) const
791{
792 for (auto const& boss : bosses)
793 if (boss.state != DONE)
794 return false;
795
796 return true;
797}
@ DONE
Definition: InstanceScript.h:60
std::vector< BossInfo > bosses
Definition: InstanceScript.h:326

References bosses, and DONE.

Referenced by instance_zulaman::instance_zulaman_InstanceMapScript::CheckInstanceStatus(), instance_zulaman::instance_zulaman_InstanceMapScript::SetBossState(), and instance_black_temple::instance_black_temple_InstanceMapScript::SetBossState().

◆ AllBossesDone() [2/2]

bool InstanceScript::AllBossesDone ( std::initializer_list< uint32 bossIds) const
800{
801 for (auto const& bossId : bossIds)
802 if (!IsBossDone(bossId))
803 return false;
804
805 return true;
806}
bool IsBossDone(uint32 bossId) const
Definition: InstanceScript.h:278

References IsBossDone().

◆ CheckAchievementCriteriaMeet()

bool InstanceScript::CheckAchievementCriteriaMeet ( uint32  criteria_id,
Player const *  ,
Unit const *  = nullptr,
uint32  = 0 
)
virtual

Reimplemented in instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, and instance_oculus::instance_oculus_InstanceMapScript.

714{
715 LOG_ERROR("scripts.ai", "Achievement system call InstanceScript::CheckAchievementCriteriaMeet but instance script for map {} not have implementation for achievement criteria {}",
716 instance->GetId(), criteria_id);
717 return false;
718}
#define LOG_ERROR(filterType__,...)
Definition: Log.h:157
uint32 GetId() const
Definition: Map.h:377

References Map::GetId(), instance, and LOG_ERROR.

Referenced by AchievementCriteriaData::Meets().

◆ CheckRequiredBosses()

◆ CreatureLooted()

virtual void InstanceScript::CreatureLooted ( Creature ,
LootType   
)
inlinevirtual

◆ DoAction()

◆ DoCastSpellOnPlayer()

void InstanceScript::DoCastSpellOnPlayer ( Player player,
uint32  spell,
bool  includePets,
bool  includeControlled 
)
685{
686 if (!player)
687 return;
688
689 player->CastSpell(player, spell, true);
690
691 if (!includePets)
692 return;
693
694 for (uint8 itr2 = 0; itr2 < MAX_SUMMON_SLOT; ++itr2)
695 {
696 ObjectGuid summonGUID = player->m_SummonSlot[itr2];
697 if (!summonGUID.IsEmpty())
698 if (Creature* summon = instance->GetCreature(summonGUID))
699 summon->CastSpell(player, spell, true);
700 }
701
702 if (!includeControlled)
703 return;
704
705 for (auto itr2 = player->m_Controlled.begin(); itr2 != player->m_Controlled.end(); ++itr2)
706 {
707 if (Unit* controlled = *itr2)
708 if (controlled->IsInWorld() && controlled->IsCreature())
709 controlled->CastSpell(player, spell, true);
710 }
711}
std::uint8_t uint8
Definition: Define.h:109
#define MAX_SUMMON_SLOT
Definition: Unit.h:601
Definition: Creature.h:43
Definition: ObjectGuid.h:118
bool IsEmpty() const
Definition: ObjectGuid.h:161
Definition: Unit.h:630
ControlSet m_Controlled
Definition: Unit.h:1940
SpellCastResult CastSpell(SpellCastTargets const &targets, SpellInfo const *spellInfo, CustomSpellValues const *value, TriggerCastFlags triggerFlags=TRIGGERED_NONE, Item *castItem=nullptr, AuraEffect const *triggeredByAura=nullptr, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition: Unit.cpp:1167
ObjectGuid m_SummonSlot[MAX_SUMMON_SLOT]
Definition: Unit.h:1944
Creature * GetCreature(ObjectGuid const guid)
Definition: Map.cpp:3317

References Unit::CastSpell(), Map::GetCreature(), instance, ObjectGuid::IsEmpty(), Unit::m_Controlled, Unit::m_SummonSlot, and MAX_SUMMON_SLOT.

Referenced by instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnPlayerEnter().

◆ DoCastSpellOnPlayers()

◆ DoForAllMinions()

void InstanceScript::DoForAllMinions ( uint32  id,
std::function< void(Creature *)>  exec 
)
426{
427 BossInfo* bossInfo = &bosses[id];
428 MinionSet listCopy = bossInfo->minion;
429
430 for (auto const& minion : listCopy)
431 {
432 if (minion)
433 {
434 exec(minion);
435 }
436 }
437}
std::set< Creature * > MinionSet
Definition: InstanceScript.h:41
Definition: InstanceScript.h:111
MinionSet minion
Definition: InstanceScript.h:115

References bosses, and BossInfo::minion.

Referenced by boss_fathomlord_karathress::DoAction(), boss_hydromancer_thespia::JustDied(), boss_warlord_kalithresh::JustDied(), boss_fathomlord_karathress::JustEngagedWith(), boss_magtheridon::JustEngagedWith(), boss_fathomlord_karathress::JustReachedHome(), boss_fathomlord_karathress::Reset(), and boss_warlord_kalithresh::Reset().

◆ DoRemoveAurasDueToSpellOnPlayers()

void InstanceScript::DoRemoveAurasDueToSpellOnPlayers ( uint32  spell)
666{
667 instance->DoForAllPlayers([&](Player* player)
668 {
669 player->RemoveAurasDueToSpell(spell);
670 if (Pet* pet = player->GetPet())
671 pet->RemoveAurasDueToSpell(spell);
672 });
673}
Definition: Pet.h:41
Pet * GetPet() const
Definition: Player.cpp:8939
void RemoveAurasDueToSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, uint8 reqEffMask=0, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition: Unit.cpp:4909

References Map::DoForAllPlayers(), Player::GetPet(), instance, and Unit::RemoveAurasDueToSpell().

Referenced by boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::CleanAuras(), boss_sartharion_dragonAI::ClearInstance(), boss_sartharion_vesperon::boss_sartharion_vesperonAI::ClearInstance(), boss_kalecgos::ClearPlayerAuras(), boss_hodir::boss_hodirAI::DamageTaken(), boss_twin_valkyrAI::DoAction(), instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript::DoAction(), boss_amanitar::EnterEvadeMode(), boss_sartharion_tenebron::boss_sartharion_tenebronAI::ExecuteEvent(), npc_echo_of_medivh::HandlePieceJustDied(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::HealReceived(), boss_amanitar::JustDied(), boss_twin_valkyrAI::JustDied(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::JustDied(), boss_rotface::boss_rotfaceAI::JustDied(), boss_sindragosa::boss_sindragosaAI::JustDied(), boss_toravon::boss_toravonAI::JustDied(), boss_moroes::JustDied(), boss_felmyst::JustDied(), boss_buru::JustDied(), boss_thaddius::boss_thaddiusAI::JustDied(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::JustEngagedWith(), boss_professor_putricide::boss_professor_putricideAI::JustEngagedWith(), boss_professor_putricide::boss_professor_putricideAI::JustReachedHome(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnPlayerEnter(), instance_stratholme::instance_stratholme_InstanceMapScript::OnUnitDeath(), boss_baroness_anastari::boss_baroness_anastariAI::Reset(), boss_felmyst::Reset(), boss_sartharion::boss_sartharionAI::Reset(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::Reset(), boss_thaddius::boss_thaddiusAI::Reset(), boss_hodir::boss_hodirAI::Reset(), boss_yoggsaron_sara::boss_yoggsaron_saraAI::Reset(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::SetData(), instance_karazhan::instance_karazhan_InstanceMapScript::SetData(), npc_echo_of_medivh::sGossipSelect(), boss_sartharion_vesperon::boss_sartharion_vesperonAI::SummonedCreatureDies(), instance_stratholme::instance_stratholme_InstanceMapScript::Update(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::Update(), boss_icehowl::boss_icehowlAI::UpdateAI(), boss_professor_putricide::boss_professor_putricideAI::UpdateAI(), and boss_yoggsaron_sara::boss_yoggsaron_saraAI::UpdateAI().

◆ DoRespawnCreature() [1/2]

void InstanceScript::DoRespawnCreature ( ObjectGuid  guid,
bool  force = false 
)

◆ DoRespawnCreature() [2/2]

void InstanceScript::DoRespawnCreature ( uint32  type,
bool  force = false 
)
596{
597 if (Creature* creature = instance->GetCreature(GetObjectGuid(type)))
598 {
599 creature->Respawn(force);
600 }
601}
ObjectGuid GetObjectGuid(uint32 type) const
Definition: InstanceScript.cpp:86

References Map::GetCreature(), GetObjectGuid(), and instance.

◆ DoRespawnGameObject()

void InstanceScript::DoRespawnGameObject ( ObjectGuid  guid,
uint32  timeToDespawn = MINUTE 
)
562{
563 if (GameObject* go = instance->GetGameObject(uiGuid))
564 {
565 switch (go->GetGoType())
566 {
571 // not expect any of these should ever be handled
572 LOG_ERROR("scripts", "InstanceScript: DoRespawnGameObject can't respawn gameobject entry {}, because type is {}.", go->GetEntry(), go->GetGoType());
573 return;
574 default:
575 break;
576 }
577
578 if (go->isSpawned())
579 return;
580
581 go->SetRespawnTime(uiTimeToDespawn);
582 }
583 else
584 LOG_DEBUG("scripts", "InstanceScript: DoRespawnGameObject failed");
585}
#define LOG_DEBUG(filterType__,...)
Definition: Log.h:169
@ GAMEOBJECT_TYPE_BUTTON
Definition: SharedDefines.h:1561
@ GAMEOBJECT_TYPE_TRAP
Definition: SharedDefines.h:1566
@ GAMEOBJECT_TYPE_FISHINGNODE
Definition: SharedDefines.h:1577
@ GAMEOBJECT_TYPE_DOOR
Definition: SharedDefines.h:1560
Definition: GameObject.h:120
GameObject * GetGameObject(ObjectGuid const guid)
Definition: Map.cpp:3322

References GAMEOBJECT_TYPE_BUTTON, GAMEOBJECT_TYPE_DOOR, GAMEOBJECT_TYPE_FISHINGNODE, GAMEOBJECT_TYPE_TRAP, Map::GetGameObject(), instance, LOG_DEBUG, and LOG_ERROR.

Referenced by npc_echo_of_medivh::HandlePieceJustDied(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::SetData(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::SetData(), instance_karazhan::instance_karazhan_InstanceMapScript::SetData(), and instance_oculus::instance_oculus_InstanceMapScript::SetData().

◆ DoSendNotifyToInstance()

void InstanceScript::DoSendNotifyToInstance ( char const *  format,
  ... 
)
621{
622 if (!instance->GetPlayers().IsEmpty())
623 {
624 va_list ap;
625 va_start(ap, format);
626 char buff[1024];
627 vsnprintf(buff, 1024, format, ap);
628 va_end(ap);
629
630 instance->DoForAllPlayers([&, buff](Player* player)
631 {
632 ChatHandler(player->GetSession()).SendNotification("{}", buff);
633 });
634 }
635}
bool IsEmpty() const
Definition: LinkedList.h:97
Definition: Chat.h:37
void SendNotification(std::string_view str)
Definition: Chat.cpp:104
WorldSession * GetSession() const
Definition: Player.h:1998
PlayerList const & GetPlayers() const
Definition: Map.h:484

References Map::DoForAllPlayers(), Map::GetPlayers(), Player::GetSession(), instance, LinkedListHead::IsEmpty(), and ChatHandler::SendNotification().

◆ DoStartTimedAchievement()

◆ DoStopTimedAchievement()

◆ DoUpdateAchievementCriteria()

◆ DoUpdateWorldState()

void InstanceScript::DoUpdateWorldState ( uint32  worldstateId,
uint32  worldstateValue 
)
604{
605 Map::PlayerList const& lPlayers = instance->GetPlayers();
606
607 if (!lPlayers.IsEmpty())
608 {
609 for (Map::PlayerList::const_iterator itr = lPlayers.begin(); itr != lPlayers.end(); ++itr)
610 if (Player* player = itr->GetSource())
611 player->SendUpdateWorldState(uiStateId, uiStateData);
612 }
613 else
614 {
615 LOG_DEBUG("scripts.ai", "DoUpdateWorldState attempt send data but no players in map.");
616 }
617}
Definition: LinkedList.h:139
Definition: MapRefMgr.h:26
iterator begin()
Definition: MapRefMgr.h:36
iterator end()
Definition: MapRefMgr.h:37

References MapRefMgr::begin(), MapRefMgr::end(), Map::GetPlayers(), instance, LinkedListHead::IsEmpty(), and LOG_DEBUG.

Referenced by instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::AddWave1(), instance_zulaman::instance_zulaman_InstanceMapScript::DoAction(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::DoWipe1(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::HandleDropAttempt(), spell_halion_twilight_division::HandleDummy(), instance_violet_hold::instance_violet_hold_InstanceMapScript::InstanceCleanup(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnCreatureCreate(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnUnitDeath(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::ScheduleNextPortal(), instance_zulaman::instance_zulaman_InstanceMapScript::SetBossState(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::SetBossState(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::SetData(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::SetData(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::SetData(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetData(), instance_oculus::instance_oculus_InstanceMapScript::SetData(), instance_ulduar::instance_ulduar_InstanceMapScript::SetData(), instance_violet_hold::instance_violet_hold_InstanceMapScript::SetData(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::Update(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::Update(), instance_violet_hold::instance_violet_hold_InstanceMapScript::Update(), npc_arthas::npc_arthasAI::UpdateAI(), npc_halion_controller::npc_halion_controllerAI::UpdateCorporeality(), and instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::UpdateEventState().

◆ DoUseDoorOrButton()

void InstanceScript::DoUseDoorOrButton ( ObjectGuid  guid,
uint32  withRestoreTime = 0,
bool  useAlternativeState = false 
)
541{
542 if (!uiGuid)
543 return;
544
545 GameObject* go = instance->GetGameObject(uiGuid);
546
547 if (go)
548 {
550 {
551 if (go->getLootState() == GO_READY)
552 go->UseDoorOrButton(uiWithRestoreTime, bUseAlternativeState);
553 else if (go->getLootState() == GO_ACTIVATED)
554 go->ResetDoorOrButton();
555 }
556 else
557 LOG_ERROR("scripts.ai", "SD2: Script call DoUseDoorOrButton, but gameobject entry {} is type {}.", go->GetEntry(), go->GetGoType());
558 }
559}
@ GO_ACTIVATED
Definition: GameObject.h:112
@ GO_READY
Definition: GameObject.h:111
void UseDoorOrButton(uint32 time_to_restore=0, bool alternative=false, Unit *user=nullptr)
Definition: GameObject.cpp:1431
LootState getLootState() const
Definition: GameObject.h:224
GameobjectTypes GetGoType() const
Definition: GameObject.h:203
void ResetDoorOrButton()
Definition: GameObject.cpp:1421

References GAMEOBJECT_TYPE_BUTTON, GAMEOBJECT_TYPE_DOOR, Object::GetEntry(), Map::GetGameObject(), GameObject::GetGoType(), GameObject::getLootState(), GO_ACTIVATED, GO_READY, instance, LOG_ERROR, GameObject::ResetDoorOrButton(), and GameObject::UseDoorOrButton().

Referenced by instance_stratholme::instance_stratholme_InstanceMapScript::gate_delay(), boss_bigbadwolf::JustEngagedWith(), instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript::SetData(), instance_stratholme::instance_stratholme_InstanceMapScript::Update(), and npc_barnes::npc_barnesAI::WaypointReached().

◆ FillInitialWorldStates()

◆ GetBossBoundary()

◆ GetBossInfo()

BossInfo const * InstanceScript::GetBossInfo ( uint32  id) const
inline
238{ return &bosses[id]; }

References bosses.

Referenced by instance_nexus::instance_nexus_InstanceMapScript::SetBossState().

◆ GetBossState()

EncounterState InstanceScript::GetBossState ( uint32  id) const
inline
235{ return id < bosses.size() ? bosses[id].state : TO_BE_DECIDED; }
@ TO_BE_DECIDED
Definition: InstanceScript.h:62

References bosses, and TO_BE_DECIDED.

Referenced by BossAI::_EnterEvadeMode(), boss_hakkar::boss_hakkarAI::ApplyHakkarPowerStacks(), boss_felmyst::boss_felmyst(), boss_wrath_scryer_soccothrates::boss_wrath_scryer_soccothrates(), spell_serpentshrine_cavern_coilfang_water::CalcPeriodic(), boss_majordomo::boss_majordomoAI::CanAIAttack(), npc_gunship_mage::npc_gunship_mageAI::CanAIAttack(), npc_gunship_rocketeer::npc_gunship_rocketeerAI::CanAIAttack(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::CanAIAttack(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::CanAIAttack(), npc_igb_ship_crew::npc_igb_ship_crewAI::CanAIAttack(), npc_gunship_boarding_addAI::CanAIAttack(), npc_gunship_gunner::npc_gunship_gunnerAI::CanAIAttack(), boss_keristrasza::CanRemovePrison(), BossAI::CanRespawn(), instance_naxxramas::instance_naxxramas_InstanceMapScript::CheckAchievementCriteriaMeet(), spell_igb_rocket_pack_useable_aura::CheckAreaTarget(), instance_molten_core::instance_molten_core_InstanceMapScript::CheckMajordomoExecutus(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::CheckRequiredBosses(), npc_core_rager::npc_core_ragerAI::DamageTaken(), npc_gunship::npc_gunshipAI::DamageTaken(), go_suppression_device::go_suppression_deviceAI::DoAction(), boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::DoAction(), npc_strangulate_vehicle::npc_strangulate_vehicleAI::DoAction(), npc_crok_scourgebane::npc_crok_scourgebaneAI::DoAction(), instance_blackrock_spire::instance_blackrock_spireMapScript::Dragonspireroomcheck(), SendEncounterUnit::Execute(), boss_sartharion_tenebron::boss_sartharion_tenebronAI::ExecuteEvent(), instance_zulgurub::instance_zulgurub_InstanceMapScript::GetData(), go_chromaggus_lever::go_chromaggus_leverAI::GossipHello(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::HandleDropAttempt(), instance_commandscript::HandleInstanceGetBossStateCommand(), spell_serpentshrine_cavern_coilfang_water::HandlePeriodic(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::HealReceived(), go_suppression_device::go_suppression_deviceAI::InitializeAI(), boss_majordomo::boss_majordomoAI::InitializeAI(), instance_ahnkahet::instance_ahnkahet_InstanceScript::IsAllSpheresActivated(), IsBossDone(), instance_naxxramas::instance_naxxramas_InstanceMapScript::IsEncounterInProgress(), npc_taldaram_flamesphere::IsSummonedBy(), npc_oculus_drake::npc_oculus_drakeAI::IsSummonedBy(), boss_sartharion_dragonAI::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), boss_four_horsemen::boss_four_horsemenAI::JustDied(), boss_sartharion_dragonAI::JustEngagedWith(), boss_hakkar::boss_hakkarAI::JustEngagedWith(), npc_crystalline_frayer::JustEngagedWith(), boss_sartharion::boss_sartharionAI::JustEngagedWith(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::JustEngagedWith(), boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::JustEngagedWith(), boss_majordomo::boss_majordomoAI::JustReachedHome(), npc_tirion_fordring_tft::npc_tirion_fordringAI::JustReachedHome(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::JustReachedHome(), npc_akama_illidan::JustReachedHome(), boss_sartharion_dragonAI::JustSummoned(), npc_gluttonous_abomination::npc_gluttonous_abominationAI::JustSummoned(), npc_medivh_bm::MoveInLineOfSight(), npc_crok_scourgebane::npc_crok_scourgebaneAI::npc_crok_scourgebaneAI(), spell_blood_queen_vampiric_bite::OnCast(), instance_blackrock_spire::instance_blackrock_spireMapScript::OnCreatureCreate(), instance_karazhan::instance_karazhan_InstanceMapScript::OnCreatureCreate(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnCreatureCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnCreatureCreate(), instance_black_temple::instance_black_temple_InstanceMapScript::OnCreatureCreate(), instance_gundrak::instance_gundrak_InstanceMapScript::OnGameObjectCreate(), instance_nexus::instance_nexus_InstanceMapScript::OnGameObjectCreate(), instance_blackrock_spire::instance_blackrock_spireMapScript::OnGameObjectCreate(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::OnGameObjectCreate(), instance_molten_core::instance_molten_core_InstanceMapScript::OnGameObjectCreate(), instance_karazhan::instance_karazhan_InstanceMapScript::OnGameObjectCreate(), instance_zulgurub::instance_zulgurub_InstanceMapScript::OnGameObjectCreate(), instance_ahnkahet::instance_ahnkahet_InstanceScript::OnGameObjectCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnGameObjectCreate(), instance_black_temple::instance_black_temple_InstanceMapScript::OnGameObjectCreate(), instance_steam_vault::instance_steam_vault_InstanceMapScript::OnGameObjectCreate(), instance_naxxramas::instance_naxxramas_InstanceMapScript::OnGameObjectCreate(), npc_high_overlord_saurfang_icc::OnGossipHello(), npc_muradin_bronzebeard_icc::OnGossipHello(), npc_high_overlord_saurfang_icc::OnGossipSelect(), npc_muradin_bronzebeard_icc::OnGossipSelect(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::OnPlayerEnter(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::OnPlayerEnter(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::OnPlayerEnter(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnPlayerEnter(), at_icc_saurfang_portal::OnTrigger(), at_thaddius_entrance::OnTrigger(), at_blackrock_stadium::OnTrigger(), instance_karazhan::instance_karazhan_InstanceMapScript::OnUnitDeath(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnUnitDeath(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnUnitDeath(), spell_dreamwalker_nightmare_cloud_aura::PeriodicTick(), instance_blackrock_spire::instance_blackrock_spireMapScript::ProcessEvent(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::ProcessEvent(), boss_gyth::boss_gythAI::Reset(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::Reset(), boss_rend_blackhand::boss_rend_blackhandAI::Reset(), npc_core_rager::npc_core_ragerAI::Reset(), boss_majordomo::boss_majordomoAI::Reset(), npc_kiljaeden_controller::Reset(), boss_archimonde::Reset(), npc_medivh_bm::Reset(), npc_xerestrasza::npc_xerestraszaAI::Reset(), boss_general_zarithrian::boss_general_zarithrianAI::Reset(), npc_blood_queen_lana_thel::npc_blood_queen_lana_thelAI::Reset(), boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::Reset(), boss_professor_putricide::boss_professor_putricideAI::Reset(), npc_tirion_fordring_tft::npc_tirion_fordringAI::Reset(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::Reset(), npc_arthas_teleport_visual::npc_arthas_teleport_visualAI::Reset(), npc_icc_gauntlet_controller::npc_icc_gauntlet_controllerAI::Reset(), boss_four_horsemen::boss_four_horsemenAI::Reset(), boss_thaddius::boss_thaddiusAI::Reset(), npc_akama_illidan::Reset(), npc_akama_shade::Reset(), boss_sartharion::boss_sartharionAI::RespawnDragons(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::SetBossState(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetBossState(), instance_blackrock_spire::instance_blackrock_spireMapScript::SetData(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetData(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::SetData(), instance_gundrak::instance_gundrak_InstanceMapScript::SetData(), boss_victor_nefarius::boss_victor_nefariusAI::sGossipSelect(), npc_akama_illidan::sGossipSelect(), instance_molten_core::instance_molten_core_InstanceMapScript::SummonMajordomoExecutus(), instance_blackrock_spire::instance_blackrock_spireMapScript::Update(), instance_naxxramas::instance_naxxramas_InstanceMapScript::Update(), boss_mandokir::boss_mandokirAI::UpdateAI(), npc_time_rift::UpdateAI(), boss_jedoga_shadowseeker::UpdateAI(), boss_halion::boss_halionAI::UpdateAI(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::UpdateAI(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::UpdateAI(), npc_gunship_boarding_leader::npc_gunship_boarding_leaderAI::UpdateAI(), npc_gunship_boarding_add::npc_gunship_boarding_add_realAI::UpdateAI(), npc_gunship_mage::npc_gunship_mageAI::UpdateAI(), npc_gunship_gunner::npc_gunship_gunnerAI::UpdateAI(), npc_bone_spike::npc_bone_spikeAI::UpdateAI(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::UpdateAI(), npc_the_lich_king_controller::npc_the_lich_king_controllerAI::UpdateAI(), npc_valithria_cloud::npc_valithria_cloudAI::UpdateAI(), npc_vrykul_skeleton::UpdateAI(), npc_gunship::npc_gunshipAI::UpdateAI(), and npc_gunship_rocketeer::npc_gunship_rocketeerAI::UpdateAI().

◆ GetBossStateName()

std::string InstanceScript::GetBossStateName ( uint8  state)
static
809{
810 // See enum EncounterState in InstanceScript.h
811 switch (state)
812 {
813 case NOT_STARTED:
814 return "NOT_STARTED";
815 case IN_PROGRESS:
816 return "IN_PROGRESS";
817 case FAIL:
818 return "FAIL";
819 case DONE:
820 return "DONE";
821 case SPECIAL:
822 return "SPECIAL";
823 case TO_BE_DECIDED:
824 return "TO_BE_DECIDED";
825 default:
826 return "INVALID";
827 }
828}
@ IN_PROGRESS
Definition: InstanceScript.h:58
@ FAIL
Definition: InstanceScript.h:59
@ SPECIAL
Definition: InstanceScript.h:61
@ NOT_STARTED
Definition: InstanceScript.h:57

References DONE, FAIL, IN_PROGRESS, NOT_STARTED, SPECIAL, and TO_BE_DECIDED.

Referenced by instance_commandscript::HandleInstanceGetBossStateCommand(), instance_commandscript::HandleInstanceSetBossStateCommand(), and SmartScript::ProcessAction().

◆ GetCompletedEncounterMask()

uint32 InstanceScript::GetCompletedEncounterMask ( ) const
inline
253{ return completedEncounters; }

References completedEncounters.

Referenced by InstanceMap::AddPlayerToMap().

◆ GetCreature()

Creature * InstanceScript::GetCreature ( uint32  type)
104{
105 return instance->GetCreature(GetObjectGuid(type));
106}

References Map::GetCreature(), GetObjectGuid(), and instance.

Referenced by instance_blood_furnace::instance_blood_furnace_InstanceMapScript::ActivateCell(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::CallNextRajaxxLeader(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::CleanupInstance(), boss_attumen::DamageTaken(), boss_romulo::DamageTaken(), boss_illidari_council_memberAI::DamageTaken(), npc_akama_shade::DamageTaken(), boss_bug_trio::DamageTaken(), DespawnAll(), boss_julianne::DoAction(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::DoAction(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::DoAction(), instance_karazhan::instance_karazhan_InstanceMapScript::DoAction(), boss_kalecgos::DoAction(), boss_illidan_stormrage::DoAction(), npc_maiev_illidan::DoAction(), boss_illidari_council::DoAction(), DoActions(), boss_razorgore::boss_razorgoreAI::DoChangePhase(), npc_time_rift::DoSummonAtRift(), boss_ahune::Emerge(), boss_bug_trio::EnterCombatWithTrio(), boss_attumen::EnterEvadeMode(), boss_priestess_lackey_commonAI::EnterEvadeMode(), boss_sacrolash::EnterEvadeMode(), boss_alythess::EnterEvadeMode(), boss_illidan_stormrage::EnterEvadeMode(), boss_illidari_council::EnterEvadeMode(), boss_fathomguard_sharkkis::EnterEvadeMode(), boss_fathomguard_tidalvess::EnterEvadeMode(), boss_fathomguard_caribdis::EnterEvadeMode(), boss_ahune::EnterEvadeMode(), boss_halazzi::EnterPhase(), boss_bug_trio::EvadeAllBosses(), boss_ahune::ExecuteEvent(), boss_twinemperorsAI::GetTwin(), go_ossirian_crystal::go_ossirian_crystalAI::GossipHello(), go_chromaggus_lever::go_chromaggus_leverAI::GossipHello(), go_ahune_ice_stone::GossipSelect(), boss_warbringer_omrogg::HandleHeadTalk(), spell_illidari_council_circle_of_healing::HandleSharedRule(), npc_toxic_slime::InitializeAI(), boss_aeonus::IsSummonedBy(), boss_sacrolash::JustDied(), boss_alythess::JustDied(), boss_thekal::JustDied(), npc_zealot_lorkhan::JustDied(), npc_zealot_zath::JustDied(), boss_eye_of_cthun::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), boss_fathomguard_sharkkis::JustDied(), boss_fathomguard_tidalvess::JustDied(), boss_fathomguard_caribdis::JustDied(), boss_ahune::JustDied(), npc_frozen_core::JustDied(), boss_dalliah_the_doomsayer::JustDied(), boss_brutallus::JustDied(), boss_azgalor::JustDied(), npc_buru_egg::JustDied(), boss_kurinnaxx::JustDied(), npc_general_andorov::JustDied(), boss_cthun::JustDied(), boss_shade_of_akama::JustDied(), boss_fathomlord_karathress::JustDied(), boss_warchief_kargath_bladefist::JustDied(), boss_sathrovarr::JustEngagedWith(), npc_zealot_lorkhan::JustEngagedWith(), boss_illidari_council_memberAI::JustEngagedWith(), boss_dalliah_the_doomsayer::JustEngagedWith(), npc_buru_egg::JustEngagedWith(), boss_priestess_lackey_commonAI::JustEngagedWith(), boss_sacrolash::JustEngagedWith(), boss_alythess::JustEngagedWith(), boss_illidan_stormrage::JustEngagedWith(), boss_fathomguard_sharkkis::JustEngagedWith(), boss_fathomguard_tidalvess::JustEngagedWith(), boss_fathomguard_caribdis::JustEngagedWith(), boss_warchief_kargath_bladefist::JustEngagedWith(), boss_romulo::JustReachedHome(), boss_aeonus::JustReachedHome(), npc_akama_illidan::JustReachedHome(), npc_warchief_portal::JustSummoned(), boss_attumen::JustSummoned(), npc_hive_zara_larva::JustSummoned(), boss_eye_of_cthun::JustSummoned(), npc_creature_generator_akama::JustSummoned(), npc_buru_egg::JustSummoned(), boss_midnight::KilledUnit(), boss_priestess_lackey_commonAI::KilledUnit(), npc_earthen_ring_flamecaller::LookOpening(), boss_bug_trio::MovementInform(), npc_twilight_volunteer::MovementInform(), npc_akama_illidan::MovementInform(), boss_shade_of_akama::MovementInform(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::OnCreatureCreate(), instance_karazhan::instance_karazhan_InstanceMapScript::OnCreatureCreate(), instance_zulgurub::instance_zulgurub_InstanceMapScript::OnCreatureCreate(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::OnCreatureCreate(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::OnCreatureCreate(), instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript::OnGameObjectCreate(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnGameObjectCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnPlayerEnter(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::OnPlayerEnter(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnUnitDeath(), instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript::OnUnitDeath(), boss_kaelthas::PrepareAdvisors(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::ProcessEvent(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::ProcessEvent(), boss_kalecgos::Reset(), boss_kiljaeden::Reset(), boss_thekal::Reset(), npc_ancient_wisp::Reset(), boss_illidan_stormrage::Reset(), boss_warchief_kargath_bladefist::Reset(), boss_dalliah_the_doomsayer::Reset(), boss_wrath_scryer_soccothrates::Reset(), instance_zulaman::instance_zulaman_InstanceMapScript::ResetAkilzonGauntlet(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::ResetRajaxxWaves(), boss_thekal::ReviveZealot(), boss_julianne::ScheduleCombat(), boss_romulo::ScheduleCombat(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::ScheduleNextPortal(), boss_cthun::ScheduleTasks(), boss_gathios_the_shatterer::SelectCouncilMember(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::SetBossState(), instance_black_temple::instance_black_temple_InstanceMapScript::SetBossState(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::SetData(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::SetData(), instance_arcatraz::instance_arcatraz_InstanceMapScript::SetData(), instance_ahnkahet::instance_ahnkahet_InstanceScript::SetData(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::SetData(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::SetData(), SetSummoner(), boss_ahune::Submerge(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::Update(), npc_madrigosa::UpdateAI(), npc_time_rift::UpdateAI(), npc_twilight_volunteer::UpdateAI(), boss_veras_darkshadow::UpdateAI(), npc_frozen_core::UpdateAI(), npc_ahune_bunny::UpdateAI(), npc_gunship::npc_gunshipAI::UpdateAI(), and npc_general_andorov::UpdateEscortAI().

◆ GetEncounterCount()

uint32 InstanceScript::GetEncounterCount ( ) const
inline

◆ GetGameObject()

◆ GetGuidData()

ObjectGuid InstanceScript::GetGuidData ( uint32  type) const
overridevirtual

Reimplemented from ZoneScript.

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_karazhan::instance_karazhan_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_blood_furnace::instance_blood_furnace_InstanceMapScript, instance_shattered_halls::instance_shattered_halls_InstanceMapScript, instance_arcatraz::instance_arcatraz_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, instance_the_eye::instance_the_eye_InstanceMapScript, instance_blackrock_spire::instance_blackrock_spireMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_molten_core::instance_molten_core_InstanceMapScript, instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript, instance_scholomance::instance_scholomance_InstanceMapScript, instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript, instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript, instance_zulgurub::instance_zulgurub_InstanceMapScript, instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, and instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript.

99{
100 return GetObjectGuid(type);
101}

References GetObjectGuid().

Referenced by boss_sjonnir::boss_sjonnirAI::ActivatePipe(), boss_freya_summons::boss_freya_summonsAI::boss_freya_summonsAI(), boss_twilight_halion::boss_twilight_halionAI::boss_twilight_halionAI(), boss_tyrannus::boss_tyrannusAI::boss_tyrannusAI(), boss_moira_bronzebeardAI::CastOnEmperorIfPossible(), spell_putricide_mutation_init::CheckRequirementInternal(), boss_prince_valanar_icc::boss_prince_valanarAI::CheckRoom(), violet_hold_trashAI::ClearDoorSealAura(), boss_mimiron::boss_mimironAI::CloseDoorAndButton(), boss_kologarn_eyebeam::boss_kologarn_eyebeamAI::DamageDealt(), npc_mograine::npc_mograineAI::DamageTaken(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::DamageTaken(), boss_halion::boss_halionAI::DamageTaken(), boss_twilight_halion::boss_twilight_halionAI::DamageTaken(), boss_the_lich_king::boss_the_lich_kingAI::DamageTaken(), npc_ulduar_flash_freeze::npc_ulduar_flash_freezeAI::DamageTaken(), boss_thorim_start_npcs::boss_thorim_start_npcsAI::DamageTaken(), boss_yoggsaron_brain::boss_yoggsaron_brainAI::DamageTaken(), boss_hodir::boss_hodirAI::DoAction(), npc_hor_lich_king::npc_hor_lich_kingAI::DoAction(), boss_taldaram::DoAction(), npc_high_overlord_saurfang_icc::npc_high_overlord_saurfangAI::DoAction(), npc_muradin_bronzebeard_icc::npc_muradin_bronzebeard_iccAI::DoAction(), boss_the_lich_king::boss_the_lich_kingAI::DoAction(), npc_strangulate_vehicle::npc_strangulate_vehicleAI::DoAction(), npc_crok_scourgebane::npc_crok_scourgebaneAI::DoAction(), npc_argent_captainAI::DoAction(), brann_bronzebeard::brann_bronzebeardAI::DoAction(), npc_ahune_bunny::DoAction(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::DoAction(), boss_black_knight::boss_black_knightAI::DoAction(), boss_tyrannus::boss_tyrannusAI::DoAction(), npc_molten_golem::npc_molten_golemAI::DoAction(), boss_thorim_sif::boss_thorim_sifAI::DoAction(), npc_xt002_heart::npc_xt002_heartAI::DoAction(), boss_yoggsaron_sara::boss_yoggsaron_saraAI::DoAction(), boss_yoggsaron_brain::boss_yoggsaron_brainAI::DoAction(), npc_rocknot::npc_rocknotAI::DoGo(), boss_halion::boss_halionAI::EnterEvadeMode(), boss_prince_keleseth_icc::boss_prince_kelesethAI::EnterEvadeMode(), boss_prince_taldaram_icc::boss_prince_taldaramAI::EnterEvadeMode(), boss_prince_valanar_icc::boss_prince_valanarAI::EnterEvadeMode(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::EnterEvadeMode(), boss_festergut::boss_festergutAI::EnterEvadeMode(), boss_rotface::boss_rotfaceAI::EnterEvadeMode(), boss_the_lich_king::boss_the_lich_kingAI::EnterEvadeMode(), npc_tirion_fordring_tft::npc_tirion_fordringAI::EnterEvadeMode(), npc_argent_captainAI::EnterEvadeMode(), boss_sartharion_tenebron::boss_sartharion_tenebronAI::ExecuteEvent(), spell_the_lich_king_restore_soul::FilterTargets(), boss_erekem::boss_erekemAI::GetChainHealTargetGUID(), npc_chesspiece::GetEnemyPiece(), npc_ulduar_harpoonfirestate::npc_ulduar_harpoonfirestateAI::GetHarpoonGunIdForThisHFS(), npc_chesspiece::GetLowestHpFriendlyPiece(), boss_twin_valkyrAI::GetSister(), boss_thorim::boss_thorimAI::GetThorimObject(), go_troll_cage::go_troll_cageAI::GossipHello(), boss_netherspite::HandleDoors(), spell_halion_twilight_division::HandleDummy(), npc_grimstone::npc_grimstoneAI::HandleGameObject(), npc_echo_of_medivh::HandlePieceJustDied(), spell_putricide_unbound_plague::HandleScript(), spell_putricide_mutated_transformation::HandleSummon(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::HealReceived(), go_troll_cage::go_troll_cageAI::initBlyCrewMember(), boss_urok_doomhowl::boss_urok_doomhowlAI::InitializeAI(), boss_warchief_kargath_bladefist::InitializeAI(), IsEncounterComplete(), npc_direbrew_minion::IsSummonedBy(), npc_onyx_flamecaller::npc_onyx_flamecallerAI::IsSummonedBy(), npc_raging_spirit::npc_raging_spiritAI::IsSummonedBy(), npc_suppresser::npc_suppresserAI::IsSummonedBy(), npc_strangulate_vehicle::npc_strangulate_vehicleAI::IsSummonedBy(), boss_emperor_dagran_thaurissan::boss_draganthaurissanAI::JustDied(), boss_rend_blackhand::boss_rend_blackhandAI::JustDied(), npc_chesspiece::JustDied(), boss_shade_of_aran::JustDied(), npc_kilrek::JustDied(), npc_zulian_prowler::npc_zulian_prowlerAI::JustDied(), boss_rajaxx::JustDied(), boss_sartharion_dragonAI::JustDied(), npc_memory::npc_memoryAI::JustDied(), boss_jormungarAI::JustDied(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustDied(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustDied(), boss_prince_valanar_icc::boss_prince_valanarAI::JustDied(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::JustDied(), boss_festergut::boss_festergutAI::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), boss_rotface::boss_rotfaceAI::JustDied(), npc_little_ooze::npc_little_oozeAI::JustDied(), npc_big_ooze::npc_big_oozeAI::JustDied(), npc_raging_spirit::npc_raging_spiritAI::JustDied(), npc_spirit_warden::npc_spirit_wardenAI::JustDied(), boss_sister_svalna::boss_sister_svalnaAI::JustDied(), boss_thaddius_summon::boss_thaddius_summonAI::JustDied(), boss_drakos::boss_drakosAI::JustDied(), boss_sjonnir::boss_sjonnirAI::JustDied(), brann_bronzebeard::brann_bronzebeardAI::JustDied(), boss_steelbreaker::boss_steelbreakerAI::JustDied(), boss_runemaster_molgeim::boss_runemaster_molgeimAI::JustDied(), boss_stormcaller_brundir::boss_stormcaller_brundirAI::JustDied(), npc_auriaya_feral_defender::npc_auriaya_feral_defenderAI::JustDied(), npc_ulduar_saronite_vapors::npc_ulduar_saronite_vaporsAI::JustDied(), npc_ulduar_saronite_animus::npc_ulduar_saronite_animusAI::JustDied(), npc_ulduar_hodir_priest::npc_ulduar_hodir_priestAI::JustDied(), npc_ulduar_hodir_druid::npc_ulduar_hodir_druidAI::JustDied(), npc_ulduar_hodir_shaman::npc_ulduar_hodir_shamanAI::JustDied(), npc_ulduar_hodir_mage::npc_ulduar_hodir_mageAI::JustDied(), boss_kologarn::boss_kologarnAI::JustDied(), boss_kologarn_arms::boss_kologarn_armsAI::JustDied(), boss_thorim_start_npcs::boss_thorim_start_npcsAI::JustDied(), boss_thorim_runic_colossus::boss_thorim_runic_colossusAI::JustDied(), boss_xt002::boss_xt002AI::JustDied(), npc_xt002_heart::npc_xt002_heartAI::JustDied(), boss_yoggsaron::boss_yoggsaronAI::JustDied(), boss_skarvald_the_constructor::JustDied(), boss_dalronn_the_controller::JustDied(), npc_massive_jormungar::npc_massive_jormungarAI::JustDied(), npc_ferocious_rhino::npc_ferocious_rhinoAI::JustDied(), npc_ravenous_furbolg::npc_ravenous_furbolgAI::JustDied(), npc_frenzied_worgen::npc_frenzied_worgenAI::JustDied(), boss_skadi::boss_skadiAI::JustDied(), npc_ichor_globule::npc_ichor_globuleAI::JustDied(), violet_hold_trashAI::JustDied(), boss_kelidan_the_breaker::JustDied(), boss_the_maker::JustDied(), boss_epoch_hunter::JustDied(), boss_baltharus_the_warborn::boss_baltharus_the_warbornAI::JustDied(), boss_halion::boss_halionAI::JustDied(), boss_twilight_halion::boss_twilight_halionAI::JustDied(), boss_faerlina::boss_faerlinaAI::JustDied(), boss_four_horsemen::boss_four_horsemenAI::JustDied(), boss_gothik::boss_gothikAI::JustDied(), boss_kelthuzad::boss_kelthuzadAI::JustDied(), boss_noth::boss_nothAI::JustDied(), boss_thaddius::boss_thaddiusAI::JustDied(), boss_flame_leviathan_defense_turret::boss_flame_leviathan_defense_turretAI::JustDied(), boss_freya_elder_stonebark::boss_freya_elder_stonebarkAI::JustDied(), boss_freya_elder_brightleaf::boss_freya_elder_brightleafAI::JustDied(), boss_freya_elder_ironbranch::boss_freya_elder_ironbranchAI::JustDied(), boss_warchief_kargath_bladefist::JustDied(), boss_shade_of_aran::JustEngagedWith(), boss_bigbadwolf::JustEngagedWith(), npc_healing_ward::JustEngagedWith(), npc_pos_deathwhisper_necrolyte::npc_pos_deathwhisper_necrolyteAI::JustEngagedWith(), npc_risen_archmage::npc_risen_archmageAI::JustEngagedWith(), boss_sister_svalna::boss_sister_svalnaAI::JustEngagedWith(), boss_sjonnir::boss_sjonnirAI::JustEngagedWith(), npc_auriaya_sanctum_sentry::npc_auriaya_sanctum_sentryAI::JustEngagedWith(), boss_freya::boss_freyaAI::JustEngagedWith(), boss_kologarn::boss_kologarnAI::JustEngagedWith(), boss_xt002::boss_xt002AI::JustEngagedWith(), boss_the_maker::JustEngagedWith(), boss_sartharion::boss_sartharionAI::JustEngagedWith(), boss_thaddius_summon::boss_thaddius_summonAI::JustEngagedWith(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::JustEngagedWith(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustEngagedWith(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustEngagedWith(), boss_prince_valanar_icc::boss_prince_valanarAI::JustEngagedWith(), boss_festergut::boss_festergutAI::JustEngagedWith(), boss_rotface::boss_rotfaceAI::JustEngagedWith(), boss_faerlina::boss_faerlinaAI::JustEngagedWith(), boss_four_horsemen::boss_four_horsemenAI::JustEngagedWith(), boss_gothik::boss_gothikAI::JustEngagedWith(), boss_heigan::boss_heiganAI::JustEngagedWith(), boss_kelthuzad::boss_kelthuzadAI::JustEngagedWith(), boss_loatheb::boss_loathebAI::JustEngagedWith(), boss_maexxna::boss_maexxnaAI::JustEngagedWith(), boss_noth::boss_nothAI::JustEngagedWith(), boss_steelbreaker::boss_steelbreakerAI::JustEngagedWith(), boss_runemaster_molgeim::boss_runemaster_molgeimAI::JustEngagedWith(), boss_stormcaller_brundir::boss_stormcaller_brundirAI::JustEngagedWith(), boss_skarvald_the_constructor::JustEngagedWith(), boss_dalronn_the_controller::JustEngagedWith(), boss_erekem::boss_erekemAI::JustEngagedWith(), npc_erekem_guard::npc_erekem_guardAI::JustEngagedWith(), boss_arlokk::boss_arlokkAI::JustReachedHome(), boss_yoggsaron_cloud::boss_yoggsaron_cloudAI::JustSummoned(), boss_captain_skarloc::JustSummoned(), boss_sartharion_dragonAI::JustSummoned(), npc_gothik_trigger::npc_gothik_triggerAI::JustSummoned(), boss_mandokir::boss_mandokirAI::KilledUnit(), npc_chesspiece::MovementInform(), npc_hive_zara_larva::MovementInform(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::MovementInform(), boss_professor_putricide::boss_professor_putricideAI::MovementInform(), npc_tirion_fordring_tft::npc_tirion_fordringAI::MovementInform(), npc_valkyr_shadowguard::npc_valkyr_shadowguardAI::MovementInform(), npc_gunship_boarding_addAI::MovementInform(), npc_sergeant_bly::npc_sergeant_blyAI::MovementInform(), npc_hor_lich_king::npc_hor_lich_kingAI::MovementInform(), npc_xt002_scrapbot::npc_xt002_scrapbotAI::MovementInform(), npc_big_ooze::npc_big_oozeAI::npc_big_oozeAI(), npc_little_ooze::npc_little_oozeAI::npc_little_oozeAI(), npc_pos_leader_second::npc_pos_leader_secondAI::npc_pos_leader_secondAI(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::npc_pos_martin_or_gorkun_secondAI(), npc_ulduar_saronite_animus::npc_ulduar_saronite_animusAI::npc_ulduar_saronite_animusAI(), spell_blood_queen_vampiric_bite::OnCast(), achievement_yogg_saron_darkness::OnCheck(), achievement_yogg_saron_he_waits_dreaming::OnCheck(), go_palehoof_sphere::OnGossipHello(), npc_ulduar_expedition_commander::OnGossipHello(), go_harpoon_canon::OnGossipHello(), go_ulduar_working_harpoon::OnGossipHello(), npc_ulduar_expedition_commander::OnGossipSelect(), at_thaddius_entrance::OnTrigger(), at_tyrannus_event_starter::OnTrigger(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::OpenDoors(), IgbTeleportOnVictoryCheck::operator()(), npc_thrall_old_hillsbrad::npc_thrall_old_hillsbradAI::ReorderInstance(), boss_rend_blackhand::boss_rend_blackhandAI::Reset(), boss_shade_of_aran::Reset(), npc_image_of_medivh::npc_image_of_medivhAI::Reset(), npc_zulian_prowler::npc_zulian_prowlerAI::Reset(), boss_mandokir::boss_mandokirAI::Reset(), boss_tyrannus::boss_tyrannusAI::Reset(), boss_the_lich_king::boss_the_lich_kingAI::Reset(), boss_faerlina::boss_faerlinaAI::Reset(), boss_four_horsemen::boss_four_horsemenAI::Reset(), boss_gothik::boss_gothikAI::Reset(), boss_heigan::boss_heiganAI::Reset(), boss_kelthuzad::boss_kelthuzadAI::Reset(), boss_loatheb::boss_loathebAI::Reset(), boss_maexxna::boss_maexxnaAI::Reset(), boss_noth::boss_nothAI::Reset(), boss_thaddius::boss_thaddiusAI::Reset(), boss_sjonnir::boss_sjonnirAI::Reset(), brann_bronzebeard::brann_bronzebeardAI::Reset(), boss_kologarn::boss_kologarnAI::Reset(), boss_xt002::boss_xt002AI::Reset(), npc_xt002_scrapbot::npc_xt002_scrapbotAI::Reset(), npc_xt002_boombot::npc_xt002_boombotAI::Reset(), boss_yoggsaron_sara::boss_yoggsaron_saraAI::Reset(), boss_palehoof::boss_palehoofAI::Reset(), boss_the_maker::Reset(), npc_warden_mellichar::npc_warden_mellicharAI::Reset(), brann_bronzebeard::brann_bronzebeardAI::ResetEvent(), npc_ahune_bunny::ResetFlameCallers(), boss_mimiron::boss_mimironAI::ResetGameObjects(), RespawnAssemblyOfIron(), boss_sartharion::boss_sartharionAI::RespawnDragons(), boss_svala::boss_svalaAI::SetData(), npc_ulduar_harpoonfirestate::npc_ulduar_harpoonfirestateAI::SetData(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::SetData(), boss_darkmaster_gandling::boss_darkmaster_gandlingAI::SetGate(), npc_crok_scourgebane::npc_crok_scourgebaneAI::SetGUID(), boss_kaelthas::SetRoomState(), npc_tirion_fordring_tft::npc_tirion_fordringAI::sGossipSelect(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::SpellHit(), boss_razorscale::boss_razorscaleAI::SpellHit(), npc_chesspiece::SpellHitTarget(), boss_yoggsaron_voice::boss_yoggsaron_voiceAI::SpellHitTarget(), npc_gothik_trigger::npc_gothik_triggerAI::SummonedCreatureDespawn(), boss_sartharion_shadron::boss_sartharion_shadronAI::SummonedCreatureDies(), npc_sergeant_bly::npc_sergeant_blyAI::switchFactionIfAlive(), brann_bronzebeard::brann_bronzebeardAI::SwitchHeadVisaul(), npc_rocknot::npc_rocknotAI::UpdateAI(), boss_rend_blackhand::boss_rend_blackhandAI::UpdateAI(), npc_core_rager::npc_core_ragerAI::UpdateAI(), boss_majordomo::boss_majordomoAI::UpdateAI(), npc_chesspiece::UpdateAI(), npc_mograine::npc_mograineAI::UpdateAI(), boss_high_inquisitor_whitemane::boss_high_inquisitor_whitemaneAI::UpdateAI(), npc_arthas::npc_arthasAI::UpdateAI(), npc_thrall_old_hillsbrad::npc_thrall_old_hillsbradAI::UpdateAI(), npc_sergeant_bly::npc_sergeant_blyAI::UpdateAI(), boss_sartharion::boss_sartharionAI::UpdateAI(), boss_general_zarithrian::boss_general_zarithrianAI::UpdateAI(), boss_halion::boss_halionAI::UpdateAI(), boss_twilight_halion::boss_twilight_halionAI::UpdateAI(), npc_halion_controller::npc_halion_controllerAI::UpdateAI(), npc_snobold_vassal::npc_snobold_vassalAI::UpdateAI(), boss_jormungarAI::UpdateAI(), npc_fos_corrupted_soul_fragment::npc_fos_corrupted_soul_fragmentAI::UpdateAI(), npc_hor_leader::npc_hor_leaderAI::UpdateAI(), npc_hor_lich_king::npc_hor_lich_kingAI::UpdateAI(), npc_hor_leader_second::npc_hor_leader_secondAI::UpdateAI(), boss_krick::boss_krickAI::UpdateAI(), boss_tyrannus::boss_tyrannusAI::UpdateAI(), npc_pos_leader::npc_pos_leaderAI::UpdateAI(), npc_pos_after_first_boss::npc_pos_after_first_bossAI::UpdateAI(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::UpdateAI(), npc_pos_leader_second::npc_pos_leader_secondAI::UpdateAI(), boss_prince_valanar_icc::boss_prince_valanarAI::UpdateAI(), npc_blood_queen_lana_thel::npc_blood_queen_lana_thelAI::UpdateAI(), npc_high_overlord_saurfang_icc::npc_high_overlord_saurfangAI::UpdateAI(), npc_muradin_bronzebeard_icc::npc_muradin_bronzebeard_iccAI::UpdateAI(), boss_festergut::boss_festergutAI::UpdateAI(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::UpdateAI(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::UpdateAI(), npc_cult_fanatic::npc_cult_fanaticAI::UpdateAI(), npc_cult_adherent::npc_cult_adherentAI::UpdateAI(), boss_rotface::boss_rotfaceAI::UpdateAI(), npc_tirion_fordring_tft::npc_tirion_fordringAI::UpdateAI(), npc_valkyr_shadowguard::npc_valkyr_shadowguardAI::UpdateAI(), npc_strangulate_vehicle::npc_strangulate_vehicleAI::UpdateAI(), npc_terenas_menethil::npc_terenas_menethilAI::UpdateAI(), npc_valithria_cloud::npc_valithria_cloudAI::UpdateAI(), npc_crok_scourgebane::npc_crok_scourgebaneAI::UpdateAI(), boss_gothik::boss_gothikAI::UpdateAI(), boss_kelthuzad::boss_kelthuzadAI::UpdateAI(), boss_thaddius_summon::boss_thaddius_summonAI::UpdateAI(), npc_power_spark::npc_power_sparkAI::UpdateAI(), boss_sjonnir::boss_sjonnirAI::UpdateAI(), boss_algalon_the_observer::boss_algalon_the_observerAI::UpdateAI(), npc_brann_bronzebeard_algalon::npc_brann_bronzebeard_algalonAI::UpdateAI(), boss_hodir::boss_hodirAI::UpdateAI(), npc_ulduar_hodir_priest::npc_ulduar_hodir_priestAI::UpdateAI(), npc_ulduar_hodir_druid::npc_ulduar_hodir_druidAI::UpdateAI(), npc_ulduar_hodir_shaman::npc_ulduar_hodir_shamanAI::UpdateAI(), npc_ulduar_hodir_mage::npc_ulduar_hodir_mageAI::UpdateAI(), boss_kologarn_eyebeam::boss_kologarn_eyebeamAI::UpdateAI(), boss_mimiron::boss_mimironAI::UpdateAI(), boss_razorscale::boss_razorscaleAI::UpdateAI(), npc_ulduar_expedition_engineer::npc_ulduar_expedition_engineerAI::UpdateAI(), boss_yoggsaron_sara::boss_yoggsaron_saraAI::UpdateAI(), boss_palehoof::boss_palehoofAI::UpdateAI(), boss_svala::boss_svalaAI::UpdateAI(), boss_erekem::boss_erekemAI::UpdateAI(), npc_ahune_bunny::UpdateAI(), npc_warden_mellichar::npc_warden_mellicharAI::UpdateAI(), npc_ichor_globule::npc_ichor_globuleAI::UpdateAI(), npc_suppresser::npc_suppresserAI::UpdateAI(), npc_xt002_scrapbot::npc_xt002_scrapbotAI::UpdateAI(), npc_xt002_boombot::npc_xt002_boombotAI::UpdateAI(), npc_halion_controller::npc_halion_controllerAI::UpdateCorporeality(), brann_bronzebeard::brann_bronzebeardAI::UpdateEscortAI(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::UpdateRunes(), npc_arthas::npc_arthasAI::WaypointReached(), npc_barnes::npc_barnesAI::WaypointReached(), npc_thrall_old_hillsbrad::npc_thrall_old_hillsbradAI::WaypointReached(), npc_taretha::npc_tarethaAI::WaypointReached(), npc_crok_scourgebane::npc_crok_scourgebaneAI::WaypointReached(), and npc_crok_scourgebane::npc_crok_scourgebaneAI::WaypointStart().

◆ GetObjectGuid()

ObjectGuid InstanceScript::GetObjectGuid ( uint32  type) const
87{
88 ObjectGuidMap::const_iterator i = _objectGuids.find(type);
89
90 if (i != _objectGuids.end())
91 {
92 return i->second;
93 }
94
95 return ObjectGuid::Empty;
96}
static ObjectGuid const Empty
Definition: ObjectGuid.h:120

References _objectGuids, and ObjectGuid::Empty.

Referenced by DoRespawnCreature(), GetCreature(), GetGameObject(), and GetGuidData().

◆ GetPersistentData()

◆ GetSaveData()

std::string InstanceScript::GetSaveData ( )
virtual

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_deadmines::instance_deadmines_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, and instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript.

501{
503
504 std::ostringstream saveStream;
505
506 WriteSaveDataHeaders(saveStream);
507 WriteSaveDataBossStates(saveStream);
508 WritePersistentData(saveStream);
509 WriteSaveDataMore(saveStream);
510
512
513 return saveStream.str();
514}
#define OUT_SAVE_INST_DATA_COMPLETE
Definition: InstanceScript.h:29
#define OUT_SAVE_INST_DATA
Definition: InstanceScript.h:28
void WriteSaveDataBossStates(std::ostringstream &data)
Definition: InstanceScript.cpp:524
void WritePersistentData(std::ostringstream &data)
Definition: InstanceScript.cpp:532
void WriteSaveDataHeaders(std::ostringstream &data)
Definition: InstanceScript.cpp:516
virtual void WriteSaveDataMore(std::ostringstream &)
Definition: InstanceScript.h:320

References OUT_SAVE_INST_DATA, OUT_SAVE_INST_DATA_COMPLETE, WritePersistentData(), WriteSaveDataBossStates(), WriteSaveDataHeaders(), and WriteSaveDataMore().

Referenced by SaveToDB().

◆ GetStoredGameObjectState()

uint8 InstanceScript::GetStoredGameObjectState ( ObjectGuid::LowType  spawnId) const
831{
832 auto i = _objectStateMap.find(spawnId);
833
834 if (i != _objectStateMap.end())
835 {
836 return i->second;
837 }
838
839 return 3; // Any state higher than 2 to get the default state for the object we are loading.
840}
ObjectStateMap _objectStateMap
Definition: InstanceScript.h:334

References _objectStateMap.

Referenced by instance_deadmines::instance_deadmines_InstanceMapScript::OnGameObjectCreate().

◆ HandleGameObject()

void InstanceScript::HandleGameObject ( ObjectGuid  guid,
bool  open,
GameObject go = nullptr 
)
114{
115 if (!go)
116 go = instance->GetGameObject(GUID);
117 if (go)
119 else
120 {
121 LOG_DEBUG("scripts.ai", "InstanceScript: HandleGameObject failed");
122 }
123}
@ GO_STATE_READY
Definition: GameObjectData.h:690
@ GO_STATE_ACTIVE
Definition: GameObjectData.h:689
void SetGoState(GOState state)
Definition: GameObject.cpp:2479

References Map::GetGameObject(), GO_STATE_ACTIVE, GO_STATE_READY, instance, LOG_DEBUG, and GameObject::SetGoState().

Referenced by instance_blood_furnace::instance_blood_furnace_InstanceMapScript::ActivateCell(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::AddWave1(), instance_zulaman::instance_zulaman_InstanceMapScript::CheckInstanceStatus(), boss_taldaram::DoAction(), npc_high_overlord_saurfang_icc::npc_high_overlord_saurfangAI::DoAction(), npc_muradin_bronzebeard_icc::npc_muradin_bronzebeard_iccAI::DoAction(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::DoWipe1(), instance_blackrock_spire::instance_blackrock_spireMapScript::Dragonspireroomcheck(), go_chromaggus_lever::go_chromaggus_leverAI::GossipHello(), npc_grimstone::npc_grimstoneAI::HandleGameObject(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::InstanceCleanup(), instance_violet_hold::instance_violet_hold_InstanceMapScript::InstanceCleanup(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::InstanceCleanup(), boss_skadi::boss_skadiAI::JustDied(), boss_kelidan_the_breaker::JustDied(), boss_the_maker::JustDied(), boss_the_maker::JustEngagedWith(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::MovementInform(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::OnCreatureCreate(), instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript::OnGameObjectCreate(), instance_uldaman::instance_uldaman_InstanceMapScript::OnGameObjectCreate(), instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript::OnGameObjectCreate(), instance_maraudon::instance_maraudon_InstanceMapScript::OnGameObjectCreate(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OnGameObjectCreate(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::OnGameObjectCreate(), instance_blackrock_spire::instance_blackrock_spireMapScript::OnGameObjectCreate(), instance_ahnkahet::instance_ahnkahet_InstanceScript::OnGameObjectCreate(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::OnGameObjectCreate(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::OnGameObjectCreate(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::OnGameObjectCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnGameObjectCreate(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::OnGameObjectCreate(), instance_violet_hold::instance_violet_hold_InstanceMapScript::OnGameObjectCreate(), instance_black_temple::instance_black_temple_InstanceMapScript::OnGameObjectCreate(), instance_steam_vault::instance_steam_vault_InstanceMapScript::OnGameObjectCreate(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::OnGameObjectCreate(), instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript::OnGameObjectCreate(), instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript::OnUnitDeath(), boss_the_maker::Reset(), npc_warden_mellichar::npc_warden_mellicharAI::Reset(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::ResetPrisons(), instance_karazhan::instance_karazhan_InstanceMapScript::SetBossState(), instance_zulaman::instance_zulaman_InstanceMapScript::SetBossState(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::SetBossState(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetBossState(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::SetBossState(), instance_arcatraz::instance_arcatraz_InstanceMapScript::SetBossState(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::SetData(), instance_karazhan::instance_karazhan_InstanceMapScript::SetData(), instance_scholomance::instance_scholomance_InstanceMapScript::SetData(), instance_uldaman::instance_uldaman_InstanceMapScript::SetData(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::SetData(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::SetData(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetData(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::SetData(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::SetData(), instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript::SetData(), instance_violet_hold::instance_violet_hold_InstanceMapScript::SetData(), instance_arcatraz::instance_arcatraz_InstanceMapScript::SetData(), instance_ahnkahet::instance_ahnkahet_InstanceScript::SetData(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::SetData(), instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript::SetData(), boss_darkmaster_gandling::boss_darkmaster_gandlingAI::SetGate(), instance_violet_hold::instance_violet_hold_InstanceMapScript::StartBossEncounter(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::TombOfSevenReset(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::Update(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::Update(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::Update(), instance_violet_hold::instance_violet_hold_InstanceMapScript::Update(), boss_halion::boss_halionAI::UpdateAI(), npc_hor_leader::npc_hor_leaderAI::UpdateAI(), npc_warden_mellichar::npc_warden_mellicharAI::UpdateAI(), and npc_barnes::npc_barnesAI::WaypointReached().

◆ Initialize()

virtual void InstanceScript::Initialize ( )
inlinevirtual

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_deadmines::instance_deadmines_InstanceMapScript, instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_uldaman::instance_uldaman_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript, instance_hyjal::instance_mount_hyjal_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_dire_maul::instance_dire_maul_InstanceMapScript, instance_maraudon::instance_maraudon_InstanceMapScript, instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript, instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript, instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript, instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_gundrak::instance_gundrak_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_nexus::instance_nexus_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript, instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript, instance_the_underbog::instance_the_underbog_InstanceMapScript, instance_blood_furnace::instance_blood_furnace_InstanceMapScript, instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript, instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript, and instance_shattered_halls::instance_shattered_halls_InstanceMapScript.

151{}

Referenced by InstanceMap::CreateInstanceScript().

◆ IsAreaTriggerDone()

bool InstanceScript::IsAreaTriggerDone ( uint32  id) const
inline
264{ return _activatedAreaTriggers.find(id) != _activatedAreaTriggers.end(); }
std::unordered_set< uint32 > _activatedAreaTriggers
Definition: InstanceScript.h:336

References _activatedAreaTriggers.

◆ IsBossDone()

bool InstanceScript::IsBossDone ( uint32  bossId) const
inline
278{ return GetBossState(bossId) == DONE; };
EncounterState GetBossState(uint32 id) const
Definition: InstanceScript.h:235

References DONE, and GetBossState().

Referenced by AllBossesDone(), and npc_madrigosa::npc_madrigosa().

◆ IsEncounterInProgress()

bool InstanceScript::IsEncounterInProgress ( ) const
virtual

Reimplemented in instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, and instance_violet_hold::instance_violet_hold_InstanceMapScript.

126{
127 for (std::vector<BossInfo>::const_iterator itr = bosses.begin(); itr != bosses.end(); ++itr)
128 if (itr->state == IN_PROGRESS)
129 return true;
130
131 return false;
132}

References bosses, and IN_PROGRESS.

Referenced by InstanceMap::CannotEnter(), Spell::EffectSanctuary(), spell_teron_gorefiend_shadow_of_death::HandleEffectRemove(), AuraEffect::HandleFeignDeath(), WorldSession::HandleSetRaidDifficultyOpcode(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::IsEncounterInProgress(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), npc_oculus_drake::npc_oculus_drakeAI::UpdateAI(), and npc_halion_controller::npc_halion_controllerAI::UpdateCorporeality().

◆ Load()

void InstanceScript::Load ( char const *  data)
virtual

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_deadmines::instance_deadmines_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, and instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript.

440{
441 if (!data)
442 {
444 return;
445 }
446
447 OUT_LOAD_INST_DATA(data);
448
449 std::istringstream loadStream(data);
450
451 if (ReadSaveDataHeaders(loadStream))
452 {
453 ReadSaveDataBossStates(loadStream);
454 ReadSavePersistentData(loadStream);
455 ReadSaveDataMore(loadStream);
456 }
457 else
459
461}
#define OUT_LOAD_INST_DATA_FAIL
Definition: InstanceScript.h:32
#define OUT_LOAD_INST_DATA_COMPLETE
Definition: InstanceScript.h:31
#define OUT_LOAD_INST_DATA(a)
Definition: InstanceScript.h:30
virtual void ReadSaveDataMore(std::istringstream &)
Definition: InstanceScript.h:316
void ReadSavePersistentData(std::istringstream &data)
Definition: InstanceScript.cpp:492
bool ReadSaveDataHeaders(std::istringstream &data)
Definition: InstanceScript.cpp:463
void ReadSaveDataBossStates(std::istringstream &data)
Definition: InstanceScript.cpp:477

References OUT_LOAD_INST_DATA, OUT_LOAD_INST_DATA_COMPLETE, OUT_LOAD_INST_DATA_FAIL, ReadSaveDataBossStates(), ReadSaveDataHeaders(), ReadSaveDataMore(), and ReadSavePersistentData().

Referenced by InstanceMap::CreateInstanceScript().

◆ LoadBossBoundaries()

◆ LoadDoorData()

void InstanceScript::LoadDoorData ( DoorData const *  data)
protected
165{
166 while (data->entry)
167 {
168 if (data->bossId < bosses.size())
169 doors.insert(std::make_pair(data->entry, DoorInfo(&bosses[data->bossId], data->type)));
170
171 ++data;
172 }
173 LOG_DEBUG("scripts.ai", "InstanceScript::LoadDoorData: {} doors loaded.", uint64(doors.size()));
174}
std::uint64_t uint64
Definition: Define.h:106

References bosses, DoorData::bossId, doors, DoorData::entry, LOG_DEBUG, and DoorData::type.

Referenced by instance_zulaman::instance_zulaman_InstanceMapScript::Initialize(), instance_gundrak::instance_gundrak_InstanceMapScript::Initialize(), instance_nexus::instance_nexus_InstanceMapScript::Initialize(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::Initialize(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::Initialize(), instance_ahnkahet::instance_ahnkahet_InstanceScript::instance_ahnkahet_InstanceScript(), instance_arcatraz::instance_arcatraz_InstanceMapScript::instance_arcatraz_InstanceMapScript(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::instance_azjol_nerub_InstanceScript(), instance_black_temple::instance_black_temple_InstanceMapScript::instance_black_temple_InstanceMapScript(), instance_blackrock_spire::instance_blackrock_spireMapScript::instance_blackrock_spireMapScript(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::instance_blackwing_lair_InstanceMapScript(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::instance_blood_furnace_InstanceMapScript(), instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript::instance_drak_tharon_keep_InstanceScript(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::instance_gruuls_lair_InstanceMapScript(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::instance_icecrown_citadel_InstanceMapScript(), instance_karazhan::instance_karazhan_InstanceMapScript::instance_karazhan_InstanceMapScript(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::instance_magisters_terrace_InstanceMapScript(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::instance_magtheridons_lair_InstanceMapScript(), instance_mechanar::instance_mechanar_InstanceMapScript::instance_mechanar_InstanceMapScript(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::instance_mount_hyjal_InstanceMapScript(), instance_naxxramas::instance_naxxramas_InstanceMapScript::instance_naxxramas_InstanceMapScript(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::instance_ruby_sanctum_InstanceMapScript(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::instance_sethekk_halls_InstanceMapScript(), instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript::instance_shadow_labyrinth_InstanceMapScript(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::instance_sunwell_plateau_InstanceMapScript(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::instance_temple_of_ahnqiraj_InstanceMapScript(), instance_the_eye::instance_the_eye_InstanceMapScript::instance_the_eye_InstanceMapScript(), and instance_zulgurub::instance_zulgurub_InstanceMapScript::instance_zulgurub_InstanceMapScript().

◆ LoadInstanceSavedGameobjectStateData()

void InstanceScript::LoadInstanceSavedGameobjectStateData ( )
771{
772 _objectStateMap.clear();
773
775 stmt->SetData(0, instance->GetInstanceId());
776
777 if (PreparedQueryResult result = CharacterDatabase.Query(stmt))
778 {
779 Field* fields;
780
781 do
782 {
783 fields = result->Fetch();
784 StoreGameObjectState(fields[0].Get<uint32>(), fields[1].Get<uint8>());
785
786 } while (result->NextRow());
787 }
788}
@ CHAR_SELECT_INSTANCE_SAVED_DATA
Definition: CharacterDatabase.h:524
std::shared_ptr< PreparedResultSet > PreparedQueryResult
Definition: DatabaseEnvFwd.h:45
DatabaseWorkerPool< CharacterDatabaseConnection > CharacterDatabase
Accessor to the character database.
Definition: DatabaseEnv.cpp:21
Definition: PreparedStatement.h:157
Class used to access individual fields of database query result.
Definition: Field.h:98
Acore::Types::is_default< T > SetData(const uint8 index, T value)
Definition: PreparedStatement.h:77
void StoreGameObjectState(ObjectGuid::LowType spawnId, uint8 state)
Definition: InstanceScript.h:273
uint32 GetInstanceId() const
Definition: Map.h:417

References _objectStateMap, CHAR_SELECT_INSTANCE_SAVED_DATA, CharacterDatabase, Map::GetInstanceId(), instance, PreparedStatementBase::SetData(), and StoreGameObjectState().

Referenced by InstanceMap::CreateInstanceScript().

◆ LoadMinionData()

◆ LoadObjectData() [1/2]

void InstanceScript::LoadObjectData ( ObjectData const *  creatureData,
ObjectData const *  gameObjectData 
)
protected
177{
178 if (creatureData)
179 {
181 }
182
183 if (gameObjectData)
184 {
186 }
187
188 LOG_DEBUG("scripts", "InstanceScript::LoadObjectData: {} objects loaded.", _creatureInfo.size() + _gameObjectInfo.size());
189}
ObjectData const creatureData[]
Definition: instance_blackwing_lair.cpp:45
ObjectData const gameObjectData[]
Definition: instance_karazhan.cpp:53
void LoadObjectData(ObjectData const *creatureData, ObjectData const *gameObjectData)
Definition: InstanceScript.cpp:176

References _creatureInfo, _gameObjectInfo, creatureData, gameObjectData, LoadObjectData(), and LOG_DEBUG.

Referenced by instance_zulaman::instance_zulaman_InstanceMapScript::Initialize(), instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript::Initialize(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::Initialize(), instance_the_underbog::instance_the_underbog_InstanceMapScript::Initialize(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::Initialize(), instance_ahnkahet::instance_ahnkahet_InstanceScript::instance_ahnkahet_InstanceScript(), instance_arcatraz::instance_arcatraz_InstanceMapScript::instance_arcatraz_InstanceMapScript(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::instance_azjol_nerub_InstanceScript(), instance_black_temple::instance_black_temple_InstanceMapScript::instance_black_temple_InstanceMapScript(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::instance_blackwing_lair_InstanceMapScript(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::instance_blood_furnace_InstanceMapScript(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::instance_gruuls_lair_InstanceMapScript(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::instance_icecrown_citadel_InstanceMapScript(), instance_karazhan::instance_karazhan_InstanceMapScript::instance_karazhan_InstanceMapScript(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::instance_magisters_terrace_InstanceMapScript(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::instance_mount_hyjal_InstanceMapScript(), instance_naxxramas::instance_naxxramas_InstanceMapScript::instance_naxxramas_InstanceMapScript(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::instance_ruins_of_ahnqiraj_InstanceMapScript(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::instance_sethekk_halls_InstanceMapScript(), instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript::instance_shadow_labyrinth_InstanceMapScript(), instance_steam_vault::instance_steam_vault_InstanceMapScript::instance_steam_vault_InstanceMapScript(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::instance_sunwell_plateau_InstanceMapScript(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::instance_temple_of_ahnqiraj_InstanceMapScript(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::instance_the_black_morass_InstanceMapScript(), instance_the_eye::instance_the_eye_InstanceMapScript::instance_the_eye_InstanceMapScript(), instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::instance_the_slave_pens_InstanceMapScript(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::instance_utgarde_keep_InstanceMapScript(), instance_zulgurub::instance_zulgurub_InstanceMapScript::instance_zulgurub_InstanceMapScript(), and LoadObjectData().

◆ LoadObjectData() [2/2]

void InstanceScript::LoadObjectData ( ObjectData const *  creatureData,
ObjectInfoMap objectInfo 
)
staticprivate
192{
193 while (data->entry)
194 {
195 objectInfo[data->entry] = data->type;
196 ++data;
197 }
198}

References ObjectData::entry, and ObjectData::type.

◆ LoadSummonData()

◆ MarkAreaTriggerDone()

void InstanceScript::MarkAreaTriggerDone ( uint32  id)
inline
262{ _activatedAreaTriggers.insert(id); }

References _activatedAreaTriggers.

◆ OnCreatureCreate()

void InstanceScript::OnCreatureCreate ( Creature creature)
overridevirtual

Reimplemented from ZoneScript.

Reimplemented in instance_scholomance::instance_scholomance_InstanceMapScript, instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_blackrock_spire::instance_blackrock_spireMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_molten_core::instance_molten_core_InstanceMapScript, instance_gnomeregan::instance_gnomeregan_InstanceMapScript, instance_karazhan::instance_karazhan_InstanceMapScript, instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript, instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript, instance_uldaman::instance_uldaman_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_zulgurub::instance_zulgurub_InstanceMapScript, instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript, instance_hyjal::instance_mount_hyjal_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_the_black_morass::instance_the_black_morass_InstanceMapScript, instance_dire_maul::instance_dire_maul_InstanceMapScript, instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript, instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript, instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_azjol_nerub::instance_azjol_nerub_InstanceScript, instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_nexus::instance_nexus_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript, instance_black_temple::instance_black_temple_InstanceMapScript, instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript, instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript, instance_blood_furnace::instance_blood_furnace_InstanceMapScript, instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript, instance_shattered_halls::instance_shattered_halls_InstanceMapScript, instance_the_eye::instance_the_eye_InstanceMapScript, instance_mechanar::instance_mechanar_InstanceMapScript, instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, and instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript.

59{
60 AddObject(creature);
61 AddMinion(creature);
62
63 if (creature->IsSummon())
64 SetSummoner(creature);
65}
bool IsSummon() const
Definition: Unit.h:751
void AddMinion(Creature *minion, bool add=true)
Definition: InstanceScript.cpp:346
void SetSummoner(Creature *creature)
Definition: InstanceScript.cpp:363

References AddMinion(), AddObject(), Unit::IsSummon(), and SetSummoner().

Referenced by instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::OnCreatureCreate(), instance_karazhan::instance_karazhan_InstanceMapScript::OnCreatureCreate(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::OnCreatureCreate(), instance_zulaman::instance_zulaman_InstanceMapScript::OnCreatureCreate(), instance_zulgurub::instance_zulgurub_InstanceMapScript::OnCreatureCreate(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnCreatureCreate(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::OnCreatureCreate(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::OnCreatureCreate(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnCreatureCreate(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::OnCreatureCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnCreatureCreate(), instance_naxxramas::instance_naxxramas_InstanceMapScript::OnCreatureCreate(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::OnCreatureCreate(), instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript::OnCreatureCreate(), instance_black_temple::instance_black_temple_InstanceMapScript::OnCreatureCreate(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::OnCreatureCreate(), instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::OnCreatureCreate(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::OnCreatureCreate(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::OnCreatureCreate(), and instance_the_eye::instance_the_eye_InstanceMapScript::OnCreatureCreate().

◆ OnCreatureRemove()

◆ OnGameObjectCreate()

void InstanceScript::OnGameObjectCreate ( GameObject go)
overridevirtual

Reimplemented from ZoneScript.

Reimplemented in instance_deadmines::instance_deadmines_InstanceMapScript, instance_gnomeregan::instance_gnomeregan_InstanceMapScript, instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_uldaman::instance_uldaman_InstanceMapScript, instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_dire_maul::instance_dire_maul_InstanceMapScript, instance_maraudon::instance_maraudon_InstanceMapScript, instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_gundrak::instance_gundrak_InstanceMapScript, instance_nexus::instance_nexus_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_mechanar::instance_mechanar_InstanceMapScript, instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_blackrock_spire::instance_blackrock_spireMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_molten_core::instance_molten_core_InstanceMapScript, instance_karazhan::instance_karazhan_InstanceMapScript, instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript, instance_scholomance::instance_scholomance_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_zulgurub::instance_zulgurub_InstanceMapScript, instance_hyjal::instance_mount_hyjal_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript, instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript, instance_ahnkahet::instance_ahnkahet_InstanceScript, instance_azjol_nerub::instance_azjol_nerub_InstanceScript, instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, instance_black_temple::instance_black_temple_InstanceMapScript, instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript, instance_steam_vault::instance_steam_vault_InstanceMapScript, instance_blood_furnace::instance_blood_furnace_InstanceMapScript, instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript, instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript, instance_arcatraz::instance_arcatraz_InstanceMapScript, instance_the_eye::instance_the_eye_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, and instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript.

74{
75 AddObject(go);
76 AddDoor(go);
77 sScriptMgr->AfterInstanceGameObjectCreate(instance, go);
78}
#define sScriptMgr
Definition: ScriptMgr.h:709
void AddDoor(GameObject *door, bool add=true)
Definition: InstanceScript.cpp:319

References AddDoor(), AddObject(), instance, and sScriptMgr.

Referenced by instance_blackrock_spire::instance_blackrock_spireMapScript::OnGameObjectCreate(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::OnGameObjectCreate(), instance_karazhan::instance_karazhan_InstanceMapScript::OnGameObjectCreate(), instance_zulaman::instance_zulaman_InstanceMapScript::OnGameObjectCreate(), instance_zulgurub::instance_zulgurub_InstanceMapScript::OnGameObjectCreate(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::OnGameObjectCreate(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnGameObjectCreate(), instance_ahnkahet::instance_ahnkahet_InstanceScript::OnGameObjectCreate(), instance_black_temple::instance_black_temple_InstanceMapScript::OnGameObjectCreate(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::OnGameObjectCreate(), instance_steam_vault::instance_steam_vault_InstanceMapScript::OnGameObjectCreate(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::OnGameObjectCreate(), instance_the_eye::instance_the_eye_InstanceMapScript::OnGameObjectCreate(), and instance_naxxramas::instance_naxxramas_InstanceMapScript::OnGameObjectCreate().

◆ OnGameObjectRemove()

◆ OnPlayerAreaUpdate()

virtual void InstanceScript::OnPlayerAreaUpdate ( Player ,
uint32  ,
uint32   
)
inlinevirtual

◆ OnPlayerEnter()

virtual void InstanceScript::OnPlayerEnter ( Player )
inlinevirtual

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_molten_core::instance_molten_core_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_the_black_morass::instance_the_black_morass_InstanceMapScript, instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_shattered_halls::instance_shattered_halls_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, and instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript.

185{}

Referenced by InstanceMap::AddPlayerToMap().

◆ OnPlayerInWaterStateUpdate()

virtual void InstanceScript::OnPlayerInWaterStateUpdate ( Player ,
bool   
)
inlinevirtual

◆ ReadSaveDataBossStates()

void InstanceScript::ReadSaveDataBossStates ( std::istringstream &  data)
protected
478{
479 uint32 bossId = 0;
480 for (std::vector<BossInfo>::iterator i = bosses.begin(); i != bosses.end(); ++i, ++bossId)
481 {
482 uint32 buff;
483 data >> buff;
484 if (buff == IN_PROGRESS || buff == FAIL || buff == SPECIAL)
485 buff = NOT_STARTED;
486
487 if (buff < TO_BE_DECIDED)
488 SetBossState(bossId, EncounterState(buff));
489 }
490}
std::uint32_t uint32
Definition: Define.h:107
EncounterState
Definition: InstanceScript.h:56
virtual bool SetBossState(uint32 id, EncounterState state)
Definition: InstanceScript.cpp:373

References bosses, FAIL, IN_PROGRESS, NOT_STARTED, SetBossState(), SPECIAL, and TO_BE_DECIDED.

Referenced by Load().

◆ ReadSaveDataHeaders()

bool InstanceScript::ReadSaveDataHeaders ( std::istringstream &  data)
protected
464{
465 for (char header : headers)
466 {
467 char buff;
468 data >> buff;
469
470 if (header != buff)
471 return false;
472 }
473
474 return true;
475}
std::vector< char > headers
Definition: InstanceScript.h:325

References headers.

Referenced by Load().

◆ ReadSaveDataMore()

virtual void InstanceScript::ReadSaveDataMore ( std::istringstream &  )
inlineprotectedvirtual

Reimplemented in instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_gnomeregan::instance_gnomeregan_InstanceMapScript, instance_scholomance::instance_scholomance_InstanceMapScript, instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_uldaman::instance_uldaman_InstanceMapScript, instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_dire_maul::instance_dire_maul_InstanceMapScript, instance_maraudon::instance_maraudon_InstanceMapScript, instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript, instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, and instance_shattered_halls::instance_shattered_halls_InstanceMapScript.

316{ }

Referenced by Load().

◆ ReadSavePersistentData()

void InstanceScript::ReadSavePersistentData ( std::istringstream &  data)
protected
493{
494 for (uint32 i = 0; i < persistentData.size(); ++i)
495 {
496 data >> persistentData[i];
497 }
498}

References persistentData.

Referenced by Load().

◆ RemoveDoor()

◆ RemoveMinion()

◆ RemoveObject() [1/3]

void InstanceScript::RemoveObject ( Creature obj)
protected
280{
281 AddObject(obj, false);
282}

References AddObject().

Referenced by OnCreatureRemove(), and OnGameObjectRemove().

◆ RemoveObject() [2/3]

void InstanceScript::RemoveObject ( GameObject obj)
protected
294{
295 AddObject(obj, false);
296}

References AddObject().

◆ RemoveObject() [3/3]

void InstanceScript::RemoveObject ( WorldObject obj,
uint32  type 
)
protected
315{
316 AddObject(obj, type, false);
317}

References AddObject().

◆ ResetAreaTriggerDone()

void InstanceScript::ResetAreaTriggerDone ( uint32  id)
inline

◆ SaveToDB()

void InstanceScript::SaveToDB ( )
42{
43 std::string data = GetSaveData();
44 //if (data.empty()) // pussywizard: encounterMask can be updated and theres no reason to not save
45 // return;
46
47 // pussywizard:
48 InstanceSave* save = sInstanceSaveMgr->GetInstanceSave(instance->GetInstanceId());
49 if (save)
50 save->SetInstanceData(data);
51
53 stmt->SetData(0, data);
54 stmt->SetData(1, instance->GetInstanceId());
55 CharacterDatabase.Execute(stmt);
56}
#define sInstanceSaveMgr
Definition: InstanceSaveMgr.h:202
@ CHAR_UPD_INSTANCE_SAVE_DATA
Definition: CharacterDatabase.h:212
Definition: InstanceSaveMgr.h:56
void SetInstanceData(std::string str)
Definition: InstanceSaveMgr.h:70
virtual std::string GetSaveData()
Definition: InstanceScript.cpp:500

References CHAR_UPD_INSTANCE_SAVE_DATA, CharacterDatabase, Map::GetInstanceId(), GetSaveData(), instance, PreparedStatementBase::SetData(), InstanceSave::SetInstanceData(), and sInstanceSaveMgr.

Referenced by BossAI::_EnterEvadeMode(), BossAI::_JustDied(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::DoCheckDedicatedInsanity(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::HandleDropAttempt(), instance_commandscript::HandleInstanceSaveDataCommand(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::InstanceCleanup(), boss_victor_nefarius::boss_victor_nefariusAI::JustDied(), boss_mandokir::boss_mandokirAI::JustDied(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::OnUnitDeath(), instance_stratholme::instance_stratholme_InstanceMapScript::OnUnitDeath(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OnUnitDeath(), instance_naxxramas::instance_naxxramas_InstanceMapScript::SetBossState(), SetBossState(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetBossState(), instance_naxxramas::instance_naxxramas_InstanceMapScript::SetData(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::SetData(), instance_deadmines::instance_deadmines_InstanceMapScript::SetData(), instance_gnomeregan::instance_gnomeregan_InstanceMapScript::SetData(), instance_scholomance::instance_scholomance_InstanceMapScript::SetData(), instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript::SetData(), instance_stratholme::instance_stratholme_InstanceMapScript::SetData(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::SetData(), instance_uldaman::instance_uldaman_InstanceMapScript::SetData(), instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript::SetData(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::SetData(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::SetData(), instance_dire_maul::instance_dire_maul_InstanceMapScript::SetData(), instance_maraudon::instance_maraudon_InstanceMapScript::SetData(), instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript::SetData(), instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript::SetData(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SetData(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::SetData(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::SetData(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::SetData(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::SetData(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetData(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::SetData(), instance_oculus::instance_oculus_InstanceMapScript::SetData(), instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript::SetData(), instance_ulduar::instance_ulduar_InstanceMapScript::SetData(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::SetData(), instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript::SetData(), instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript::SetData(), instance_violet_hold::instance_violet_hold_InstanceMapScript::SetData(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::SetData(), instance_ahnkahet::instance_ahnkahet_InstanceScript::SetData(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::SetData(), instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript::SetData(), StorePersistentData(), instance_stratholme::instance_stratholme_InstanceMapScript::Update(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::Update(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::Update(), and instance_violet_hold::instance_violet_hold_InstanceMapScript::Update().

◆ SendEncounterUnit()

void InstanceScript::SendEncounterUnit ( uint32  type,
Unit unit = nullptr,
uint8  param1 = 0,
uint8  param2 = 0 
)
740{
741 // size of this packet is at most 15 (usually less)
743 data << uint32(type);
744
745 switch (type)
746 {
750 data << unit->GetPackGUID();
751 data << uint8(param1);
752 break;
756 data << uint8(param1);
757 break;
759 data << uint8(param1);
760 data << uint8(param2);
761 break;
763 default:
764 break;
765 }
766
767 instance->SendToPlayers(&data);
768}
@ ENCOUNTER_FRAME_ENABLE_OBJECTIVE
Definition: InstanceScript.h:49
@ ENCOUNTER_FRAME_DISENGAGE
Definition: InstanceScript.h:46
@ ENCOUNTER_FRAME_UPDATE_PRIORITY
Definition: InstanceScript.h:47
@ ENCOUNTER_FRAME_DISABLE_OBJECTIVE
Definition: InstanceScript.h:51
@ ENCOUNTER_FRAME_UPDATE_OBJECTIVE
Definition: InstanceScript.h:50
@ ENCOUNTER_FRAME_REFRESH_FRAMES
Definition: InstanceScript.h:52
@ ENCOUNTER_FRAME_ADD_TIMER
Definition: InstanceScript.h:48
@ ENCOUNTER_FRAME_ENGAGE
Definition: InstanceScript.h:45
@ SMSG_UPDATE_INSTANCE_ENCOUNTER_UNIT
Definition: Opcodes.h:562
PackedGuid const & GetPackGUID() const
Definition: Object.h:114
void SendToPlayers(WorldPacket const *data) const
Definition: Map.cpp:2757
Definition: WorldPacket.h:26

References ENCOUNTER_FRAME_ADD_TIMER, ENCOUNTER_FRAME_DISABLE_OBJECTIVE, ENCOUNTER_FRAME_DISENGAGE, ENCOUNTER_FRAME_ENABLE_OBJECTIVE, ENCOUNTER_FRAME_ENGAGE, ENCOUNTER_FRAME_REFRESH_FRAMES, ENCOUNTER_FRAME_UPDATE_OBJECTIVE, ENCOUNTER_FRAME_UPDATE_PRIORITY, Object::GetPackGUID(), instance, Map::SendToPlayers(), and SMSG_UPDATE_INSTANCE_ENCOUNTER_UNIT.

Referenced by boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::DamageTaken(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::DoAction(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::DoAction(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::DoAction(), boss_halion::boss_halionAI::EnterEvadeMode(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::HealReceived(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustDied(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustDied(), boss_prince_valanar_icc::boss_prince_valanarAI::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), boss_halion::boss_halionAI::JustDied(), boss_twilight_halion::boss_twilight_halionAI::JustDied(), boss_halion::boss_halionAI::JustEngagedWith(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustEngagedWith(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustEngagedWith(), boss_prince_valanar_icc::boss_prince_valanarAI::JustEngagedWith(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustReachedHome(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustReachedHome(), boss_prince_valanar_icc::boss_prince_valanarAI::JustReachedHome(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::Reset(), and boss_twilight_halion::boss_twilight_halionAI::UpdateAI().

◆ ServerAllowsTwoSideGroups()

bool InstanceScript::ServerAllowsTwoSideGroups ( )
inline
232{ return sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_GROUP); }
@ CONFIG_ALLOW_TWO_SIDE_INTERACTION_GROUP
Definition: IWorld.h:75
#define sWorld
Definition: World.h:443

References CONFIG_ALLOW_TWO_SIDE_INTERACTION_GROUP, and sWorld.

◆ SetBossNumber()

void InstanceScript::SetBossNumber ( uint32  number)
inlineprotected
285{ bosses.resize(number); }

References bosses.

Referenced by instance_zulaman::instance_zulaman_InstanceMapScript::Initialize(), instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript::Initialize(), instance_gundrak::instance_gundrak_InstanceMapScript::Initialize(), instance_nexus::instance_nexus_InstanceMapScript::Initialize(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::Initialize(), instance_the_underbog::instance_the_underbog_InstanceMapScript::Initialize(), instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript::Initialize(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::Initialize(), instance_ahnkahet::instance_ahnkahet_InstanceScript::instance_ahnkahet_InstanceScript(), instance_arcatraz::instance_arcatraz_InstanceMapScript::instance_arcatraz_InstanceMapScript(), instance_auchenai_crypts::instance_auchenai_crypts_InstanceMapScript::instance_auchenai_crypts_InstanceMapScript(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::instance_azjol_nerub_InstanceScript(), instance_black_temple::instance_black_temple_InstanceMapScript::instance_black_temple_InstanceMapScript(), instance_blackrock_spire::instance_blackrock_spireMapScript::instance_blackrock_spireMapScript(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::instance_blackwing_lair_InstanceMapScript(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::instance_blood_furnace_InstanceMapScript(), instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript::instance_drak_tharon_keep_InstanceScript(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::instance_gruuls_lair_InstanceMapScript(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::instance_icecrown_citadel_InstanceMapScript(), instance_karazhan::instance_karazhan_InstanceMapScript::instance_karazhan_InstanceMapScript(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::instance_magisters_terrace_InstanceMapScript(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::instance_magtheridons_lair_InstanceMapScript(), instance_mana_tombs::instance_mana_tombs_InstanceMapScript::instance_mana_tombs_InstanceMapScript(), instance_mechanar::instance_mechanar_InstanceMapScript::instance_mechanar_InstanceMapScript(), instance_molten_core::instance_molten_core_InstanceMapScript::instance_molten_core_InstanceMapScript(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::instance_mount_hyjal_InstanceMapScript(), instance_naxxramas::instance_naxxramas_InstanceMapScript::instance_naxxramas_InstanceMapScript(), instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript::instance_obsidian_sanctum_InstanceMapScript(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::instance_ruby_sanctum_InstanceMapScript(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::instance_ruins_of_ahnqiraj_InstanceMapScript(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::instance_sethekk_halls_InstanceMapScript(), instance_shadow_labyrinth::instance_shadow_labyrinth_InstanceMapScript::instance_shadow_labyrinth_InstanceMapScript(), instance_steam_vault::instance_steam_vault_InstanceMapScript::instance_steam_vault_InstanceMapScript(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::instance_sunwell_plateau_InstanceMapScript(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::instance_temple_of_ahnqiraj_InstanceMapScript(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::instance_the_black_morass_InstanceMapScript(), instance_the_botanica::instance_the_botanica_InstanceMapScript::instance_the_botanica_InstanceMapScript(), instance_the_eye::instance_the_eye_InstanceMapScript::instance_the_eye_InstanceMapScript(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::instance_utgarde_keep_InstanceMapScript(), and instance_zulgurub::instance_zulgurub_InstanceMapScript::instance_zulgurub_InstanceMapScript().

◆ SetBossState()

bool InstanceScript::SetBossState ( uint32  id,
EncounterState  state 
)
virtual

Reimplemented in instance_molten_core::instance_molten_core_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_steam_vault::instance_steam_vault_InstanceMapScript, instance_nexus::instance_nexus_InstanceMapScript, instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript, instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript, instance_blackrock_spire::instance_blackrock_spireMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_karazhan::instance_karazhan_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_zulgurub::instance_zulgurub_InstanceMapScript, instance_the_black_morass::instance_the_black_morass_InstanceMapScript, instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript, instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript, instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript, instance_gundrak::instance_gundrak_InstanceMapScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_black_temple::instance_black_temple_InstanceMapScript, instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript, instance_blood_furnace::instance_blood_furnace_InstanceMapScript, instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript, and instance_arcatraz::instance_arcatraz_InstanceMapScript.

374{
375 if (id < bosses.size())
376 {
377 BossInfo* bossInfo = &bosses[id];
378 sScriptMgr->OnBeforeSetBossState(id, state, bossInfo->state, instance);
379 if (bossInfo->state == TO_BE_DECIDED) // loading
380 {
381 bossInfo->state = state;
382 return false;
383 }
384 else
385 {
386 if (bossInfo->state == state)
387 return false;
388
389 if (state == DONE)
390 for (MinionSet::iterator i = bossInfo->minion.begin(); i != bossInfo->minion.end(); ++i)
391 if ((*i)->isWorldBoss() && (*i)->IsAlive())
392 return false;
393
394 bossInfo->state = state;
395 SaveToDB();
396 }
397
398 for (uint32 type = 0; type < MAX_DOOR_TYPES; ++type)
399 for (DoorSet::iterator i = bossInfo->door[type].begin(); i != bossInfo->door[type].end(); ++i)
400 UpdateDoorState(*i);
401
402 for (MinionSet::iterator i = bossInfo->minion.begin(); i != bossInfo->minion.end(); ++i)
403 UpdateMinionState(*i, state);
404
405 return true;
406 }
407 return false;
408}
@ MAX_DOOR_TYPES
Definition: InstanceScript.h:70
EncounterState state
Definition: InstanceScript.h:113
void UpdateMinionState(Creature *minion, EncounterState state)
Definition: InstanceScript.cpp:209
void SaveToDB()
Definition: InstanceScript.cpp:41

References bosses, DONE, BossInfo::door, instance, MAX_DOOR_TYPES, BossInfo::minion, SaveToDB(), sScriptMgr, BossInfo::state, TO_BE_DECIDED, UpdateDoorState(), and UpdateMinionState().

Referenced by BossAI::_EnterEvadeMode(), BossAI::_JustDied(), BossAI::_JustEngagedWith(), BossAI::_Reset(), npc_warden_mellichar::npc_warden_mellicharAI::DamageTaken(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::DoAction(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::DoAction(), boss_broggok::DoAction(), boss_hadronox::boss_hadronoxAI::DoAction(), npc_icc_gauntlet_controller::npc_icc_gauntlet_controllerAI::DoAction(), boss_dorothee::EnterEvadeMode(), boss_roar::EnterEvadeMode(), boss_strawman::EnterEvadeMode(), boss_tinhead::EnterEvadeMode(), boss_crone::EnterEvadeMode(), boss_bigbadwolf::EnterEvadeMode(), boss_julianne::EnterEvadeMode(), boss_romulo::EnterEvadeMode(), boss_gyth::boss_gythAI::EnterEvadeMode(), boss_rend_blackhand::boss_rend_blackhandAI::EnterEvadeMode(), boss_sindragosa::boss_sindragosaAI::EnterEvadeMode(), boss_the_lich_king::boss_the_lich_kingAI::EnterEvadeMode(), boss_ouro::EnterEvadeMode(), npc_dirt_mound::EnterEvadeMode(), instance_commandscript::HandleInstanceSetBossStateCommand(), boss_valithria_dreamwalker::boss_valithria_dreamwalkerAI::HealReceived(), boss_gyth::boss_gythAI::JustDied(), boss_overlord_wyrmthalak::boss_overlordwyrmthalakAI::JustDied(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::JustDied(), boss_rend_blackhand::boss_rend_blackhandAI::JustDied(), boss_victor_nefarius::boss_victor_nefariusAI::JustDied(), boss_crone::JustDied(), boss_bigbadwolf::JustDied(), boss_julianne::JustDied(), boss_romulo::JustDied(), boss_priestess_delrissa::JustDied(), boss_sacrolash::JustDied(), boss_alythess::JustDied(), boss_zuljin::JustDied(), boss_mandokir::boss_mandokirAI::JustDied(), npc_ohgan::npc_ohganAI::JustDied(), npc_vilebranch_speaker::JustDied(), boss_sartharion_dragonAI::JustDied(), boss_prince_valanar_icc::boss_prince_valanarAI::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), npc_icc_gauntlet_controller::npc_icc_gauntlet_controllerAI::JustDied(), boss_novos::boss_novosAI::JustDied(), boss_sartharion_dragonAI::JustEngagedWith(), boss_lord_marrowgar::JustEngagedWith(), boss_olm_the_summoner::JustEngagedWith(), boss_kiggler_the_crazed::JustEngagedWith(), boss_blindeye_the_seer::JustEngagedWith(), boss_krosh_firehand::JustEngagedWith(), boss_the_lich_king::boss_the_lich_kingAI::JustEngagedWith(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::JustEngagedWith(), boss_trollgore::boss_trollgoreAI::JustEngagedWith(), boss_prince_valanar_icc::boss_prince_valanarAI::JustEngagedWith(), boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::JustEngagedWith(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::JustEngagedWith(), boss_lady_deathwhisper::boss_lady_deathwhisperAI::JustEngagedWith(), boss_professor_putricide::boss_professor_putricideAI::JustEngagedWith(), boss_sindragosa::boss_sindragosaAI::JustEngagedWith(), boss_prince_valanar_icc::boss_prince_valanarAI::JustReachedHome(), boss_deathbringer_saurfang::boss_deathbringer_saurfangAI::JustReachedHome(), boss_festergut::boss_festergutAI::JustReachedHome(), boss_lord_marrowgar::JustReachedHome(), boss_professor_putricide::boss_professor_putricideAI::JustReachedHome(), boss_rotface::boss_rotfaceAI::JustReachedHome(), boss_mandokir::boss_mandokirAI::MovementInform(), boss_professor_putricide::boss_professor_putricideAI::MovementInform(), npc_akama_illidan::PathEndReached(), SmartScript::ProcessAction(), ReadSaveDataBossStates(), boss_gyth::boss_gythAI::Reset(), boss_rend_blackhand::boss_rend_blackhandAI::Reset(), boss_majordomo::boss_majordomoAI::Reset(), boss_priestess_delrissa::Reset(), boss_kalec::Reset(), npc_kiljaeden_controller::Reset(), boss_mandokir::boss_mandokirAI::Reset(), boss_ouro::Reset(), boss_novos::boss_novosAI::Reset(), boss_prince_valanar_icc::boss_prince_valanarAI::Reset(), boss_blood_queen_lana_thel::boss_blood_queen_lana_thelAI::Reset(), npc_green_dragon_combat_trigger::npc_green_dragon_combat_triggerAI::Reset(), npc_icc_gauntlet_controller::npc_icc_gauntlet_controllerAI::Reset(), boss_olm_the_summoner::Reset(), boss_kiggler_the_crazed::Reset(), boss_blindeye_the_seer::Reset(), boss_krosh_firehand::Reset(), boss_grand_warlock_nethekurse::Reset(), npc_warden_mellichar::npc_warden_mellicharAI::Reset(), instance_molten_core::instance_molten_core_InstanceMapScript::SetBossState(), instance_naxxramas::instance_naxxramas_InstanceMapScript::SetBossState(), instance_steam_vault::instance_steam_vault_InstanceMapScript::SetBossState(), instance_nexus::instance_nexus_InstanceMapScript::SetBossState(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::SetBossState(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::SetBossState(), instance_blackrock_spire::instance_blackrock_spireMapScript::SetBossState(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::SetBossState(), instance_karazhan::instance_karazhan_InstanceMapScript::SetBossState(), instance_zulaman::instance_zulaman_InstanceMapScript::SetBossState(), instance_zulgurub::instance_zulgurub_InstanceMapScript::SetBossState(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::SetBossState(), instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript::SetBossState(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::SetBossState(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::SetBossState(), instance_gundrak::instance_gundrak_InstanceMapScript::SetBossState(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetBossState(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::SetBossState(), instance_black_temple::instance_black_temple_InstanceMapScript::SetBossState(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::SetBossState(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::SetBossState(), instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript::SetBossState(), instance_arcatraz::instance_arcatraz_InstanceMapScript::SetBossState(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::SetData(), boss_shade_of_akama::SpellHit(), npc_barnes::npc_barnesAI::StartEvent(), boss_rend_blackhand::boss_rend_blackhandAI::SummonedCreatureDespawn(), boss_priestess_delrissa::SummonedCreatureDies(), boss_majordomo::boss_majordomoAI::SummonedCreatureDies(), npc_kiljaeden_controller::SummonedCreatureDies(), npc_warden_mellichar::npc_warden_mellicharAI::SummonedCreatureDies(), boss_pyroguard_emberseer::boss_pyroguard_emberseerAI::UpdateAI(), boss_rend_blackhand::boss_rend_blackhandAI::UpdateAI(), and npc_halion_controller::npc_halion_controllerAI::UpdateAI().

◆ SetCompletedEncountersMask()

void InstanceScript::SetCompletedEncountersMask ( uint32  newMask,
bool  save 
)
721{
722 if (completedEncounters == newMask)
723 return;
724 completedEncounters = newMask;
725 // pussywizard:
726 if (save)
727 {
728 InstanceSave* iSave = sInstanceSaveMgr->GetInstanceSave(instance->GetInstanceId());
729 if (iSave)
731
734 stmt->SetData(1, instance->GetInstanceId());
735 CharacterDatabase.Execute(stmt);
736 }
737}
@ CHAR_UPD_INSTANCE_SAVE_ENCOUNTERMASK
Definition: CharacterDatabase.h:213
void SetCompletedEncounterMask(uint32 mask)
Definition: InstanceSaveMgr.h:72

References CHAR_UPD_INSTANCE_SAVE_ENCOUNTERMASK, CharacterDatabase, completedEncounters, Map::GetInstanceId(), instance, InstanceSave::SetCompletedEncounterMask(), PreparedStatementBase::SetData(), and sInstanceSaveMgr.

Referenced by InstanceMap::CreateInstanceScript().

◆ SetHeaders()

void InstanceScript::SetHeaders ( std::string const &  dataHeaders)
protected
142{
143 for (char header : dataHeaders)
144 {
145 if (isalpha(header))
146 {
147 headers.push_back(header);
148 }
149 }
150}

References headers.

Referenced by instance_uldaman::instance_uldaman_InstanceMapScript::Initialize(), instance_zulaman::instance_zulaman_InstanceMapScript::Initialize(), instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript::Initialize(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::Initialize(), instance_dire_maul::instance_dire_maul_InstanceMapScript::Initialize(), instance_maraudon::instance_maraudon_InstanceMapScript::Initialize(), instance_onyxias_lair::instance_onyxias_lair_InstanceMapScript::Initialize(), instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript::Initialize(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::Initialize(), instance_nexus::instance_nexus_InstanceMapScript::Initialize(), instance_oculus::instance_oculus_InstanceMapScript::Initialize(), instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript::Initialize(), instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript::Initialize(), instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript::Initialize(), instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript::Initialize(), instance_violet_hold::instance_violet_hold_InstanceMapScript::Initialize(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::Initialize(), instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript::Initialize(), instance_ahnkahet::instance_ahnkahet_InstanceScript::instance_ahnkahet_InstanceScript(), instance_arcatraz::instance_arcatraz_InstanceMapScript::instance_arcatraz_InstanceMapScript(), instance_auchenai_crypts::instance_auchenai_crypts_InstanceMapScript::instance_auchenai_crypts_InstanceMapScript(), instance_azjol_nerub::instance_azjol_nerub_InstanceScript::instance_azjol_nerub_InstanceScript(), instance_black_temple::instance_black_temple_InstanceMapScript::instance_black_temple_InstanceMapScript(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::instance_blackrock_depths_InstanceMapScript(), instance_blackrock_spire::instance_blackrock_spireMapScript::instance_blackrock_spireMapScript(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::instance_blackwing_lair_InstanceMapScript(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::instance_blood_furnace_InstanceMapScript(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::instance_culling_of_stratholme_InstanceMapScript(), instance_deadmines::instance_deadmines_InstanceMapScript::instance_deadmines_InstanceMapScript(), instance_drak_tharon_keep::instance_drak_tharon_keep_InstanceScript::instance_drak_tharon_keep_InstanceScript(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::instance_forge_of_souls_InstanceScript(), instance_gnomeregan::instance_gnomeregan_InstanceMapScript::instance_gnomeregan_InstanceMapScript(), instance_gruuls_lair::instance_gruuls_lair_InstanceMapScript::instance_gruuls_lair_InstanceMapScript(), instance_gundrak::instance_gundrak_InstanceMapScript::instance_gundrak_InstanceMapScript(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::instance_halls_of_reflection_InstanceMapScript(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::instance_icecrown_citadel_InstanceMapScript(), instance_karazhan::instance_karazhan_InstanceMapScript::instance_karazhan_InstanceMapScript(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::instance_magisters_terrace_InstanceMapScript(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::instance_magtheridons_lair_InstanceMapScript(), instance_mana_tombs::instance_mana_tombs_InstanceMapScript::instance_mana_tombs_InstanceMapScript(), instance_mechanar::instance_mechanar_InstanceMapScript::instance_mechanar_InstanceMapScript(), instance_molten_core::instance_molten_core_InstanceMapScript::instance_molten_core_InstanceMapScript(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::instance_mount_hyjal_InstanceMapScript(), instance_naxxramas::instance_naxxramas_InstanceMapScript::instance_naxxramas_InstanceMapScript(), instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript::instance_obsidian_sanctum_InstanceMapScript(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::instance_pit_of_saron_InstanceScript(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::instance_ruby_sanctum_InstanceMapScript(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::instance_ruins_of_ahnqiraj_InstanceMapScript(), instance_scarlet_monastery::instance_scarlet_monastery_InstanceMapScript::instance_scarlet_monastery_InstanceMapScript(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::instance_sethekk_halls_InstanceMapScript(), instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript::instance_shadowfang_keep_InstanceMapScript(), instance_steam_vault::instance_steam_vault_InstanceMapScript::instance_steam_vault_InstanceMapScript(), instance_stratholme::instance_stratholme_InstanceMapScript::instance_stratholme_InstanceMapScript(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::instance_sunken_temple_InstanceMapScript(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::instance_sunwell_plateau_InstanceMapScript(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::instance_temple_of_ahnqiraj_InstanceMapScript(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::instance_the_black_morass_InstanceMapScript(), instance_the_botanica::instance_the_botanica_InstanceMapScript::instance_the_botanica_InstanceMapScript(), instance_the_eye::instance_the_eye_InstanceMapScript::instance_the_eye_InstanceMapScript(), instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::instance_the_slave_pens_InstanceMapScript(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::instance_trial_of_the_champion_InstanceMapScript(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::instance_trial_of_the_crusader_InstanceMapScript(), instance_ulduar::instance_ulduar_InstanceMapScript::instance_ulduar_InstanceMapScript(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::instance_utgarde_keep_InstanceMapScript(), and instance_zulgurub::instance_zulgurub_InstanceMapScript::instance_zulgurub_InstanceMapScript().

◆ SetPersistentDataCount()

◆ SetSummoner()

void InstanceScript::SetSummoner ( Creature creature)
protected
364{
365 auto const& summonData = _summonInfo.find(creature->GetEntry());
366
367 if (summonData != _summonInfo.end())
368 if (Creature* summoner = GetCreature(summonData->second))
369 if (summoner->IsAIEnabled)
370 summoner->AI()->JustSummoned(creature);
371}
ObjectData const summonData[]
Definition: instance_sunwell_plateau.cpp:62
Creature * GetCreature(uint32 type)
Definition: InstanceScript.cpp:103

References _summonInfo, GetCreature(), Object::GetEntry(), and summonData.

Referenced by OnCreatureCreate().

◆ StoreGameObjectState()

void InstanceScript::StoreGameObjectState ( ObjectGuid::LowType  spawnId,
uint8  state 
)
inline
273{ _objectStateMap[spawnId] = state; };

References _objectStateMap.

Referenced by LoadInstanceSavedGameobjectStateData().

◆ StorePersistentData()

void InstanceScript::StorePersistentData ( uint32  index,
uint32  data 
)

◆ Update()

void InstanceScript::Update ( uint32  diff)
virtual

Reimplemented in instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript, instance_blackrock_spire::instance_blackrock_spireMapScript, instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_zulaman::instance_zulaman_InstanceMapScript, instance_hyjal::instance_mount_hyjal_InstanceMapScript, instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_the_black_morass::instance_the_black_morass_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_gundrak::instance_gundrak_InstanceMapScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, and instance_shattered_halls::instance_shattered_halls_InstanceMapScript.

236{
237 scheduler.Update(diff);
238}
TaskScheduler & Update(success_t const &callback=EmptyCallback)
Definition: TaskScheduler.cpp:27
TaskScheduler scheduler
Definition: InstanceScript.h:282

References scheduler, and TaskScheduler::Update().

Referenced by InstanceMap::Update(), and instance_ulduar::instance_ulduar_InstanceMapScript::Update().

◆ UpdateDoorState()

void InstanceScript::UpdateDoorState ( GameObject door)
protected
241{
242 DoorInfoMapBounds range = doors.equal_range(door->GetEntry());
243 if (range.first == range.second)
244 return;
245
246 // xinef: doors can be assigned to few bosses, if any of them demands doors closed - they should be closed (added & operator for assigment)
247 bool open = true;
248 for (; range.first != range.second && open; ++range.first)
249 {
250 DoorInfo const& info = range.first->second;
251 switch (info.type)
252 {
253 case DOOR_TYPE_ROOM:
254 open &= (info.bossInfo->state != IN_PROGRESS);
255 break;
257 open &= (info.bossInfo->state == DONE);
258 break;
260 open &= (info.bossInfo->state == IN_PROGRESS);
261 break;
262 default:
263 break;
264 }
265 }
266
268}
@ DOOR_TYPE_SPAWN_HOLE
Definition: InstanceScript.h:69
@ DOOR_TYPE_ROOM
Definition: InstanceScript.h:67
@ DOOR_TYPE_PASSAGE
Definition: InstanceScript.h:68

References DoorInfo::bossInfo, DONE, DOOR_TYPE_PASSAGE, DOOR_TYPE_ROOM, DOOR_TYPE_SPAWN_HOLE, doors, Object::GetEntry(), GO_STATE_ACTIVE, GO_STATE_READY, IN_PROGRESS, GameObject::SetGoState(), BossInfo::state, and DoorInfo::type.

Referenced by AddDoor(), and SetBossState().

◆ UpdateMinionState()

void InstanceScript::UpdateMinionState ( Creature minion,
EncounterState  state 
)
protected
210{
211 switch (state)
212 {
213 case NOT_STARTED:
214 if (!minion->IsAlive())
215 minion->Respawn();
216 else if (minion->IsInCombat())
217 minion->AI()->EnterEvadeMode();
218 break;
219 case IN_PROGRESS:
220 if (!minion->IsAlive())
221 minion->Respawn();
222 else
223 {
224 if (minion->GetReactState() == REACT_AGGRESSIVE)
225 {
226 minion->AI()->DoZoneInCombat(nullptr, 100.0f);
227 }
228 }
229 break;
230 default:
231 break;
232 }
233}
@ REACT_AGGRESSIVE
Definition: Unit.h:550
void DoZoneInCombat(Creature *creature=nullptr, float maxRangeToNearestTarget=250.0f)
Definition: CreatureAI.cpp:106
virtual void EnterEvadeMode(EvadeReason why=EVADE_REASON_OTHER)
Definition: CreatureAI.cpp:208
void Respawn(bool force=false)
Definition: Creature.cpp:2035
ReactStates GetReactState() const
Definition: Creature.h:95
CreatureAI * AI() const
Definition: Creature.h:140
bool IsAlive() const
Definition: Unit.h:1654
bool IsInCombat() const
Definition: Unit.h:884

References Creature::AI(), CreatureAI::DoZoneInCombat(), CreatureAI::EnterEvadeMode(), Creature::GetReactState(), IN_PROGRESS, Unit::IsAlive(), Unit::IsInCombat(), NOT_STARTED, REACT_AGGRESSIVE, and Creature::Respawn().

Referenced by SetBossState().

◆ WritePersistentData()

void InstanceScript::WritePersistentData ( std::ostringstream &  data)
protected
533{
534 for (auto const& entry : persistentData)
535 {
536 data << entry << ' ';
537 }
538}

References persistentData.

Referenced by GetSaveData().

◆ WriteSaveDataBossStates()

void InstanceScript::WriteSaveDataBossStates ( std::ostringstream &  data)
protected
525{
526 for (BossInfo const& bossInfo : bosses)
527 {
528 data << uint32(bossInfo.state) << ' ';
529 }
530}

References bosses.

Referenced by GetSaveData().

◆ WriteSaveDataHeaders()

void InstanceScript::WriteSaveDataHeaders ( std::ostringstream &  data)
protected
517{
518 for (char header : headers)
519 {
520 data << header << ' ';
521 }
522}

References headers.

Referenced by GetSaveData().

◆ WriteSaveDataMore()

virtual void InstanceScript::WriteSaveDataMore ( std::ostringstream &  )
inlineprotectedvirtual

Reimplemented in instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript, instance_gnomeregan::instance_gnomeregan_InstanceMapScript, instance_scholomance::instance_scholomance_InstanceMapScript, instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript, instance_stratholme::instance_stratholme_InstanceMapScript, instance_sunken_temple::instance_sunken_temple_InstanceMapScript, instance_uldaman::instance_uldaman_InstanceMapScript, instance_blackfathom_deeps::instance_blackfathom_deeps_InstanceMapScript, instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript, instance_dire_maul::instance_dire_maul_InstanceMapScript, instance_maraudon::instance_maraudon_InstanceMapScript, instance_razorfen_downs::instance_razorfen_downs_InstanceMapScript, instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript, instance_zulfarrak::instance_zulfarrak_InstanceMapScript, instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript, instance_forge_of_souls::instance_forge_of_souls_InstanceScript, instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript, instance_pit_of_saron::instance_pit_of_saron_InstanceScript, instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript, instance_naxxramas::instance_naxxramas_InstanceMapScript, instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript, instance_oculus::instance_oculus_InstanceMapScript, instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript, instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript, instance_ulduar::instance_ulduar_InstanceMapScript, instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript, instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript, instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript, instance_violet_hold::instance_violet_hold_InstanceMapScript, and instance_shattered_halls::instance_shattered_halls_InstanceMapScript.

320{ }

Referenced by GetSaveData().

Member Data Documentation

◆ _activatedAreaTriggers

std::unordered_set<uint32> InstanceScript::_activatedAreaTriggers
private

◆ _creatureInfo

ObjectInfoMap InstanceScript::_creatureInfo
private

Referenced by AddObject(), and LoadObjectData().

◆ _gameObjectInfo

ObjectInfoMap InstanceScript::_gameObjectInfo
private

Referenced by AddObject(), and LoadObjectData().

◆ _objectGuids

ObjectGuidMap InstanceScript::_objectGuids
private

Referenced by AddObject(), and GetObjectGuid().

◆ _objectStateMap

◆ _summonInfo

ObjectInfoMap InstanceScript::_summonInfo
private

Referenced by LoadSummonData(), and SetSummoner().

◆ bosses

◆ completedEncounters

uint32 InstanceScript::completedEncounters
private

◆ doors

DoorInfoMap InstanceScript::doors
private

◆ headers

std::vector<char> InstanceScript::headers
private

◆ instance

Map* InstanceScript::instance

Referenced by instance_blood_furnace::instance_blood_furnace_InstanceMapScript::ActivatePrisoners(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::AddWave1(), boss_tyrannus::boss_tyrannusAI::boss_tyrannusAI(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::CallNextRajaxxLeader(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::CheckAchievementCriteriaMeet(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::CheckAchievementCriteriaMeet(), instance_naxxramas::instance_naxxramas_InstanceMapScript::CheckAchievementCriteriaMeet(), instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript::CheckAchievementCriteriaMeet(), CheckAchievementCriteriaMeet(), instance_molten_core::instance_molten_core_InstanceMapScript::CheckMajordomoExecutus(), boss_prince_valanar_icc::boss_prince_valanarAI::CheckRoom(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::CheckTombReset(), instance_stratholme::instance_stratholme_InstanceMapScript::CheckZiggurats(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::ChromieWhisper(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::CleanupInstance(), violet_hold_trashAI::ClearDoorSealAura(), boss_hodir::boss_hodirAI::DoAction(), npc_hor_lich_king::npc_hor_lich_kingAI::DoAction(), npc_vh_void_sentry::npc_vh_void_sentryAI::DoAction(), instance_molten_core::instance_molten_core_InstanceMapScript::DoAction(), instance_obsidian_sanctum::instance_obsidian_sanctum_InstanceMapScript::DoAction(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::DoAction(), boss_black_knight::boss_black_knightAI::DoAction(), boss_tyrannus::boss_tyrannusAI::DoAction(), DoCastSpellOnPlayer(), DoCastSpellOnPlayers(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::DoCheckDedicatedInsanity(), npc_rocknot::npc_rocknotAI::DoGo(), instance_violet_hold::instance_violet_hold_InstanceMapScript::DoNeedCleanup(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::DoNeedCleanup(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::DoNeedCleanup(), DoRemoveAurasDueToSpellOnPlayers(), DoRespawnCreature(), DoRespawnGameObject(), DoSendNotifyToInstance(), DoStartTimedAchievement(), DoStopTimedAchievement(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::DoSummonGrandChampion(), DoUpdateAchievementCriteria(), DoUpdateWorldState(), DoUseDoorOrButton(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::DoWipe1(), instance_blackrock_spire::instance_blackrock_spireMapScript::Dragonspireroomcheck(), instance_blackrock_spire::instance_blackrock_spireMapScript::Dragonspireroomstore(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::EnsureGridLoaded(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::EnsureGridLoaded(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::FillInitialWorldStates(), instance_stratholme::instance_stratholme_InstanceMapScript::gate_critter_delay(), boss_erekem::boss_erekemAI::GetChainHealTargetGUID(), GetCreature(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::GetCreatureEntry(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::GetCreatureEntry(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::GetData(), GetGameObject(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::GetGameObjectEntry(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::HandleDropAttempt(), HandleGameObject(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::HandleOutro(), boss_urok_doomhowl::boss_urok_doomhowlAI::InitializeAI(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::InstanceCleanup(), instance_violet_hold::instance_violet_hold_InstanceMapScript::InstanceCleanup(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::InstanceCleanup(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::IsEncounterInProgress(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::IsEncounterInProgress(), instance_ulduar::instance_ulduar_InstanceMapScript::IsEncounterInProgress(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::IsWaveAllDead(), boss_shade_of_aran::JustDied(), boss_rajaxx::JustDied(), boss_jormungarAI::JustDied(), npc_gunship::npc_gunshipAI::JustDied(), boss_varos::boss_varosAI::JustDied(), npc_ulduar_hodir_priest::npc_ulduar_hodir_priestAI::JustDied(), npc_ulduar_hodir_druid::npc_ulduar_hodir_druidAI::JustDied(), npc_ulduar_hodir_shaman::npc_ulduar_hodir_shamanAI::JustDied(), npc_ulduar_hodir_mage::npc_ulduar_hodir_mageAI::JustDied(), boss_kologarn::boss_kologarnAI::JustDied(), boss_skarvald_the_constructor::JustDied(), boss_dalronn_the_controller::JustDied(), npc_ichor_globule::npc_ichor_globuleAI::JustDied(), npc_vh_void_sentry::npc_vh_void_sentryAI::JustDied(), boss_shade_of_aran::JustEngagedWith(), boss_anubarak_trial::boss_anubarak_trialAI::JustEngagedWith(), npc_pos_deathwhisper_necrolyte::npc_pos_deathwhisper_necrolyteAI::JustEngagedWith(), boss_kologarn::boss_kologarnAI::JustEngagedWith(), boss_prince_keleseth_icc::boss_prince_kelesethAI::JustEngagedWith(), boss_prince_taldaram_icc::boss_prince_taldaramAI::JustEngagedWith(), boss_prince_valanar_icc::boss_prince_valanarAI::JustEngagedWith(), boss_skarvald_the_constructor::JustEngagedWith(), boss_dalronn_the_controller::JustEngagedWith(), boss_erekem::boss_erekemAI::JustEngagedWith(), npc_erekem_guard::npc_erekem_guardAI::JustEngagedWith(), LoadInstanceSavedGameobjectStateData(), boss_professor_putricide::boss_professor_putricideAI::MovementInform(), npc_gunship_boarding_addAI::MovementInform(), npc_hor_lich_king::npc_hor_lich_kingAI::MovementInform(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::MoveNPCIfAlive(), npc_frost_tomb::npc_frost_tomb(), npc_pos_leader_second::npc_pos_leader_secondAI::npc_pos_leader_secondAI(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::npc_pos_martin_or_gorkun_secondAI(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::OnCreatureCreate(), instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript::OnCreatureCreate(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnCreatureCreate(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::OnCreatureCreate(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::OnCreatureCreate(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::OnCreatureCreate(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::OnCreatureCreate(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::OnCreatureCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnCreatureCreate(), instance_nexus::instance_nexus_InstanceMapScript::OnCreatureCreate(), instance_ulduar::instance_ulduar_InstanceMapScript::OnCreatureCreate(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::OnCreatureCreate(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::OnGameObjectCreate(), instance_ulduar::instance_ulduar_InstanceMapScript::OnGameObjectCreate(), OnGameObjectCreate(), instance_molten_core::instance_molten_core_InstanceMapScript::OnGameObjectCreate(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnGameObjectCreate(), instance_naxxramas::instance_naxxramas_InstanceMapScript::OnGameObjectRemove(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::OnPlayerEnter(), instance_forge_of_souls::instance_forge_of_souls_InstanceScript::OnPlayerEnter(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::OnPlayerEnter(), instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript::OnPlayerEnter(), instance_stratholme::instance_stratholme_InstanceMapScript::OnPlayerEnter(), instance_sunwell_plateau::instance_sunwell_plateau_InstanceMapScript::OnPlayerEnter(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::OnPlayerEnter(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::OnPlayerEnter(), instance_ruins_of_ahnqiraj::instance_ruins_of_ahnqiraj_InstanceMapScript::OnPlayerEnter(), instance_ulduar::instance_ulduar_InstanceMapScript::OnPlayerEnter(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::OnPlayerEnter(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::OnPlayerEnter(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::OnPlayerEnter(), at_tyrannus_event_starter::OnTrigger(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::OnUnitDeath(), instance_karazhan::instance_karazhan_InstanceMapScript::OnUnitDeath(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::OnUnitDeath(), instance_temple_of_ahnqiraj::instance_temple_of_ahnqiraj_InstanceMapScript::OnUnitDeath(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::OnUnitDeath(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::OnUnitDeath(), instance_blackrock_spire::instance_blackrock_spireMapScript::ProcessEvent(), instance_magisters_terrace::instance_magisters_terrace_InstanceMapScript::ProcessEvent(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::ProcessEvent(), instance_sethekk_halls::instance_sethekk_halls_InstanceMapScript::ProcessEvent(), instance_stratholme::instance_stratholme_InstanceMapScript::ProcessSlaughterEvent(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::RandomizeCompositionsAndShow(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::ReadSaveDataMore(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::ReadSaveDataMore(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::RemoveBackPack(), instance_zulgurub::instance_zulgurub_InstanceMapScript::RemoveHakkarPowerStack(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::ReplaceMoiraIfSaved(), boss_shade_of_aran::Reset(), boss_tyrannus::boss_tyrannusAI::Reset(), boss_kologarn::boss_kologarnAI::Reset(), boss_palehoof::boss_palehoofAI::Reset(), instance_zulaman::instance_zulaman_InstanceMapScript::ResetAkilzonGauntlet(), instance_blood_furnace::instance_blood_furnace_InstanceMapScript::ResetPrisoners(), SaveToDB(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::ScheduleNextPortal(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SendAddsUpStairs(), SendEncounterUnit(), instance_molten_core::instance_molten_core_InstanceMapScript::SetBossState(), instance_naxxramas::instance_naxxramas_InstanceMapScript::SetBossState(), SetBossState(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::SetBossState(), instance_blackrock_spire::instance_blackrock_spireMapScript::SetBossState(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::SetBossState(), instance_karazhan::instance_karazhan_InstanceMapScript::SetBossState(), instance_the_black_morass::instance_the_black_morass_InstanceMapScript::SetBossState(), instance_ruby_sanctum::instance_ruby_sanctum_InstanceMapScript::SetBossState(), instance_gundrak::instance_gundrak_InstanceMapScript::SetBossState(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetBossState(), instance_black_temple::instance_black_temple_InstanceMapScript::SetBossState(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::SetBossState(), instance_hellfire_ramparts::instance_hellfire_ramparts_InstanceMapScript::SetBossState(), instance_ulduar::instance_ulduar_InstanceMapScript::setChestsLootable(), SetCompletedEncountersMask(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::SetData(), instance_blackrock_spire::instance_blackrock_spireMapScript::SetData(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::SetData(), instance_karazhan::instance_karazhan_InstanceMapScript::SetData(), instance_scholomance::instance_scholomance_InstanceMapScript::SetData(), instance_shadowfang_keep::instance_shadowfang_keep_InstanceMapScript::SetData(), instance_stratholme::instance_stratholme_InstanceMapScript::SetData(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::SetData(), instance_hyjal::instance_mount_hyjal_InstanceMapScript::SetData(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::SetData(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::SetData(), instance_dire_maul::instance_dire_maul_InstanceMapScript::SetData(), instance_wailing_caverns::instance_wailing_caverns_InstanceMapScript::SetData(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::SetData(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::SetData(), instance_pit_of_saron::instance_pit_of_saron_InstanceScript::SetData(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SetData(), instance_eye_of_eternity::instance_eye_of_eternity_InstanceMapScript::SetData(), instance_oculus::instance_oculus_InstanceMapScript::SetData(), instance_halls_of_stone::instance_halls_of_stone_InstanceMapScript::SetData(), instance_ulduar::instance_ulduar_InstanceMapScript::SetData(), instance_utgarde_keep::instance_utgarde_keep_InstanceMapScript::SetData(), instance_utgarde_pinnacle::instance_utgarde_pinnacle_InstanceMapScript::SetData(), instance_violet_hold::instance_violet_hold_InstanceMapScript::SetData(), instance_magtheridons_lair::instance_magtheridons_lair_InstanceMapScript::SetData(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::SetData(), instance_gundrak::instance_gundrak_InstanceMapScript::SetData(), instance_serpent_shrine::instance_serpentshrine_cavern_InstanceMapScript::SetData(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::SetData(), instance_halls_of_lightning::instance_halls_of_lightning_InstanceMapScript::SetData(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::SpawnAnubArak(), instance_icecrown_citadel::instance_icecrown_citadel_InstanceMapScript::SpawnGunship(), instance_ulduar::instance_ulduar_InstanceMapScript::SpawnLeviathanEncounterVehicles(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SpawnPyramidWave(), instance_zulaman::instance_zulaman_InstanceMapScript::StartAkilzonGauntlet(), instance_violet_hold::instance_violet_hold_InstanceMapScript::StartBossEncounter(), instance_zulaman::instance_zulaman_InstanceMapScript::SummonHostage(), instance_molten_core::instance_molten_core_InstanceMapScript::SummonMajordomoExecutus(), instance_blackrock_spire::instance_blackrock_spireMapScript::SummonSolakarWave(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::TombOfSevenEvent(), instance_blackrock_depths::instance_blackrock_depths_InstanceMapScript::TombOfSevenReset(), instance_blackwing_lair::instance_blackwing_lair_InstanceMapScript::Update(), instance_stratholme::instance_stratholme_InstanceMapScript::Update(), instance_sunken_temple::instance_sunken_temple_InstanceMapScript::Update(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::Update(), instance_old_hillsbrad::instance_old_hillsbrad_InstanceMapScript::Update(), instance_zulfarrak::instance_zulfarrak_InstanceMapScript::Update(), instance_trial_of_the_champion::instance_trial_of_the_champion_InstanceMapScript::Update(), instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::Update(), instance_halls_of_reflection::instance_halls_of_reflection_InstanceMapScript::Update(), instance_gundrak::instance_gundrak_InstanceMapScript::Update(), instance_naxxramas::instance_naxxramas_InstanceMapScript::Update(), instance_vault_of_archavon::instance_vault_of_archavon_InstanceMapScript::Update(), instance_violet_hold::instance_violet_hold_InstanceMapScript::Update(), instance_shattered_halls::instance_shattered_halls_InstanceMapScript::Update(), npc_arthas::npc_arthasAI::UpdateAI(), boss_black_knight::boss_black_knightAI::UpdateAI(), npc_fos_corrupted_soul_fragment::npc_fos_corrupted_soul_fragmentAI::UpdateAI(), npc_hor_leader::npc_hor_leaderAI::UpdateAI(), npc_hor_lich_king::npc_hor_lich_kingAI::UpdateAI(), npc_hor_leader_second::npc_hor_leader_secondAI::UpdateAI(), boss_krick::boss_krickAI::UpdateAI(), boss_tyrannus::boss_tyrannusAI::UpdateAI(), npc_pos_leader::npc_pos_leaderAI::UpdateAI(), npc_pos_after_first_boss::npc_pos_after_first_bossAI::UpdateAI(), npc_pos_tyrannus_events::npc_pos_tyrannus_eventsAI::UpdateAI(), npc_pos_martin_or_gorkun_second::npc_pos_martin_or_gorkun_secondAI::UpdateAI(), npc_pos_leader_second::npc_pos_leader_secondAI::UpdateAI(), boss_prince_valanar_icc::boss_prince_valanarAI::UpdateAI(), npc_high_overlord_saurfang_igb::npc_high_overlord_saurfang_igbAI::UpdateAI(), npc_muradin_bronzebeard_igb::npc_muradin_bronzebeard_igbAI::UpdateAI(), boss_faerlina::boss_faerlinaAI::UpdateAI(), npc_power_spark::npc_power_sparkAI::UpdateAI(), boss_hodir::boss_hodirAI::UpdateAI(), boss_erekem::boss_erekemAI::UpdateAI(), boss_xevozz::boss_xevozzAI::UpdateAI(), npc_vh_teleportation_portal::npc_vh_teleportation_portalAI::UpdateAI(), npc_ichor_globule::npc_ichor_globuleAI::UpdateAI(), instance_culling_of_stratholme::instance_culling_of_stratholme_InstanceMapScript::UpdateEventState(), npc_arthas::npc_arthasAI::WaypointReached(), and instance_trial_of_the_crusader::instance_trial_of_the_crusader_InstanceMapScript::WriteSaveDataMore().

◆ minions

MinionInfoMap InstanceScript::minions
private

Referenced by AddMinion(), and LoadMinionData().

◆ persistentData

std::vector<uint32> InstanceScript::persistentData
private

◆ scheduler