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

Public Member Functions

 instance_zulfarrak_InstanceMapScript (Map *map)
 
void Initialize () override
 
void OnCreatureCreate (Creature *creature) override
 
void OnGameObjectCreate (GameObject *gameobject) override
 
void OnUnitDeath (Unit *unit) override
 
void SetData (uint32 type, uint32 data) override
 
uint32 GetData (uint32 type) const override
 
ObjectGuid GetGuidData (uint32 data) const override
 
void Update (uint32 diff) override
 
void MoveNPCIfAlive (uint32 entry, float x, float y, float z, float o)
 
void SpawnPyramidWave (uint32 wave)
 
bool IsWaveAllDead ()
 
void SendAddsUpStairs (uint32 count)
 
void ReadSaveDataMore (std::istringstream &data) override
 
void WriteSaveDataMore (std::ostringstream &data) 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)
 

Public Attributes

ObjectGuid EndDoorGUID
 
ObjectGuid BlyGUID
 
ObjectGuid WeegliGUID
 
ObjectGuid OroGUID
 
ObjectGuid RavenGUID
 
ObjectGuid MurtaGUID
 
ObjectGuid ShadowpriestGUID
 
GuidList addsAtBase
 
GuidList movedadds
 
uint32 GahzrillaSummoned
 
uint32 PyramidPhase
 
uint32 major_wave_Timer
 
uint32 minor_wave_Timer
 
uint32 addGroupSize
 
uint32 waypoint
 
- Public Attributes inherited from InstanceScript
Mapinstance
 
TaskScheduler scheduler
 

Additional Inherited Members

- Static Public Member Functions inherited from InstanceScript
static std::string GetBossStateName (uint8 state)
 
- 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_zulfarrak_InstanceMapScript()

instance_zulfarrak::instance_zulfarrak_InstanceMapScript::instance_zulfarrak_InstanceMapScript ( Map map)
inline
118: InstanceScript(map) { }
Definition: InstanceScript.h:142

Member Function Documentation

◆ GetData()

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::GetData ( uint32  type) const
inlineoverridevirtual

Reimplemented from ZoneScript.

225 {
226 switch (type)
227 {
228 case DATA_PYRAMID:
229 return PyramidPhase;
230 case DATA_GAHZRILLA:
231 return GahzrillaSummoned;
232 }
233
234 return 0;
235 }
@ DATA_GAHZRILLA
Definition: zulfarrak.h:52
@ DATA_PYRAMID
Definition: zulfarrak.h:51
uint32 PyramidPhase
Definition: instance_zulfarrak.cpp:132
uint32 GahzrillaSummoned
Definition: instance_zulfarrak.cpp:131

References DATA_GAHZRILLA, DATA_PYRAMID, GahzrillaSummoned, and PyramidPhase.

◆ GetGuidData()

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::GetGuidData ( uint32  data) const
inlineoverridevirtual

Reimplemented from InstanceScript.

238 {
239 switch (data)
240 {
241 case NPC_BLY:
242 return BlyGUID;
243 case NPC_RAVEN:
244 return RavenGUID;
245 case NPC_ORO:
246 return OroGUID;
247 case NPC_WEEGLI:
248 return WeegliGUID;
249 case NPC_MURTA:
250 return MurtaGUID;
252 return ShadowpriestGUID;
253 case GO_END_DOOR:
254 return EndDoorGUID;
255 }
256
257 return ObjectGuid::Empty;
258 }
@ GO_END_DOOR
Definition: zulfarrak.h:46
@ NPC_WEEGLI
Definition: zulfarrak.h:40
@ NPC_SHADOWPRIEST_SEZZZIZ
Definition: zulfarrak.h:34
@ NPC_ORO
Definition: zulfarrak.h:39
@ NPC_MURTA
Definition: zulfarrak.h:41
@ NPC_BLY
Definition: zulfarrak.h:37
@ NPC_RAVEN
Definition: zulfarrak.h:38
static ObjectGuid const Empty
Definition: ObjectGuid.h:120
ObjectGuid OroGUID
Definition: instance_zulfarrak.cpp:123
ObjectGuid ShadowpriestGUID
Definition: instance_zulfarrak.cpp:126
ObjectGuid MurtaGUID
Definition: instance_zulfarrak.cpp:125
ObjectGuid EndDoorGUID
Definition: instance_zulfarrak.cpp:120
ObjectGuid RavenGUID
Definition: instance_zulfarrak.cpp:124
ObjectGuid BlyGUID
Definition: instance_zulfarrak.cpp:121
ObjectGuid WeegliGUID
Definition: instance_zulfarrak.cpp:122

