AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript Struct Reference
Inheritance diagram for instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript:
InstanceScript ZoneScript

Public Member Functions

 instance_the_slave_pens_InstanceMapScript (Map *map)
 
void OnCreatureCreate (Creature *creature) override
 
void SetGuidData (uint32 data, ObjectGuid guid) override
 
ObjectGuid GetGuidData (uint32 type) const override
 
- Public Member Functions inherited from InstanceScript
 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)
 

Protected Attributes

ObjectGuid AhuneGUID
 
ObjectGuid AhuneBunnyGUID
 
ObjectGuid FrozenCoreGUID
 
ObjectGuid LumaGUID
 
ObjectGuid FlameCallerGUIDs [3]
 
ObjectGuid BonfireBunnyGUIDs [3]
 
ObjectGuid BeamBunnyGUIDs [3]
 
uint8 counter
 

Additional Inherited Members

- Static Public Member Functions inherited from InstanceScript
static std::string GetBossStateName (uint8 state)
 
- Public Attributes inherited from InstanceScript
Mapinstance
 
TaskScheduler scheduler
 
- Protected Member Functions inherited from InstanceScript
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 &)
 

Detailed Description

Constructor & Destructor Documentation

◆ instance_the_slave_pens_InstanceMapScript()

instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::instance_the_slave_pens_InstanceMapScript ( Map map)
inline
54 : InstanceScript(map)
55 {
59 }
ObjectData const creatureData[]
Definition: instance_the_slave_pens.cpp:31
@ DATA_FLAMECALLER_000
Definition: the_slave_pens.h:37
#define DataHeader
Definition: blackrock_depths.h:23
Definition: InstanceScript.h:142
void SetHeaders(std::string const &dataHeaders)
Definition: InstanceScript.cpp:141
void LoadObjectData(ObjectData const *creatureData, ObjectData const *gameObjectData)
Definition: InstanceScript.cpp:176
uint8 counter
Definition: instance_the_slave_pens.cpp:169

References counter, creatureData, DATA_FLAMECALLER_000, DataHeader, InstanceScript::LoadObjectData(), and InstanceScript::SetHeaders().

Member Function Documentation

◆ GetGuidData()

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::GetGuidData ( uint32  type) const
inlineoverridevirtual

Reimplemented from InstanceScript.

125 {
126 switch (type)
127 {
128 case DATA_AHUNE:
129 return AhuneGUID;
130 case DATA_AHUNE_BUNNY:
131 return AhuneBunnyGUID;
132 case DATA_FROZEN_CORE:
133 return FrozenCoreGUID;
135 return FlameCallerGUIDs[0];
137 return FlameCallerGUIDs[1];
139 return FlameCallerGUIDs[2];
141 return BonfireBunnyGUIDs[0];
143 return BonfireBunnyGUIDs[1];
145 return BonfireBunnyGUIDs[2];
147 return BeamBunnyGUIDs[0];
149 return BeamBunnyGUIDs[1];
151 return BeamBunnyGUIDs[2];
153 return LumaGUID;
154 default:
155 break;
156 }
157
158 return ObjectGuid::Empty;
159 }
@ DATA_BONFIRE_BUNNY_000
Definition: the_slave_pens.h:40
@ DATA_BEAM_BUNNY_002
Definition: the_slave_pens.h:45
@ DATA_AHUNE_BUNNY
Definition: the_slave_pens.h:35
@ DATA_FROZEN_CORE
Definition: the_slave_pens.h:36
@ DATA_AHUNE
Definition: the_slave_pens.h:33
@ DATA_BEAM_BUNNY_001
Definition: the_slave_pens.h:44
@ DATA_FLAMECALLER_001
Definition: the_slave_pens.h:38
@ DATA_BONFIRE_BUNNY_001
Definition: the_slave_pens.h:41
@ DATA_LUMA_SKYMOTHER
Definition: the_slave_pens.h:46
@ DATA_BEAM_BUNNY_000
Definition: the_slave_pens.h:43
@ DATA_BONFIRE_BUNNY_002
Definition: the_slave_pens.h:42
@ DATA_FLAMECALLER_002
Definition: the_slave_pens.h:39
static ObjectGuid const Empty
Definition: ObjectGuid.h:120
ObjectGuid BeamBunnyGUIDs[3]
Definition: instance_the_slave_pens.cpp:168
ObjectGuid LumaGUID
Definition: instance_the_slave_pens.cpp:165
ObjectGuid FlameCallerGUIDs[3]
Definition: instance_the_slave_pens.cpp:166
ObjectGuid FrozenCoreGUID
Definition: instance_the_slave_pens.cpp:164
ObjectGuid AhuneGUID
Definition: instance_the_slave_pens.cpp:162
ObjectGuid BonfireBunnyGUIDs[3]
Definition: instance_the_slave_pens.cpp:167
ObjectGuid AhuneBunnyGUID
Definition: instance_the_slave_pens.cpp:163

References AhuneBunnyGUID, AhuneGUID, BeamBunnyGUIDs, BonfireBunnyGUIDs, DATA_AHUNE, DATA_AHUNE_BUNNY, DATA_BEAM_BUNNY_000, DATA_BEAM_BUNNY_001, DATA_BEAM_BUNNY_002, DATA_BONFIRE_BUNNY_000, DATA_BONFIRE_BUNNY_001, DATA_BONFIRE_BUNNY_002, DATA_FLAMECALLER_000, DATA_FLAMECALLER_001, DATA_FLAMECALLER_002, DATA_FROZEN_CORE, DATA_LUMA_SKYMOTHER, ObjectGuid::Empty, FlameCallerGUIDs, FrozenCoreGUID, and LumaGUID.

