mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Core/Scripts: Split OnCreatureCreate() and OnGameObjectCreate() into two virtual functions each.
Note to scripters: be aware that you will need to hook into the Remove functions if you want to do stuff at GO/creature removal. Closes issue 5011. --HG-- branch : trunk
This commit is contained in:
@@ -182,7 +182,7 @@ void Creature::AddToWorld()
|
||||
if (!IsInWorld())
|
||||
{
|
||||
if (m_zoneScript)
|
||||
m_zoneScript->OnCreatureCreate(this, true);
|
||||
m_zoneScript->OnCreatureCreate(this);
|
||||
sObjectAccessor.AddObject(this);
|
||||
Unit::AddToWorld();
|
||||
SearchFormation();
|
||||
@@ -197,7 +197,7 @@ void Creature::RemoveFromWorld()
|
||||
if (IsInWorld())
|
||||
{
|
||||
if (m_zoneScript)
|
||||
m_zoneScript->OnCreatureCreate(this, false);
|
||||
m_zoneScript->OnCreatureRemove(this);
|
||||
if (m_formation)
|
||||
formation_mgr.RemoveCreatureFromGroup(m_formation, this);
|
||||
Unit::RemoveFromWorld();
|
||||
|
||||
@@ -125,7 +125,7 @@ void GameObject::AddToWorld()
|
||||
if (!IsInWorld())
|
||||
{
|
||||
if (m_zoneScript)
|
||||
m_zoneScript->OnGameObjectCreate(this, true);
|
||||
m_zoneScript->OnGameObjectCreate(this);
|
||||
|
||||
sObjectAccessor.AddObject(this);
|
||||
WorldObject::AddToWorld();
|
||||
@@ -138,7 +138,7 @@ void GameObject::RemoveFromWorld()
|
||||
if (IsInWorld())
|
||||
{
|
||||
if (m_zoneScript)
|
||||
m_zoneScript->OnGameObjectCreate(this, false);
|
||||
m_zoneScript->OnGameObjectRemove(this);
|
||||
|
||||
// Possible crash at access to deleted GO in Unit::m_gameobj
|
||||
if (uint64 owner_guid = GetOwnerGUID())
|
||||
|
||||
@@ -33,8 +33,10 @@ class ZoneScript
|
||||
virtual uint32 GetCreatureEntry(uint32 /*guidlow*/, const CreatureData *data) { return data->id; }
|
||||
virtual uint32 GetGameObjectEntry(uint32 /*guidlow*/, uint32 entry) { return entry; }
|
||||
|
||||
virtual void OnCreatureCreate(Creature *, bool /*add*/) {}
|
||||
virtual void OnGameObjectCreate(GameObject * /*go*/, bool /*add*/) {}
|
||||
virtual void OnCreatureCreate(Creature *) {}
|
||||
virtual void OnCreatureRemove(Creature *) {}
|
||||
virtual void OnGameObjectCreate(GameObject *) {}
|
||||
virtual void OnGameObjectRemove(GameObject *) {}
|
||||
|
||||
//All-purpose data storage 64 bit
|
||||
virtual uint64 GetData64(uint32 /*DataId*/) { return 0; }
|
||||
|
||||
@@ -590,11 +590,11 @@ void OutdoorPvP::TeamApplyBuff(TeamId team, uint32 spellId, uint32 spellId2)
|
||||
TeamCastSpell(OTHER_TEAM(team), spellId2 ? -(int32)spellId2 : -(int32)spellId);
|
||||
}
|
||||
|
||||
void OutdoorPvP::OnGameObjectCreate(GameObject *go, bool add)
|
||||
void OutdoorPvP::OnGameObjectCreate(GameObject *go)
|
||||
{
|
||||
if (go->GetGoType() != GAMEOBJECT_TYPE_CAPTURE_POINT)
|
||||
return;
|
||||
|
||||
if (OPvPCapturePoint *cp = GetCapturePoint(go->GetDBTableGUIDLow()))
|
||||
cp->m_capturePoint = add ? go : NULL;
|
||||
cp->m_capturePoint = go;
|
||||
}
|
||||
|
||||
@@ -219,8 +219,8 @@ class OutdoorPvP : public ZoneScript
|
||||
// setup stuff
|
||||
virtual bool SetupOutdoorPvP() {return true;}
|
||||
|
||||
void OnGameObjectCreate(GameObject *go, bool add);
|
||||
void OnCreatureCreate(Creature *, bool /*add*/) {}
|
||||
void OnGameObjectCreate(GameObject *go);
|
||||
void OnCreatureCreate(Creature *) {}
|
||||
|
||||
// send world state update to all players present
|
||||
void SendUpdateWorldState(uint32 field, uint32 value);
|
||||
|
||||
@@ -157,58 +157,58 @@ public:
|
||||
TombBossGUIDs[i] = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_EMPEROR: EmperorGUID = pCreature->GetGUID(); break;
|
||||
case NPC_PHALANX: PhalanxGUID = pCreature->GetGUID(); break;
|
||||
case NPC_DOOMREL: TombBossGUIDs[0] = pCreature->GetGUID(); break;
|
||||
case NPC_DOPEREL: TombBossGUIDs[1] = pCreature->GetGUID(); break;
|
||||
case NPC_HATEREL: TombBossGUIDs[2] = pCreature->GetGUID(); break;
|
||||
case NPC_VILEREL: TombBossGUIDs[3] = pCreature->GetGUID(); break;
|
||||
case NPC_SEETHREL: TombBossGUIDs[4] = pCreature->GetGUID(); break;
|
||||
case NPC_GLOOMREL: TombBossGUIDs[5] = pCreature->GetGUID(); break;
|
||||
case NPC_ANGERREL: TombBossGUIDs[6] = pCreature->GetGUID(); break;
|
||||
case NPC_EMPEROR: EmperorGUID = creature->GetGUID(); break;
|
||||
case NPC_PHALANX: PhalanxGUID = creature->GetGUID(); break;
|
||||
case NPC_DOOMREL: TombBossGUIDs[0] = creature->GetGUID(); break;
|
||||
case NPC_DOPEREL: TombBossGUIDs[1] = creature->GetGUID(); break;
|
||||
case NPC_HATEREL: TombBossGUIDs[2] = creature->GetGUID(); break;
|
||||
case NPC_VILEREL: TombBossGUIDs[3] = creature->GetGUID(); break;
|
||||
case NPC_SEETHREL: TombBossGUIDs[4] = creature->GetGUID(); break;
|
||||
case NPC_GLOOMREL: TombBossGUIDs[5] = creature->GetGUID(); break;
|
||||
case NPC_ANGERREL: TombBossGUIDs[6] = creature->GetGUID(); break;
|
||||
case NPC_MAGMUS:
|
||||
MagmusGUID = pCreature->GetGUID();
|
||||
if (!pCreature->isAlive())
|
||||
MagmusGUID = creature->GetGUID();
|
||||
if (!creature->isAlive())
|
||||
HandleGameObject(GetData64(DATA_THRONE_DOOR), true); // if Magmus is dead open door to last boss
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_ARENA1: GoArena1GUID = pGo->GetGUID(); break;
|
||||
case GO_ARENA2: GoArena2GUID = pGo->GetGUID(); break;
|
||||
case GO_ARENA3: GoArena3GUID = pGo->GetGUID(); break;
|
||||
case GO_ARENA4: GoArena4GUID = pGo->GetGUID(); break;
|
||||
case GO_SHADOW_LOCK: GoShadowLockGUID = pGo->GetGUID(); break;
|
||||
case GO_SHADOW_MECHANISM: GoShadowMechGUID = pGo->GetGUID(); break;
|
||||
case GO_SHADOW_GIANT_DOOR: GoShadowGiantGUID = pGo->GetGUID(); break;
|
||||
case GO_SHADOW_DUMMY: GoShadowDummyGUID = pGo->GetGUID(); break;
|
||||
case GO_BAR_KEG_SHOT: GoBarKegGUID = pGo->GetGUID(); break;
|
||||
case GO_BAR_KEG_TRAP: GoBarKegTrapGUID = pGo->GetGUID(); break;
|
||||
case GO_BAR_DOOR: GoBarDoorGUID = pGo->GetGUID(); break;
|
||||
case GO_TOMB_ENTER: GoTombEnterGUID = pGo->GetGUID(); break;
|
||||
case GO_ARENA1: GoArena1GUID = go->GetGUID(); break;
|
||||
case GO_ARENA2: GoArena2GUID = go->GetGUID(); break;
|
||||
case GO_ARENA3: GoArena3GUID = go->GetGUID(); break;
|
||||
case GO_ARENA4: GoArena4GUID = go->GetGUID(); break;
|
||||
case GO_SHADOW_LOCK: GoShadowLockGUID = go->GetGUID(); break;
|
||||
case GO_SHADOW_MECHANISM: GoShadowMechGUID = go->GetGUID(); break;
|
||||
case GO_SHADOW_GIANT_DOOR: GoShadowGiantGUID = go->GetGUID(); break;
|
||||
case GO_SHADOW_DUMMY: GoShadowDummyGUID = go->GetGUID(); break;
|
||||
case GO_BAR_KEG_SHOT: GoBarKegGUID = go->GetGUID(); break;
|
||||
case GO_BAR_KEG_TRAP: GoBarKegTrapGUID = go->GetGUID(); break;
|
||||
case GO_BAR_DOOR: GoBarDoorGUID = go->GetGUID(); break;
|
||||
case GO_TOMB_ENTER: GoTombEnterGUID = go->GetGUID(); break;
|
||||
case GO_TOMB_EXIT:
|
||||
GoTombExitGUID = pGo->GetGUID();
|
||||
GoTombExitGUID = go->GetGUID();
|
||||
if (GhostKillCount >= 7)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
else
|
||||
HandleGameObject(0, false, pGo);
|
||||
HandleGameObject(0, false, go);
|
||||
break;
|
||||
case GO_LYCEUM: GoLyceumGUID = pGo->GetGUID(); break;
|
||||
case GO_SF_S: GoSFSGUID = pGo->GetGUID(); break;
|
||||
case GO_SF_N: GoSFNGUID = pGo->GetGUID(); break;
|
||||
case GO_GOLEM_ROOM_N: GoGolemNGUID = pGo->GetGUID(); break;
|
||||
case GO_GOLEM_ROOM_S: GoGolemSGUID = pGo->GetGUID(); break;
|
||||
case GO_THRONE_ROOM: GoThroneGUID = pGo->GetGUID(); break;
|
||||
case GO_CHEST_SEVEN: GoChestGUID = pGo->GetGUID(); break;
|
||||
case GO_SPECTRAL_CHALICE: GoSpectralChaliceGUID = pGo->GetGUID(); break;
|
||||
case GO_LYCEUM: GoLyceumGUID = go->GetGUID(); break;
|
||||
case GO_SF_S: GoSFSGUID = go->GetGUID(); break;
|
||||
case GO_SF_N: GoSFNGUID = go->GetGUID(); break;
|
||||
case GO_GOLEM_ROOM_N: GoGolemNGUID = go->GetGUID(); break;
|
||||
case GO_GOLEM_ROOM_S: GoGolemSGUID = go->GetGUID(); break;
|
||||
case GO_THRONE_ROOM: GoThroneGUID = go->GetGUID(); break;
|
||||
case GO_CHEST_SEVEN: GoChestGUID = go->GetGUID(); break;
|
||||
case GO_SPECTRAL_CHALICE: GoSpectralChaliceGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -87,7 +87,7 @@ class instance_deadmines : public InstanceMapScript
|
||||
if (!IronCladDoorGUID || !DefiasCannonGUID || !DoorLeverGUID)
|
||||
return;
|
||||
|
||||
GameObject *pIronCladDoor = instance->GetGameObject(IronCladDoorGUID);
|
||||
GameObject* pIronCladDoor = instance->GetGameObject(IronCladDoorGUID);
|
||||
if (!pIronCladDoor)
|
||||
return;
|
||||
|
||||
@@ -126,11 +126,11 @@ class instance_deadmines : public InstanceMapScript
|
||||
|
||||
void SummonCreatures()
|
||||
{
|
||||
if (GameObject *pIronCladDoor = instance->GetGameObject(IronCladDoorGUID))
|
||||
if (GameObject* pIronCladDoor = instance->GetGameObject(IronCladDoorGUID))
|
||||
{
|
||||
Creature *DefiasPirate1 = pIronCladDoor->SummonCreature(657,pIronCladDoor->GetPositionX() - 2,pIronCladDoor->GetPositionY()-7,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
Creature *DefiasPirate2 = pIronCladDoor->SummonCreature(657,pIronCladDoor->GetPositionX() + 3,pIronCladDoor->GetPositionY()-6,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
Creature *DefiasCompanion = pIronCladDoor->SummonCreature(3450,pIronCladDoor->GetPositionX() + 2,pIronCladDoor->GetPositionY()-6,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
Creature* DefiasPirate1 = pIronCladDoor->SummonCreature(657,pIronCladDoor->GetPositionX() - 2,pIronCladDoor->GetPositionY()-7,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
Creature* DefiasPirate2 = pIronCladDoor->SummonCreature(657,pIronCladDoor->GetPositionX() + 3,pIronCladDoor->GetPositionY()-6,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
Creature* DefiasCompanion = pIronCladDoor->SummonCreature(3450,pIronCladDoor->GetPositionX() + 2,pIronCladDoor->GetPositionY()-6,pIronCladDoor->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3000);
|
||||
|
||||
DefiasPirate1GUID = DefiasPirate1->GetGUID();
|
||||
DefiasPirate2GUID = DefiasPirate2->GetGUID();
|
||||
@@ -143,9 +143,9 @@ class instance_deadmines : public InstanceMapScript
|
||||
if (!DefiasPirate1GUID || !DefiasPirate2GUID || !DefiasCompanionGUID)
|
||||
return;
|
||||
|
||||
Creature *pDefiasPirate1 = instance->GetCreature(DefiasPirate1GUID);
|
||||
Creature *pDefiasPirate2 = instance->GetCreature(DefiasPirate2GUID);
|
||||
Creature *pDefiasCompanion = instance->GetCreature(DefiasCompanionGUID);
|
||||
Creature* pDefiasPirate1 = instance->GetCreature(DefiasPirate1GUID);
|
||||
Creature* pDefiasPirate2 = instance->GetCreature(DefiasPirate2GUID);
|
||||
Creature* pDefiasCompanion = instance->GetCreature(DefiasCompanionGUID);
|
||||
if (!pDefiasPirate1 || !pDefiasPirate2 || !pDefiasCompanion)
|
||||
return;
|
||||
|
||||
@@ -154,15 +154,15 @@ class instance_deadmines : public InstanceMapScript
|
||||
MoveCreatureInside(pDefiasCompanion);
|
||||
}
|
||||
|
||||
void MoveCreatureInside(Creature* pCreature)
|
||||
void MoveCreatureInside(Creature* creature)
|
||||
{
|
||||
pCreature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
pCreature->GetMotionMaster()->MovePoint(0, -102.7f,-655.9f, pCreature->GetPositionZ());
|
||||
creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
creature->GetMotionMaster()->MovePoint(0, -102.7f,-655.9f, creature->GetPositionZ());
|
||||
}
|
||||
|
||||
void ShootCannon()
|
||||
{
|
||||
if (GameObject *pDefiasCannon = instance->GetGameObject(DefiasCannonGUID))
|
||||
if (GameObject* pDefiasCannon = instance->GetGameObject(DefiasCannonGUID))
|
||||
{
|
||||
pDefiasCannon->SetGoState(GO_STATE_ACTIVE);
|
||||
DoPlaySound(pDefiasCannon, SOUND_CANNONFIRE);
|
||||
@@ -171,7 +171,7 @@ class instance_deadmines : public InstanceMapScript
|
||||
|
||||
void BlastOutDoor()
|
||||
{
|
||||
if (GameObject *pIronCladDoor = instance->GetGameObject(IronCladDoorGUID))
|
||||
if (GameObject* pIronCladDoor = instance->GetGameObject(IronCladDoorGUID))
|
||||
{
|
||||
pIronCladDoor->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
|
||||
DoPlaySound(pIronCladDoor, SOUND_DESTROYDOOR);
|
||||
@@ -180,19 +180,19 @@ class instance_deadmines : public InstanceMapScript
|
||||
|
||||
void LeverStucked()
|
||||
{
|
||||
if (GameObject *pDoorLever = instance->GetGameObject(DoorLeverGUID))
|
||||
if (GameObject* pDoorLever = instance->GetGameObject(DoorLeverGUID))
|
||||
pDoorLever->SetUInt32Value(GAMEOBJECT_FLAGS, 4);
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_FACTORY_DOOR: FactoryDoorGUID = pGo->GetGUID(); break;
|
||||
case GO_IRONCLAD_DOOR: IronCladDoorGUID = pGo->GetGUID(); break;
|
||||
case GO_DEFIAS_CANNON: DefiasCannonGUID = pGo->GetGUID(); break;
|
||||
case GO_DOOR_LEVER: DoorLeverGUID = pGo->GetGUID(); break;
|
||||
case GO_MR_SMITE_CHEST: uiSmiteChestGUID = pGo->GetGUID(); break;
|
||||
case GO_FACTORY_DOOR: FactoryDoorGUID = go->GetGUID(); break;
|
||||
case GO_IRONCLAD_DOOR: IronCladDoorGUID = go->GetGUID(); break;
|
||||
case GO_DEFIAS_CANNON: DefiasCannonGUID = go->GetGUID(); break;
|
||||
case GO_DOOR_LEVER: DoorLeverGUID = go->GetGUID(); break;
|
||||
case GO_MR_SMITE_CHEST: uiSmiteChestGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -206,8 +206,8 @@ class instance_deadmines : public InstanceMapScript
|
||||
break;
|
||||
case EVENT_RHAHKZOR:
|
||||
if (data == DONE)
|
||||
if (GameObject* pGo = instance->GetGameObject(FactoryDoorGUID))
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
if (GameObject* go = instance->GetGameObject(FactoryDoorGUID))
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -76,27 +76,27 @@ public:
|
||||
OUT_LOAD_INST_DATA_COMPLETE;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*bAdd*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_BLASTMASTER_EMI_SHORTFUSE: uiBastmasterEmiShortfuseGUID = pCreature->GetGUID(); break;
|
||||
case NPC_BLASTMASTER_EMI_SHORTFUSE: uiBastmasterEmiShortfuseGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_CAVE_IN_LEFT:
|
||||
uiCaveInLeftGUID = pGo->GetGUID();
|
||||
uiCaveInLeftGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE || m_auiEncounter[0] == NOT_STARTED)
|
||||
HandleGameObject(NULL,false,pGo);
|
||||
HandleGameObject(NULL,false,go);
|
||||
break;
|
||||
case GO_CAVE_IN_RIGHT:
|
||||
uiCaveInRightGUID = pGo->GetGUID();
|
||||
uiCaveInRightGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE || m_auiEncounter[0] == NOT_STARTED)
|
||||
HandleGameObject(NULL,false,pGo);
|
||||
HandleGameObject(NULL,false,go);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -116,13 +116,13 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case 17229: m_uiKilrekGUID = pCreature->GetGUID(); break;
|
||||
case 15688: m_uiTerestianGUID = pCreature->GetGUID(); break;
|
||||
case 15687: m_uiMoroesGUID = pCreature->GetGUID(); break;
|
||||
case 17229: m_uiKilrekGUID = creature->GetGUID(); break;
|
||||
case 15688: m_uiTerestianGUID = creature->GetGUID(); break;
|
||||
case 15687: m_uiMoroesGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -185,36 +185,36 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 183932: m_uiCurtainGUID = pGo->GetGUID(); break;
|
||||
case 183932: m_uiCurtainGUID = go->GetGUID(); break;
|
||||
case 184278:
|
||||
m_uiStageDoorLeftGUID = pGo->GetGUID();
|
||||
m_uiStageDoorLeftGUID = go->GetGUID();
|
||||
if (m_auiEncounter[4] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
case 184279:
|
||||
m_uiStageDoorRightGUID = pGo->GetGUID();
|
||||
m_uiStageDoorRightGUID = go->GetGUID();
|
||||
if (m_auiEncounter[4] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
case 184517: m_uiLibraryDoor = pGo->GetGUID(); break;
|
||||
case 185521: m_uiMassiveDoor = pGo->GetGUID(); break;
|
||||
case 184276: m_uiGamesmansDoor = pGo->GetGUID(); break;
|
||||
case 184277: m_uiGamesmansExitDoor = pGo->GetGUID(); break;
|
||||
case 185134: m_uiNetherspaceDoor = pGo->GetGUID(); break;
|
||||
case 184274: MastersTerraceDoor[0] = pGo->GetGUID(); break;
|
||||
case 184280: MastersTerraceDoor[1] = pGo->GetGUID(); break;
|
||||
case 184517: m_uiLibraryDoor = go->GetGUID(); break;
|
||||
case 185521: m_uiMassiveDoor = go->GetGUID(); break;
|
||||
case 184276: m_uiGamesmansDoor = go->GetGUID(); break;
|
||||
case 184277: m_uiGamesmansExitDoor = go->GetGUID(); break;
|
||||
case 185134: m_uiNetherspaceDoor = go->GetGUID(); break;
|
||||
case 184274: MastersTerraceDoor[0] = go->GetGUID(); break;
|
||||
case 184280: MastersTerraceDoor[1] = go->GetGUID(); break;
|
||||
case 184275:
|
||||
m_uiSideEntranceDoor = pGo->GetGUID();
|
||||
m_uiSideEntranceDoor = go->GetGUID();
|
||||
if (m_auiEncounter[4] == DONE)
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
|
||||
else
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
|
||||
break;
|
||||
case 185119: DustCoveredChest = pGo->GetGUID(); break;
|
||||
case 185119: DustCoveredChest = go->GetGUID(); break;
|
||||
}
|
||||
|
||||
switch(m_uiOperaEvent)
|
||||
|
||||
@@ -137,29 +137,29 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 24723: SelinGUID = pCreature->GetGUID(); break;
|
||||
case 24560: DelrissaGUID = pCreature->GetGUID(); break;
|
||||
case 24722: FelCrystals.push_back(pCreature->GetGUID()); break;
|
||||
case 24723: SelinGUID = creature->GetGUID(); break;
|
||||
case 24560: DelrissaGUID = creature->GetGUID(); break;
|
||||
case 24722: FelCrystals.push_back(creature->GetGUID()); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 187896: VexallusDoorGUID = pGo->GetGUID(); break;
|
||||
case 187896: VexallusDoorGUID = go->GetGUID(); break;
|
||||
//SunwellRaid Gate 02
|
||||
case 187979: SelinDoorGUID = pGo->GetGUID(); break;
|
||||
case 187979: SelinDoorGUID = go->GetGUID(); break;
|
||||
//Assembly Chamber Door
|
||||
case 188065: SelinEncounterDoorGUID = pGo->GetGUID(); break;
|
||||
case 187770: DelrissaDoorGUID = pGo->GetGUID(); break;
|
||||
case 188064: KaelDoorGUID = pGo->GetGUID(); break;
|
||||
case 188165: KaelStatue[0] = pGo->GetGUID(); break;
|
||||
case 188166: KaelStatue[1] = pGo->GetGUID(); break;
|
||||
case 188065: SelinEncounterDoorGUID = go->GetGUID(); break;
|
||||
case 187770: DelrissaDoorGUID = go->GetGUID(); break;
|
||||
case 188064: KaelDoorGUID = go->GetGUID(); break;
|
||||
case 188165: KaelStatue[0] = go->GetGUID(); break;
|
||||
case 188166: KaelStatue[1] = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -105,83 +105,83 @@ public:
|
||||
return false;
|
||||
};
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 176951: //Sulfuron
|
||||
RuneKoro = pGo->GetGUID();
|
||||
RuneKoro = go->GetGUID();
|
||||
break;
|
||||
case 176952: //Geddon
|
||||
RuneZeth = pGo->GetGUID();
|
||||
RuneZeth = go->GetGUID();
|
||||
break;
|
||||
case 176953: //Shazzrah
|
||||
RuneMazj = pGo->GetGUID();
|
||||
RuneMazj = go->GetGUID();
|
||||
break;
|
||||
case 176954: //Golemagg
|
||||
RuneTheri = pGo->GetGUID();
|
||||
RuneTheri = go->GetGUID();
|
||||
break;
|
||||
case 176955: //Garr
|
||||
RuneBlaz = pGo->GetGUID();
|
||||
RuneBlaz = go->GetGUID();
|
||||
break;
|
||||
case 176956: //Magmadar
|
||||
RuneKress = pGo->GetGUID();
|
||||
RuneKress = go->GetGUID();
|
||||
break;
|
||||
case 176957: //Gehennas
|
||||
RuneMohn = pGo->GetGUID();
|
||||
RuneMohn = go->GetGUID();
|
||||
break;
|
||||
case 179703:
|
||||
m_uiFirelordCacheGUID = pGo->GetGUID(); //when majordomo event == DONE DoRespawnGameObject(m_uiFirelordCacheGUID,);
|
||||
m_uiFirelordCacheGUID = go->GetGUID(); //when majordomo event == DONE DoRespawnGameObject(m_uiFirelordCacheGUID,);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case ID_LUCIFRON:
|
||||
Lucifron = pCreature->GetGUID();
|
||||
Lucifron = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_MAGMADAR:
|
||||
Magmadar = pCreature->GetGUID();
|
||||
Magmadar = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_GEHENNAS:
|
||||
Gehennas = pCreature->GetGUID();
|
||||
Gehennas = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_GARR:
|
||||
Garr = pCreature->GetGUID();
|
||||
Garr = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_GEDDON:
|
||||
Geddon = pCreature->GetGUID();
|
||||
Geddon = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_SHAZZRAH:
|
||||
Shazzrah = pCreature->GetGUID();
|
||||
Shazzrah = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_SULFURON:
|
||||
Sulfuron = pCreature->GetGUID();
|
||||
Sulfuron = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_GOLEMAGG:
|
||||
Golemagg = pCreature->GetGUID();
|
||||
Golemagg = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_DOMO:
|
||||
Domo = pCreature->GetGUID();
|
||||
Domo = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_RAGNAROS:
|
||||
Ragnaros = pCreature->GetGUID();
|
||||
Ragnaros = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case ID_FLAMEWAKERPRIEST:
|
||||
FlamewakerPriest = pCreature->GetGUID();
|
||||
FlamewakerPriest = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -74,25 +74,25 @@ public:
|
||||
DoorHighInquisitorGUID = 0;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case ENTRY_PUMPKIN_SHRINE: PumpkinShrineGUID = pGo->GetGUID();break;
|
||||
case 104600: DoorHighInquisitorGUID = pGo->GetGUID(); break;
|
||||
case ENTRY_PUMPKIN_SHRINE: PumpkinShrineGUID = go->GetGUID();break;
|
||||
case 104600: DoorHighInquisitorGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case ENTRY_HORSEMAN: HorsemanGUID = pCreature->GetGUID(); break;
|
||||
case ENTRY_HEAD: HeadGUID = pCreature->GetGUID(); break;
|
||||
case ENTRY_PUMPKIN: HorsemanAdds.insert(pCreature->GetGUID());break;
|
||||
case 3976: MograineGUID = pCreature->GetGUID(); break;
|
||||
case 3977: WhitemaneGUID = pCreature->GetGUID(); break;
|
||||
case 3981: VorrelGUID = pCreature->GetGUID(); break;
|
||||
case ENTRY_HORSEMAN: HorsemanGUID = creature->GetGUID(); break;
|
||||
case ENTRY_HEAD: HeadGUID = creature->GetGUID(); break;
|
||||
case ENTRY_PUMPKIN: HorsemanAdds.insert(creature->GetGUID());break;
|
||||
case 3976: MograineGUID = creature->GetGUID(); break;
|
||||
case 3977: WhitemaneGUID = creature->GetGUID(); break;
|
||||
case 3981: VorrelGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -81,18 +81,18 @@ public:
|
||||
IsBossDied[i] = false;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_GATE_KIRTONOS: GateKirtonosGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_GANDLING: GateGandlingGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_MALICIA: GateMiliciaGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_THEOLEN: GateTheolenGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_POLKELT: GatePolkeltGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_RAVENIAN: GateRavenianGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_BAROV: GateBarovGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_ILLUCIA: GateIlluciaGUID = pGo->GetGUID(); break;
|
||||
case GO_GATE_KIRTONOS: GateKirtonosGUID = go->GetGUID(); break;
|
||||
case GO_GATE_GANDLING: GateGandlingGUID = go->GetGUID(); break;
|
||||
case GO_GATE_MALICIA: GateMiliciaGUID = go->GetGUID(); break;
|
||||
case GO_GATE_THEOLEN: GateTheolenGUID = go->GetGUID(); break;
|
||||
case GO_GATE_POLKELT: GatePolkeltGUID = go->GetGUID(); break;
|
||||
case GO_GATE_RAVENIAN: GateRavenianGUID = go->GetGUID(); break;
|
||||
case GO_GATE_BAROV: GateBarovGUID = go->GetGUID(); break;
|
||||
case GO_GATE_ILLUCIA: GateIlluciaGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -98,34 +98,34 @@ public:
|
||||
uiTimer = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_ASH: uiAshGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ADA: uiAdaGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ARCHMAGE_ARUGAL: uiArchmageArugalGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ASH: uiAshGUID = creature->GetGUID(); break;
|
||||
case NPC_ADA: uiAdaGUID = creature->GetGUID(); break;
|
||||
case NPC_ARCHMAGE_ARUGAL: uiArchmageArugalGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_COURTYARD_DOOR:
|
||||
DoorCourtyardGUID = pGo->GetGUID();
|
||||
DoorCourtyardGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
case GO_SORCERER_DOOR:
|
||||
DoorSorcererGUID = pGo->GetGUID();
|
||||
DoorSorcererGUID = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
case GO_ARUGAL_DOOR:
|
||||
DoorArugalGUID = pGo->GetGUID();
|
||||
DoorArugalGUID = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,76 +134,76 @@ public:
|
||||
if (!goGuid)
|
||||
return;
|
||||
|
||||
if (GameObject* pGo = instance->GetGameObject(goGuid))
|
||||
if (GameObject* go = instance->GetGameObject(goGuid))
|
||||
{
|
||||
if (withRestoreTime)
|
||||
pGo->UseDoorOrButton(10);
|
||||
go->UseDoorOrButton(10);
|
||||
else
|
||||
pGo->SetGoState((GOState)newState);
|
||||
go->SetGoState((GOState)newState);
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case C_BARON: baronGUID = pCreature->GetGUID(); break;
|
||||
case C_YSIDA_TRIGGER: ysidaTriggerGUID = pCreature->GetGUID(); break;
|
||||
case C_CRYSTAL: crystalsGUID.insert(pCreature->GetGUID()); break;
|
||||
case C_BARON: baronGUID = creature->GetGUID(); break;
|
||||
case C_YSIDA_TRIGGER: ysidaTriggerGUID = creature->GetGUID(); break;
|
||||
case C_CRYSTAL: crystalsGUID.insert(creature->GetGUID()); break;
|
||||
case C_ABOM_BILE:
|
||||
case C_ABOM_VENOM: abomnationGUID.insert(pCreature->GetGUID()); break;
|
||||
case C_ABOM_VENOM: abomnationGUID.insert(creature->GetGUID()); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_SERVICE_ENTRANCE:
|
||||
serviceEntranceGUID = pGo->GetGUID();
|
||||
serviceEntranceGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_GAUNTLET_GATE1:
|
||||
//weird, but unless flag is set, client will not respond as expected. DB bug?
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_LOCKED);
|
||||
gauntletGate1GUID = pGo->GetGUID();
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_LOCKED);
|
||||
gauntletGate1GUID = go->GetGUID();
|
||||
break;
|
||||
case GO_ZIGGURAT1:
|
||||
ziggurat1GUID = pGo->GetGUID();
|
||||
ziggurat1GUID = go->GetGUID();
|
||||
if (GetData(TYPE_BARONESS) == IN_PROGRESS)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_ZIGGURAT2:
|
||||
ziggurat2GUID = pGo->GetGUID();
|
||||
ziggurat2GUID = go->GetGUID();
|
||||
if (GetData(TYPE_NERUB) == IN_PROGRESS)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_ZIGGURAT3:
|
||||
ziggurat3GUID = pGo->GetGUID();
|
||||
ziggurat3GUID = go->GetGUID();
|
||||
if (GetData(TYPE_PALLID) == IN_PROGRESS)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_ZIGGURAT4:
|
||||
ziggurat4GUID = pGo->GetGUID();
|
||||
ziggurat4GUID = go->GetGUID();
|
||||
if (GetData(TYPE_BARON) == DONE || GetData(TYPE_RAMSTEIN) == DONE)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_ZIGGURAT5:
|
||||
ziggurat5GUID = pGo->GetGUID();
|
||||
ziggurat5GUID = go->GetGUID();
|
||||
if (GetData(TYPE_BARON) == DONE || GetData(TYPE_RAMSTEIN) == DONE)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_PORT_GAUNTLET:
|
||||
portGauntletGUID = pGo->GetGUID();
|
||||
portGauntletGUID = go->GetGUID();
|
||||
if (GetData(TYPE_BARONESS) == IN_PROGRESS && GetData(TYPE_NERUB) == IN_PROGRESS && GetData(TYPE_PALLID) == IN_PROGRESS)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_PORT_SLAUGTHER:
|
||||
portSlaugtherGUID = pGo->GetGUID();
|
||||
portSlaugtherGUID = go->GetGUID();
|
||||
if (GetData(TYPE_BARONESS) == IN_PROGRESS && GetData(TYPE_NERUB) == IN_PROGRESS && GetData(TYPE_PALLID) == IN_PROGRESS)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_PORT_ELDERS:
|
||||
portElderGUID = pGo->GetGUID();
|
||||
portElderGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,17 +93,17 @@ public:
|
||||
s6 = false;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_ATALAI_STATUE1: GOAtalaiStatue1 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE2: GOAtalaiStatue2 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE3: GOAtalaiStatue3 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE4: GOAtalaiStatue4 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE5: GOAtalaiStatue5 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE6: GOAtalaiStatue6 = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_IDOL: GOAtalaiIdol = pGo->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE1: GOAtalaiStatue1 = go->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE2: GOAtalaiStatue2 = go->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE3: GOAtalaiStatue3 = go->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE4: GOAtalaiStatue4 = go->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE5: GOAtalaiStatue5 = go->GetGUID(); break;
|
||||
case GO_ATALAI_STATUE6: GOAtalaiStatue6 = go->GetGUID(); break;
|
||||
case GO_ATALAI_IDOL: GOAtalaiIdol = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -114,7 +114,7 @@ public:
|
||||
case GO_ATALAI_STATUE1:
|
||||
if (!s1 && !s2 && !s3 && !s4 && !s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue1 = instance->GetGameObject(GOAtalaiStatue1))
|
||||
if (GameObject* pAtalaiStatue1 = instance->GetGameObject(GOAtalaiStatue1))
|
||||
UseStatue(pAtalaiStatue1);
|
||||
s1 = true;
|
||||
State = 0;
|
||||
@@ -123,7 +123,7 @@ public:
|
||||
case GO_ATALAI_STATUE2:
|
||||
if (s1 && !s2 && !s3 && !s4 && !s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue2 = instance->GetGameObject(GOAtalaiStatue2))
|
||||
if (GameObject* pAtalaiStatue2 = instance->GetGameObject(GOAtalaiStatue2))
|
||||
UseStatue(pAtalaiStatue2);
|
||||
s2 = true;
|
||||
State = 0;
|
||||
@@ -132,7 +132,7 @@ public:
|
||||
case GO_ATALAI_STATUE3:
|
||||
if (s1 && s2 && !s3 && !s4 && !s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue3 = instance->GetGameObject(GOAtalaiStatue3))
|
||||
if (GameObject* pAtalaiStatue3 = instance->GetGameObject(GOAtalaiStatue3))
|
||||
UseStatue(pAtalaiStatue3);
|
||||
s3 = true;
|
||||
State = 0;
|
||||
@@ -141,7 +141,7 @@ public:
|
||||
case GO_ATALAI_STATUE4:
|
||||
if (s1 && s2 && s3 && !s4 && !s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue4 = instance->GetGameObject(GOAtalaiStatue4))
|
||||
if (GameObject* pAtalaiStatue4 = instance->GetGameObject(GOAtalaiStatue4))
|
||||
UseStatue(pAtalaiStatue4);
|
||||
s4 = true;
|
||||
State = 0;
|
||||
@@ -150,7 +150,7 @@ public:
|
||||
case GO_ATALAI_STATUE5:
|
||||
if (s1 && s2 && s3 && s4 && !s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue5 = instance->GetGameObject(GOAtalaiStatue5))
|
||||
if (GameObject* pAtalaiStatue5 = instance->GetGameObject(GOAtalaiStatue5))
|
||||
UseStatue(pAtalaiStatue5);
|
||||
s5 = true;
|
||||
State = 0;
|
||||
@@ -159,7 +159,7 @@ public:
|
||||
case GO_ATALAI_STATUE6:
|
||||
if (s1 && s2 && s3 && s4 && s5 && !s6)
|
||||
{
|
||||
if (GameObject *pAtalaiStatue6 = instance->GetGameObject(GOAtalaiStatue6))
|
||||
if (GameObject* pAtalaiStatue6 = instance->GetGameObject(GOAtalaiStatue6))
|
||||
UseStatue(pAtalaiStatue6);
|
||||
s6 = true;
|
||||
State = 0;
|
||||
@@ -168,14 +168,14 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
void UseStatue(GameObject* pGo)
|
||||
void UseStatue(GameObject* go)
|
||||
{
|
||||
pGo->SummonGameObject(GO_ATALAI_LIGHT1,pGo->GetPositionX(),pGo->GetPositionY(),pGo->GetPositionZ(),0,0,0,0,0,0);
|
||||
pGo->SetUInt32Value(GAMEOBJECT_FLAGS, 4);
|
||||
go->SummonGameObject(GO_ATALAI_LIGHT1,go->GetPositionX(),go->GetPositionY(),go->GetPositionZ(),0,0,0,0,0,0);
|
||||
go->SetUInt32Value(GAMEOBJECT_FLAGS, 4);
|
||||
}
|
||||
|
||||
/*
|
||||
void UseLastStatue(GameObject* pGo)
|
||||
void UseLastStatue(GameObject* go)
|
||||
{
|
||||
AtalaiStatue1->SummonGameObject(GO_ATALAI_LIGHT2,AtalaiStatue1->GetPositionX(),AtalaiStatue1->GetPositionY(),AtalaiStatue1->GetPositionZ(),0,0,0,0,0,100000);
|
||||
AtalaiStatue2->SummonGameObject(GO_ATALAI_LIGHT2,AtalaiStatue2->GetPositionX(),AtalaiStatue2->GetPositionY(),AtalaiStatue2->GetPositionZ(),0,0,0,0,0,100000);
|
||||
@@ -183,7 +183,7 @@ public:
|
||||
AtalaiStatue4->SummonGameObject(GO_ATALAI_LIGHT2,AtalaiStatue4->GetPositionX(),AtalaiStatue4->GetPositionY(),AtalaiStatue4->GetPositionZ(),0,0,0,0,0,100000);
|
||||
AtalaiStatue5->SummonGameObject(GO_ATALAI_LIGHT2,AtalaiStatue5->GetPositionX(),AtalaiStatue5->GetPositionY(),AtalaiStatue5->GetPositionZ(),0,0,0,0,0,100000);
|
||||
AtalaiStatue6->SummonGameObject(GO_ATALAI_LIGHT2,AtalaiStatue6->GetPositionX(),AtalaiStatue6->GetPositionY(),AtalaiStatue6->GetPositionZ(),0,0,0,0,0,100000);
|
||||
pGo->SummonGameObject(148838,-488.997,96.61,-189.019,-1.52,0,0,0,0,100000);
|
||||
go->SummonGameObject(148838,-488.997,96.61,-189.019,-1.52,0,0,0,0,100000);
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
@@ -138,43 +138,43 @@ public:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 24850: Kalecgos_Dragon = pCreature->GetGUID(); break;
|
||||
case 24891: Kalecgos_Human = pCreature->GetGUID(); break;
|
||||
case 24892: Sathrovarr = pCreature->GetGUID(); break;
|
||||
case 24882: Brutallus = pCreature->GetGUID(); break;
|
||||
case 24895: Madrigosa = pCreature->GetGUID(); break;
|
||||
case 25038: Felmyst = pCreature->GetGUID(); break;
|
||||
case 25166: Alythess = pCreature->GetGUID(); break;
|
||||
case 25165: Sacrolash = pCreature->GetGUID(); break;
|
||||
case 25741: Muru = pCreature->GetGUID(); break;
|
||||
case 25315: KilJaeden = pCreature->GetGUID(); break;
|
||||
case 25608: KilJaedenController = pCreature->GetGUID(); break;
|
||||
case 26046: Anveena = pCreature->GetGUID(); break;
|
||||
case 25319: KalecgosKJ = pCreature->GetGUID(); break;
|
||||
case 24850: Kalecgos_Dragon = creature->GetGUID(); break;
|
||||
case 24891: Kalecgos_Human = creature->GetGUID(); break;
|
||||
case 24892: Sathrovarr = creature->GetGUID(); break;
|
||||
case 24882: Brutallus = creature->GetGUID(); break;
|
||||
case 24895: Madrigosa = creature->GetGUID(); break;
|
||||
case 25038: Felmyst = creature->GetGUID(); break;
|
||||
case 25166: Alythess = creature->GetGUID(); break;
|
||||
case 25165: Sacrolash = creature->GetGUID(); break;
|
||||
case 25741: Muru = creature->GetGUID(); break;
|
||||
case 25315: KilJaeden = creature->GetGUID(); break;
|
||||
case 25608: KilJaedenController = creature->GetGUID(); break;
|
||||
case 26046: Anveena = creature->GetGUID(); break;
|
||||
case 25319: KalecgosKJ = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 188421: ForceField = pGo->GetGUID(); break;
|
||||
case 188523: KalecgosWall[0] = pGo->GetGUID(); break;
|
||||
case 188524: KalecgosWall[0] = pGo->GetGUID(); break;
|
||||
case 188421: ForceField = go->GetGUID(); break;
|
||||
case 188523: KalecgosWall[0] = go->GetGUID(); break;
|
||||
case 188524: KalecgosWall[0] = go->GetGUID(); break;
|
||||
case 188075:
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
FireBarrier = pGo->GetGUID();
|
||||
HandleGameObject(NULL, true, go);
|
||||
FireBarrier = go->GetGUID();
|
||||
break;
|
||||
case 187990: MurusGate[0] = pGo->GetGUID(); break;
|
||||
case 187990: MurusGate[0] = go->GetGUID(); break;
|
||||
case 188118:
|
||||
if (m_auiEncounter[4] == DONE)
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
MurusGate[1]= pGo->GetGUID();
|
||||
HandleGameObject(NULL, true, go);
|
||||
MurusGate[1]= go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,65 +100,65 @@ class instance_uldaman : public InstanceMapScript
|
||||
uint32 m_auiEncounter[MAX_ENCOUNTER];
|
||||
std::string str_data;
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGO, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch (pGO->GetEntry())
|
||||
switch (go->GetEntry())
|
||||
{
|
||||
case GO_ALTAR_OF_THE_KEEPER_TEMPLE_DOOR: // lock the door
|
||||
uiAltarOfTheKeeperTempleDoor = pGO->GetGUID();
|
||||
uiAltarOfTheKeeperTempleDoor = go->GetGUID();
|
||||
|
||||
if(m_auiEncounter[0] == DONE)
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
|
||||
case GO_ARCHAEDAS_TEMPLE_DOOR:
|
||||
uiArchaedasTempleDoor = pGO->GetGUID();
|
||||
uiArchaedasTempleDoor = go->GetGUID();
|
||||
|
||||
if(m_auiEncounter[0] == DONE)
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
|
||||
case GO_ANCIENT_VAULT_DOOR:
|
||||
pGO->SetGoState(GO_STATE_READY);
|
||||
pGO->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
|
||||
uiAncientVaultDoor = pGO->GetGUID();
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
go->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
|
||||
uiAncientVaultDoor = go->GetGUID();
|
||||
|
||||
if(m_auiEncounter[1] == DONE)
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
|
||||
case GO_IRONAYA_SEAL_DOOR:
|
||||
uiIronayaSealDoor = pGO->GetGUID();
|
||||
uiIronayaSealDoor = go->GetGUID();
|
||||
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
|
||||
case GO_KEYSTONE:
|
||||
uiKeystoneGUID = pGO->GetGUID();
|
||||
uiKeystoneGUID = go->GetGUID();
|
||||
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
{
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
pGO->SetUInt32Value(GAMEOBJECT_FLAGS, GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(NULL, true, go);
|
||||
go->SetUInt32Value(GAMEOBJECT_FLAGS, GO_FLAG_INTERACT_COND);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void SetFrozenState(Creature* pCreature)
|
||||
void SetFrozenState(Creature* creature)
|
||||
{
|
||||
pCreature->setFaction(35);
|
||||
pCreature->RemoveAllAuras();
|
||||
creature->setFaction(35);
|
||||
creature->RemoveAllAuras();
|
||||
//creature->RemoveFlag (UNIT_FIELD_FLAGS,UNIT_FLAG_ANIMATION_FROZEN);
|
||||
pCreature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
pCreature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_DISABLE_MOVE);
|
||||
creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_DISABLE_MOVE);
|
||||
}
|
||||
|
||||
void SetDoor(uint64 guid, bool open)
|
||||
{
|
||||
GameObject* pGO = instance->GetGameObject(guid);
|
||||
if (!pGO)
|
||||
GameObject* go = instance->GetGameObject(guid);
|
||||
if (!go)
|
||||
return;
|
||||
|
||||
HandleGameObject(guid, open);
|
||||
@@ -166,18 +166,18 @@ class instance_uldaman : public InstanceMapScript
|
||||
|
||||
void BlockGO(uint64 guid)
|
||||
{
|
||||
GameObject *pGO = instance->GetGameObject(guid);
|
||||
if(!pGO)
|
||||
GameObject* go = instance->GetGameObject(guid);
|
||||
if(!go)
|
||||
return;
|
||||
|
||||
pGO->SetUInt32Value(GAMEOBJECT_FLAGS, GO_FLAG_INTERACT_COND);
|
||||
go->SetUInt32Value(GAMEOBJECT_FLAGS, GO_FLAG_INTERACT_COND);
|
||||
}
|
||||
|
||||
void ActivateStoneKeepers()
|
||||
{
|
||||
for (std::vector<uint64>::const_iterator i = vStoneKeeper.begin(); i != vStoneKeeper.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (!pTarget || !pTarget->isAlive() || pTarget->getFaction() == 14)
|
||||
continue;
|
||||
pTarget->RemoveFlag(UNIT_FIELD_FLAGS,UNIT_FLAG_DISABLE_MOVE);
|
||||
@@ -192,13 +192,13 @@ class instance_uldaman : public InstanceMapScript
|
||||
|
||||
void ActivateWallMinions()
|
||||
{
|
||||
Creature *archaedas = instance->GetCreature(uiArchaedasGUID);
|
||||
Creature* archaedas = instance->GetCreature(uiArchaedasGUID);
|
||||
if (!archaedas)
|
||||
return;
|
||||
|
||||
for (std::vector<uint64>::const_iterator i = vArchaedasWallMinions.begin(); i != vArchaedasWallMinions.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (!pTarget || !pTarget->isAlive() || pTarget->getFaction() == 14)
|
||||
continue;
|
||||
archaedas->CastSpell(pTarget, SPELL_AWAKEN_VAULT_WALKER, true);
|
||||
@@ -213,7 +213,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// first despawn any aggroed wall minions
|
||||
for (std::vector<uint64>::const_iterator i = vArchaedasWallMinions.begin(); i != vArchaedasWallMinions.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (!pTarget || pTarget->isDead() || pTarget->getFaction() != 14)
|
||||
continue;
|
||||
pTarget->setDeathState(JUST_DIED);
|
||||
@@ -223,7 +223,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// Vault Walkers
|
||||
for (std::vector<uint64>::const_iterator i = vVaultWalker.begin(); i != vVaultWalker.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (!pTarget || pTarget->isDead() || pTarget->getFaction() != 14)
|
||||
continue;
|
||||
pTarget->setDeathState(JUST_DIED);
|
||||
@@ -233,7 +233,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// Earthen Guardians
|
||||
for (std::vector<uint64>::const_iterator i = vEarthenGuardian.begin(); i != vEarthenGuardian.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (!pTarget || pTarget->isDead() || pTarget->getFaction() != 14)
|
||||
continue;
|
||||
pTarget->setDeathState(JUST_DIED);
|
||||
@@ -243,7 +243,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
|
||||
void ActivateArchaedas(uint64 target)
|
||||
{
|
||||
Creature *archaedas = instance->GetCreature(uiArchaedasGUID);
|
||||
Creature* archaedas = instance->GetCreature(uiArchaedasGUID);
|
||||
if (!archaedas)
|
||||
return;
|
||||
|
||||
@@ -256,7 +256,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
|
||||
void ActivateIronaya()
|
||||
{
|
||||
Creature *ironaya = instance->GetCreature(uiIronayaGUID);
|
||||
Creature* ironaya = instance->GetCreature(uiIronayaGUID);
|
||||
if(!ironaya)
|
||||
return;
|
||||
|
||||
@@ -270,7 +270,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// first respawn any aggroed wall minions
|
||||
for (std::vector<uint64>::const_iterator i = vArchaedasWallMinions.begin(); i != vArchaedasWallMinions.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (pTarget && pTarget->isDead())
|
||||
{
|
||||
pTarget->Respawn();
|
||||
@@ -282,7 +282,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// Vault Walkers
|
||||
for (std::vector<uint64>::const_iterator i = vVaultWalker.begin(); i != vVaultWalker.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (pTarget && pTarget->isDead())
|
||||
{
|
||||
pTarget->Respawn();
|
||||
@@ -294,7 +294,7 @@ class instance_uldaman : public InstanceMapScript
|
||||
// Earthen Guardians
|
||||
for (std::vector<uint64>::const_iterator i = vEarthenGuardian.begin(); i != vEarthenGuardian.end(); ++i)
|
||||
{
|
||||
Creature *pTarget = instance->GetCreature(*i);
|
||||
Creature* pTarget = instance->GetCreature(*i);
|
||||
if (pTarget && pTarget->isDead())
|
||||
{
|
||||
pTarget->Respawn();
|
||||
@@ -425,39 +425,39 @@ class instance_uldaman : public InstanceMapScript
|
||||
OUT_LOAD_INST_DATA_COMPLETE;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry()) {
|
||||
switch (creature->GetEntry()) {
|
||||
case 4857: // Stone Keeper
|
||||
SetFrozenState (pCreature);
|
||||
vStoneKeeper.push_back(pCreature->GetGUID());
|
||||
SetFrozenState (creature);
|
||||
vStoneKeeper.push_back(creature->GetGUID());
|
||||
break;
|
||||
|
||||
case 7309: // Earthen Custodian
|
||||
vArchaedasWallMinions.push_back(pCreature->GetGUID());
|
||||
vArchaedasWallMinions.push_back(creature->GetGUID());
|
||||
break;
|
||||
|
||||
case 7077: // Earthen Hallshaper
|
||||
vArchaedasWallMinions.push_back(pCreature->GetGUID());
|
||||
vArchaedasWallMinions.push_back(creature->GetGUID());
|
||||
break;
|
||||
|
||||
case 7076: // Earthen Guardian
|
||||
vEarthenGuardian.push_back(pCreature->GetGUID());
|
||||
vEarthenGuardian.push_back(creature->GetGUID());
|
||||
break;
|
||||
|
||||
case 7228: // Ironaya
|
||||
uiIronayaGUID = pCreature->GetGUID();
|
||||
uiIronayaGUID = creature->GetGUID();
|
||||
|
||||
if(m_auiEncounter[2] != DONE)
|
||||
SetFrozenState (pCreature);
|
||||
SetFrozenState (creature);
|
||||
break;
|
||||
|
||||
case 10120: // Vault Walker
|
||||
vVaultWalker.push_back(pCreature->GetGUID());
|
||||
vVaultWalker.push_back(creature->GetGUID());
|
||||
break;
|
||||
|
||||
case 2748: // Archaedas
|
||||
uiArchaedasGUID = pCreature->GetGUID();
|
||||
uiArchaedasGUID = creature->GetGUID();
|
||||
break;
|
||||
|
||||
} // end switch
|
||||
|
||||
@@ -38,7 +38,7 @@ EndScriptData */
|
||||
// But we cannot add loots to gameobject, so we have to use the fixed loot_template
|
||||
struct SHostageInfo
|
||||
{
|
||||
uint32 npc, pGo;
|
||||
uint32 npc, go;
|
||||
float x, y, z, o;
|
||||
};
|
||||
|
||||
@@ -114,9 +114,9 @@ class instance_zulaman : public InstanceMapScript
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 23578://janalai
|
||||
case 23863://zuljin
|
||||
@@ -127,20 +127,20 @@ class instance_zulaman : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 186303: HalazziDoorGUID = pGo->GetGUID(); break;
|
||||
case 186304: ZulJinGateGUID = pGo->GetGUID(); break;
|
||||
case 186305: HexLordGateGUID = pGo->GetGUID(); break;
|
||||
case 186858: AkilzonDoorGUID = pGo->GetGUID(); break;
|
||||
case 186859: ZulJinDoorGUID = pGo->GetGUID(); break;
|
||||
case 186303: HalazziDoorGUID = go->GetGUID(); break;
|
||||
case 186304: ZulJinGateGUID = go->GetGUID(); break;
|
||||
case 186305: HexLordGateGUID = go->GetGUID(); break;
|
||||
case 186858: AkilzonDoorGUID = go->GetGUID(); break;
|
||||
case 186859: ZulJinDoorGUID = go->GetGUID(); break;
|
||||
|
||||
case 187021: HarkorsSatchelGUID = pGo->GetGUID(); break;
|
||||
case 186648: TanzarsTrunkGUID = pGo->GetGUID(); break;
|
||||
case 186672: AshlisBagGUID = pGo->GetGUID(); break;
|
||||
case 186667: KrazsPackageGUID = pGo->GetGUID(); break;
|
||||
case 187021: HarkorsSatchelGUID = go->GetGUID(); break;
|
||||
case 186648: TanzarsTrunkGUID = go->GetGUID(); break;
|
||||
case 186672: AshlisBagGUID = go->GetGUID(); break;
|
||||
case 186667: KrazsPackageGUID = go->GetGUID(); break;
|
||||
default: break;
|
||||
|
||||
}
|
||||
|
||||
@@ -63,14 +63,14 @@ class instance_zulgurub : public InstanceMapScript
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 11347: m_uiLorKhanGUID = pCreature->GetGUID(); break;
|
||||
case 11348: m_uiZathGUID = pCreature->GetGUID(); break;
|
||||
case 14509: m_uiThekalGUID = pCreature->GetGUID(); break;
|
||||
case 11380: m_uiJindoGUID = pCreature->GetGUID(); break;
|
||||
case 11347: m_uiLorKhanGUID = creature->GetGUID(); break;
|
||||
case 11348: m_uiZathGUID = creature->GetGUID(); break;
|
||||
case 14509: m_uiThekalGUID = creature->GetGUID(); break;
|
||||
case 11380: m_uiJindoGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -94,49 +94,49 @@ public:
|
||||
uiDeathTimes = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case NPC_TWILIGHT_LORD_KELRIS:
|
||||
m_uiTwilightLordKelrisGUID = pCreature->GetGUID();
|
||||
m_uiTwilightLordKelrisGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_LORGUS_JETT:
|
||||
pCreature->SetHomePosition(LorgusPosition[urand(0,3)]);
|
||||
creature->SetHomePosition(LorgusPosition[urand(0,3)]);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_FIRE_OF_AKU_MAI_1:
|
||||
m_uiShrine1GUID = pGo->GetGUID();
|
||||
m_uiShrine1GUID = go->GetGUID();
|
||||
break;
|
||||
case GO_FIRE_OF_AKU_MAI_2:
|
||||
m_uiShrine2GUID = pGo->GetGUID();
|
||||
m_uiShrine2GUID = go->GetGUID();
|
||||
break;
|
||||
case GO_FIRE_OF_AKU_MAI_3:
|
||||
m_uiShrine3GUID = pGo->GetGUID();
|
||||
m_uiShrine3GUID = go->GetGUID();
|
||||
break;
|
||||
case GO_FIRE_OF_AKU_MAI_4:
|
||||
m_uiShrine4GUID = pGo->GetGUID();
|
||||
m_uiShrine4GUID = go->GetGUID();
|
||||
break;
|
||||
case GO_SHRINE_OF_GELIHAST:
|
||||
m_uiShrineOfGelihastGUID = pGo->GetGUID();
|
||||
m_uiShrineOfGelihastGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] != DONE)
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
case GO_ALTAR_OF_THE_DEEPS:
|
||||
m_uiAltarOfTheDeepsGUID = pGo->GetGUID();
|
||||
m_uiAltarOfTheDeepsGUID = go->GetGUID();
|
||||
if (m_auiEncounter[3] != DONE)
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
case GO_AKU_MAI_DOOR:
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
m_uiMainDoorGUID = pGo->GetGUID();
|
||||
HandleGameObject(NULL,true,go);
|
||||
m_uiMainDoorGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -148,16 +148,16 @@ public:
|
||||
case TYPE_GELIHAST:
|
||||
m_auiEncounter[0] = uiData;
|
||||
if (uiData == DONE)
|
||||
if (GameObject *pGo = instance->GetGameObject(m_uiShrineOfGelihastGUID))
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
if (GameObject* go = instance->GetGameObject(m_uiShrineOfGelihastGUID))
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
case TYPE_AKU_MAI:
|
||||
m_auiEncounter[3] = uiData;
|
||||
if (uiData == DONE)
|
||||
if (GameObject *pGo = instance->GetGameObject(m_uiAltarOfTheDeepsGUID))
|
||||
if (GameObject* go = instance->GetGameObject(m_uiAltarOfTheDeepsGUID))
|
||||
{
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
pGo->SummonCreature(NPC_MORRIDUNE,SpawnsLocation[4], TEMPSUMMON_CORPSE_TIMED_DESPAWN, 300000);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->SummonCreature(NPC_MORRIDUNE,SpawnsLocation[4], TEMPSUMMON_CORPSE_TIMED_DESPAWN, 300000);
|
||||
}
|
||||
break;
|
||||
case DATA_FIRE:
|
||||
|
||||
@@ -115,42 +115,42 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 182060:
|
||||
HordeGate = pGo->GetGUID();
|
||||
HordeGate = go->GetGUID();
|
||||
if (allianceRetreat)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
else
|
||||
HandleGameObject(0, false, pGo);
|
||||
HandleGameObject(0, false, go);
|
||||
break;
|
||||
case 182061:
|
||||
ElfGate = pGo->GetGUID();
|
||||
ElfGate = go->GetGUID();
|
||||
if (hordeRetreat)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
else
|
||||
HandleGameObject(0, false, pGo);
|
||||
HandleGameObject(0, false, go);
|
||||
break;
|
||||
case GO_ANCIENT_GEM:
|
||||
m_uiAncientGemGUID.push_back(pGo->GetGUID());
|
||||
m_uiAncientGemGUID.push_back(go->GetGUID());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 17767: RageWinterchill = pCreature->GetGUID(); break;
|
||||
case 17808: Anetheron = pCreature->GetGUID(); break;
|
||||
case 17888: Kazrogal = pCreature->GetGUID(); break;
|
||||
case 17842: Azgalor = pCreature->GetGUID(); break;
|
||||
case 17968: Archimonde = pCreature->GetGUID(); break;
|
||||
case 17772: JainaProudmoore = pCreature->GetGUID(); break;
|
||||
case 17852: Thrall = pCreature->GetGUID(); break;
|
||||
case 17948: TyrandeWhisperwind = pCreature->GetGUID(); break;
|
||||
case 17767: RageWinterchill = creature->GetGUID(); break;
|
||||
case 17808: Anetheron = creature->GetGUID(); break;
|
||||
case 17888: Kazrogal = creature->GetGUID(); break;
|
||||
case 17842: Azgalor = creature->GetGUID(); break;
|
||||
case 17968: Archimonde = creature->GetGUID(); break;
|
||||
case 17772: JainaProudmoore = creature->GetGUID(); break;
|
||||
case 17852: Thrall = creature->GetGUID(); break;
|
||||
case 17948: TyrandeWhisperwind = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -188,12 +188,12 @@ public:
|
||||
if (ArchiYell)break;
|
||||
ArchiYell = true;
|
||||
|
||||
Creature* pCreature = instance->GetCreature(Azgalor);
|
||||
if (pCreature)
|
||||
Creature* creature = instance->GetCreature(Azgalor);
|
||||
if (creature)
|
||||
{
|
||||
Creature* pUnit = pCreature->SummonCreature(21987,pCreature->GetPositionX(),pCreature->GetPositionY(),pCreature->GetPositionZ(),0,TEMPSUMMON_TIMED_DESPAWN,10000);
|
||||
Creature* pUnit = creature->SummonCreature(21987,creature->GetPositionX(),creature->GetPositionY(),creature->GetPositionZ(),0,TEMPSUMMON_TIMED_DESPAWN,10000);
|
||||
|
||||
Map* pMap = pCreature->GetMap();
|
||||
Map* pMap = creature->GetMap();
|
||||
if (pMap->IsDungeon() && pUnit)
|
||||
{
|
||||
pUnit->SetVisible(false);
|
||||
|
||||
@@ -66,54 +66,54 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_ARTHAS:
|
||||
uiArthas = pCreature->GetGUID();
|
||||
uiArthas = creature->GetGUID();
|
||||
break;
|
||||
case NPC_MEATHOOK:
|
||||
uiMeathook = pCreature->GetGUID();
|
||||
uiMeathook = creature->GetGUID();
|
||||
break;
|
||||
case NPC_SALRAMM:
|
||||
uiSalramm = pCreature->GetGUID();
|
||||
uiSalramm = creature->GetGUID();
|
||||
break;
|
||||
case NPC_EPOCH:
|
||||
uiEpoch = pCreature->GetGUID();
|
||||
uiEpoch = creature->GetGUID();
|
||||
break;
|
||||
case NPC_MAL_GANIS:
|
||||
uiMalGanis = pCreature->GetGUID();
|
||||
uiMalGanis = creature->GetGUID();
|
||||
break;
|
||||
case NPC_INFINITE:
|
||||
uiInfinite = pCreature->GetGUID();
|
||||
uiInfinite = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_SHKAF_GATE:
|
||||
uiShkafGate = pGo->GetGUID();
|
||||
uiShkafGate = go->GetGUID();
|
||||
break;
|
||||
case GO_MALGANIS_GATE_1:
|
||||
uiMalGanisGate1 = pGo->GetGUID();
|
||||
uiMalGanisGate1 = go->GetGUID();
|
||||
break;
|
||||
case GO_MALGANIS_GATE_2:
|
||||
uiMalGanisGate2 = pGo->GetGUID();
|
||||
uiMalGanisGate2 = go->GetGUID();
|
||||
break;
|
||||
case GO_EXIT_GATE:
|
||||
uiExitGate = pGo->GetGUID();
|
||||
uiExitGate = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
HandleGameObject(uiExitGate,true);
|
||||
break;
|
||||
case GO_MALGANIS_CHEST_N:
|
||||
case GO_MALGANIS_CHEST_H:
|
||||
uiMalGanisChest = pGo->GetGUID();
|
||||
uiMalGanisChest = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -144,8 +144,8 @@ public:
|
||||
break;
|
||||
case DONE:
|
||||
HandleGameObject(uiExitGate, true);
|
||||
if (GameObject *pGo = instance->GetGameObject(uiMalGanisChest))
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
if (GameObject* go = instance->GetGameObject(uiMalGanisChest))
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -130,10 +130,10 @@ public:
|
||||
pPlayer->SendUpdateWorldState(WORLD_STATE_BM,0);
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (pCreature->GetEntry() == C_MEDIVH)
|
||||
MedivhGUID = pCreature->GetGUID();
|
||||
if (creature->GetEntry() == C_MEDIVH)
|
||||
MedivhGUID = creature->GetGUID();
|
||||
}
|
||||
|
||||
//what other conditions to check?
|
||||
@@ -272,7 +272,7 @@ public:
|
||||
//normalize Z-level if we can, if rift is not at ground level.
|
||||
pos.m_positionZ = std::max(me->GetMap()->GetHeight(pos.m_positionX, pos.m_positionY, MAX_HEIGHT), me->GetMap()->GetWaterLevel(pos.m_positionX, pos.m_positionY));
|
||||
|
||||
if (Creature *summon = me->SummonCreature(entry, pos, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 600000))
|
||||
if (Creature* summon = me->SummonCreature(entry, pos, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 600000))
|
||||
return summon;
|
||||
|
||||
sLog.outDebug("TSCR: Instance Dark Portal: What just happened there? No boss, no loot, no fun...");
|
||||
@@ -292,7 +292,7 @@ public:
|
||||
|
||||
CurrentRiftId = tmp;
|
||||
|
||||
Creature *pTemp = pMedivh->SummonCreature(C_TIME_RIFT,
|
||||
Creature* pTemp = pMedivh->SummonCreature(C_TIME_RIFT,
|
||||
PortalLocation[tmp][0],PortalLocation[tmp][1],PortalLocation[tmp][2],PortalLocation[tmp][3],
|
||||
TEMPSUMMON_CORPSE_DESPAWN,0);
|
||||
if (pTemp)
|
||||
@@ -300,7 +300,7 @@ public:
|
||||
pTemp->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
pTemp->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
|
||||
if (Creature *pBoss = SummonedPortalBoss(pTemp))
|
||||
if (Creature* pBoss = SummonedPortalBoss(pTemp))
|
||||
{
|
||||
if (pBoss->GetEntry() == C_AEONUS)
|
||||
pBoss->AddThreat(pMedivh,0.0f);
|
||||
|
||||
@@ -101,18 +101,18 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case THRALL_ENTRY:
|
||||
ThrallGUID = pCreature->GetGUID();
|
||||
ThrallGUID = creature->GetGUID();
|
||||
break;
|
||||
case TARETHA_ENTRY:
|
||||
TarethaGUID = pCreature->GetGUID();
|
||||
TarethaGUID = creature->GetGUID();
|
||||
break;
|
||||
case EPOCH_ENTRY:
|
||||
EpochGUID = pCreature->GetGUID();
|
||||
EpochGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -67,33 +67,30 @@ public:
|
||||
m_uiEruptTimer = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case NPC_ONYXIA:
|
||||
m_uiOnyxiasGUID = pCreature->GetGUID();
|
||||
m_uiOnyxiasGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if ((pGo->GetGOInfo()->displayId == 4392 || pGo->GetGOInfo()->displayId == 4472) && pGo->GetGOInfo()->trap.spellId == 17731)
|
||||
if ((go->GetGOInfo()->displayId == 4392 || go->GetGOInfo()->displayId == 4472) && go->GetGOInfo()->trap.spellId == 17731)
|
||||
{
|
||||
if (add)
|
||||
FloorEruptionGUID[0].insert(std::make_pair(pGo->GetGUID(),0));
|
||||
else
|
||||
FloorEruptionGUID[0].erase(pGo->GetGUID());
|
||||
FloorEruptionGUID[0].insert(std::make_pair(go->GetGUID(),0));
|
||||
return;
|
||||
}
|
||||
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_WHELP_SPAWNER:
|
||||
Position pGoPos;
|
||||
pGo->GetPosition(&pGoPos);
|
||||
if (Creature* pTemp = pGo->SummonCreature(NPC_WHELP,pGoPos,TEMPSUMMON_CORPSE_DESPAWN))
|
||||
Position goPos;
|
||||
go->GetPosition(&goPos);
|
||||
if (Creature* pTemp = go->SummonCreature(NPC_WHELP,goPos,TEMPSUMMON_CORPSE_DESPAWN))
|
||||
{
|
||||
pTemp->SetInCombatWithZone();
|
||||
++m_uiManyWhelpsCounter;
|
||||
@@ -102,9 +99,18 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectRemove(GameObject* go)
|
||||
{
|
||||
if ((go->GetGOInfo()->displayId == 4392 || go->GetGOInfo()->displayId == 4472) && go->GetGOInfo()->trap.spellId == 17731)
|
||||
{
|
||||
FloorEruptionGUID[0].erase(go->GetGUID());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
void FloorEruption(uint64 floorEruptedGUID)
|
||||
{
|
||||
if (GameObject *pFloorEruption = instance->GetGameObject(floorEruptedGUID))
|
||||
if (GameObject* pFloorEruption = instance->GetGameObject(floorEruptedGUID))
|
||||
{
|
||||
//THIS GOB IS A TRAP - What shall i do? =(
|
||||
//Cast it spell? Copyed Heigan method
|
||||
|
||||
@@ -99,14 +99,14 @@ public:
|
||||
OUT_LOAD_INST_DATA_COMPLETE;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_GONG:
|
||||
uiGongGUID = pGo->GetGUID();
|
||||
uiGongGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
@@ -123,19 +123,19 @@ public:
|
||||
{
|
||||
case 9:
|
||||
case 14:
|
||||
if (GameObject* pGo = instance->GetGameObject(uiGongGUID))
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
if (GameObject* go = instance->GetGameObject(uiGongGUID))
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
break;
|
||||
case 1:
|
||||
case 10:
|
||||
case 16:
|
||||
{
|
||||
GameObject* pGo = instance->GetGameObject(uiGongGUID);
|
||||
GameObject* go = instance->GetGameObject(uiGongGUID);
|
||||
|
||||
if (!pGo)
|
||||
if (!go)
|
||||
return;
|
||||
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
|
||||
uint32 uiCreature = 0;
|
||||
uint8 uiSummonTimes = 0;
|
||||
@@ -158,17 +158,17 @@ public:
|
||||
}
|
||||
|
||||
|
||||
if (Creature* pCreature = pGo->SummonCreature(uiCreature,2502.635f,844.140f,46.896f,0.633f))
|
||||
if (Creature* creature = go->SummonCreature(uiCreature,2502.635f,844.140f,46.896f,0.633f))
|
||||
{
|
||||
if (uiGongWaves == 10 || uiGongWaves == 1)
|
||||
{
|
||||
for (uint8 i = 0; i < uiSummonTimes; ++i)
|
||||
{
|
||||
if (Creature* pSummon = pGo->SummonCreature(uiCreature,2502.635f + float(irand(-5,5)),844.140f + float(irand(-5,5)),46.896f,0.633f))
|
||||
if (Creature* pSummon = go->SummonCreature(uiCreature,2502.635f + float(irand(-5,5)),844.140f + float(irand(-5,5)),46.896f,0.633f))
|
||||
pSummon->GetMotionMaster()->MovePoint(0,2533.479f + float(irand(-5,5)),870.020f + float(irand(-5,5)),47.678f);
|
||||
}
|
||||
}
|
||||
pCreature->GetMotionMaster()->MovePoint(0,2533.479f + float(irand(-5,5)),870.020f + float(irand(-5,5)),47.678f);
|
||||
creature->GetMotionMaster()->MovePoint(0,2533.479f + float(irand(-5,5)),870.020f + float(irand(-5,5)),47.678f);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -69,11 +69,11 @@ public:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*apply*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 21099: DoorWardGUID = pGo->GetGUID(); break;
|
||||
case 21099: DoorWardGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -80,27 +80,27 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case CREATURE_KURINAXX:
|
||||
uiKurinaxx = pCreature->GetGUID();
|
||||
uiKurinaxx = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_RAJAXX:
|
||||
uiRajaxx = pCreature->GetGUID();
|
||||
uiRajaxx = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_MOAM:
|
||||
uiMoam = pCreature->GetGUID();
|
||||
uiMoam = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_BURU:
|
||||
uiBuru = pCreature->GetGUID();
|
||||
uiBuru = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_AYAMISS:
|
||||
uiAyamiss = pCreature->GetGUID();
|
||||
uiAyamiss = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_OSSIRIAN:
|
||||
uiOssirian = pCreature->GetGUID();
|
||||
uiOssirian = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -71,15 +71,15 @@ public:
|
||||
CthunPhase = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case 15263: SkeramGUID = pCreature->GetGUID(); break;
|
||||
case 15544: VemGUID = pCreature->GetGUID(); break;
|
||||
case 15511: KriGUID = pCreature->GetGUID(); break;
|
||||
case 15276: VeklorGUID = pCreature->GetGUID(); break;
|
||||
case 15275: VeknilashGUID = pCreature->GetGUID(); break;
|
||||
case 15263: SkeramGUID = creature->GetGUID(); break;
|
||||
case 15544: VemGUID = creature->GetGUID(); break;
|
||||
case 15511: KriGUID = creature->GetGUID(); break;
|
||||
case 15276: VeklorGUID = creature->GetGUID(); break;
|
||||
case 15275: VeknilashGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -55,10 +55,10 @@ public:
|
||||
NaralexGUID = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (pCreature->GetEntry() == DATA_NARALEX)
|
||||
NaralexGUID = pCreature->GetGUID();
|
||||
if (creature->GetEntry() == DATA_NARALEX)
|
||||
NaralexGUID = creature->GetGUID();
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
|
||||
@@ -120,48 +120,48 @@ public:
|
||||
GahzRillaEncounter = NOT_STARTED;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case ENTRY_ZUMRAH:
|
||||
ZumrahGUID = pCreature->GetGUID();
|
||||
ZumrahGUID = creature->GetGUID();
|
||||
break;
|
||||
case ENTRY_BLY:
|
||||
BlyGUID = pCreature->GetGUID();
|
||||
pCreature->SetReactState(REACT_PASSIVE); // starts out passive (in a cage)
|
||||
BlyGUID = creature->GetGUID();
|
||||
creature->SetReactState(REACT_PASSIVE); // starts out passive (in a cage)
|
||||
break;
|
||||
case ENTRY_RAVEN:
|
||||
RavenGUID = pCreature->GetGUID();
|
||||
pCreature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
RavenGUID = creature->GetGUID();
|
||||
creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
break;
|
||||
case ENTRY_ORO:
|
||||
OroGUID = pCreature->GetGUID();
|
||||
pCreature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
OroGUID = creature->GetGUID();
|
||||
creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
break;
|
||||
case ENTRY_WEEGLI:
|
||||
WeegliGUID = pCreature->GetGUID();
|
||||
pCreature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
WeegliGUID = creature->GetGUID();
|
||||
creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
break;
|
||||
case ENTRY_MURTA:
|
||||
MurtaGUID = pCreature->GetGUID();
|
||||
pCreature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
MurtaGUID = creature->GetGUID();
|
||||
creature->SetReactState(REACT_PASSIVE);// starts out passive (in a cage)
|
||||
break;
|
||||
case NPC_GAHZRILLA:
|
||||
if (GahzRillaEncounter >= IN_PROGRESS)
|
||||
pCreature->DisappearAndDie();
|
||||
creature->DisappearAndDie();
|
||||
else
|
||||
GahzRillaEncounter = IN_PROGRESS;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*apply*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_END_DOOR:
|
||||
EndDoorGUID = pGo->GetGUID();
|
||||
EndDoorGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,36 +69,36 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 28684: uiKrikthir = pCreature->GetGUID(); break;
|
||||
case 28921: uiHadronox = pCreature->GetGUID(); break;
|
||||
case 29120: uiAnubarak = pCreature->GetGUID(); break;
|
||||
case 28730: uiWatcherGashra = pCreature->GetGUID(); break;
|
||||
case 28731: uiWatcherSilthik = pCreature->GetGUID(); break;
|
||||
case 28729: uiWatcherNarjil = pCreature->GetGUID(); break;
|
||||
case 28684: uiKrikthir = creature->GetGUID(); break;
|
||||
case 28921: uiHadronox = creature->GetGUID(); break;
|
||||
case 29120: uiAnubarak = creature->GetGUID(); break;
|
||||
case 28730: uiWatcherGashra = creature->GetGUID(); break;
|
||||
case 28731: uiWatcherSilthik = creature->GetGUID(); break;
|
||||
case 28729: uiWatcherNarjil = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch (pGo->GetEntry())
|
||||
switch (go->GetEntry())
|
||||
{
|
||||
case 192395:
|
||||
uiKrikthirDoor = pGo->GetGUID();
|
||||
uiKrikthirDoor = go->GetGUID();
|
||||
if (auiEncounter[0] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
HandleGameObject(NULL,true,go);
|
||||
break;
|
||||
case 192396:
|
||||
uiAnubarakDoor[0] = pGo->GetGUID();
|
||||
uiAnubarakDoor[0] = go->GetGUID();
|
||||
break;
|
||||
case 192397:
|
||||
uiAnubarakDoor[1] = pGo->GetGUID();
|
||||
uiAnubarakDoor[1] = go->GetGUID();
|
||||
break;
|
||||
case 192398:
|
||||
uiAnubarakDoor[2] = pGo->GetGUID();
|
||||
uiAnubarakDoor[2] = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -94,43 +94,43 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 29309: Elder_Nadox = pCreature->GetGUID(); break;
|
||||
case 29308: Prince_Taldaram = pCreature->GetGUID(); break;
|
||||
case 29310: Jedoga_Shadowseeker = pCreature->GetGUID(); break;
|
||||
case 29311: Herald_Volazj = pCreature->GetGUID(); break;
|
||||
case 30258: Amanitar = pCreature->GetGUID(); break;
|
||||
case 30114: InitiandGUIDs.insert(pCreature->GetGUID()); break;
|
||||
case 29309: Elder_Nadox = creature->GetGUID(); break;
|
||||
case 29308: Prince_Taldaram = creature->GetGUID(); break;
|
||||
case 29310: Jedoga_Shadowseeker = creature->GetGUID(); break;
|
||||
case 29311: Herald_Volazj = creature->GetGUID(); break;
|
||||
case 30258: Amanitar = creature->GetGUID(); break;
|
||||
case 30114: InitiandGUIDs.insert(creature->GetGUID()); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 193564: Prince_TaldaramPlatform = pGo->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE) HandleGameObject(NULL,true,pGo); break;
|
||||
case 193093: Prince_TaldaramSpheres[0] = pGo->GetGUID();
|
||||
case 193564: Prince_TaldaramPlatform = go->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE) HandleGameObject(NULL,true,go); break;
|
||||
case 193093: Prince_TaldaramSpheres[0] = go->GetGUID();
|
||||
if (spheres[0] == IN_PROGRESS)
|
||||
{
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
else pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
else go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
case 193094: Prince_TaldaramSpheres[1] = pGo->GetGUID();
|
||||
case 193094: Prince_TaldaramSpheres[1] = go->GetGUID();
|
||||
if (spheres[1] == IN_PROGRESS)
|
||||
{
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
else pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
else go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
case 192236: Prince_TaldaramGate = pGo->GetGUID(); // Web gate past Prince Taldaram
|
||||
if (m_auiEncounter[1] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 192236: Prince_TaldaramGate = go->GetGUID(); // Web gate past Prince Taldaram
|
||||
if (m_auiEncounter[1] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -99,7 +99,7 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*bAdd*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
uint32 TeamInInstance = 0;
|
||||
@@ -110,56 +110,56 @@ public:
|
||||
TeamInInstance = pPlayer->GetTeam();
|
||||
}
|
||||
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
// Champions
|
||||
case VEHICLE_MOKRA_SKILLCRUSHER_MOUNT:
|
||||
if (TeamInInstance == HORDE)
|
||||
pCreature->UpdateEntry(VEHICLE_MARSHAL_JACOB_ALERIUS_MOUNT, ALLIANCE);
|
||||
creature->UpdateEntry(VEHICLE_MARSHAL_JACOB_ALERIUS_MOUNT, ALLIANCE);
|
||||
break;
|
||||
case VEHICLE_ERESSEA_DAWNSINGER_MOUNT:
|
||||
if (TeamInInstance == HORDE)
|
||||
pCreature->UpdateEntry(VEHICLE_AMBROSE_BOLTSPARK_MOUNT, ALLIANCE);
|
||||
creature->UpdateEntry(VEHICLE_AMBROSE_BOLTSPARK_MOUNT, ALLIANCE);
|
||||
break;
|
||||
case VEHICLE_RUNOK_WILDMANE_MOUNT:
|
||||
if (TeamInInstance == HORDE)
|
||||
pCreature->UpdateEntry(VEHICLE_COLOSOS_MOUNT, ALLIANCE);
|
||||
creature->UpdateEntry(VEHICLE_COLOSOS_MOUNT, ALLIANCE);
|
||||
break;
|
||||
case VEHICLE_ZUL_TORE_MOUNT:
|
||||
if (TeamInInstance == HORDE)
|
||||
pCreature->UpdateEntry(VEHICLE_EVENSONG_MOUNT, ALLIANCE);
|
||||
creature->UpdateEntry(VEHICLE_EVENSONG_MOUNT, ALLIANCE);
|
||||
break;
|
||||
case VEHICLE_DEATHSTALKER_VESCERI_MOUNT:
|
||||
if (TeamInInstance == HORDE)
|
||||
pCreature->UpdateEntry(VEHICLE_LANA_STOUTHAMMER_MOUNT, ALLIANCE);
|
||||
creature->UpdateEntry(VEHICLE_LANA_STOUTHAMMER_MOUNT, ALLIANCE);
|
||||
break;
|
||||
// Coliseum Announcer || Just NPC_JAEREN must be spawned.
|
||||
case NPC_JAEREN:
|
||||
uiAnnouncerGUID = pCreature->GetGUID();
|
||||
uiAnnouncerGUID = creature->GetGUID();
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_ARELAS,ALLIANCE);
|
||||
creature->UpdateEntry(NPC_ARELAS,ALLIANCE);
|
||||
break;
|
||||
case VEHICLE_ARGENT_WARHORSE:
|
||||
case VEHICLE_ARGENT_BATTLEWORG:
|
||||
VehicleList.push_back(pCreature->GetGUID());
|
||||
VehicleList.push_back(creature->GetGUID());
|
||||
break;
|
||||
case NPC_EADRIC:
|
||||
case NPC_PALETRESS:
|
||||
uiArgentChampionGUID = pCreature->GetGUID();
|
||||
uiArgentChampionGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGO, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGO->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_MAIN_GATE:
|
||||
uiMainGateGUID = pGO->GetGUID();
|
||||
uiMainGateGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_CHAMPIONS_LOOT:
|
||||
case GO_CHAMPIONS_LOOT_H:
|
||||
uiChampionLootGUID = pGO->GetGUID();
|
||||
uiChampionLootGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -149,63 +149,63 @@ public:
|
||||
void OpenDoor(uint64 guid)
|
||||
{
|
||||
if (!guid) return;
|
||||
GameObject* pGo = instance->GetGameObject(guid);
|
||||
if (pGo) pGo->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
|
||||
GameObject* go = instance->GetGameObject(guid);
|
||||
if (go) go->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
|
||||
}
|
||||
|
||||
void CloseDoor(uint64 guid)
|
||||
{
|
||||
if (!guid) return;
|
||||
GameObject* pGo = instance->GetGameObject(guid);
|
||||
if (pGo) pGo->SetGoState(GO_STATE_READY);
|
||||
GameObject* go = instance->GetGameObject(guid);
|
||||
if (go) go->SetGoState(GO_STATE_READY);
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_BARRENT: m_uiBarrentGUID = pCreature->GetGUID(); break;
|
||||
case NPC_TIRION: m_uiTirionGUID = pCreature->GetGUID(); break;
|
||||
case NPC_FIZZLEBANG: m_uiFizzlebangGUID = pCreature->GetGUID(); break;
|
||||
case NPC_GARROSH: m_uiGarroshGUID = pCreature->GetGUID(); break;
|
||||
case NPC_VARIAN: m_uiVarianGUID = pCreature->GetGUID(); break;
|
||||
case NPC_BARRENT: m_uiBarrentGUID = creature->GetGUID(); break;
|
||||
case NPC_TIRION: m_uiTirionGUID = creature->GetGUID(); break;
|
||||
case NPC_FIZZLEBANG: m_uiFizzlebangGUID = creature->GetGUID(); break;
|
||||
case NPC_GARROSH: m_uiGarroshGUID = creature->GetGUID(); break;
|
||||
case NPC_VARIAN: m_uiVarianGUID = creature->GetGUID(); break;
|
||||
|
||||
case NPC_GORMOK: m_uiGormokGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ACIDMAW: m_uiAcidmawGUID = pCreature->GetGUID(); break;
|
||||
case NPC_DREADSCALE: m_uiDreadscaleGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ICEHOWL: m_uiIcehowlGUID = pCreature->GetGUID(); break;
|
||||
case NPC_JARAXXUS: m_uiJaraxxusGUID = pCreature->GetGUID(); break;
|
||||
case NPC_CHAMPIONS_CONTROLLER: m_uiChampionsControllerGUID = pCreature->GetGUID(); break;
|
||||
case NPC_DARKBANE: m_uiDarkbaneGUID = pCreature->GetGUID(); break;
|
||||
case NPC_LIGHTBANE: m_uiLightbaneGUID = pCreature->GetGUID(); break;
|
||||
case NPC_ANUBARAK: m_uiAnubarakGUID = pCreature->GetGUID(); break;
|
||||
case NPC_GORMOK: m_uiGormokGUID = creature->GetGUID(); break;
|
||||
case NPC_ACIDMAW: m_uiAcidmawGUID = creature->GetGUID(); break;
|
||||
case NPC_DREADSCALE: m_uiDreadscaleGUID = creature->GetGUID(); break;
|
||||
case NPC_ICEHOWL: m_uiIcehowlGUID = creature->GetGUID(); break;
|
||||
case NPC_JARAXXUS: m_uiJaraxxusGUID = creature->GetGUID(); break;
|
||||
case NPC_CHAMPIONS_CONTROLLER: m_uiChampionsControllerGUID = creature->GetGUID(); break;
|
||||
case NPC_DARKBANE: m_uiDarkbaneGUID = creature->GetGUID(); break;
|
||||
case NPC_LIGHTBANE: m_uiLightbaneGUID = creature->GetGUID(); break;
|
||||
case NPC_ANUBARAK: m_uiAnubarakGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGO, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGO->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_CRUSADERS_CACHE_10:
|
||||
if (instance->GetSpawnMode() == RAID_DIFFICULTY_10MAN_NORMAL)
|
||||
m_uiCrusadersCacheGUID = pGO->GetGUID();
|
||||
m_uiCrusadersCacheGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_CRUSADERS_CACHE_25:
|
||||
if (instance->GetSpawnMode() == RAID_DIFFICULTY_25MAN_NORMAL)
|
||||
m_uiCrusadersCacheGUID = pGO->GetGUID();
|
||||
m_uiCrusadersCacheGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_CRUSADERS_CACHE_10_H:
|
||||
if (instance->GetSpawnMode() == RAID_DIFFICULTY_10MAN_HEROIC)
|
||||
m_uiCrusadersCacheGUID = pGO->GetGUID();
|
||||
m_uiCrusadersCacheGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_CRUSADERS_CACHE_25_H:
|
||||
if (instance->GetSpawnMode() == RAID_DIFFICULTY_25MAN_HEROIC)
|
||||
m_uiCrusadersCacheGUID = pGO->GetGUID();
|
||||
m_uiCrusadersCacheGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_ARGENT_COLISEUM_FLOOR: m_uiFloorGUID = pGO->GetGUID(); break;
|
||||
case GO_MAIN_GATE_DOOR: m_uiMainGateDoorGUID = pGO->GetGUID(); break;
|
||||
case GO_EAST_PORTCULLIS: m_uiEastPortcullisGUID = pGO->GetGUID(); break;
|
||||
case GO_WEB_DOOR: m_uiWebDoorGUID = pGO->GetGUID(); break;
|
||||
case GO_ARGENT_COLISEUM_FLOOR: m_uiFloorGUID = go->GetGUID(); break;
|
||||
case GO_MAIN_GATE_DOOR: m_uiMainGateDoorGUID = go->GetGUID(); break;
|
||||
case GO_EAST_PORTCULLIS: m_uiEastPortcullisGUID = go->GetGUID(); break;
|
||||
case GO_WEB_DOOR: m_uiWebDoorGUID = go->GetGUID(); break;
|
||||
|
||||
case GO_TRIBUTE_CHEST_10H_25:
|
||||
case GO_TRIBUTE_CHEST_10H_45:
|
||||
@@ -215,7 +215,7 @@ public:
|
||||
case GO_TRIBUTE_CHEST_25H_45:
|
||||
case GO_TRIBUTE_CHEST_25H_50:
|
||||
case GO_TRIBUTE_CHEST_25H_99:
|
||||
m_uiTributeChestGUID = pGO->GetGUID(); break;
|
||||
m_uiTributeChestGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -88,40 +88,40 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_NOVOS_CRYSTAL_1:
|
||||
uiNovosCrystal1 = pGo->GetGUID();
|
||||
uiNovosCrystal1 = go->GetGUID();
|
||||
break;
|
||||
case GO_NOVOS_CRYSTAL_2:
|
||||
uiNovosCrystal2 = pGo->GetGUID();
|
||||
uiNovosCrystal2 = go->GetGUID();
|
||||
break;
|
||||
case GO_NOVOS_CRYSTAL_3:
|
||||
uiNovosCrystal3 = pGo->GetGUID();
|
||||
uiNovosCrystal3 = go->GetGUID();
|
||||
break;
|
||||
case GO_NOVOS_CRYSTAL_4:
|
||||
uiNovosCrystal4 = pGo->GetGUID();
|
||||
uiNovosCrystal4 = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_TROLLGORE:
|
||||
uiTrollgore = pCreature->GetGUID();
|
||||
uiTrollgore = creature->GetGUID();
|
||||
break;
|
||||
case NPC_NOVOS:
|
||||
uiNovos = pCreature->GetGUID();
|
||||
uiNovos = creature->GetGUID();
|
||||
break;
|
||||
case NPC_KING_DRED:
|
||||
uiDred = pCreature->GetGUID();
|
||||
uiDred = creature->GetGUID();
|
||||
break;
|
||||
case NPC_THARON_JA:
|
||||
uiTharonJa = pCreature->GetGUID();
|
||||
uiTharonJa = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ class instance_forge_of_souls : public InstanceMapScript
|
||||
teamInInstance = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
if (!players.isEmpty())
|
||||
|
||||
@@ -150,67 +150,61 @@ public:
|
||||
uiEncounter[i] = NOT_STARTED;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool add)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (!add)
|
||||
return;
|
||||
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
if (!players.isEmpty())
|
||||
if (Player* pPlayer = players.begin()->getSource())
|
||||
uiTeamInInstance = pPlayer->GetTeam();
|
||||
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_FALRIC:
|
||||
uiFalric = pCreature->GetGUID();
|
||||
uiFalric = creature->GetGUID();
|
||||
break;
|
||||
case NPC_MARWYN:
|
||||
uiMarwyn = pCreature->GetGUID();
|
||||
uiMarwyn = creature->GetGUID();
|
||||
break;
|
||||
case NPC_LICH_KING_EVENT:
|
||||
uiLichKingEvent = pCreature->GetGUID();
|
||||
uiLichKingEvent = creature->GetGUID();
|
||||
break;
|
||||
case NPC_JAINA_PART1:
|
||||
uiJainaPart1 = pCreature->GetGUID();
|
||||
uiJainaPart1 = creature->GetGUID();
|
||||
break;
|
||||
case NPC_SYLVANAS_PART1:
|
||||
uiSylvanasPart1 = pCreature->GetGUID();
|
||||
uiSylvanasPart1 = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if (!add)
|
||||
return;
|
||||
|
||||
// TODO: init state depending on encounters
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_FROSTMOURNE:
|
||||
uiFrostmourne = pGo->GetGUID();
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, false, pGo);
|
||||
uiFrostmourne = go->GetGUID();
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, false, go);
|
||||
break;
|
||||
case GO_FROSTMOURNE_ALTAR:
|
||||
uiFrostmourneAltar = pGo->GetGUID();
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, true, pGo);
|
||||
uiFrostmourneAltar = go->GetGUID();
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_FRONT_DOOR:
|
||||
uiFrontDoor = pGo->GetGUID();
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, true, pGo);
|
||||
uiFrontDoor = go->GetGUID();
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
HandleGameObject(0, true, go);
|
||||
break;
|
||||
case GO_ARTHAS_DOOR:
|
||||
uiArthasDoor = pGo->GetGUID();
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
uiArthasDoor = go->GetGUID();
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
|
||||
if (uiEncounter[1] == DONE)
|
||||
HandleGameObject(0, true, pGo);
|
||||
HandleGameObject(0, true, go);
|
||||
else
|
||||
HandleGameObject(0, false, pGo);
|
||||
HandleGameObject(0, false, go);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -333,13 +327,13 @@ public:
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
if (Creature *pFalric = instance->GetCreature(uiFalric))
|
||||
if (Creature* pFalric = instance->GetCreature(uiFalric))
|
||||
SpawnWave(pFalric);
|
||||
break;
|
||||
case 5:
|
||||
if (GetData(DATA_FALRIC_EVENT) == DONE)
|
||||
events.ScheduleEvent(EVENT_NEXT_WAVE, 10000);
|
||||
else if (Creature *pFalric = instance->GetCreature(uiFalric))
|
||||
else if (Creature* pFalric = instance->GetCreature(uiFalric))
|
||||
if (pFalric->AI())
|
||||
pFalric->AI()->DoAction(ACTION_ENTER_COMBAT);
|
||||
break;
|
||||
@@ -347,12 +341,12 @@ public:
|
||||
case 7:
|
||||
case 8:
|
||||
case 9:
|
||||
if (Creature *pMarwyn = instance->GetCreature(uiMarwyn))
|
||||
if (Creature* pMarwyn = instance->GetCreature(uiMarwyn))
|
||||
SpawnWave(pMarwyn);
|
||||
break;
|
||||
case 10:
|
||||
if (GetData(DATA_MARWYN_EVENT) != DONE) // wave should not have been started if DONE. Check anyway to avoid bug exploit!
|
||||
if (Creature *pMarwyn = instance->GetCreature(uiMarwyn))
|
||||
if (Creature* pMarwyn = instance->GetCreature(uiMarwyn))
|
||||
if (pMarwyn->AI())
|
||||
pMarwyn->AI()->DoAction(ACTION_ENTER_COMBAT);
|
||||
break;
|
||||
@@ -383,7 +377,7 @@ public:
|
||||
}
|
||||
|
||||
// spawn a wave on behalf of the summoner.
|
||||
void SpawnWave(Creature *pSummoner)
|
||||
void SpawnWave(Creature* pSummoner)
|
||||
{
|
||||
uint32 index;
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
|
||||
@@ -82,57 +82,57 @@ public:
|
||||
uiTeamInInstance = pPlayer->GetTeam();
|
||||
}
|
||||
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case CREATURE_KRICK:
|
||||
uiKrick = pCreature->GetGUID();
|
||||
uiKrick = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case CREATURE_ICK:
|
||||
uiIck = pCreature->GetGUID();
|
||||
uiIck = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case CREATURE_GARFROST:
|
||||
uiGarfrost = pCreature->GetGUID();
|
||||
uiGarfrost = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case CREATURE_TYRANNUS:
|
||||
uiTyrannus = pCreature->GetGUID();
|
||||
uiTyrannus = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case CREATURE_RIMEFANG:
|
||||
uiRimefang = pCreature->GetGUID();
|
||||
uiRimefang = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case NPC_SYLVANAS_PART1:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_JAINA_PART1, ALLIANCE);
|
||||
uiJainaOrSylvanas1 = pCreature->GetGUID();
|
||||
creature->UpdateEntry(NPC_JAINA_PART1, ALLIANCE);
|
||||
uiJainaOrSylvanas1 = creature->GetGUID();
|
||||
break;
|
||||
case NPC_SYLVANAS_PART2:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_JAINA_PART2, ALLIANCE);
|
||||
uiJainaOrSylvanas2 = pCreature->GetGUID();
|
||||
creature->UpdateEntry(NPC_JAINA_PART2, ALLIANCE);
|
||||
uiJainaOrSylvanas2 = creature->GetGUID();
|
||||
break;
|
||||
case NPC_KILARA:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_ELANDRA, ALLIANCE);
|
||||
creature->UpdateEntry(NPC_ELANDRA, ALLIANCE);
|
||||
break;
|
||||
case NPC_KORALEN:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_KORLAEN, ALLIANCE);
|
||||
creature->UpdateEntry(NPC_KORLAEN, ALLIANCE);
|
||||
break;
|
||||
case NPC_CHAMPION_1_HORDE:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_CHAMPION_1_ALLIANCE, ALLIANCE);
|
||||
creature->UpdateEntry(NPC_CHAMPION_1_ALLIANCE, ALLIANCE);
|
||||
break;
|
||||
case NPC_CHAMPION_2_HORDE:
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_CHAMPION_2_ALLIANCE, ALLIANCE);
|
||||
creature->UpdateEntry(NPC_CHAMPION_2_ALLIANCE, ALLIANCE);
|
||||
break;
|
||||
case NPC_CHAMPION_3_HORDE: // No 3rd set for Alliance?
|
||||
if (uiTeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(NPC_CHAMPION_2_ALLIANCE, ALLIANCE);
|
||||
creature->UpdateEntry(NPC_CHAMPION_2_ALLIANCE, ALLIANCE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -137,115 +137,115 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case CREATURE_SLAD_RAN: uiSladRan = pCreature->GetGUID(); break;
|
||||
case CREATURE_MOORABI: uiMoorabi = pCreature->GetGUID(); break;
|
||||
case CREATURE_GALDARAH: uiGalDarah = pCreature->GetGUID(); break;
|
||||
case CREATURE_DRAKKARICOLOSSUS: uiDrakkariColossus = pCreature->GetGUID(); break;
|
||||
case CREATURE_ECK: uiEckTheFerocious = pCreature->GetGUID(); break;
|
||||
case CREATURE_SLAD_RAN: uiSladRan = creature->GetGUID(); break;
|
||||
case CREATURE_MOORABI: uiMoorabi = creature->GetGUID(); break;
|
||||
case CREATURE_GALDARAH: uiGalDarah = creature->GetGUID(); break;
|
||||
case CREATURE_DRAKKARICOLOSSUS: uiDrakkariColossus = creature->GetGUID(); break;
|
||||
case CREATURE_ECK: uiEckTheFerocious = creature->GetGUID(); break;
|
||||
case CREATURE_RUIN_DWELLER:
|
||||
if (pCreature->isAlive())
|
||||
DwellerGUIDs.insert(pCreature->GetGUID());
|
||||
if (creature->isAlive())
|
||||
DwellerGUIDs.insert(creature->GetGUID());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 192518:
|
||||
uiSladRanAltar = pGo->GetGUID();
|
||||
uiSladRanAltar = go->GetGUID();
|
||||
// Make sure that they start out as unusuable
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
{
|
||||
if (uiSladRanStatueState == GO_STATE_ACTIVE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
else
|
||||
{
|
||||
++phase;
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 192519:
|
||||
uiMoorabiAltar = pGo->GetGUID();
|
||||
uiMoorabiAltar = go->GetGUID();
|
||||
// Make sure that they start out as unusuable
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
{
|
||||
if (uiMoorabiStatueState == GO_STATE_ACTIVE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
else
|
||||
{
|
||||
++phase;
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 192520:
|
||||
uiDrakkariColossusAltar = pGo->GetGUID();
|
||||
uiDrakkariColossusAltar = go->GetGUID();
|
||||
// Make sure that they start out as unusuable
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
{
|
||||
if (uiDrakkariColossusStatueState == GO_STATE_ACTIVE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
else
|
||||
{
|
||||
++phase;
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 192564:
|
||||
uiSladRanStatue = pGo->GetGUID();
|
||||
pGo->SetGoState(uiSladRanStatueState);
|
||||
uiSladRanStatue = go->GetGUID();
|
||||
go->SetGoState(uiSladRanStatueState);
|
||||
break;
|
||||
case 192565:
|
||||
uiMoorabiStatue = pGo->GetGUID();
|
||||
pGo->SetGoState(uiMoorabiStatueState);
|
||||
uiMoorabiStatue = go->GetGUID();
|
||||
go->SetGoState(uiMoorabiStatueState);
|
||||
break;
|
||||
case 192566:
|
||||
uiGalDarahStatue = pGo->GetGUID();
|
||||
pGo->SetGoState(uiGalDarahStatueState);
|
||||
uiGalDarahStatue = go->GetGUID();
|
||||
go->SetGoState(uiGalDarahStatueState);
|
||||
break;
|
||||
case 192567:
|
||||
uiDrakkariColossusStatue = pGo->GetGUID();
|
||||
pGo->SetGoState(uiDrakkariColossusStatueState);
|
||||
uiDrakkariColossusStatue = go->GetGUID();
|
||||
go->SetGoState(uiDrakkariColossusStatueState);
|
||||
break;
|
||||
case 192632:
|
||||
uiEckTheFerociousDoor = pGo->GetGUID();
|
||||
uiEckTheFerociousDoor = go->GetGUID();
|
||||
if (bHeroicMode && m_auiEncounter[1] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
HandleGameObject(NULL,true,go);
|
||||
break;
|
||||
case 192569:
|
||||
uiEckTheFerociousDoorBehind = pGo->GetGUID();
|
||||
uiEckTheFerociousDoorBehind = go->GetGUID();
|
||||
if (bHeroicMode && m_auiEncounter[4] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
HandleGameObject(NULL,true,go);
|
||||
case 193208:
|
||||
uiGalDarahDoor1 = pGo->GetGUID();
|
||||
uiGalDarahDoor1 = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
HandleGameObject(NULL,true,go);
|
||||
break;
|
||||
case 193209:
|
||||
uiGalDarahDoor2 = pGo->GetGUID();
|
||||
uiGalDarahDoor2 = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
HandleGameObject(NULL,true,pGo);
|
||||
HandleGameObject(NULL,true,go);
|
||||
break;
|
||||
case 193188:
|
||||
uiBridge = pGo->GetGUID();
|
||||
pGo->SetGoState(uiBridgeState);
|
||||
uiBridge = go->GetGUID();
|
||||
go->SetGoState(uiBridgeState);
|
||||
break;
|
||||
case 192633:
|
||||
uiCollision = pGo->GetGUID();
|
||||
pGo->SetGoState(uiCollisionState);
|
||||
uiCollision = go->GetGUID();
|
||||
go->SetGoState(uiCollisionState);
|
||||
|
||||
// Can't spawn here with SpawnGameObject because pGo isn't added to world yet...
|
||||
// Can't spawn here with SpawnGameObject because go isn't added to world yet...
|
||||
if (uiCollisionState == GO_STATE_ACTIVE_ALTERNATIVE)
|
||||
spawnSupport = true;
|
||||
break;
|
||||
@@ -260,18 +260,18 @@ public:
|
||||
m_auiEncounter[0] = data;
|
||||
if (data == DONE)
|
||||
{
|
||||
GameObject* pGo = instance->GetGameObject(uiSladRanAltar);
|
||||
if (pGo)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
GameObject* go = instance->GetGameObject(uiSladRanAltar);
|
||||
if (go)
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
}
|
||||
break;
|
||||
case DATA_MOORABI_EVENT:
|
||||
m_auiEncounter[1] = data;
|
||||
if (data == DONE)
|
||||
{
|
||||
GameObject* pGo = instance->GetGameObject(uiMoorabiAltar);
|
||||
if (pGo)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
GameObject* go = instance->GetGameObject(uiMoorabiAltar);
|
||||
if (go)
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
if (bHeroicMode)
|
||||
HandleGameObject(uiEckTheFerociousDoor,true);
|
||||
}
|
||||
@@ -280,9 +280,9 @@ public:
|
||||
m_auiEncounter[2] = data;
|
||||
if (data == DONE)
|
||||
{
|
||||
GameObject* pGo = instance->GetGameObject(uiDrakkariColossusAltar);
|
||||
if (pGo)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
GameObject* go = instance->GetGameObject(uiDrakkariColossusAltar);
|
||||
if (go)
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_UNK1);
|
||||
}
|
||||
break;
|
||||
case DATA_GAL_DARAH_EVENT:
|
||||
@@ -506,7 +506,7 @@ class go_gundrak_altar : public GameObjectScript
|
||||
public:
|
||||
go_gundrak_altar() : GameObjectScript("go_gundrak_altar") { }
|
||||
|
||||
bool OnGossipHello(Player * /*pPlayer*/, GameObject *pGO)
|
||||
bool OnGossipHello(Player * /*pPlayer*/, GameObject* pGO)
|
||||
{
|
||||
InstanceScript *pInstance = pGO->GetInstanceScript();
|
||||
uint64 uiStatue = 0;
|
||||
|
||||
@@ -84,11 +84,8 @@ class instance_icecrown_citadel : public InstanceMapScript
|
||||
teamInInstance = player->GetTeam();
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature, bool add)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (!add)
|
||||
return;
|
||||
|
||||
if (!teamInInstance)
|
||||
{
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
@@ -178,7 +175,7 @@ class instance_icecrown_citadel : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* go, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch (go->GetEntry())
|
||||
{
|
||||
@@ -199,7 +196,7 @@ class instance_icecrown_citadel : public InstanceMapScript
|
||||
case GO_SINDRAGOSA_ENTRANCE_DOOR:
|
||||
case GO_SINDRAGOSA_SHORTCUT_ENTRANCE_DOOR:
|
||||
case GO_SINDRAGOSA_SHORTCUT_EXIT_DOOR:
|
||||
AddDoor(go, add);
|
||||
AddDoor(go, true);
|
||||
break;
|
||||
case GO_LADY_DEATHWHISPER_ELEVATOR:
|
||||
ladyDeathwisperElevator = go->GetGUID();
|
||||
|
||||
@@ -144,60 +144,73 @@ public:
|
||||
time_t minHorsemenDiedTime;
|
||||
time_t maxHorsemenDiedTime;
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool add)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 15989: SapphironGUID = add ? pCreature->GetGUID() : 0; return;
|
||||
case 15953: uiFaerlina = pCreature->GetGUID(); return;
|
||||
case 16064: uiThane = pCreature->GetGUID(); return;
|
||||
case 16065: uiLady = pCreature->GetGUID(); return;
|
||||
case 30549: uiBaron = pCreature->GetGUID(); return;
|
||||
case 16063: uiSir = pCreature->GetGUID(); return;
|
||||
case 15928: uiThaddius = pCreature->GetGUID(); return;
|
||||
case 15930: uiFeugen = pCreature->GetGUID(); return;
|
||||
case 15929: uiStalagg = pCreature->GetGUID(); return;
|
||||
case 15990: uiKelthuzad = pCreature->GetGUID(); return;
|
||||
case 15989: SapphironGUID = creature->GetGUID(); return;
|
||||
case 15953: uiFaerlina = creature->GetGUID(); return;
|
||||
case 16064: uiThane = creature->GetGUID(); return;
|
||||
case 16065: uiLady = creature->GetGUID(); return;
|
||||
case 30549: uiBaron = creature->GetGUID(); return;
|
||||
case 16063: uiSir = creature->GetGUID(); return;
|
||||
case 15928: uiThaddius = creature->GetGUID(); return;
|
||||
case 15930: uiFeugen = creature->GetGUID(); return;
|
||||
case 15929: uiStalagg = creature->GetGUID(); return;
|
||||
case 15990: uiKelthuzad = creature->GetGUID(); return;
|
||||
}
|
||||
|
||||
AddMinion(pCreature, add);
|
||||
AddMinion(creature, true);
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if (pGo->GetGOInfo()->displayId == 6785 || pGo->GetGOInfo()->displayId == 1287)
|
||||
if (go->GetGOInfo()->displayId == 6785 || go->GetGOInfo()->displayId == 1287)
|
||||
{
|
||||
uint32 section = GetEruptionSection(pGo->GetPositionX(), pGo->GetPositionY());
|
||||
if (add)
|
||||
HeiganEruptionGUID[section].insert(pGo->GetGUID());
|
||||
else
|
||||
HeiganEruptionGUID[section].erase(pGo->GetGUID());
|
||||
uint32 section = GetEruptionSection(go->GetPositionX(), go->GetPositionY());
|
||||
HeiganEruptionGUID[section].insert(go->GetGUID());
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_GOTHIK_GATE:
|
||||
GothikGateGUID = go->GetGUID();
|
||||
go->SetGoState(gothikDoorState);
|
||||
break;
|
||||
case GO_HORSEMEN_CHEST: HorsemenChestGUID = go->GetGUID(); break;
|
||||
case GO_HORSEMEN_CHEST_HERO: HorsemenChestGUID = go->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL01: uiPortals[0] = go->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL02: uiPortals[1] = go->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL03: uiPortals[2] = go->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL04: uiPortals[3] = go->GetGUID(); break;
|
||||
case GO_KELTHUZAD_TRIGGER: uiKelthuzadTrigger = go->GetGUID(); break;
|
||||
}
|
||||
|
||||
AddDoor(go, true);
|
||||
}
|
||||
|
||||
void OnGameObjectRemove(GameObject* go)
|
||||
{
|
||||
if (go->GetGOInfo()->displayId == 6785 || go->GetGOInfo()->displayId == 1287)
|
||||
{
|
||||
uint32 section = GetEruptionSection(go->GetPositionX(), go->GetPositionY());
|
||||
|
||||
HeiganEruptionGUID[section].erase(go->GetGUID());
|
||||
return;
|
||||
}
|
||||
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_BIRTH:
|
||||
if (!add && SapphironGUID)
|
||||
if (SapphironGUID)
|
||||
{
|
||||
if (Creature *pSapphiron = instance->GetCreature(SapphironGUID))
|
||||
if (Creature* pSapphiron = instance->GetCreature(SapphironGUID))
|
||||
pSapphiron->AI()->DoAction(DATA_SAPPHIRON_BIRTH);
|
||||
return;
|
||||
}
|
||||
case GO_GOTHIK_GATE:
|
||||
GothikGateGUID = add ? pGo->GetGUID() : 0;
|
||||
pGo->SetGoState(gothikDoorState);
|
||||
break;
|
||||
case GO_HORSEMEN_CHEST: HorsemenChestGUID = add ? pGo->GetGUID() : 0; break;
|
||||
case GO_HORSEMEN_CHEST_HERO: HorsemenChestGUID = add ? pGo->GetGUID() : 0; break;
|
||||
case GO_KELTHUZAD_PORTAL01: uiPortals[0] = pGo->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL02: uiPortals[1] = pGo->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL03: uiPortals[2] = pGo->GetGUID(); break;
|
||||
case GO_KELTHUZAD_PORTAL04: uiPortals[3] = pGo->GetGUID(); break;
|
||||
case GO_KELTHUZAD_TRIGGER: uiKelthuzadTrigger = pGo->GetGUID(); break;
|
||||
}
|
||||
|
||||
AddDoor(pGo, add);
|
||||
}
|
||||
|
||||
void SetData(uint32 id, uint32 value)
|
||||
@@ -208,8 +221,8 @@ public:
|
||||
HeiganErupt(value);
|
||||
break;
|
||||
case DATA_GOTHIK_GATE:
|
||||
if (GameObject *pGothikGate = instance->GetGameObject(GothikGateGUID))
|
||||
pGothikGate->SetGoState(GOState(value));
|
||||
if (GameObject* gothikGate = instance->GetGameObject(GothikGateGUID))
|
||||
gothikGate->SetGoState(GOState(value));
|
||||
gothikDoorState = GOState(value);
|
||||
break;
|
||||
|
||||
@@ -278,7 +291,7 @@ public:
|
||||
|
||||
if (id == BOSS_HORSEMEN && state == DONE)
|
||||
{
|
||||
if (GameObject *pHorsemenChest = instance->GetGameObject(HorsemenChestGUID))
|
||||
if (GameObject* pHorsemenChest = instance->GetGameObject(HorsemenChestGUID))
|
||||
pHorsemenChest->SetRespawnTime(pHorsemenChest->GetRespawnDelay());
|
||||
}
|
||||
|
||||
@@ -294,7 +307,7 @@ public:
|
||||
|
||||
for (std::set<uint64>::const_iterator itr = HeiganEruptionGUID[i].begin(); itr != HeiganEruptionGUID[i].end(); ++itr)
|
||||
{
|
||||
if (GameObject *pHeiganEruption = instance->GetGameObject(*itr))
|
||||
if (GameObject* pHeiganEruption = instance->GetGameObject(*itr))
|
||||
{
|
||||
pHeiganEruption->SendCustomAnim();
|
||||
pHeiganEruption->CastSpell(NULL, SPELL_ERUPTION);
|
||||
|
||||
@@ -59,7 +59,7 @@ public:
|
||||
Keristrasza = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature *pCreature, bool /*bAdd*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
Map::PlayerList const &players = instance->GetPlayers();
|
||||
uint32 TeamInInstance = 0;
|
||||
@@ -69,81 +69,81 @@ public:
|
||||
if (Player* pPlayer = players.begin()->getSource())
|
||||
TeamInInstance = pPlayer->GetTeam();
|
||||
}
|
||||
switch (pCreature->GetEntry())
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case 26763:
|
||||
Anomalus = pCreature->GetGUID();
|
||||
Anomalus = creature->GetGUID();
|
||||
break;
|
||||
case 26723:
|
||||
Keristrasza = pCreature->GetGUID();
|
||||
Keristrasza = creature->GetGUID();
|
||||
break;
|
||||
// Alliance npcs are spawned by default, if you are alliance, you will fight against horde npcs.
|
||||
case 26800:
|
||||
{
|
||||
if (ServerAllowsTwoSideGroups())
|
||||
pCreature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
creature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(26799, HORDE);
|
||||
creature->UpdateEntry(26799, HORDE);
|
||||
break;
|
||||
}
|
||||
case 26802:
|
||||
{
|
||||
if (ServerAllowsTwoSideGroups())
|
||||
pCreature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
creature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(26801, HORDE);
|
||||
creature->UpdateEntry(26801, HORDE);
|
||||
break;
|
||||
}
|
||||
case 26805:
|
||||
{
|
||||
if (ServerAllowsTwoSideGroups())
|
||||
pCreature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
creature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(26803, HORDE);
|
||||
creature->UpdateEntry(26803, HORDE);
|
||||
break;
|
||||
}
|
||||
case 27949:
|
||||
{
|
||||
if (ServerAllowsTwoSideGroups())
|
||||
pCreature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
creature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(27947, HORDE);
|
||||
creature->UpdateEntry(27947, HORDE);
|
||||
break;
|
||||
}
|
||||
case 26796:
|
||||
{
|
||||
if (ServerAllowsTwoSideGroups())
|
||||
pCreature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
creature->setFaction(FACTION_HOSTILE_FOR_ALL);
|
||||
if (TeamInInstance == ALLIANCE)
|
||||
pCreature->UpdateEntry(26798, HORDE);
|
||||
creature->UpdateEntry(26798, HORDE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject *pGo, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch (pGo->GetEntry())
|
||||
switch (go->GetEntry())
|
||||
{
|
||||
case 188527:
|
||||
{
|
||||
AnomalusContainmentSphere = pGo->GetGUID();
|
||||
AnomalusContainmentSphere = go->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
}
|
||||
case 188528:
|
||||
{
|
||||
OrmoroksContainmentSphere = pGo->GetGUID();
|
||||
OrmoroksContainmentSphere = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
}
|
||||
case 188526:
|
||||
{
|
||||
TelestrasContainmentSphere = pGo->GetGUID();
|
||||
TelestrasContainmentSphere = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -169,7 +169,7 @@ public:
|
||||
{
|
||||
if (data == DONE)
|
||||
{
|
||||
GameObject *Sphere = instance->GetGameObject(TelestrasContainmentSphere);
|
||||
GameObject* Sphere = instance->GetGameObject(TelestrasContainmentSphere);
|
||||
if (Sphere)
|
||||
Sphere->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
@@ -180,7 +180,7 @@ public:
|
||||
{
|
||||
if (data == DONE)
|
||||
{
|
||||
if (GameObject *Sphere = instance->GetGameObject(AnomalusContainmentSphere))
|
||||
if (GameObject* Sphere = instance->GetGameObject(AnomalusContainmentSphere))
|
||||
Sphere->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
m_auiEncounter[1] = data;
|
||||
@@ -190,7 +190,7 @@ public:
|
||||
{
|
||||
if (data == DONE)
|
||||
{
|
||||
if (GameObject *Sphere = instance->GetGameObject(OrmoroksContainmentSphere))
|
||||
if (GameObject* Sphere = instance->GetGameObject(OrmoroksContainmentSphere))
|
||||
Sphere->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
m_auiEncounter[2] = data;
|
||||
|
||||
@@ -57,35 +57,35 @@ public:
|
||||
uiPlataformUrom = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case CREATURE_DRAKOS:
|
||||
uiDrakos = pCreature->GetGUID();
|
||||
uiDrakos = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_VAROS:
|
||||
uiVaros = pCreature->GetGUID();
|
||||
uiVaros = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_UROM:
|
||||
uiUrom = pCreature->GetGUID();
|
||||
uiUrom = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_EREGOS:
|
||||
uiEregos = pCreature->GetGUID();
|
||||
uiEregos = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGO, bool /*bAdd*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if (pGO->GetEntry() == GO_DRAGON_CAGE_DOOR)
|
||||
if (go->GetEntry() == GO_DRAGON_CAGE_DOOR)
|
||||
{
|
||||
if (GetData(DATA_DRAKOS_EVENT) == DONE)
|
||||
pGO->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGO->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
|
||||
GameObjectList.push_back(pGO->GetGUID());
|
||||
GameObjectList.push_back(go->GetGUID());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -150,8 +150,8 @@ public:
|
||||
|
||||
for (std::list<uint64>::const_iterator itr = GameObjectList.begin(); itr != GameObjectList.end(); ++itr)
|
||||
{
|
||||
if (GameObject* pGO = instance->GetGameObject(*itr))
|
||||
pGO->SetGoState(GO_STATE_ACTIVE);
|
||||
if (GameObject* go = instance->GetGameObject(*itr))
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -62,26 +62,26 @@ public:
|
||||
m_bVesperonKilled = false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_SARTHARION:
|
||||
m_uiSartharionGUID = pCreature->GetGUID();
|
||||
m_uiSartharionGUID = creature->GetGUID();
|
||||
break;
|
||||
//three dragons below set to active state once created.
|
||||
//we must expect bigger raid to encounter main boss, and then three dragons must be active due to grid differences
|
||||
case NPC_TENEBRON:
|
||||
m_uiTenebronGUID = pCreature->GetGUID();
|
||||
pCreature->setActive(true);
|
||||
m_uiTenebronGUID = creature->GetGUID();
|
||||
creature->setActive(true);
|
||||
break;
|
||||
case NPC_SHADRON:
|
||||
m_uiShadronGUID = pCreature->GetGUID();
|
||||
pCreature->setActive(true);
|
||||
m_uiShadronGUID = creature->GetGUID();
|
||||
creature->setActive(true);
|
||||
break;
|
||||
case NPC_VESPERON:
|
||||
m_uiVesperonGUID = pCreature->GetGUID();
|
||||
pCreature->setActive(true);
|
||||
m_uiVesperonGUID = creature->GetGUID();
|
||||
creature->setActive(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -76,59 +76,59 @@ public:
|
||||
m_uiLokenGlobeGUID = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_BJARNGRIM:
|
||||
m_uiGeneralBjarngrimGUID = pCreature->GetGUID();
|
||||
m_uiGeneralBjarngrimGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_VOLKHAN:
|
||||
m_uiVolkhanGUID = pCreature->GetGUID();
|
||||
m_uiVolkhanGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_IONAR:
|
||||
m_uiIonarGUID = pCreature->GetGUID();
|
||||
m_uiIonarGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_LOKEN:
|
||||
m_uiLokenGUID = pCreature->GetGUID();
|
||||
m_uiLokenGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_BJARNGRIM_DOOR:
|
||||
m_uiBjarngrimDoorGUID = pGo->GetGUID();
|
||||
m_uiBjarngrimDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_VOLKHAN_DOOR:
|
||||
m_uiVolkhanDoorGUID = pGo->GetGUID();
|
||||
m_uiVolkhanDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_IONAR_DOOR:
|
||||
m_uiIonarDoorGUID = pGo->GetGUID();
|
||||
m_uiIonarDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_LOKEN_DOOR:
|
||||
m_uiLokenDoorGUID = pGo->GetGUID();
|
||||
m_uiLokenDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_LOKEN_THRONE:
|
||||
m_uiLokenGlobeGUID = pGo->GetGUID();
|
||||
m_uiLokenGlobeGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -89,65 +89,65 @@ public:
|
||||
m_auiEncounter[i] = NOT_STARTED;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case CREATURE_MAIDEN: uiMaidenOfGrief = pCreature->GetGUID(); break;
|
||||
case CREATURE_KRYSTALLUS: uiKrystallus = pCreature->GetGUID(); break;
|
||||
case CREATURE_SJONNIR: uiSjonnir = pCreature->GetGUID(); break;
|
||||
case CREATURE_MARNAK: uiMarnak = pCreature->GetGUID(); break;
|
||||
case CREATURE_KADDRAK: uiKaddrak = pCreature->GetGUID(); break;
|
||||
case CREATURE_ABEDNEUM: uiAbedneum = pCreature->GetGUID(); break;
|
||||
case CREATURE_BRANN: uiBrann = pCreature->GetGUID(); break;
|
||||
case CREATURE_MAIDEN: uiMaidenOfGrief = creature->GetGUID(); break;
|
||||
case CREATURE_KRYSTALLUS: uiKrystallus = creature->GetGUID(); break;
|
||||
case CREATURE_SJONNIR: uiSjonnir = creature->GetGUID(); break;
|
||||
case CREATURE_MARNAK: uiMarnak = creature->GetGUID(); break;
|
||||
case CREATURE_KADDRAK: uiKaddrak = creature->GetGUID(); break;
|
||||
case CREATURE_ABEDNEUM: uiAbedneum = creature->GetGUID(); break;
|
||||
case CREATURE_BRANN: uiBrann = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_ABEDNEUM:
|
||||
uiAbedneumGo = pGo->GetGUID();
|
||||
uiAbedneumGo = go->GetGUID();
|
||||
break;
|
||||
case GO_MARNAK:
|
||||
uiMarnakGo = pGo->GetGUID();
|
||||
uiMarnakGo = go->GetGUID();
|
||||
break;
|
||||
case GO_KADDRAK:
|
||||
uiKaddrakGo = pGo->GetGUID();
|
||||
uiKaddrakGo = go->GetGUID();
|
||||
break;
|
||||
case GO_MAIDEN_DOOR:
|
||||
uiMaidenOfGriefDoor = pGo->GetGUID();
|
||||
uiMaidenOfGriefDoor = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_BRANN_DOOR:
|
||||
uiBrannDoor = pGo->GetGUID();
|
||||
uiBrannDoor = go->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_SJONNIR_DOOR:
|
||||
uiSjonnirDoor = pGo->GetGUID();
|
||||
uiSjonnirDoor = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
else
|
||||
pGo->SetGoState(GO_STATE_READY);
|
||||
go->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case GO_TRIBUNAL_CONSOLE:
|
||||
uiTribunalConsole = pGo->GetGUID();
|
||||
uiTribunalConsole = go->GetGUID();
|
||||
break;
|
||||
case GO_TRIBUNAL_CHEST:
|
||||
case GO_TRIBUNAL_CHEST_HERO:
|
||||
uiTribunalChest = pGo->GetGUID();
|
||||
uiTribunalChest = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
break;
|
||||
case 191527:
|
||||
uiTribunalSkyFloor = pGo->GetGUID();
|
||||
uiTribunalSkyFloor = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -174,9 +174,9 @@ public:
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
{
|
||||
HandleGameObject(uiSjonnirDoor,true);
|
||||
GameObject *pGo = instance->GetGameObject(uiTribunalChest);
|
||||
if (pGo)
|
||||
pGo->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
GameObject* go = instance->GetGameObject(uiTribunalChest);
|
||||
if (go)
|
||||
go->RemoveFlag(GAMEOBJECT_FLAGS,GO_FLAG_INTERACT_COND);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -112,103 +112,103 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_LEVIATHAN:
|
||||
uiLeviathanGUID = pCreature->GetGUID();
|
||||
uiLeviathanGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_IGNIS:
|
||||
uiIgnisGUID = pCreature->GetGUID();
|
||||
uiIgnisGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_RAZORSCALE:
|
||||
uiRazorscaleGUID = pCreature->GetGUID();
|
||||
uiRazorscaleGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_EXPEDITION_COMMANDER:
|
||||
uiExpCommanderGUID = pCreature->GetGUID();
|
||||
uiExpCommanderGUID = creature->GetGUID();
|
||||
return;
|
||||
case NPC_XT002:
|
||||
uiXT002GUID = pCreature->GetGUID();
|
||||
uiXT002GUID = creature->GetGUID();
|
||||
break;
|
||||
|
||||
// Assembly of Iron
|
||||
case NPC_STEELBREAKER:
|
||||
uiAssemblyGUIDs[0] = pCreature->GetGUID();
|
||||
uiAssemblyGUIDs[0] = creature->GetGUID();
|
||||
break;
|
||||
case NPC_MOLGEIM:
|
||||
uiAssemblyGUIDs[1] = pCreature->GetGUID();
|
||||
uiAssemblyGUIDs[1] = creature->GetGUID();
|
||||
break;
|
||||
case NPC_BRUNDIR:
|
||||
uiAssemblyGUIDs[2] = pCreature->GetGUID();
|
||||
uiAssemblyGUIDs[2] = creature->GetGUID();
|
||||
break;
|
||||
|
||||
case NPC_KOLOGARN:
|
||||
uiKologarnGUID = pCreature->GetGUID();
|
||||
uiKologarnGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_AURIAYA:
|
||||
uiAuriayaGUID = pCreature->GetGUID();
|
||||
uiAuriayaGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_MIMIRON:
|
||||
uiMimironGUID = pCreature->GetGUID();
|
||||
uiMimironGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_HODIR:
|
||||
uiHodirGUID = pCreature->GetGUID();
|
||||
uiHodirGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_THORIM:
|
||||
uiThorimGUID = pCreature->GetGUID();
|
||||
uiThorimGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_FREYA:
|
||||
uiFreyaGUID = pCreature->GetGUID();
|
||||
uiFreyaGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_VEZAX:
|
||||
uiVezaxGUID = pCreature->GetGUID();
|
||||
uiVezaxGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_YOGGSARON:
|
||||
uiYoggSaronGUID = pCreature->GetGUID();
|
||||
uiYoggSaronGUID = creature->GetGUID();
|
||||
break;
|
||||
case NPC_ALGALON:
|
||||
uiAlgalonGUID = pCreature->GetGUID();
|
||||
uiAlgalonGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGO, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGO->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_KOLOGARN_CHEST_HERO:
|
||||
case GO_KOLOGARN_CHEST:
|
||||
uiKologarnChestGUID = add ? pGO->GetGUID() : NULL;
|
||||
uiKologarnChestGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_THORIM_CHEST_HERO:
|
||||
case GO_THORIM_CHEST:
|
||||
uiThorimChestGUID = add ? pGO->GetGUID() : NULL;
|
||||
uiThorimChestGUID =go->GetGUID();
|
||||
break;
|
||||
case GO_HODIR_CHEST_HERO:
|
||||
case GO_HODIR_CHEST:
|
||||
uiHodirChestGUID = add ? pGO->GetGUID() : NULL;
|
||||
uiHodirChestGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_FREYA_CHEST_HERO:
|
||||
case GO_FREYA_CHEST:
|
||||
uiFreyaChestGUID = add ? pGO->GetGUID() : NULL;
|
||||
uiFreyaChestGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_LEVIATHAN_DOOR:
|
||||
uiLeviathanDoor[flag] = pGO->GetGUID();
|
||||
HandleGameObject(NULL, true, pGO);
|
||||
uiLeviathanDoor[flag] = go->GetGUID();
|
||||
HandleGameObject(NULL, true, go);
|
||||
flag++;
|
||||
if (flag == 7)
|
||||
flag =0;
|
||||
break;
|
||||
case GO_LEVIATHAN_GATE:
|
||||
uiLeviathanGateGUID = add ? pGO->GetGUID() : NULL;
|
||||
HandleGameObject(NULL, false, pGO);
|
||||
uiLeviathanGateGUID = go->GetGUID();
|
||||
HandleGameObject(NULL, false, go);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void ProcessEvent(GameObject* /*pGO*/, uint32 uiEventId)
|
||||
void ProcessEvent(GameObject* /*go*/, uint32 uiEventId)
|
||||
{
|
||||
// Flame Leviathan's Tower Event triggers
|
||||
Creature* pFlameLeviathan = instance->GetCreature(uiLeviathanGUID);
|
||||
@@ -261,23 +261,23 @@ public:
|
||||
break;
|
||||
case TYPE_KOLOGARN:
|
||||
if (state == DONE)
|
||||
if (GameObject* pGO = instance->GetGameObject(uiKologarnChestGUID))
|
||||
pGO->SetRespawnTime(pGO->GetRespawnDelay());
|
||||
if (GameObject* go = instance->GetGameObject(uiKologarnChestGUID))
|
||||
go->SetRespawnTime(go->GetRespawnDelay());
|
||||
break;
|
||||
case TYPE_HODIR:
|
||||
if (state == DONE)
|
||||
if (GameObject* pGO = instance->GetGameObject(uiHodirChestGUID))
|
||||
pGO->SetRespawnTime(pGO->GetRespawnDelay());
|
||||
if (GameObject* go = instance->GetGameObject(uiHodirChestGUID))
|
||||
go->SetRespawnTime(go->GetRespawnDelay());
|
||||
break;
|
||||
case TYPE_THORIM:
|
||||
if (state == DONE)
|
||||
if (GameObject* pGO = instance->GetGameObject(uiThorimChestGUID))
|
||||
pGO->SetRespawnTime(pGO->GetRespawnDelay());
|
||||
if (GameObject* go = instance->GetGameObject(uiThorimChestGUID))
|
||||
go->SetRespawnTime(go->GetRespawnDelay());
|
||||
break;
|
||||
case TYPE_FREYA:
|
||||
if (state == DONE)
|
||||
if (GameObject* pGO = instance->GetGameObject(uiFreyaChestGUID))
|
||||
pGO->SetRespawnTime(pGO->GetRespawnDelay());
|
||||
if (GameObject* go = instance->GetGameObject(uiFreyaChestGUID))
|
||||
go->SetRespawnTime(go->GetRespawnDelay());
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -122,44 +122,44 @@ public:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 23953: Keleseth = pCreature->GetGUID(); break;
|
||||
case 24201: Dalronn = pCreature->GetGUID(); break;
|
||||
case 24200: Skarvald = pCreature->GetGUID(); break;
|
||||
case 23954: Ingvar = pCreature->GetGUID(); break;
|
||||
case 23953: Keleseth = creature->GetGUID(); break;
|
||||
case 24201: Dalronn = creature->GetGUID(); break;
|
||||
case 24200: Skarvald = creature->GetGUID(); break;
|
||||
case 23954: Ingvar = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
//door and object id
|
||||
case ENTRY_BELLOW_1: forge_bellow[0] = pGo->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_BELLOW_2: forge_bellow[1] = pGo->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_BELLOW_3: forge_bellow[2] = pGo->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_FORGEFIRE_1: forge_fire[0] = pGo->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_FORGEFIRE_2: forge_fire[1] = pGo->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_FORGEFIRE_3: forge_fire[2] = pGo->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_GLOWING_ANVIL_1: forge_anvil[0] = pGo->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_GLOWING_ANVIL_2: forge_anvil[1] = pGo->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_GLOWING_ANVIL_3: forge_anvil[2] = pGo->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_GIANT_PORTCULLIS_1: portcullis[0] = pGo->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_GIANT_PORTCULLIS_2: portcullis[1] = pGo->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case ENTRY_BELLOW_1: forge_bellow[0] = go->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_BELLOW_2: forge_bellow[1] = go->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_BELLOW_3: forge_bellow[2] = go->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_FORGEFIRE_1: forge_fire[0] = go->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_FORGEFIRE_2: forge_fire[1] = go->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_FORGEFIRE_3: forge_fire[2] = go->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_GLOWING_ANVIL_1: forge_anvil[0] = go->GetGUID();
|
||||
if (forge_event[0] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_GLOWING_ANVIL_2: forge_anvil[1] = go->GetGUID();
|
||||
if (forge_event[1] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_GLOWING_ANVIL_3: forge_anvil[2] = go->GetGUID();
|
||||
if (forge_event[2] != NOT_STARTED)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_GIANT_PORTCULLIS_1: portcullis[0] = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case ENTRY_GIANT_PORTCULLIS_2: portcullis[1] = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -102,41 +102,41 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case BOSS_SVALA_SORROWGRAVE: uiSvalaSorrowgrave = pCreature->GetGUID(); break;
|
||||
case BOSS_GORTOK_PALEHOOF: uiGortokPalehoof = pCreature->GetGUID(); break;
|
||||
case BOSS_SKADI_RUTHLESS: uiSkadiTheRuthless = pCreature->GetGUID(); break;
|
||||
case BOSS_KING_YMIRON: uiKingYmiron = pCreature->GetGUID(); break;
|
||||
case MOB_FRENZIED_WORGEN: uiFrenziedWorgen = pCreature->GetGUID(); break;
|
||||
case MOB_RAVENOUS_FURBOLG: uiRavenousFurbolg = pCreature->GetGUID(); break;
|
||||
case MOB_MASSIVE_JORMUNGAR: uiMassiveJormungar = pCreature->GetGUID(); break;
|
||||
case MOB_FEROCIOUS_RHINO: uiFerociousRhino = pCreature->GetGUID(); break;
|
||||
case MOB_SVALA: uiSvala = pCreature->GetGUID(); break;
|
||||
case MOB_PALEHOOF_ORB: uiPalehoofOrb = pCreature->GetGUID(); break;
|
||||
case BOSS_SVALA_SORROWGRAVE: uiSvalaSorrowgrave = creature->GetGUID(); break;
|
||||
case BOSS_GORTOK_PALEHOOF: uiGortokPalehoof = creature->GetGUID(); break;
|
||||
case BOSS_SKADI_RUTHLESS: uiSkadiTheRuthless = creature->GetGUID(); break;
|
||||
case BOSS_KING_YMIRON: uiKingYmiron = creature->GetGUID(); break;
|
||||
case MOB_FRENZIED_WORGEN: uiFrenziedWorgen = creature->GetGUID(); break;
|
||||
case MOB_RAVENOUS_FURBOLG: uiRavenousFurbolg = creature->GetGUID(); break;
|
||||
case MOB_MASSIVE_JORMUNGAR: uiMassiveJormungar = creature->GetGUID(); break;
|
||||
case MOB_FEROCIOUS_RHINO: uiFerociousRhino = creature->GetGUID(); break;
|
||||
case MOB_SVALA: uiSvala = creature->GetGUID(); break;
|
||||
case MOB_PALEHOOF_ORB: uiPalehoofOrb = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case ENTRY_SKADI_THE_RUTHLESS_DOOR:
|
||||
uiSkadiTheRuthlessDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE) HandleGameObject(NULL, true, pGo);
|
||||
uiSkadiTheRuthlessDoor = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE) HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
case ENTRY_KING_YMIRON_DOOR:
|
||||
uiKingYmironDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE) HandleGameObject(NULL, true, pGo);
|
||||
uiKingYmironDoor = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE) HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
case ENTRY_GORK_PALEHOOF_SPHERE:
|
||||
uiGortokPalehoofSphere = pGo->GetGUID();
|
||||
uiGortokPalehoofSphere = go->GetGUID();
|
||||
if (m_auiEncounter[1] == DONE)
|
||||
{
|
||||
HandleGameObject(NULL, true, pGo);
|
||||
pGo->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
HandleGameObject(NULL, true, go);
|
||||
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_UNK1);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -68,7 +68,7 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature *creature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
|
||||
@@ -227,85 +227,85 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool add)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case CREATURE_XEVOZZ:
|
||||
uiXevozz = pCreature->GetGUID();
|
||||
uiXevozz = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_LAVANTHOR:
|
||||
uiLavanthor = pCreature->GetGUID();
|
||||
uiLavanthor = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_ICHORON:
|
||||
uiIchoron = pCreature->GetGUID();
|
||||
uiIchoron = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_ZURAMAT:
|
||||
uiZuramat = pCreature->GetGUID();
|
||||
uiZuramat = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_EREKEM:
|
||||
uiErekem = pCreature->GetGUID();
|
||||
uiErekem = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_EREKEM_GUARD:
|
||||
if (uiCountErekemGuards < 2)
|
||||
{
|
||||
uiErekemGuard[uiCountErekemGuards++] = pCreature->GetGUID();
|
||||
pCreature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE|UNIT_FLAG_NON_ATTACKABLE);
|
||||
uiErekemGuard[uiCountErekemGuards++] = creature->GetGUID();
|
||||
creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE|UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
break;
|
||||
case CREATURE_MORAGG:
|
||||
uiMoragg = pCreature->GetGUID();
|
||||
uiMoragg = creature->GetGUID();
|
||||
break;
|
||||
case CREATURE_CYANIGOSA:
|
||||
uiCyanigosa = pCreature->GetGUID();
|
||||
pCreature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE|UNIT_FLAG_NON_ATTACKABLE);
|
||||
uiCyanigosa = creature->GetGUID();
|
||||
creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE|UNIT_FLAG_NON_ATTACKABLE);
|
||||
break;
|
||||
case CREATURE_SINCLARI:
|
||||
uiSinclari = pCreature->GetGUID();
|
||||
uiSinclari = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
|
||||
if (add && (pCreature->GetGUID() == uiFirstBoss || pCreature->GetGUID() == uiSecondBoss))
|
||||
if (creature->GetGUID() == uiFirstBoss || creature->GetGUID() == uiSecondBoss)
|
||||
{
|
||||
pCreature->AllLootRemovedFromCorpse();
|
||||
pCreature->RemoveLootMode(1);
|
||||
creature->AllLootRemovedFromCorpse();
|
||||
creature->RemoveLootMode(1);
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_EREKEM_GUARD_1_DOOR:
|
||||
uiErekemLeftGuardCell = pGo->GetGUID();
|
||||
uiErekemLeftGuardCell = go->GetGUID();
|
||||
break;
|
||||
case GO_EREKEM_GUARD_2_DOOR:
|
||||
uiErekemRightGuardCell = pGo->GetGUID();
|
||||
uiErekemRightGuardCell = go->GetGUID();
|
||||
break;
|
||||
case GO_EREKEM_DOOR:
|
||||
uiErekemCell = pGo->GetGUID();
|
||||
uiErekemCell = go->GetGUID();
|
||||
break;
|
||||
case GO_ZURAMAT_DOOR:
|
||||
uiZuramatCell = pGo->GetGUID();
|
||||
uiZuramatCell = go->GetGUID();
|
||||
break;
|
||||
case GO_LAVANTHOR_DOOR:
|
||||
uiLavanthorCell = pGo->GetGUID();
|
||||
uiLavanthorCell = go->GetGUID();
|
||||
break;
|
||||
case GO_MORAGG_DOOR:
|
||||
uiMoraggCell = pGo->GetGUID();
|
||||
uiMoraggCell = go->GetGUID();
|
||||
break;
|
||||
case GO_ICHORON_DOOR:
|
||||
uiIchoronCell = pGo->GetGUID();
|
||||
uiIchoronCell = go->GetGUID();
|
||||
break;
|
||||
case GO_XEVOZZ_DOOR:
|
||||
uiXevozzCell = pGo->GetGUID();
|
||||
uiXevozzCell = go->GetGUID();
|
||||
break;
|
||||
case GO_MAIN_DOOR:
|
||||
uiMainDoor = pGo->GetGUID();
|
||||
uiMainDoor = go->GetGUID();
|
||||
break;
|
||||
case GO_ACTIVATION_CRYSTAL:
|
||||
if (uiCountActivationCrystals < 3)
|
||||
uiActivationCrystal[uiCountActivationCrystals++] = pGo->GetGUID();
|
||||
uiActivationCrystal[uiCountActivationCrystals++] = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -468,8 +468,8 @@ public:
|
||||
void SpawnPortal()
|
||||
{
|
||||
SetData(DATA_PORTAL_LOCATION, (GetData(DATA_PORTAL_LOCATION) + urand(1,5))%6);
|
||||
if (Creature *pSinclari = instance->GetCreature(uiSinclari))
|
||||
if(Creature *portal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL,PortalLocation[GetData(DATA_PORTAL_LOCATION)],TEMPSUMMON_CORPSE_DESPAWN))
|
||||
if (Creature* pSinclari = instance->GetCreature(uiSinclari))
|
||||
if(Creature* portal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL,PortalLocation[GetData(DATA_PORTAL_LOCATION)],TEMPSUMMON_CORPSE_DESPAWN))
|
||||
uiTeleportationPortal = portal->GetGUID();
|
||||
}
|
||||
|
||||
@@ -569,11 +569,11 @@ public:
|
||||
case 6:
|
||||
if (uiFirstBoss == 0)
|
||||
uiFirstBoss = urand(1,6);
|
||||
if (Creature *pSinclari = instance->GetCreature(uiSinclari))
|
||||
if (Creature* pSinclari = instance->GetCreature(uiSinclari))
|
||||
{
|
||||
if(Creature *pPortal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL, MiddleRoomPortalSaboLocation, TEMPSUMMON_CORPSE_DESPAWN))
|
||||
if(Creature* pPortal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL, MiddleRoomPortalSaboLocation, TEMPSUMMON_CORPSE_DESPAWN))
|
||||
uiSaboteurPortal = pPortal->GetGUID();
|
||||
if (Creature *pAzureSaboteur = pSinclari->SummonCreature(CREATURE_SABOTEOUR, MiddleRoomLocation, TEMPSUMMON_DEAD_DESPAWN))
|
||||
if (Creature* pAzureSaboteur = pSinclari->SummonCreature(CREATURE_SABOTEOUR, MiddleRoomLocation, TEMPSUMMON_DEAD_DESPAWN))
|
||||
pAzureSaboteur->CastSpell(pAzureSaboteur, SABOTEUR_SHIELD_EFFECT, false);
|
||||
}
|
||||
break;
|
||||
@@ -583,17 +583,17 @@ public:
|
||||
{
|
||||
uiSecondBoss = urand(1,6);
|
||||
} while (uiSecondBoss == uiFirstBoss);
|
||||
if (Creature *pSinclari = instance->GetCreature(uiSinclari))
|
||||
if (Creature* pSinclari = instance->GetCreature(uiSinclari))
|
||||
{
|
||||
if(Creature *pPortal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL, MiddleRoomPortalSaboLocation, TEMPSUMMON_CORPSE_DESPAWN))
|
||||
if(Creature* pPortal = pSinclari->SummonCreature(CREATURE_TELEPORTATION_PORTAL, MiddleRoomPortalSaboLocation, TEMPSUMMON_CORPSE_DESPAWN))
|
||||
uiSaboteurPortal = pPortal->GetGUID();
|
||||
if (Creature *pAzureSaboteur = pSinclari->SummonCreature(CREATURE_SABOTEOUR, MiddleRoomLocation, TEMPSUMMON_DEAD_DESPAWN))
|
||||
if (Creature* pAzureSaboteur = pSinclari->SummonCreature(CREATURE_SABOTEOUR, MiddleRoomLocation, TEMPSUMMON_DEAD_DESPAWN))
|
||||
pAzureSaboteur->CastSpell(pAzureSaboteur, SABOTEUR_SHIELD_EFFECT, false);
|
||||
}
|
||||
break;
|
||||
case 18:
|
||||
{
|
||||
Creature *pSinclari = instance->GetCreature(uiSinclari);
|
||||
Creature* pSinclari = instance->GetCreature(uiSinclari);
|
||||
if (pSinclari)
|
||||
pSinclari->SummonCreature(CREATURE_CYANIGOSA,CyanigosasSpawnLocation,TEMPSUMMON_DEAD_DESPAWN);
|
||||
break;
|
||||
@@ -727,7 +727,7 @@ public:
|
||||
}
|
||||
|
||||
// Cyanigosa is spawned but not tranformed, prefight event
|
||||
Creature *pCyanigosa = instance->GetCreature(uiCyanigosa);
|
||||
Creature* pCyanigosa = instance->GetCreature(uiCyanigosa);
|
||||
if (pCyanigosa && !pCyanigosa->HasAura(CYANIGOSA_SPELL_TRANSFORM))
|
||||
{
|
||||
if (uiCyanigosaEventTimer <= diff)
|
||||
@@ -788,9 +788,9 @@ public:
|
||||
// TODO: All visual, spells etc
|
||||
for (std::set<uint64>::const_iterator itr = trashMobs.begin(); itr != trashMobs.end(); ++itr)
|
||||
{
|
||||
Creature* pCreature = instance->GetCreature(*itr);
|
||||
if (pCreature && pCreature->isAlive())
|
||||
pCreature->CastSpell(pCreature,SPELL_ARCANE_LIGHTNING,true); // Who should cast the spell?
|
||||
Creature* creature = instance->GetCreature(*itr);
|
||||
if (creature && creature->isAlive())
|
||||
creature->CastSpell(creature,SPELL_ARCANE_LIGHTNING,true); // Who should cast the spell?
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -55,21 +55,21 @@ public:
|
||||
m_uiIkissDoorGUID = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (pCreature->GetEntry() == NPC_ANZU)
|
||||
if (creature->GetEntry() == NPC_ANZU)
|
||||
{
|
||||
if (AnzuEncounter >= IN_PROGRESS)
|
||||
pCreature->DisappearAndDie();
|
||||
creature->DisappearAndDie();
|
||||
else
|
||||
AnzuEncounter = IN_PROGRESS;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if (pGo->GetEntry() == IKISS_DOOR)
|
||||
m_uiIkissDoorGUID = pGo->GetGUID();
|
||||
if (go->GetEntry() == IKISS_DOOR)
|
||||
m_uiIkissDoorGUID = go->GetGUID();
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
|
||||
@@ -80,32 +80,32 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case REFECTORY_DOOR:
|
||||
m_uiRefectoryDoorGUID = pGo->GetGUID();
|
||||
m_uiRefectoryDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[2] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
case SCREAMING_HALL_DOOR:
|
||||
m_uiScreamingHallDoorGUID = pGo->GetGUID();
|
||||
m_uiScreamingHallDoorGUID = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)
|
||||
pGo->SetGoState(GO_STATE_ACTIVE);
|
||||
go->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 18732:
|
||||
m_uiGrandmasterVorpil = pCreature->GetGUID();
|
||||
m_uiGrandmasterVorpil = creature->GetGUID();
|
||||
break;
|
||||
case 18796:
|
||||
if (pCreature->isAlive())
|
||||
if (creature->isAlive())
|
||||
{
|
||||
++m_uiFelOverseerCount;
|
||||
sLog.outDebug("TSCR: Shadow Labyrinth: counting %u Fel Overseers.",m_uiFelOverseerCount);
|
||||
|
||||
@@ -140,51 +140,51 @@ public:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 22887: Najentus = pCreature->GetGUID(); break;
|
||||
case 23089: Akama = pCreature->GetGUID(); break;
|
||||
case 22990: Akama_Shade = pCreature->GetGUID(); break;
|
||||
case 22841: ShadeOfAkama = pCreature->GetGUID(); break;
|
||||
case 22898: Supremus = pCreature->GetGUID(); break;
|
||||
case 22917: IllidanStormrage = pCreature->GetGUID(); break;
|
||||
case 22949: GathiosTheShatterer = pCreature->GetGUID(); break;
|
||||
case 22950: HighNethermancerZerevor = pCreature->GetGUID(); break;
|
||||
case 22951: LadyMalande = pCreature->GetGUID(); break;
|
||||
case 22952: VerasDarkshadow = pCreature->GetGUID(); break;
|
||||
case 23426: IllidariCouncil = pCreature->GetGUID(); break;
|
||||
case 23499: BloodElfCouncilVoice = pCreature->GetGUID(); break;
|
||||
case 22887: Najentus = creature->GetGUID(); break;
|
||||
case 23089: Akama = creature->GetGUID(); break;
|
||||
case 22990: Akama_Shade = creature->GetGUID(); break;
|
||||
case 22841: ShadeOfAkama = creature->GetGUID(); break;
|
||||
case 22898: Supremus = creature->GetGUID(); break;
|
||||
case 22917: IllidanStormrage = creature->GetGUID(); break;
|
||||
case 22949: GathiosTheShatterer = creature->GetGUID(); break;
|
||||
case 22950: HighNethermancerZerevor = creature->GetGUID(); break;
|
||||
case 22951: LadyMalande = creature->GetGUID(); break;
|
||||
case 22952: VerasDarkshadow = creature->GetGUID(); break;
|
||||
case 23426: IllidariCouncil = creature->GetGUID(); break;
|
||||
case 23499: BloodElfCouncilVoice = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 185483: NajentusGate = pGo->GetGUID();// Gate past Naj'entus (at the entrance to Supermoose's courtyards)
|
||||
if (m_auiEncounter[0] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185882: MainTempleDoors = pGo->GetGUID();// Main Temple Doors - right past Supermoose (Supremus)
|
||||
if (m_auiEncounter[1] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185478: ShadeOfAkamaDoor = pGo->GetGUID();break;
|
||||
case 185480: CommonDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 186153: TeronDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185892: GuurtogDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[4] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185479: TempleDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[5] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185482: MotherDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[6] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185481: CouncilDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[7] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 186152: SimpleDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[7] == DONE)HandleGameObject(NULL,true,pGo);break;
|
||||
case 185905: IllidanGate = pGo->GetGUID(); break; // Gate leading to Temple Summit
|
||||
case 186261: IllidanDoor[0] = pGo->GetGUID(); break; // Right door at Temple Summit
|
||||
case 186262: IllidanDoor[1] = pGo->GetGUID(); break; // Left door at Temple Summit
|
||||
case 185483: NajentusGate = go->GetGUID();// Gate past Naj'entus (at the entrance to Supermoose's courtyards)
|
||||
if (m_auiEncounter[0] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185882: MainTempleDoors = go->GetGUID();// Main Temple Doors - right past Supermoose (Supremus)
|
||||
if (m_auiEncounter[1] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185478: ShadeOfAkamaDoor = go->GetGUID();break;
|
||||
case 185480: CommonDoor = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 186153: TeronDoor = go->GetGUID();
|
||||
if (m_auiEncounter[3] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185892: GuurtogDoor = go->GetGUID();
|
||||
if (m_auiEncounter[4] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185479: TempleDoor = go->GetGUID();
|
||||
if (m_auiEncounter[5] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185482: MotherDoor = go->GetGUID();
|
||||
if (m_auiEncounter[6] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185481: CouncilDoor = go->GetGUID();
|
||||
if (m_auiEncounter[7] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 186152: SimpleDoor = go->GetGUID();
|
||||
if (m_auiEncounter[7] == DONE)HandleGameObject(NULL,true,go);break;
|
||||
case 185905: IllidanGate = go->GetGUID(); break; // Gate leading to Temple Summit
|
||||
case 186261: IllidanDoor[0] = go->GetGUID(); break; // Right door at Temple Summit
|
||||
case 186262: IllidanDoor[1] = go->GetGUID(); break; // Left door at Temple Summit
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -52,9 +52,9 @@ class go_bridge_console : public GameObjectScript
|
||||
public:
|
||||
go_bridge_console() : GameObjectScript("go_bridge_console") { }
|
||||
|
||||
bool OnGossipHello(Player* /*pPlayer*/, GameObject* pGo)
|
||||
bool OnGossipHello(Player* /*pPlayer*/, GameObject* go)
|
||||
{
|
||||
InstanceScript* pInstance = pGo->GetInstanceScript();
|
||||
InstanceScript* pInstance = go->GetInstanceScript();
|
||||
|
||||
if (!pInstance)
|
||||
return false;
|
||||
@@ -210,28 +210,28 @@ public:
|
||||
} else FrenzySpawnTimer -= diff;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 184568:
|
||||
ControlConsole = pGo->GetGUID();
|
||||
pGo->setActive(true);
|
||||
ControlConsole = go->GetGUID();
|
||||
go->setActive(true);
|
||||
break;
|
||||
|
||||
case 184203:
|
||||
BridgePart[0] = pGo->GetGUID();
|
||||
pGo->setActive(true);
|
||||
BridgePart[0] = go->GetGUID();
|
||||
go->setActive(true);
|
||||
break;
|
||||
|
||||
case 184204:
|
||||
BridgePart[1] = pGo->GetGUID();
|
||||
pGo->setActive(true);
|
||||
BridgePart[1] = go->GetGUID();
|
||||
go->setActive(true);
|
||||
break;
|
||||
|
||||
case 184205:
|
||||
BridgePart[2] = pGo->GetGUID();
|
||||
pGo->setActive(true);
|
||||
BridgePart[2] = go->GetGUID();
|
||||
go->setActive(true);
|
||||
break;
|
||||
case GAMEOBJECT_FISHINGNODE_ENTRY://no way checking if fish is hooked, so we create a timed event
|
||||
if (LurkerSubEvent == LURKER_NOT_STARTED)
|
||||
@@ -243,20 +243,20 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 21212: LadyVashj = pCreature->GetGUID(); break;
|
||||
case 21214: Karathress = pCreature->GetGUID(); break;
|
||||
case 21966: Sharkkis = pCreature->GetGUID(); break;
|
||||
case 21217: LurkerBelow = pCreature->GetGUID(); break;
|
||||
case 21965: Tidalvess = pCreature->GetGUID(); break;
|
||||
case 21964: Caribdis = pCreature->GetGUID(); break;
|
||||
case 21215: LeotherasTheBlind = pCreature->GetGUID(); break;
|
||||
case 21212: LadyVashj = creature->GetGUID(); break;
|
||||
case 21214: Karathress = creature->GetGUID(); break;
|
||||
case 21966: Sharkkis = creature->GetGUID(); break;
|
||||
case 21217: LurkerBelow = creature->GetGUID(); break;
|
||||
case 21965: Tidalvess = creature->GetGUID(); break;
|
||||
case 21964: Caribdis = creature->GetGUID(); break;
|
||||
case 21215: LeotherasTheBlind = creature->GetGUID(); break;
|
||||
/*case TRASHMOB_COILFANG_PRIESTESS:
|
||||
case TRASHMOB_COILFANG_SHATTERER:
|
||||
if (pCreature->isAlive())
|
||||
if (creature->isAlive())
|
||||
++TrashCount;
|
||||
break;*/
|
||||
}
|
||||
|
||||
@@ -43,17 +43,17 @@ class go_main_chambers_access_panel : public GameObjectScript
|
||||
public:
|
||||
go_main_chambers_access_panel() : GameObjectScript("go_main_chambers_access_panel") { }
|
||||
|
||||
bool OnGossipHello(Player* /*pPlayer*/, GameObject* pGo)
|
||||
bool OnGossipHello(Player* /*pPlayer*/, GameObject* go)
|
||||
{
|
||||
InstanceScript* pInstance = pGo->GetInstanceScript();
|
||||
InstanceScript* pInstance = go->GetInstanceScript();
|
||||
|
||||
if (!pInstance)
|
||||
return false;
|
||||
|
||||
if (pGo->GetEntry() == ACCESS_PANEL_HYDRO && (pInstance->GetData(TYPE_HYDROMANCER_THESPIA) == DONE || pInstance->GetData(TYPE_HYDROMANCER_THESPIA) == SPECIAL))
|
||||
if (go->GetEntry() == ACCESS_PANEL_HYDRO && (pInstance->GetData(TYPE_HYDROMANCER_THESPIA) == DONE || pInstance->GetData(TYPE_HYDROMANCER_THESPIA) == SPECIAL))
|
||||
pInstance->SetData(TYPE_HYDROMANCER_THESPIA,SPECIAL);
|
||||
|
||||
if (pGo->GetEntry() == ACCESS_PANEL_MEK && (pInstance->GetData(TYPE_MEKGINEER_STEAMRIGGER) == DONE || pInstance->GetData(TYPE_MEKGINEER_STEAMRIGGER) == SPECIAL))
|
||||
if (go->GetEntry() == ACCESS_PANEL_MEK && (pInstance->GetData(TYPE_MEKGINEER_STEAMRIGGER) == DONE || pInstance->GetData(TYPE_MEKGINEER_STEAMRIGGER) == SPECIAL))
|
||||
pInstance->SetData(TYPE_MEKGINEER_STEAMRIGGER,SPECIAL);
|
||||
|
||||
return true;
|
||||
@@ -106,23 +106,23 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 17797: ThespiaGUID = pCreature->GetGUID(); break;
|
||||
case 17796: MekgineerGUID = pCreature->GetGUID(); break;
|
||||
case 17798: KalithreshGUID = pCreature->GetGUID(); break;
|
||||
case 17797: ThespiaGUID = creature->GetGUID(); break;
|
||||
case 17796: MekgineerGUID = creature->GetGUID(); break;
|
||||
case 17798: KalithreshGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case MAIN_CHAMBERS_DOOR: MainChambersDoor = pGo->GetGUID(); break;
|
||||
case ACCESS_PANEL_HYDRO: AccessPanelHydro = pGo->GetGUID(); break;
|
||||
case ACCESS_PANEL_MEK: AccessPanelMek = pGo->GetGUID(); break;
|
||||
case MAIN_CHAMBERS_DOOR: MainChambersDoor = go->GetGUID(); break;
|
||||
case ACCESS_PANEL_HYDRO: AccessPanelHydro = go->GetGUID(); break;
|
||||
case ACCESS_PANEL_MEK: AccessPanelMek = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -82,27 +82,27 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 18835: KigglerTheCrazed = pCreature->GetGUID(); break;
|
||||
case 18836: BlindeyeTheSeer = pCreature->GetGUID(); break;
|
||||
case 18834: OlmTheSummoner = pCreature->GetGUID(); break;
|
||||
case 18832: KroshFirehand = pCreature->GetGUID(); break;
|
||||
case 18831: Maulgar = pCreature->GetGUID(); break;
|
||||
case 18835: KigglerTheCrazed = creature->GetGUID(); break;
|
||||
case 18836: BlindeyeTheSeer = creature->GetGUID(); break;
|
||||
case 18834: OlmTheSummoner = creature->GetGUID(); break;
|
||||
case 18832: KroshFirehand = creature->GetGUID(); break;
|
||||
case 18831: Maulgar = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 184468:
|
||||
MaulgarDoor = pGo->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE) HandleGameObject(NULL, true, pGo);
|
||||
MaulgarDoor = go->GetGUID();
|
||||
if (m_auiEncounter[0] == DONE) HandleGameObject(NULL, true, go);
|
||||
break;
|
||||
case 184662: GruulDoor = pGo->GetGUID(); break;
|
||||
case 184662: GruulDoor = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -90,53 +90,48 @@ class instance_blood_furnace : public InstanceMapScript
|
||||
PrisonCell8GUID = 0;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool add)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (!add)
|
||||
return;
|
||||
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 17381: The_MakerGUID = pCreature->GetGUID(); break;
|
||||
case 17380: BroggokGUID = pCreature->GetGUID(); break;
|
||||
case 17377: Kelidan_The_BreakerGUID = pCreature->GetGUID(); break;
|
||||
case 17381: The_MakerGUID = creature->GetGUID(); break;
|
||||
case 17380: BroggokGUID = creature->GetGUID(); break;
|
||||
case 17377: Kelidan_The_BreakerGUID = creature->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool add)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
if (!add)
|
||||
return;
|
||||
|
||||
if (pGo->GetEntry() == 181766) //Final exit door
|
||||
Door1GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181811) //The Maker Front door
|
||||
Door2GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181812) //The Maker Rear door
|
||||
Door3GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181822) //Broggok Front door
|
||||
Door4GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181819) //Broggok Rear door
|
||||
Door5GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181823) //Kelidan exit door
|
||||
Door6GUID = pGo->GetGUID();
|
||||
if (go->GetEntry() == 181766) //Final exit door
|
||||
Door1GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181811) //The Maker Front door
|
||||
Door2GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181812) //The Maker Rear door
|
||||
Door3GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181822) //Broggok Front door
|
||||
Door4GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181819) //Broggok Rear door
|
||||
Door5GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181823) //Kelidan exit door
|
||||
Door6GUID = go->GetGUID();
|
||||
|
||||
if (pGo->GetEntry() == 181813) //The Maker prison cell front right
|
||||
PrisonCell1GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181814) //The Maker prison cell back right
|
||||
PrisonCell2GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181816) //The Maker prison cell front left
|
||||
PrisonCell3GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181815) //The Maker prison cell back left
|
||||
PrisonCell4GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181821) //Broggok prison cell front right
|
||||
PrisonCell5GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181818) //Broggok prison cell back right
|
||||
PrisonCell6GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181820) //Broggok prison cell front left
|
||||
PrisonCell7GUID = pGo->GetGUID();
|
||||
if (pGo->GetEntry() == 181817) //Broggok prison cell back left
|
||||
PrisonCell8GUID = pGo->GetGUID();
|
||||
if (go->GetEntry() == 181813) //The Maker prison cell front right
|
||||
PrisonCell1GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181814) //The Maker prison cell back right
|
||||
PrisonCell2GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181816) //The Maker prison cell front left
|
||||
PrisonCell3GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181815) //The Maker prison cell back left
|
||||
PrisonCell4GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181821) //Broggok prison cell front right
|
||||
PrisonCell5GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181818) //Broggok prison cell back right
|
||||
PrisonCell6GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181820) //Broggok prison cell front left
|
||||
PrisonCell7GUID = go->GetGUID();
|
||||
if (go->GetEntry() == 181817) //Broggok prison cell back left
|
||||
PrisonCell8GUID = go->GetGUID();
|
||||
}
|
||||
|
||||
uint64 GetData64(uint32 data)
|
||||
|
||||
@@ -51,15 +51,15 @@ class instance_ramparts : public InstanceMapScript
|
||||
m_uiChestHGUID = 0;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 185168:
|
||||
m_uiChestNGUID = pGo->GetGUID();
|
||||
m_uiChestNGUID = go->GetGUID();
|
||||
break;
|
||||
case 185169:
|
||||
m_uiChestHGUID = pGo->GetGUID();
|
||||
m_uiChestHGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -85,28 +85,28 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 17257:
|
||||
MagtheridonGUID = pCreature->GetGUID();
|
||||
MagtheridonGUID = creature->GetGUID();
|
||||
break;
|
||||
case 17256:
|
||||
ChannelerGUID.insert(pCreature->GetGUID());
|
||||
ChannelerGUID.insert(creature->GetGUID());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case 181713:
|
||||
pGo->SetUInt32Value(GAMEOBJECT_FLAGS, 0);
|
||||
go->SetUInt32Value(GAMEOBJECT_FLAGS, 0);
|
||||
break;
|
||||
case 183847:
|
||||
DoorGUID = pGo->GetGUID();
|
||||
DoorGUID = go->GetGUID();
|
||||
break;
|
||||
case 184653: // hall
|
||||
case 184634: // six columns
|
||||
@@ -115,7 +115,7 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
case 184637:
|
||||
case 184638:
|
||||
case 184639:
|
||||
ColumnGUID.insert(pGo->GetGUID());
|
||||
ColumnGUID.insert(go->GetGUID());
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -150,7 +150,7 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
m_auiEncounter[1] = NOT_STARTED;
|
||||
for (std::set<uint64>::const_iterator i = ChannelerGUID.begin(); i != ChannelerGUID.end(); ++i)
|
||||
{
|
||||
if (Creature *Channeler = instance->GetCreature(*i))
|
||||
if (Creature* Channeler = instance->GetCreature(*i))
|
||||
{
|
||||
if (Channeler->isAlive())
|
||||
Channeler->AI()->EnterEvadeMode();
|
||||
@@ -169,12 +169,12 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
// Let all five channelers aggro.
|
||||
for (std::set<uint64>::const_iterator i = ChannelerGUID.begin(); i != ChannelerGUID.end(); ++i)
|
||||
{
|
||||
Creature *Channeler = instance->GetCreature(*i);
|
||||
Creature* Channeler = instance->GetCreature(*i);
|
||||
if (Channeler && Channeler->isAlive())
|
||||
Channeler->AI()->AttackStart(Channeler->SelectNearestTarget(999));
|
||||
}
|
||||
// Release Magtheridon after two minutes.
|
||||
Creature *Magtheridon = instance->GetCreature(MagtheridonGUID);
|
||||
Creature* Magtheridon = instance->GetCreature(MagtheridonGUID);
|
||||
if (Magtheridon && Magtheridon->isAlive())
|
||||
{
|
||||
Magtheridon->MonsterTextEmote(EMOTE_BONDS_WEAKEN, 0);
|
||||
@@ -186,7 +186,7 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
case DONE: // Add buff and check if all channelers are dead.
|
||||
for (std::set<uint64>::const_iterator i = ChannelerGUID.begin(); i != ChannelerGUID.end(); ++i)
|
||||
{
|
||||
Creature *Channeler = instance->GetCreature(*i);
|
||||
Creature* Channeler = instance->GetCreature(*i);
|
||||
if (Channeler && Channeler->isAlive())
|
||||
{
|
||||
//Channeler->CastSpell(Channeler, SPELL_SOUL_TRANSFER, true);
|
||||
@@ -221,7 +221,7 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
{
|
||||
if (CageTimer <= diff)
|
||||
{
|
||||
Creature *Magtheridon = instance->GetCreature(MagtheridonGUID);
|
||||
Creature* Magtheridon = instance->GetCreature(MagtheridonGUID);
|
||||
if (Magtheridon && Magtheridon->isAlive())
|
||||
{
|
||||
Magtheridon->clearUnitState(UNIT_STAT_STUNNED);
|
||||
@@ -237,7 +237,7 @@ class instance_magtheridons_lair : public InstanceMapScript
|
||||
{
|
||||
for (std::set<uint64>::const_iterator i = ChannelerGUID.begin(); i != ChannelerGUID.end(); ++i)
|
||||
{
|
||||
if (Creature *Channeler = instance->GetCreature(*i))
|
||||
if (Creature* Channeler = instance->GetCreature(*i))
|
||||
{
|
||||
if (Channeler->isAlive())
|
||||
Channeler->AI()->EnterEvadeMode();
|
||||
|
||||
@@ -53,22 +53,22 @@ class instance_shattered_halls : public InstanceMapScript
|
||||
nethekurseDoorGUID = 0;
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case DOOR_NETHEKURSE:
|
||||
nethekurseDoorGUID = pGo->GetGUID();
|
||||
nethekurseDoorGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 16807:
|
||||
nethekurseGUID = pCreature->GetGUID();
|
||||
nethekurseGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -83,30 +83,30 @@ class instance_the_eye : public InstanceMapScript
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(pCreature->GetEntry())
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case 20064:
|
||||
ThaladredTheDarkener = pCreature->GetGUID();
|
||||
ThaladredTheDarkener = creature->GetGUID();
|
||||
break;
|
||||
case 20063:
|
||||
MasterEngineerTelonicus = pCreature->GetGUID();
|
||||
MasterEngineerTelonicus = creature->GetGUID();
|
||||
break;
|
||||
case 20062:
|
||||
GrandAstromancerCapernian = pCreature->GetGUID();
|
||||
GrandAstromancerCapernian = creature->GetGUID();
|
||||
break;
|
||||
case 20060:
|
||||
LordSanguinar = pCreature->GetGUID();
|
||||
LordSanguinar = creature->GetGUID();
|
||||
break;
|
||||
case 19622:
|
||||
Kaelthas = pCreature->GetGUID();
|
||||
Kaelthas = creature->GetGUID();
|
||||
break;
|
||||
case 18805:
|
||||
Astromancer = pCreature->GetGUID();
|
||||
Astromancer = creature->GetGUID();
|
||||
break;
|
||||
case 19514:
|
||||
Alar = pCreature->GetGUID();
|
||||
Alar = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,26 +100,26 @@ class instance_arcatraz : public InstanceMapScript
|
||||
}
|
||||
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo, bool /*add*/)
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(pGo->GetEntry())
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case CONTAINMENT_CORE_SECURITY_FIELD_ALPHA: Containment_Core_Security_Field_AlphaGUID = pGo->GetGUID(); break;
|
||||
case CONTAINMENT_CORE_SECURITY_FIELD_BETA: Containment_Core_Security_Field_BetaGUID = pGo->GetGUID(); break;
|
||||
case POD_ALPHA: Pod_AlphaGUID = pGo->GetGUID(); break;
|
||||
case POD_GAMMA: Pod_GammaGUID = pGo->GetGUID(); break;
|
||||
case POD_BETA: Pod_BetaGUID = pGo->GetGUID(); break;
|
||||
case POD_DELTA: Pod_DeltaGUID = pGo->GetGUID(); break;
|
||||
case POD_OMEGA: Pod_OmegaGUID = pGo->GetGUID(); break;
|
||||
case SEAL_SPHERE: GoSphereGUID = pGo->GetGUID(); break;
|
||||
//case WARDENS_SHIELD: Wardens_ShieldGUID = pGo->GetGUID(); break;
|
||||
case CONTAINMENT_CORE_SECURITY_FIELD_ALPHA: Containment_Core_Security_Field_AlphaGUID = go->GetGUID(); break;
|
||||
case CONTAINMENT_CORE_SECURITY_FIELD_BETA: Containment_Core_Security_Field_BetaGUID = go->GetGUID(); break;
|
||||
case POD_ALPHA: Pod_AlphaGUID = go->GetGUID(); break;
|
||||
case POD_GAMMA: Pod_GammaGUID = go->GetGUID(); break;
|
||||
case POD_BETA: Pod_BetaGUID = go->GetGUID(); break;
|
||||
case POD_DELTA: Pod_DeltaGUID = go->GetGUID(); break;
|
||||
case POD_OMEGA: Pod_OmegaGUID = go->GetGUID(); break;
|
||||
case SEAL_SPHERE: GoSphereGUID = go->GetGUID(); break;
|
||||
//case WARDENS_SHIELD: Wardens_ShieldGUID = go->GetGUID(); break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature, bool /*add*/)
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
if (pCreature->GetEntry() == MELLICHAR)
|
||||
MellicharGUID = pCreature->GetGUID();
|
||||
if (creature->GetEntry() == MELLICHAR)
|
||||
MellicharGUID = creature->GetGUID();
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
@@ -132,16 +132,16 @@ class instance_arcatraz : public InstanceMapScript
|
||||
case TYPE_DALLIAH:
|
||||
if (data == DONE)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Containment_Core_Security_Field_BetaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Containment_Core_Security_Field_BetaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[1] = data;
|
||||
break;
|
||||
case TYPE_SOCCOTHRATES:
|
||||
if (data == DONE)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Containment_Core_Security_Field_AlphaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Containment_Core_Security_Field_AlphaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[2] = data;
|
||||
break;
|
||||
@@ -158,47 +158,47 @@ class instance_arcatraz : public InstanceMapScript
|
||||
break;
|
||||
case TYPE_WARDEN_1:
|
||||
if (data == IN_PROGRESS)
|
||||
if (GameObject *pGo = instance->GetGameObject(Pod_AlphaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Pod_AlphaGUID))
|
||||
go->UseDoorOrButton();
|
||||
m_auiEncounter[4] = data;
|
||||
break;
|
||||
case TYPE_WARDEN_2:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Pod_BetaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Pod_BetaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[5] = data;
|
||||
break;
|
||||
case TYPE_WARDEN_3:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Pod_DeltaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Pod_DeltaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[6] = data;
|
||||
break;
|
||||
case TYPE_WARDEN_4:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Pod_GammaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Pod_GammaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[7] = data;
|
||||
break;
|
||||
case TYPE_WARDEN_5:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Pod_OmegaGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Pod_OmegaGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
m_auiEncounter[8] = data;
|
||||
break;
|
||||
case TYPE_SHIELD_OPEN:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
if (GameObject *pGo = instance->GetGameObject(Wardens_ShieldGUID))
|
||||
pGo->UseDoorOrButton();
|
||||
if (GameObject* go = instance->GetGameObject(Wardens_ShieldGUID))
|
||||
go->UseDoorOrButton();
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user