References BlyGUID, ObjectGuid::Empty, EndDoorGUID, GO_END_DOOR, MurtaGUID, NPC_BLY, NPC_MURTA, NPC_ORO, NPC_RAVEN, NPC_SHADOWPRIEST_SEZZZIZ, NPC_WEEGLI, OroGUID, RavenGUID, ShadowpriestGUID, and WeegliGUID.

Referenced by MoveNPCIfAlive().

◆ Initialize()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::Initialize ( )
inlineoverridevirtual

Reimplemented from InstanceScript.

139 {
142
143 PyramidPhase = 0;
146 addGroupSize = 0;
147 waypoint = 0;
148 }
#define DataHeader
Definition: blackrock_depths.h:23
@ NOT_STARTED
Definition: InstanceScript.h:57
void SetHeaders(std::string const &dataHeaders)
Definition: InstanceScript.cpp:141
uint32 major_wave_Timer
Definition: instance_zulfarrak.cpp:133
uint32 addGroupSize
Definition: instance_zulfarrak.cpp:135
uint32 waypoint
Definition: instance_zulfarrak.cpp:136
uint32 minor_wave_Timer
Definition: instance_zulfarrak.cpp:134

References addGroupSize, DataHeader, GahzrillaSummoned, major_wave_Timer, minor_wave_Timer, NOT_STARTED, PyramidPhase, InstanceScript::SetHeaders(), and waypoint.

◆ IsWaveAllDead()

bool instance_zulfarrak::instance_zulfarrak_InstanceMapScript::IsWaveAllDead ( )
inline
407 {
408 for (GuidList::iterator itr = addsAtBase.begin(); itr != addsAtBase.end(); ++itr)
409 {
410 if (Creature* add = instance->GetCreature((*itr)))
411 {
412 if (add->IsAlive())
413 {
414 return false;
415 }
416 }
417 }
418
419 for (GuidList::iterator itr = movedadds.begin(); itr != movedadds.end(); ++itr)
420 {
421 if (Creature* add = instance->GetCreature(((*itr))))
422 {
423 if (add->IsAlive())
424 {
425 return false;
426 }
427 }
428 }
429
430 return true;
431 }
Definition: Creature.h:43
Map * instance
Definition: InstanceScript.h:148
Creature * GetCreature(ObjectGuid const guid)
Definition: Map.cpp:3317
GuidList addsAtBase
Definition: instance_zulfarrak.cpp:128
GuidList movedadds
Definition: instance_zulfarrak.cpp:129

References addsAtBase, Map::GetCreature(), InstanceScript::instance, and movedadds.

Referenced by Update().

◆ MoveNPCIfAlive()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::MoveNPCIfAlive ( uint32  entry,
float  x,
float  y,
float  z,
float  o 
)
inline
368 {
370 {
371 if (npc->IsAlive())
372 {
373 npc->SetWalk(true);
374 npc->GetMotionMaster()->MovePoint(1, { x, y, z, o } );
375 npc->SetHomePosition(x, y, z, o);
376 }
377 }
378 }
npc
Definition: BattlegroundSA.h:75
ObjectGuid GetGuidData(uint32 data) const override
Definition: instance_zulfarrak.cpp:237

References Map::GetCreature(), GetGuidData(), and InstanceScript::instance.

Referenced by Update().

◆ OnCreatureCreate()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OnCreatureCreate ( Creature creature)
inlineoverridevirtual

Reimplemented from InstanceScript.

151 {
152 switch (creature->GetEntry())
153 {
154 case NPC_BLY:
155 BlyGUID = creature->GetGUID();
156 creature->SetReactState(REACT_PASSIVE); // starts out passive (in a cage)
157 break;
158 case NPC_RAVEN:
159 RavenGUID = creature->GetGUID();
160 creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
161 break;
162 case NPC_ORO:
163 OroGUID = creature->GetGUID();
164 creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
165 break;
166 case NPC_WEEGLI:
167 WeegliGUID = creature->GetGUID();
168 creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
169 break;
170 case NPC_MURTA:
171 MurtaGUID = creature->GetGUID();
172 creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
173 break;
175 ShadowpriestGUID = creature->GetGUID();
176 break;
177 default:
178 break;
179 }
180 }
@ REACT_PASSIVE
Definition: Unit.h:548
void SetReactState(ReactStates state)
A creature can have 3 ReactStates : Agressive, Passive, Neutral.
Definition: Creature.h:94
uint32 GetEntry() const
Definition: Object.h:115
static ObjectGuid GetGUID(Object const *o)
Definition: Object.h:112