◆ OnCreatureCreate()

void instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::OnCreatureCreate ( Creature creature)
inlineoverridevirtual

Reimplemented from InstanceScript.

62 {
63 switch (creature->GetEntry())
64 {
65 case NPC_AHUNE:
66 AhuneGUID = creature->GetGUID();
67 break;
68 case NPC_FROZEN_CORE:
69 FrozenCoreGUID = creature->GetGUID();
70 break;
72 AhuneBunnyGUID = creature->GetGUID();
73 break;
75 BonfireBunnyGUIDs[0] = creature->GetGUID();
76 break;
78 BonfireBunnyGUIDs[1] = creature->GetGUID();
79 break;
81 BonfireBunnyGUIDs[2] = creature->GetGUID();
82 break;
84 BeamBunnyGUIDs[0] = creature->GetGUID();
85 break;
87 BeamBunnyGUIDs[1] = creature->GetGUID();
88 break;
90 BeamBunnyGUIDs[2] = creature->GetGUID();
91 break;
93 LumaGUID = creature->GetGUID();
94 break;
96 SetGuidData(counter, creature->GetGUID());
97 ++counter;
98 break;
99 default:
100 break;
101 }
102
104 }
@ NPC_SHAMAN_BONFIRE_BUNNY_001
Definition: the_slave_pens.h:62
@ NPC_SHAMAN_BEAM_BUNNY_001
Definition: the_slave_pens.h:65
@ NPC_SHAMAN_BEAM_BUNNY_000
Definition: the_slave_pens.h:64
@ NPC_FROZEN_CORE
Definition: the_slave_pens.h:52
@ NPC_AHUNE
Definition: the_slave_pens.h:51
@ NPC_EARTHEN_RING_FLAMECALLER
Definition: the_slave_pens.h:60
@ NPC_SHAMAN_BONFIRE_BUNNY_002
Definition: the_slave_pens.h:63
@ NPC_AHUNE_LOC_BUNNY
Definition: the_slave_pens.h:59
@ NPC_SHAMAN_BONFIRE_BUNNY_000
Definition: the_slave_pens.h:61
@ NPC_LUMA_SKYMOTHER
Definition: the_slave_pens.h:58
@ NPC_SHAMAN_BEAM_BUNNY_002
Definition: the_slave_pens.h:66
uint32 GetEntry() const
Definition: Object.h:115
static ObjectGuid GetGUID(Object const *o)
Definition: Object.h:112
void OnCreatureCreate(Creature *creature) override
Definition: InstanceScript.cpp:58
void SetGuidData(uint32 data, ObjectGuid guid) override
Definition: instance_the_slave_pens.cpp:106

References AhuneBunnyGUID, AhuneGUID, BeamBunnyGUIDs, BonfireBunnyGUIDs, counter, FrozenCoreGUID, Object::GetEntry(), Object::GetGUID(), LumaGUID, NPC_AHUNE, NPC_AHUNE_LOC_BUNNY, NPC_EARTHEN_RING_FLAMECALLER, NPC_FROZEN_CORE, NPC_LUMA_SKYMOTHER, NPC_SHAMAN_BEAM_BUNNY_000, NPC_SHAMAN_BEAM_BUNNY_001, NPC_SHAMAN_BEAM_BUNNY_002, NPC_SHAMAN_BONFIRE_BUNNY_000, NPC_SHAMAN_BONFIRE_BUNNY_001, NPC_SHAMAN_BONFIRE_BUNNY_002, InstanceScript::OnCreatureCreate(), and SetGuidData().

◆ SetGuidData()

void instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::SetGuidData ( uint32  data,
ObjectGuid  guid 
)
inlineoverridevirtual

Reimplemented from ZoneScript.

107 {
108 switch (data)
109 {
111 FlameCallerGUIDs[0] = guid;
112 break;
114 FlameCallerGUIDs[1] = guid;
115 break;
117 FlameCallerGUIDs[2] = guid;
118 break;
119 default:
120 break;
121 }
122 }

References DATA_FLAMECALLER_000, DATA_FLAMECALLER_001, DATA_FLAMECALLER_002, and FlameCallerGUIDs.

Referenced by OnCreatureCreate().

Member Data Documentation

◆ AhuneBunnyGUID

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::AhuneBunnyGUID
protected

Referenced by GetGuidData(), and OnCreatureCreate().

◆ AhuneGUID

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::AhuneGUID
protected

Referenced by GetGuidData(), and OnCreatureCreate().

◆ BeamBunnyGUIDs

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::BeamBunnyGUIDs[3]
protected

Referenced by GetGuidData(), and OnCreatureCreate().

◆ BonfireBunnyGUIDs

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::BonfireBunnyGUIDs[3]
protected

Referenced by GetGuidData(), and OnCreatureCreate().

◆ counter

uint8 instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::counter
protected

◆ FlameCallerGUIDs

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::FlameCallerGUIDs[3]
protected

Referenced by GetGuidData(), and SetGuidData().

◆ FrozenCoreGUID

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::FrozenCoreGUID
protected

Referenced by GetGuidData(), and OnCreatureCreate().

◆ LumaGUID

ObjectGuid instance_the_slave_pens::instance_the_slave_pens_InstanceMapScript::LumaGUID
protected

Referenced by GetGuidData(), and OnCreatureCreate().