References BlyGUID, Object::GetEntry(), Object::GetGUID(), MurtaGUID, NPC_BLY, NPC_MURTA, NPC_ORO, NPC_RAVEN, NPC_SHADOWPRIEST_SEZZZIZ, NPC_WEEGLI, OroGUID, RavenGUID, REACT_PASSIVE, Creature::SetReactState(), ShadowpriestGUID, and WeegliGUID.

◆ OnGameObjectCreate()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OnGameObjectCreate ( GameObject gameobject)
inlineoverridevirtual

Reimplemented from InstanceScript.

183 {
184 switch (gameobject->GetEntry())
185 {
186 case GO_END_DOOR:
187 EndDoorGUID = gameobject->GetGUID();
189 {
190 HandleGameObject(gameobject->GetGUID(), true, gameobject);
191 }
192 break;
193 default:
194 break;
195 }
196 }
@ PYRAMID_DONE
Definition: zulfarrak.h:69
void HandleGameObject(ObjectGuid guid, bool open, GameObject *go=nullptr)
Definition: InstanceScript.cpp:113

References EndDoorGUID, Object::GetEntry(), Object::GetGUID(), GO_END_DOOR, InstanceScript::HandleGameObject(), PYRAMID_DONE, and PyramidPhase.

◆ OnUnitDeath()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OnUnitDeath ( Unit unit)
inlineoverridevirtual

Reimplemented from ZoneScript.

199 {
200 if (unit->GetEntry() == NPC_BLY)
201 {
203 SaveToDB();
204 }
205 }
void SaveToDB()
Definition: InstanceScript.cpp:41

References Object::GetEntry(), NPC_BLY, PYRAMID_DONE, PyramidPhase, and InstanceScript::SaveToDB().

◆ ReadSaveDataMore()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::ReadSaveDataMore ( std::istringstream &  data)
inlineoverridevirtual

Reimplemented from InstanceScript.

449 {
450 data >> PyramidPhase;
451 data >> GahzrillaSummoned;
452 }

References GahzrillaSummoned, and PyramidPhase.

◆ SendAddsUpStairs()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SendAddsUpStairs ( uint32  count)
inline
434 {
435 //pop a add from list, send him up the stairs...
436 for (uint32 addCount = 0; addCount < count && !addsAtBase.empty(); addCount++)
437 {
438 if (Creature* add = instance->GetCreature(*addsAtBase.begin()))
439 {
440 add->GetMotionMaster()->MovePath(PATH_ADDS, false);
441 movedadds.push_back(add->GetGUID());
442 }
443
444 addsAtBase.erase(addsAtBase.begin());
445 }
446 }
std::uint32_t uint32
Definition: Define.h:107
@ PATH_ADDS
Definition: instance_zulfarrak.cpp:32

References addsAtBase, Map::GetCreature(), InstanceScript::instance, movedadds, and PATH_ADDS.

Referenced by Update().

◆ SetData()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SetData ( uint32  type,
uint32  data 
)
inlineoverridevirtual

Reimplemented from ZoneScript.

208 {
209 switch (type)
210 {
211 case DATA_PYRAMID:
212 PyramidPhase = data;
213 break;
214 case DATA_GAHZRILLA:
215 GahzrillaSummoned = data;
216 break;
217 default:
218 break;
219 }
220
221 SaveToDB();
222 }

References DATA_GAHZRILLA, DATA_PYRAMID, GahzrillaSummoned, PyramidPhase, and InstanceScript::SaveToDB().

Referenced by Update().

◆ SpawnPyramidWave()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::SpawnPyramidWave ( uint32  wave)
inline
381 {
382 for (uint32 i = 0; i < pyramidSpawnTotal; i++)
383 {
384 if (pyramidSpawns[i].waveID == wave)
385 {
386 float orientation = 4.78f;
387 if (pyramidSpawns[i].creatureID == NPC_SHADOWPRIEST_SEZZZIZ || pyramidSpawns[i].creatureID == NPC_NEKRUM_GUTCHEWER)
388 {
389 orientation = 1.32f;
390 }
391
392 Position pos = { pyramidSpawns[i].pos.GetPositionX(), pyramidSpawns[i].pos.GetPositionY(), 8.87f, orientation };
394 {
395 addsAtBase.push_back(ts->GetGUID());
396
397 if (pyramidSpawns[i].creatureID != NPC_SHADOWPRIEST_SEZZZIZ && pyramidSpawns[i].creatureID != NPC_NEKRUM_GUTCHEWER)
398 {
399 ts->GetMotionMaster()->MoveRandom(10);
400 }
401 }
402 }
403 }
404 }
@ NPC_NEKRUM_GUTCHEWER
Definition: zulfarrak.h:35
static PyramidEventData pyramidSpawns[pyramidSpawnTotal]
Definition: instance_zulfarrak.cpp:48
uint32 const pyramidSpawnTotal
Definition: instance_zulfarrak.cpp:44
Definition: TemporarySummon.h:40
Definition: Position.h:27
float GetPositionX() const
Definition: Position.h:116
float GetPositionY() const
Definition: Position.h:117
TempSummon * SummonCreature(uint32 entry, Position const &pos, SummonPropertiesEntry const *properties=nullptr, uint32 duration=0, WorldObject *summoner=nullptr, uint32 spellId=0, uint32 vehId=0, bool visibleBySummonerOnly=false)
Definition: Object.cpp:2174
uint32 creatureID
Definition: instance_zulfarrak.cpp:40
Position pos
Definition: instance_zulfarrak.cpp:41

References addsAtBase, PyramidEventData::creatureID, Position::GetPositionX(), Position::GetPositionY(), InstanceScript::instance, NPC_NEKRUM_GUTCHEWER, NPC_SHADOWPRIEST_SEZZZIZ, PyramidEventData::pos, pyramidSpawns, pyramidSpawnTotal, and Map::SummonCreature().

Referenced by Update().

◆ Update()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::Update ( uint32  diff)
inlineoverridevirtual

Reimplemented from InstanceScript.

261 {
262 switch (PyramidPhase)
263 {
269 case PYRAMID_DONE:
270 break;
276 addGroupSize = 2;
277 break;
278 case PYRAMID_WAVE_1:
279 if (IsWaveAllDead())
280 {
282 major_wave_Timer = 10 * IN_MILLISECONDS; //give players a few seconds before wave 2 starts to rebuff
283 }
284 else
285 {
286 if (minor_wave_Timer <= diff)
287 {
290 }
291 else
292 {
293 minor_wave_Timer -= diff;
294 }
295 }
296 break;
298 if (major_wave_Timer <= diff)
299 {
300 // beginning 2nd wave!
304 addGroupSize = 2;
305 }
306 else
307 {
308 major_wave_Timer -= diff;
309 }
310 break;
311 case PYRAMID_WAVE_2:
312 if (IsWaveAllDead())
313 {
316 major_wave_Timer = 5 * IN_MILLISECONDS; //give NPCs time to return to their home spots
317 }
318 else
319 {
320 if (minor_wave_Timer <= diff)
321 {
324 }
325 else
326 {
327 minor_wave_Timer -= diff;
328 }
329 }
330 break;
332 if (major_wave_Timer <= diff)
333 {
334 // move NPCs to bottom of stair
335 MoveNPCIfAlive(NPC_BLY, 1887.92f, 1228.179f, 9.98f, 4.78f);
336 MoveNPCIfAlive(NPC_MURTA, 1891.57f, 1228.68f, 9.69f, 4.78f);
337 MoveNPCIfAlive(NPC_ORO, 1897.23f, 1228.34f, 9.43f, 4.78f);
338 MoveNPCIfAlive(NPC_RAVEN, 1883.68f, 1227.95f, 9.543f, 4.78f);
339 MoveNPCIfAlive(NPC_WEEGLI, 1878.02f, 1227.65f, 9.485f, 4.78f);
341 if (Creature* sergeantBlye = instance->GetCreature(BlyGUID))
342 {
343 sergeantBlye->AI()->Talk(SAY_BLY_FORWARD);
344 }
345 }
346 else
347 {
348 major_wave_Timer -= diff;
349 }
350 break;
351 case PYRAMID_WAVE_3:
352 if (IsWaveAllDead()) // move NPCS to their final positions
353 {
355 MoveNPCIfAlive(NPC_BLY, 1883.82f, 1200.83f, 8.87f, 1.32f);
356 MoveNPCIfAlive(NPC_MURTA, 1891.83f, 1201.45f, 8.87f, 1.32f);
357 MoveNPCIfAlive(NPC_ORO, 1894.50f, 1204.40f, 8.87f, 1.32f);
358 MoveNPCIfAlive(NPC_RAVEN, 1874.11f, 1206.17f, 8.87f, 1.32f);
359 MoveNPCIfAlive(NPC_WEEGLI, 1877.52f, 1199.63f, 8.87f, 1.32f);
360 }
361 break;
362 default:
363 break;
364 };
365 }
constexpr auto IN_MILLISECONDS
Definition: Common.h:53
constexpr auto MINUTE
Definition: Common.h:47
@ PYRAMID_WAVE_2
Definition: zulfarrak.h:62
@ PYRAMID_DESTROY_GATES
Definition: zulfarrak.h:67
@ PYRAMID_NOT_STARTED
Definition: zulfarrak.h:57
@ PYRAMID_ARRIVED_AT_STAIR
Definition: zulfarrak.h:59
@ PYRAMID_PRE_WAVE_2
Definition: zulfarrak.h:61
@ PYRAMID_KILLED_ALL_TROLLS
Definition: zulfarrak.h:65
@ PYRAMID_WAVE_3
Definition: zulfarrak.h:64
@ PYRAMID_GATES_DESTROYED
Definition: zulfarrak.h:68
@ PYRAMID_WAVE_1
Definition: zulfarrak.h:60
@ PYRAMID_PRE_WAVE_3
Definition: zulfarrak.h:63
@ PYRAMID_MOVED_DOWNSTAIRS
Definition: zulfarrak.h:66
@ SAY_BLY_FORWARD
Definition: instance_zulfarrak.cpp:34
void SpawnPyramidWave(uint32 wave)
Definition: instance_zulfarrak.cpp:380
void MoveNPCIfAlive(uint32 entry, float x, float y, float z, float o)
Definition: instance_zulfarrak.cpp:367
void SetData(uint32 type, uint32 data) override
Definition: instance_zulfarrak.cpp:207
void SendAddsUpStairs(uint32 count)
Definition: instance_zulfarrak.cpp:433
bool IsWaveAllDead()
Definition: instance_zulfarrak.cpp:406

References addGroupSize, BlyGUID, DATA_PYRAMID, Map::GetCreature(), IN_MILLISECONDS, InstanceScript::instance, IsWaveAllDead(), major_wave_Timer, minor_wave_Timer, MINUTE, MoveNPCIfAlive(), NPC_BLY, NPC_MURTA, NPC_ORO, NPC_RAVEN, NPC_WEEGLI, PYRAMID_ARRIVED_AT_STAIR, PYRAMID_DESTROY_GATES, PYRAMID_DONE, PYRAMID_GATES_DESTROYED, PYRAMID_KILLED_ALL_TROLLS, PYRAMID_MOVED_DOWNSTAIRS, PYRAMID_NOT_STARTED, PYRAMID_PRE_WAVE_2, PYRAMID_PRE_WAVE_3, PYRAMID_WAVE_1, PYRAMID_WAVE_2, PYRAMID_WAVE_3, PyramidPhase, SAY_BLY_FORWARD, SendAddsUpStairs(), SetData(), and SpawnPyramidWave().

◆ WriteSaveDataMore()

void instance_zulfarrak::instance_zulfarrak_InstanceMapScript::WriteSaveDataMore ( std::ostringstream &  data)
inlineoverridevirtual

Reimplemented from InstanceScript.

455 {
456 data << PyramidPhase << ' ' << GahzrillaSummoned;
457 }

References GahzrillaSummoned, and PyramidPhase.

Member Data Documentation

◆ addGroupSize

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::addGroupSize

Referenced by Initialize(), and Update().

◆ addsAtBase

GuidList instance_zulfarrak::instance_zulfarrak_InstanceMapScript::addsAtBase

◆ BlyGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::BlyGUID

◆ EndDoorGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::EndDoorGUID

Referenced by GetGuidData(), and OnGameObjectCreate().

◆ GahzrillaSummoned

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::GahzrillaSummoned

◆ major_wave_Timer

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::major_wave_Timer

Referenced by Initialize(), and Update().

◆ minor_wave_Timer

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::minor_wave_Timer

Referenced by Initialize(), and Update().

◆ movedadds

GuidList instance_zulfarrak::instance_zulfarrak_InstanceMapScript::movedadds

Referenced by IsWaveAllDead(), and SendAddsUpStairs().

◆ MurtaGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::MurtaGUID

Referenced by GetGuidData(), and OnCreatureCreate().

◆ OroGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::OroGUID

Referenced by GetGuidData(), and OnCreatureCreate().

◆ PyramidPhase

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::PyramidPhase

◆ RavenGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::RavenGUID

Referenced by GetGuidData(), and OnCreatureCreate().

◆ ShadowpriestGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::ShadowpriestGUID

Referenced by GetGuidData(), and OnCreatureCreate().

◆ waypoint

uint32 instance_zulfarrak::instance_zulfarrak_InstanceMapScript::waypoint

Referenced by Initialize().

◆ WeegliGUID

ObjectGuid instance_zulfarrak::instance_zulfarrak_InstanceMapScript::WeegliGUID

Referenced by GetGuidData(), and OnCreatureCreate().