Core/WorldStates: Migrate instance script worldstates to new system
This commit is contained in:
1 parent
fe7e42b0b8
commit
12b60099f8
18 files changed
+90
-392
No files matched your search
@@ -0,0 +1,41 @@
|
||||
DELETE FROM `world_state` WHERE `ID` IN (2436,2453,2454,2540,2541,2784,2842,3104,3106,3479,3480,3486,3504,3524,3581,3582,3583,3584,3585,3810,3815,3816,3931,3932,4116,4129,4131,4162,4389,4390,4408,4882,4884,4903,4904,4940,4941,4942,5049,5050,5051,5636);
|
||||
INSERT INTO `world_state` (`ID`,`DefaultValue`,`MapIDs`,`AreaIDs`,`Comment`) VALUES
|
||||
(2436,0,'560','','The Escape from Durnholde - Incendiary Bombs Set'),
|
||||
(2453,0,'534','','The Battle for Mount Hyjal - Show enemy count'),
|
||||
(2454,0,'534','','The Battle for Mount Hyjal - Enemy count'),
|
||||
(2540,100,'269','','Opening of the Dark Portal - Medivh\'s Shield Remaining'),
|
||||
(2541,0,'269','','Opening of the Dark Portal - Show instance status'),
|
||||
(2784,0,'269','','Opening of the Dark Portal - Time Rifts Opened'),
|
||||
(2842,0,'534','','The Battle for Mount Hyjal - Wave counter'),
|
||||
(3104,0,'568','','Zul\'Aman - Show timer'),
|
||||
(3106,15,'568','','Zul\'Aman - Timer'),
|
||||
(3479,0,'595','','The Culling of Stratholme - Show Plagued Crates Revealed'),
|
||||
(3480,0,'595','','The Culling of Stratholme - Plagued Crates Revealed'),
|
||||
(3486,0,'578','','The Oculus - Centrifuge Constructs Remaining'),
|
||||
(3504,0,'595','','The Culling of Stratholme - Scourge Wave'),
|
||||
(3524,0,'578','','The Oculus - Show Centrifuge Constructs Remaining'),
|
||||
(3581,0,'595','','The Culling of Stratholme - Elder\'s Square Gate wave marker'),
|
||||
(3582,0,'595','','The Culling of Stratholme - Festival Lane Gate wave marker'),
|
||||
(3583,0,'595','','The Culling of Stratholme - King\'s Square Fountain wave marker'),
|
||||
(3584,0,'595','','The Culling of Stratholme - Market Row Gate wave marker'),
|
||||
(3585,0,'595','','The Culling of Stratholme - Town Hall wave marker'),
|
||||
(3810,0,'608','','Violet Hold - Portals Opened'),
|
||||
(3815,100,'608,1544','','Violet Hold - Prison Seal Integrity'),
|
||||
(3816,0,'608,1544','','Violet Hold - Show'),
|
||||
(3931,25,'595','','The Culling of Stratholme - Guardian time remaining'),
|
||||
(3932,0,'595','','The Culling of Stratholme - Show Guardian time remaining'),
|
||||
(4116,0,'603','','Ulduar - Yogg-Saron keepers active'),
|
||||
(4129,4,'603','','Ulduar - Flame Leviathan destroyed towers'),
|
||||
(4131,0,'603','','Ulduar - Algalon timer'),
|
||||
(4162,0,'603','','Ulduar - Razorscale music'),
|
||||
(4389,50,'649','','Trial of the Crusader - Attempts remaining'),
|
||||
(4390,0,'649','','Trial of the Crusader - Show attempts remaining'),
|
||||
(4408,0,'649','','Trial of the Crusader - Player death count'),
|
||||
(4882,0,'668','','Halls of Reflection - Spirit Wave '),
|
||||
(4884,0,'668','','Halls of Reflection - Show Spirit Wave '),
|
||||
(5049,50,'724','','The Ruby Sanctum - Halion\'s corporeality (Normal)'),
|
||||
(5050,50,'724','','The Ruby Sanctum - Halion\'s corporeality (Twilight)'),
|
||||
(5051,0,'724','','The Ruby Sanctum - Show Halion\'s corporeality'),
|
||||
(5636,0,'603','','Ulduar - Show Algalon timer');
|
||||
|
||||
DELETE FROM `criteria_data` WHERE `ScriptName` IN ('achievement_orbital_bombardment','achievement_orbital_devastation','achievement_nuked_from_orbit','achievement_orbit_uary');
|
||||
@@ -8788,7 +8788,6 @@ void Player::SendInitWorldStates(uint32 zoneId, uint32 areaId)
|
||||
Battleground* bg = GetBattleground();
|
||||
uint32 mapid = GetMapId();
|
||||
OutdoorPvP* pvp = sOutdoorPvPMgr->GetOutdoorPvPToZoneId(zoneId);
|
||||
InstanceScript* instance = GetInstanceScript();
|
||||
|
||||
TC_LOG_DEBUG("network", "Sending SMSG_INIT_WORLD_STATES to Map: %u, Zone: %u", mapid, zoneId);
|
||||
|
||||
@@ -9267,108 +9266,6 @@ void Player::SendInitWorldStates(uint32 zoneId, uint32 areaId)
|
||||
packet.Worldstates.emplace_back(4345, 1); // 24 unknown
|
||||
}
|
||||
break;
|
||||
// The Ruby Sanctum
|
||||
case 4987:
|
||||
if (instance && mapid == 724)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(5049, 50); // 9 WORLDSTATE_CORPOREALITY_MATERIAL
|
||||
packet.Worldstates.emplace_back(5050, 50); // 10 WORLDSTATE_CORPOREALITY_TWILIGHT
|
||||
packet.Worldstates.emplace_back(5051, 0); // 11 WORLDSTATE_CORPOREALITY_TOGGLE
|
||||
}
|
||||
break;
|
||||
// Icecrown Citadel
|
||||
case 4812:
|
||||
if (instance && mapid == 631)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(4903, 0); // 9 WORLDSTATE_SHOW_TIMER (Blood Quickening weekly)
|
||||
packet.Worldstates.emplace_back(4904, 30); // 10 WORLDSTATE_EXECUTION_TIME
|
||||
packet.Worldstates.emplace_back(4940, 0); // 11 WORLDSTATE_SHOW_ATTEMPTS
|
||||
packet.Worldstates.emplace_back(4941, 50); // 12 WORLDSTATE_ATTEMPTS_REMAINING
|
||||
packet.Worldstates.emplace_back(4942, 50); // 13 WORLDSTATE_ATTEMPTS_MAX
|
||||
}
|
||||
break;
|
||||
// The Culling of Stratholme
|
||||
case 4100:
|
||||
if (instance && mapid == 595)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(3479, 0); // 9 WORLDSTATE_SHOW_CRATES
|
||||
packet.Worldstates.emplace_back(3480, 0); // 10 WORLDSTATE_CRATES_REVEALED
|
||||
packet.Worldstates.emplace_back(3504, 0); // 11 WORLDSTATE_WAVE_COUNT
|
||||
packet.Worldstates.emplace_back(3931, 25); // 12 WORLDSTATE_TIME_GUARDIAN
|
||||
packet.Worldstates.emplace_back(3932, 0); // 13 WORLDSTATE_TIME_GUARDIAN_SHOW
|
||||
}
|
||||
break;
|
||||
// The Oculus
|
||||
case 4228:
|
||||
if (instance && mapid == 578)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(3524, 0); // 9 WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW
|
||||
packet.Worldstates.emplace_back(3486, 0); // 10 WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT
|
||||
}
|
||||
break;
|
||||
// Ulduar
|
||||
case 4273:
|
||||
if (instance && mapid == 603)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(4132, 0); // 9 WORLDSTATE_ALGALON_TIMER_ENABLED
|
||||
packet.Worldstates.emplace_back(4131, 0); // 10 WORLDSTATE_ALGALON_DESPAWN_TIMER
|
||||
}
|
||||
break;
|
||||
// Violet Hold
|
||||
case 4415:
|
||||
if (instance && mapid == 608)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(3816, 0); // 9 WORLD_STATE_VH_SHOW
|
||||
packet.Worldstates.emplace_back(3815, 100); // 10 WORLD_STATE_VH_PRISON_STATE
|
||||
packet.Worldstates.emplace_back(3810, 0); // 11 WORLD_STATE_VH_WAVE_COUNT
|
||||
}
|
||||
break;
|
||||
// Halls of Refection
|
||||
case 4820:
|
||||
if (instance && mapid == 668)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(4884, 0); // 9 WORLD_STATE_HOR_WAVES_ENABLED
|
||||
packet.Worldstates.emplace_back(4882, 0); // 10 WORLD_STATE_HOR_WAVE_COUNT
|
||||
}
|
||||
break;
|
||||
// Zul Aman
|
||||
case 3805:
|
||||
if (instance && mapid == 568)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
{
|
||||
packet.Worldstates.emplace_back(3104, 0); // 9 WORLD_STATE_ZULAMAN_TIMER_ENABLED
|
||||
packet.Worldstates.emplace_back(3106, 0); // 10 WORLD_STATE_ZULAMAN_TIMER
|
||||
}
|
||||
break;
|
||||
// The Vortex Pinnacle
|
||||
case 5035:
|
||||
if (instance && mapid == 657)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
packet.Worldstates.emplace_back(5649, 0);
|
||||
break;
|
||||
// Blackwing Descent
|
||||
case 5094:
|
||||
if (instance && mapid == 669)
|
||||
instance->FillInitialWorldStates(packet);
|
||||
else
|
||||
packet.Worldstates.emplace_back(5652, 1);
|
||||
break;
|
||||
// Twin Peaks
|
||||
case 5031:
|
||||
if (bg && bg->GetTypeID(true) == BATTLEGROUND_TP)
|
||||
|
||||
@@ -40,6 +40,7 @@
|
||||
#include "ScriptReloadMgr.h"
|
||||
#include "World.h"
|
||||
#include "WorldSession.h"
|
||||
#include "WorldStateMgr.h"
|
||||
#include <cstdarg>
|
||||
#include <sstream>
|
||||
|
||||
@@ -575,18 +576,9 @@ void InstanceScript::DoRespawnGameObject(ObjectGuid guid, uint32 timeToDespawn /
|
||||
TC_LOG_DEBUG("scripts", "InstanceScript: DoRespawnGameObject failed");
|
||||
}
|
||||
|
||||
void InstanceScript::DoUpdateWorldState(uint32 uiStateId, uint32 uiStateData)
|
||||
void InstanceScript::DoUpdateWorldState(int32 worldStateId, int32 value)
|
||||
{
|
||||
Map::PlayerList const& lPlayers = instance->GetPlayers();
|
||||
|
||||
if (!lPlayers.isEmpty())
|
||||
{
|
||||
for (Map::PlayerList::const_iterator itr = lPlayers.begin(); itr != lPlayers.end(); ++itr)
|
||||
if (Player* player = itr->GetSource())
|
||||
player->SendUpdateWorldState(uiStateId, uiStateData);
|
||||
}
|
||||
else
|
||||
TC_LOG_DEBUG("scripts", "DoUpdateWorldState attempt send data but no players in map.");
|
||||
sWorldStateMgr->SetValue(worldStateId, value, instance);
|
||||
}
|
||||
|
||||
// Send Notify to all players in instance
|
||||
|
||||
@@ -43,14 +43,6 @@ enum AchievementCriteriaTypes : uint8;
|
||||
enum AchievementCriteriaTimedTypes : uint8;
|
||||
enum EncounterCreditType : uint8;
|
||||
|
||||
namespace WorldPackets
|
||||
{
|
||||
namespace WorldState
|
||||
{
|
||||
class InitWorldStates;
|
||||
}
|
||||
}
|
||||
|
||||
enum EncounterFrameType
|
||||
{
|
||||
ENCOUNTER_FRAME_SET_COMBAT_RES_LIMIT = 0,
|
||||
@@ -214,7 +206,7 @@ class TC_GAME_API InstanceScript : public ZoneScript
|
||||
void DoRespawnGameObject(ObjectGuid guid, uint32 timeToDespawn = MINUTE);
|
||||
|
||||
// Sends world state update to all players in instance
|
||||
void DoUpdateWorldState(uint32 worldstateId, uint32 worldstateValue);
|
||||
void DoUpdateWorldState(int32 worldStateId, int32 value);
|
||||
|
||||
// Send Notify to all players in instance
|
||||
void DoSendNotifyToInstance(char const* format, ...);
|
||||
@@ -259,8 +251,6 @@ class TC_GAME_API InstanceScript : public ZoneScript
|
||||
|
||||
void SendEncounterUnit(uint32 type, Unit* unit = nullptr, uint8 param1 = 0, uint8 param2 = 0);
|
||||
|
||||
virtual void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& /*data*/) { }
|
||||
|
||||
// ReCheck PhaseTemplate related conditions
|
||||
void UpdatePhasing();
|
||||
|
||||
|
||||
-1
@@ -24,7 +24,6 @@
|
||||
#include "EventMap.h"
|
||||
#include "CreatureAI.h"
|
||||
#include "TemporarySummon.h"
|
||||
#include "WorldStatePackets.h"
|
||||
#include "blackwing_descent.h"
|
||||
|
||||
ObjectData const creatureData[] =
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
#include "Map.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "MotionMaster.h"
|
||||
#include "WorldStatePackets.h"
|
||||
#include "zulaman.h"
|
||||
|
||||
ObjectData const creatureData[] =
|
||||
@@ -76,12 +75,6 @@ public:
|
||||
_speedRunState = NOT_STARTED;
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& packet) override
|
||||
{
|
||||
packet.Worldstates.emplace_back(uint32(WORLD_STATE_ZULAMAN_TIMER_ENABLED), uint32(_speedRunState ? 1 : 0));
|
||||
packet.Worldstates.emplace_back(uint32(WORLD_STATE_ZULAMAN_TIMER), uint32(_remainingSpeedRunTime));
|
||||
}
|
||||
|
||||
void Load(char const* /*data*/) override
|
||||
{
|
||||
// If players enter the instance after a soft-reset, the speedrun is failed
|
||||
|
||||
+20
-57
@@ -30,7 +30,6 @@
|
||||
#include "ScriptMgr.h"
|
||||
#include "SpellInfo.h"
|
||||
#include "TemporarySummon.h"
|
||||
#include "WorldStatePackets.h"
|
||||
#include <array>
|
||||
#include <unordered_map>
|
||||
#include <unordered_set>
|
||||
@@ -275,16 +274,9 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
LoadDoorData(doorData);
|
||||
|
||||
_currentWorldStates[WORLDSTATE_SHOW_CRATES] = _currentWorldStates[WORLDSTATE_CRATES_REVEALED] = _currentWorldStates[WORLDSTATE_WAVE_COUNT] = _currentWorldStates[WORLDSTATE_TIME_GUARDIAN_SHOW] = _currentWorldStates[WORLDSTATE_TIME_GUARDIAN] = 0;
|
||||
_sentWorldStates = _currentWorldStates;
|
||||
_plagueCrates.reserve(NUM_PLAGUE_CRATES);
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
for (WorldStateMap::const_iterator itr = _sentWorldStates.begin(); itr != _sentWorldStates.end(); ++itr)
|
||||
data.Worldstates.emplace_back(uint32(itr->first), uint32(itr->second));
|
||||
}
|
||||
|
||||
void WriteSaveDataMore(std::ostringstream& data) override
|
||||
{
|
||||
data << _currentState << ' ' << _infiniteGuardianTimeout;
|
||||
@@ -332,7 +324,7 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
break;
|
||||
case DATA_CRATE_REVEALED:
|
||||
if (uint32 missingCrates = MissingPlagueCrates())
|
||||
SetWorldState(WORLDSTATE_CRATES_REVEALED, NUM_PLAGUE_CRATES - missingCrates);
|
||||
DoUpdateWorldState(WORLDSTATE_CRATES_REVEALED, NUM_PLAGUE_CRATES - missingCrates);
|
||||
else
|
||||
SetInstanceProgress(CRATES_DONE, false);
|
||||
break;
|
||||
@@ -392,8 +384,7 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
|
||||
// clear existing world markers
|
||||
for (uint32 marker = WAVE_MARKER_MIN; marker <= WAVE_MARKER_MAX; ++marker)
|
||||
SetWorldState(COSWorldStates(marker), 0, false);
|
||||
PropagateWorldStateUpdate();
|
||||
DoUpdateWorldState(COSWorldStates(marker), 0);
|
||||
|
||||
// schedule next wave if applicable
|
||||
if (_waveCount < NUM_SCOURGE_WAVES)
|
||||
@@ -461,8 +452,8 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
if (type == DATA_INFINITE_CORRUPTOR && state == DONE)
|
||||
{
|
||||
events.CancelEvent(EVENT_GUARDIAN_TICK);
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 0, false);
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN, 0);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 0);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN, 0);
|
||||
}
|
||||
|
||||
if (!InstanceScript::SetBossState(type, state))
|
||||
@@ -487,8 +478,8 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
if (secondsToGuardianDeath <= 0)
|
||||
{
|
||||
_infiniteGuardianTimeout = 0;
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 0, false);
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN, 0);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 0);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN, 0);
|
||||
|
||||
if (Creature* corruptor = instance->GetCreature(_corruptorGUID))
|
||||
{
|
||||
@@ -515,8 +506,8 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
chromie->AI()->Talk(CHROMIE_WHISPER_GUARDIAN_3);
|
||||
|
||||
// update the timer state
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 1, false);
|
||||
SetWorldState(WORLDSTATE_TIME_GUARDIAN, minutes + 1);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN_SHOW, 1);
|
||||
DoUpdateWorldState(WORLDSTATE_TIME_GUARDIAN, minutes + 1);
|
||||
if (minutes == 4 && seconds > 30)
|
||||
events.Repeat(Seconds(seconds - 30));
|
||||
else
|
||||
@@ -540,7 +531,7 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
break;
|
||||
|
||||
++_waveCount;
|
||||
SetWorldState(WORLDSTATE_WAVE_COUNT, _waveCount);
|
||||
DoUpdateWorldState(WORLDSTATE_WAVE_COUNT, _waveCount);
|
||||
|
||||
uint8 spawnLoc = urand(WAVE_LOC_MIN, WAVE_LOC_MAX);
|
||||
while (spawnLoc == _currentSpawnLoc) // don't allow repeats
|
||||
@@ -575,8 +566,8 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
}
|
||||
|
||||
for (uint32 marker = WAVE_MARKER_MIN; marker <= WAVE_MARKER_MAX; ++marker)
|
||||
SetWorldState(COSWorldStates(marker), 0, false);
|
||||
SetWorldState(spawnLocation.WorldState, 1);
|
||||
DoUpdateWorldState(COSWorldStates(marker), 0);
|
||||
DoUpdateWorldState(spawnLocation.WorldState, 1);
|
||||
|
||||
events.RescheduleEvent(EVENT_CRIER_ANNOUNCE_WAVE, 2s);
|
||||
_currentSpawnLoc = spawnLoc;
|
||||
@@ -691,26 +682,24 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
// Plague crates
|
||||
if (state == CRATES_IN_PROGRESS)
|
||||
{
|
||||
SetWorldState(WORLDSTATE_SHOW_CRATES, 1, false);
|
||||
SetWorldState(WORLDSTATE_CRATES_REVEALED, 0, false);
|
||||
DoUpdateWorldState(WORLDSTATE_SHOW_CRATES, 1);
|
||||
DoUpdateWorldState(WORLDSTATE_CRATES_REVEALED, 0);
|
||||
}
|
||||
else if (state == CRATES_DONE)
|
||||
{
|
||||
SetWorldState(WORLDSTATE_SHOW_CRATES, 1, false);
|
||||
SetWorldState(WORLDSTATE_CRATES_REVEALED, NUM_PLAGUE_CRATES, false);
|
||||
DoUpdateWorldState(WORLDSTATE_SHOW_CRATES, 1);
|
||||
DoUpdateWorldState(WORLDSTATE_CRATES_REVEALED, NUM_PLAGUE_CRATES);
|
||||
}
|
||||
else
|
||||
{
|
||||
SetWorldState(WORLDSTATE_SHOW_CRATES, 0, false);
|
||||
SetWorldState(WORLDSTATE_CRATES_REVEALED, state == JUST_STARTED ? 0 : NUM_PLAGUE_CRATES, false);
|
||||
DoUpdateWorldState(WORLDSTATE_SHOW_CRATES, 0);
|
||||
DoUpdateWorldState(WORLDSTATE_CRATES_REVEALED, state == JUST_STARTED ? 0 : NUM_PLAGUE_CRATES);
|
||||
}
|
||||
// Scourge wave counter
|
||||
if (state == WAVES_DONE)
|
||||
SetWorldState(WORLDSTATE_WAVE_COUNT, NUM_SCOURGE_WAVES, false);
|
||||
DoUpdateWorldState(WORLDSTATE_WAVE_COUNT, NUM_SCOURGE_WAVES);
|
||||
else
|
||||
SetWorldState(WORLDSTATE_WAVE_COUNT, 0, false);
|
||||
|
||||
PropagateWorldStateUpdate();
|
||||
DoUpdateWorldState(WORLDSTATE_WAVE_COUNT, 0);
|
||||
|
||||
// Hidden Passage status handling
|
||||
if (GameObject* passage = instance->GetGameObject(_passageGUID))
|
||||
@@ -770,8 +759,6 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
}
|
||||
|
||||
private:
|
||||
typedef std::unordered_map<uint32, uint32> WorldStateMap;
|
||||
|
||||
uint32 MissingPlagueCrates() const
|
||||
{
|
||||
uint32 returnValue = 0;
|
||||
@@ -794,29 +781,6 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void SetWorldState(COSWorldStates state, uint32 value, bool immediate = true)
|
||||
{
|
||||
TC_LOG_DEBUG("scripts.cos", "instance_culling_of_stratholme::SetWorldState: %u %u", uint32(state), value);
|
||||
_currentWorldStates[state] = value;
|
||||
if (immediate)
|
||||
PropagateWorldStateUpdate();
|
||||
}
|
||||
|
||||
void PropagateWorldStateUpdate()
|
||||
{
|
||||
TC_LOG_DEBUG("scripts.cos", "instance_culling_of_stratholme::PropagateWorldStateUpdate: Propagate world states");
|
||||
for (WorldStateMap::const_iterator it = _currentWorldStates.begin(); it != _currentWorldStates.end(); ++it)
|
||||
{
|
||||
uint32& sent = _sentWorldStates[it->first];
|
||||
if (sent != it->second)
|
||||
{
|
||||
TC_LOG_DEBUG("scripts.cos", "instance_culling_of_stratholme::PropagateWorldStateUpdate: Sending world state %u (%u)", it->first, it->second);
|
||||
DoUpdateWorldState(it->first, it->second);
|
||||
sent = it->second;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void SetSpawnGroupState(COSInstanceEntries group, bool state, bool force)
|
||||
{
|
||||
if (state)
|
||||
@@ -829,8 +793,7 @@ class instance_culling_of_stratholme : public InstanceMapScript
|
||||
|
||||
EventMap events;
|
||||
COSProgressStates _currentState;
|
||||
WorldStateMap _sentWorldStates;
|
||||
WorldStateMap _currentWorldStates;
|
||||
std::unordered_map<uint32, uint32> _currentWorldStates;
|
||||
time_t _infiniteGuardianTimeout;
|
||||
|
||||
// Generic
|
||||
|
||||
+1
-16
@@ -104,13 +104,6 @@ public:
|
||||
_currentRiftId = 0;
|
||||
}
|
||||
|
||||
void InitWorldState(bool Enable = true)
|
||||
{
|
||||
DoUpdateWorldState(WORLD_STATE_BM, Enable ? 1 : 0);
|
||||
DoUpdateWorldState(WORLD_STATE_BM_SHIELD, 100);
|
||||
DoUpdateWorldState(WORLD_STATE_BM_RIFT, 0);
|
||||
}
|
||||
|
||||
bool IsEncounterInProgress() const override
|
||||
{
|
||||
if (GetData(TYPE_MEDIVH) == IN_PROGRESS)
|
||||
@@ -119,14 +112,6 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void OnPlayerEnter(Player* player) override
|
||||
{
|
||||
if (GetData(TYPE_MEDIVH) == IN_PROGRESS)
|
||||
return;
|
||||
|
||||
player->SendUpdateWorldState(WORLD_STATE_BM, 0);
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature) override
|
||||
{
|
||||
if (creature->GetEntry() == NPC_MEDIVH)
|
||||
@@ -188,7 +173,7 @@ public:
|
||||
if (data == IN_PROGRESS)
|
||||
{
|
||||
TC_LOG_DEBUG("scripts", "Instance The Black Morass: Starting event.");
|
||||
InitWorldState();
|
||||
DoUpdateWorldState(WORLD_STATE_BM, 1);
|
||||
m_auiEncounter[1] = IN_PROGRESS;
|
||||
ScheduleEventNextPortal(15000);
|
||||
}
|
||||
|
||||
@@ -23,7 +23,6 @@
|
||||
#include "Map.h"
|
||||
#include "MotionMaster.h"
|
||||
#include "TemporarySummon.h"
|
||||
#include "WorldStatePackets.h"
|
||||
#include "vortex_pinnacle.h"
|
||||
|
||||
#define MAX_ENCOUNTER 3
|
||||
@@ -226,11 +225,6 @@ class instance_vortex_pinnacle : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WS_GOLDEN_ORBS_COLLECTED), uint32(_collectedGoldenOrbs));
|
||||
}
|
||||
|
||||
void WriteSaveDataMore(std::ostringstream& data) override
|
||||
{
|
||||
data << _collectedGoldenOrbs;
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
* with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "ruby_sanctum.h"
|
||||
#include "ScriptMgr.h"
|
||||
#include "AreaBoundary.h"
|
||||
#include "Creature.h"
|
||||
@@ -22,8 +23,6 @@
|
||||
#include "GameObject.h"
|
||||
#include "InstanceScript.h"
|
||||
#include "Map.h"
|
||||
#include "WorldStatePackets.h"
|
||||
#include "ruby_sanctum.h"
|
||||
|
||||
Position const HalionControllerSpawnPos = { 3156.037f, 533.2656f, 72.97205f, 0.0f };
|
||||
|
||||
@@ -197,13 +196,6 @@ class instance_ruby_sanctum : public InstanceMapScript
|
||||
return BaltharusSharedHealth;
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WORLDSTATE_CORPOREALITY_MATERIAL), uint32(50));
|
||||
data.Worldstates.emplace_back(uint32(WORLDSTATE_CORPOREALITY_TWILIGHT), uint32(50));
|
||||
data.Worldstates.emplace_back(uint32(WORLDSTATE_CORPOREALITY_TOGGLE), uint32(0));
|
||||
}
|
||||
|
||||
protected:
|
||||
ObjectGuid ZarithrianSpawnStalkerGUID[2];
|
||||
uint32 BaltharusSharedHealth;
|
||||
|
||||
+8
-29
@@ -55,8 +55,9 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
ResilienceWillFixItTimer = 0;
|
||||
SnoboldCount = 0;
|
||||
MistressOfPainCount = 0;
|
||||
TributeToImmortalityEligible = true;
|
||||
PlayerDeathCount = 0;
|
||||
NeedSave = false;
|
||||
DoUpdateWorldState(UPDATE_STATE_UI_SHOW, instance->IsHeroic() ? 1 : 0);
|
||||
}
|
||||
|
||||
bool IsEncounterInProgress() const override
|
||||
@@ -74,14 +75,6 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
|
||||
void OnPlayerEnter(Player* player) override
|
||||
{
|
||||
if (instance->IsHeroic())
|
||||
{
|
||||
player->SendUpdateWorldState(UPDATE_STATE_UI_SHOW, 1);
|
||||
player->SendUpdateWorldState(UPDATE_STATE_UI_COUNT, GetData(TYPE_COUNTER));
|
||||
}
|
||||
else
|
||||
player->SendUpdateWorldState(UPDATE_STATE_UI_SHOW, 0);
|
||||
|
||||
// make sure Anub'arak isnt missing
|
||||
if (GetBossState(BOSS_LICH_KING) == DONE && TrialCounter && GetBossState(BOSS_ANUBARAK) != DONE)
|
||||
if (!ObjectAccessor::GetCreature(*player, GetGuidData(NPC_ANUBARAK)))
|
||||
@@ -207,8 +200,10 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
void OnUnitDeath(Unit* unit) override
|
||||
{
|
||||
if (unit->GetTypeId() == TYPEID_PLAYER && IsEncounterInProgress())
|
||||
TributeToImmortalityEligible = false;
|
||||
|
||||
{
|
||||
++PlayerDeathCount;
|
||||
DoUpdateWorldState(WORLD_STATE_PLAYER_DEATHS, PlayerDeathCount);
|
||||
}
|
||||
}
|
||||
|
||||
bool SetBossState(uint32 type, EncounterState state) override
|
||||
@@ -351,10 +346,7 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
{
|
||||
--TrialCounter;
|
||||
// decrease attempt counter at wipe
|
||||
Map::PlayerList const &PlayerList = instance->GetPlayers();
|
||||
for (Map::PlayerList::const_iterator itr = PlayerList.begin(); itr != PlayerList.end(); ++itr)
|
||||
if (Player* player = itr->GetSource())
|
||||
player->SendUpdateWorldState(UPDATE_STATE_UI_COUNT, TrialCounter);
|
||||
DoUpdateWorldState(UPDATE_STATE_UI_COUNT, TrialCounter);
|
||||
|
||||
// if theres no more attemps allowed
|
||||
if (!TrialCounter)
|
||||
@@ -687,19 +679,6 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
case THREE_SIXTY_PAIN_SPIKE_25_PLAYER:
|
||||
case THREE_SIXTY_PAIN_SPIKE_25_PLAYER_HEROIC:
|
||||
return MistressOfPainCount >= 2;
|
||||
case A_TRIBUTE_TO_SKILL_10_PLAYER:
|
||||
case A_TRIBUTE_TO_SKILL_25_PLAYER:
|
||||
return TrialCounter >= 25;
|
||||
case A_TRIBUTE_TO_MAD_SKILL_10_PLAYER:
|
||||
case A_TRIBUTE_TO_MAD_SKILL_25_PLAYER:
|
||||
return TrialCounter >= 45;
|
||||
case A_TRIBUTE_TO_INSANITY_10_PLAYER:
|
||||
case A_TRIBUTE_TO_INSANITY_25_PLAYER:
|
||||
case REALM_FIRST_GRAND_CRUSADER:
|
||||
return TrialCounter == 50;
|
||||
case A_TRIBUTE_TO_IMMORTALITY_HORDE:
|
||||
case A_TRIBUTE_TO_IMMORTALITY_ALLIANCE:
|
||||
return TrialCounter == 50 && TributeToImmortalityEligible;
|
||||
case A_TRIBUTE_TO_DEDICATED_INSANITY:
|
||||
return false/*uiGrandCrusaderAttemptsLeft == 50 && !bHasAtAnyStagePlayerEquippedTooGoodItem*/;
|
||||
default:
|
||||
@@ -746,7 +725,7 @@ class instance_trial_of_the_crusader : public InstanceMapScript
|
||||
uint32 ResilienceWillFixItTimer;
|
||||
uint8 SnoboldCount;
|
||||
uint8 MistressOfPainCount;
|
||||
bool TributeToImmortalityEligible;
|
||||
int32 PlayerDeathCount;
|
||||
};
|
||||
|
||||
InstanceScript* GetInstanceScript(InstanceMap* map) const override
|
||||
|
||||
+2
-1
@@ -68,7 +68,8 @@ extern Position const AnubarakLoc[];
|
||||
enum TCRWorldStateIds
|
||||
{
|
||||
UPDATE_STATE_UI_SHOW = 4390,
|
||||
UPDATE_STATE_UI_COUNT = 4389
|
||||
UPDATE_STATE_UI_COUNT = 4389,
|
||||
WORLD_STATE_PLAYER_DEATHS = 4408
|
||||
};
|
||||
|
||||
enum NorthrendBeasts
|
||||
|
||||
-7
@@ -27,7 +27,6 @@
|
||||
#include "TemporarySummon.h"
|
||||
#include "Transport.h"
|
||||
#include "TransportMgr.h"
|
||||
#include "WorldStatePackets.h"
|
||||
|
||||
Position const JainaSpawnPos = { 5236.659f, 1929.894f, 707.7781f, 0.8726646f }; // Jaina Spawn Position
|
||||
Position const SylvanasSpawnPos = { 5236.667f, 1929.906f, 707.7781f, 0.8377581f }; // Sylvanas Spawn Position (sniffed)
|
||||
@@ -294,12 +293,6 @@ class instance_halls_of_reflection : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_HOR_WAVES_ENABLED), uint32(_introState == DONE && GetBossState(DATA_MARWYN) != DONE));
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_HOR_WAVE_COUNT), uint32(_waveCount));
|
||||
}
|
||||
|
||||
bool SetBossState(uint32 type, EncounterState state) override
|
||||
{
|
||||
if (!InstanceScript::SetBossState(type, state))
|
||||
|
||||
@@ -26,7 +26,6 @@
|
||||
#include "PhasingHandler.h"
|
||||
#include "TemporarySummon.h"
|
||||
#include "WorldPacket.h"
|
||||
#include "WorldStatePackets.h"
|
||||
|
||||
DoorData const doorData[] =
|
||||
{
|
||||
@@ -147,20 +146,6 @@ class instance_oculus : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
if (GetBossState(DATA_DRAKOS) == DONE && GetBossState(DATA_VAROS) != DONE)
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW), uint32(1));
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT), uint32(CentrifugueConstructCounter));
|
||||
}
|
||||
else
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW), uint32(0));
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT), uint32(0));
|
||||
}
|
||||
}
|
||||
|
||||
void ProcessEvent(WorldObject* /*unit*/, uint32 eventId, WorldObject* /*invoker*/) override
|
||||
{
|
||||
if (eventId != EVENT_CALL_DRAGON)
|
||||
|
||||
@@ -140,7 +140,6 @@ enum Vehicles
|
||||
enum Misc
|
||||
{
|
||||
DATA_SHUTOUT = 29112912, // 2911, 2912 are achievement IDs
|
||||
DATA_ORBIT_ACHIEVEMENTS = 1,
|
||||
VEHICLE_SPAWNS = 5,
|
||||
FREYA_SPAWNS = 4
|
||||
|
||||
@@ -351,10 +350,6 @@ class boss_flame_leviathan : public CreatureScript
|
||||
return Shutout ? 1 : 0;
|
||||
case DATA_UNBROKEN:
|
||||
return Unbroken ? 1 : 0;
|
||||
case DATA_ORBIT_ACHIEVEMENTS:
|
||||
if (ActiveTowers) // Only on HardMode
|
||||
return ActiveTowersCount;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -521,6 +516,7 @@ class boss_flame_leviathan : public CreatureScript
|
||||
{
|
||||
towerOfStorms = false;
|
||||
--ActiveTowersCount;
|
||||
instance->DoUpdateWorldState(WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS, 4 - ActiveTowersCount);
|
||||
}
|
||||
break;
|
||||
case ACTION_TOWER_OF_FROST_DESTROYED:
|
||||
@@ -528,6 +524,7 @@ class boss_flame_leviathan : public CreatureScript
|
||||
{
|
||||
towerOfFrost = false;
|
||||
--ActiveTowersCount;
|
||||
instance->DoUpdateWorldState(WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS, 4 - ActiveTowersCount);
|
||||
}
|
||||
break;
|
||||
case ACTION_TOWER_OF_FLAMES_DESTROYED:
|
||||
@@ -535,16 +532,18 @@ class boss_flame_leviathan : public CreatureScript
|
||||
{
|
||||
towerOfFlames = false;
|
||||
--ActiveTowersCount;
|
||||
instance->DoUpdateWorldState(WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS, 4 - ActiveTowersCount);
|
||||
}
|
||||
break;
|
||||
case ACTION_TOWER_OF_LIFE_DESTROYED:
|
||||
if (towerOfLife)
|
||||
{
|
||||
towerOfLife = false;
|
||||
--ActiveTowersCount;
|
||||
instance->DoUpdateWorldState(WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS, 4 - ActiveTowersCount);
|
||||
}
|
||||
break;
|
||||
case ACTION_START_HARD_MODE: // Activate hard-mode enable all towers, apply buffs on leviathan
|
||||
instance->DoUpdateWorldState(WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS, 0);
|
||||
ActiveTowers = true;
|
||||
towerOfStorms = true;
|
||||
towerOfLife = true;
|
||||
@@ -1426,78 +1425,6 @@ class achievement_unbroken : public AchievementCriteriaScript
|
||||
}
|
||||
};
|
||||
|
||||
class achievement_orbital_bombardment : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_orbital_bombardment() : AchievementCriteriaScript("achievement_orbital_bombardment") { }
|
||||
|
||||
bool OnCheck(Player* /*source*/, Unit* target) override
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
if (Creature* Leviathan = target->ToCreature())
|
||||
if (Leviathan->AI()->GetData(DATA_ORBIT_ACHIEVEMENTS) >= 1)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
class achievement_orbital_devastation : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_orbital_devastation() : AchievementCriteriaScript("achievement_orbital_devastation") { }
|
||||
|
||||
bool OnCheck(Player* /*source*/, Unit* target) override
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
if (Creature* Leviathan = target->ToCreature())
|
||||
if (Leviathan->AI()->GetData(DATA_ORBIT_ACHIEVEMENTS) >= 2)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
class achievement_nuked_from_orbit : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_nuked_from_orbit() : AchievementCriteriaScript("achievement_nuked_from_orbit") { }
|
||||
|
||||
bool OnCheck(Player* /*source*/, Unit* target) override
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
if (Creature* Leviathan = target->ToCreature())
|
||||
if (Leviathan->AI()->GetData(DATA_ORBIT_ACHIEVEMENTS) >= 3)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
class achievement_orbit_uary : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_orbit_uary() : AchievementCriteriaScript("achievement_orbit_uary") { }
|
||||
|
||||
bool OnCheck(Player* /*source*/, Unit* target) override
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
if (Creature* Leviathan = target->ToCreature())
|
||||
if (Leviathan->AI()->GetData(DATA_ORBIT_ACHIEVEMENTS) == 4)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
class spell_load_into_catapult : public SpellScriptLoader
|
||||
{
|
||||
enum Spells
|
||||
@@ -1817,10 +1744,6 @@ void AddSC_boss_flame_leviathan()
|
||||
new achievement_three_car_garage_siege();
|
||||
new achievement_shutout();
|
||||
new achievement_unbroken();
|
||||
new achievement_orbital_bombardment();
|
||||
new achievement_orbital_devastation();
|
||||
new achievement_nuked_from_orbit();
|
||||
new achievement_orbit_uary();
|
||||
|
||||
new spell_load_into_catapult();
|
||||
new spell_auto_repair();
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
#include "ulduar.h"
|
||||
#include "Vehicle.h"
|
||||
#include "WorldPacket.h"
|
||||
#include "WorldStatePackets.h"
|
||||
|
||||
static BossBoundaryData const boundaries =
|
||||
{
|
||||
@@ -204,12 +203,6 @@ class instance_ulduar : public InstanceMapScript
|
||||
bool Unbroken;
|
||||
bool IsDriveMeCrazyEligible;
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& packet) override
|
||||
{
|
||||
packet.Worldstates.emplace_back(uint32(WORLD_STATE_ALGALON_TIMER_ENABLED), uint32(_algalonTimer && _algalonTimer <= 60));
|
||||
packet.Worldstates.emplace_back(uint32(WORLD_STATE_ALGALON_DESPAWN_TIMER), uint32(std::min<uint32>(_algalonTimer, 60)));
|
||||
}
|
||||
|
||||
void OnPlayerEnter(Player* player) override
|
||||
{
|
||||
if (!TeamInInstance)
|
||||
@@ -380,24 +373,28 @@ class instance_ulduar : public InstanceMapScript
|
||||
_summonYSKeeper[0] = false;
|
||||
SaveToDB();
|
||||
++keepersCount;
|
||||
DoUpdateWorldState(WORLD_STATE_YOGG_SARON_KEEPERS, keepersCount);
|
||||
break;
|
||||
case NPC_HODIR_YS:
|
||||
KeeperGUIDs[1] = creature->GetGUID();
|
||||
_summonYSKeeper[1] = false;
|
||||
SaveToDB();
|
||||
++keepersCount;
|
||||
DoUpdateWorldState(WORLD_STATE_YOGG_SARON_KEEPERS, keepersCount);
|
||||
break;
|
||||
case NPC_THORIM_YS:
|
||||
KeeperGUIDs[2] = creature->GetGUID();
|
||||
_summonYSKeeper[2] = false;
|
||||
SaveToDB();
|
||||
++keepersCount;
|
||||
DoUpdateWorldState(WORLD_STATE_YOGG_SARON_KEEPERS, keepersCount);
|
||||
break;
|
||||
case NPC_MIMIRON_YS:
|
||||
KeeperGUIDs[3] = creature->GetGUID();
|
||||
_summonYSKeeper[3] = false;
|
||||
SaveToDB();
|
||||
++keepersCount;
|
||||
DoUpdateWorldState(WORLD_STATE_YOGG_SARON_KEEPERS, keepersCount);
|
||||
break;
|
||||
case NPC_SANITY_WELL:
|
||||
creature->SetReactState(REACT_PASSIVE);
|
||||
@@ -894,18 +891,6 @@ class instance_ulduar : public InstanceMapScript
|
||||
case CRITERIA_DRIVE_ME_CRAZY_10:
|
||||
case CRITERIA_DRIVE_ME_CRAZY_25:
|
||||
return IsDriveMeCrazyEligible;
|
||||
case CRITERIA_THREE_LIGHTS_IN_THE_DARKNESS_10:
|
||||
case CRITERIA_THREE_LIGHTS_IN_THE_DARKNESS_25:
|
||||
return keepersCount <= 3;
|
||||
case CRITERIA_TWO_LIGHTS_IN_THE_DARKNESS_10:
|
||||
case CRITERIA_TWO_LIGHTS_IN_THE_DARKNESS_25:
|
||||
return keepersCount <= 2;
|
||||
case CRITERIA_ONE_LIGHT_IN_THE_DARKNESS_10:
|
||||
case CRITERIA_ONE_LIGHT_IN_THE_DARKNESS_25:
|
||||
return keepersCount <= 1;
|
||||
case CRITERIA_ALONE_IN_THE_DARKNESS_10:
|
||||
case CRITERIA_ALONE_IN_THE_DARKNESS_25:
|
||||
return keepersCount == 0;
|
||||
case CRITERIA_C_O_U_LEVIATHAN_10:
|
||||
case CRITERIA_C_O_U_LEVIATHAN_25:
|
||||
return (_CoUAchivePlayerDeathMask & (1 << DATA_FLAME_LEVIATHAN)) == 0;
|
||||
|
||||
@@ -346,14 +346,6 @@ enum UlduarAchievementCriteriaIds
|
||||
CRITERIA_WAITS_DREAMING_ICECROWN_10 = 10326,
|
||||
CRITERIA_DRIVE_ME_CRAZY_10 = 10185,
|
||||
CRITERIA_DRIVE_ME_CRAZY_25 = 10296,
|
||||
CRITERIA_THREE_LIGHTS_IN_THE_DARKNESS_10 = 10410,
|
||||
CRITERIA_THREE_LIGHTS_IN_THE_DARKNESS_25 = 10414,
|
||||
CRITERIA_TWO_LIGHTS_IN_THE_DARKNESS_10 = 10388,
|
||||
CRITERIA_TWO_LIGHTS_IN_THE_DARKNESS_25 = 10415,
|
||||
CRITERIA_ONE_LIGHT_IN_THE_DARKNESS_10 = 10409,
|
||||
CRITERIA_ONE_LIGHT_IN_THE_DARKNESS_25 = 10416,
|
||||
CRITERIA_ALONE_IN_THE_DARKNESS_10 = 10412,
|
||||
CRITERIA_ALONE_IN_THE_DARKNESS_25 = 10417,
|
||||
CRITERIA_HERALD_OF_TITANS = 10678,
|
||||
|
||||
// Champion of Ulduar
|
||||
@@ -461,8 +453,10 @@ enum UlduarData
|
||||
|
||||
enum UlduarWorldStates
|
||||
{
|
||||
WORLD_STATE_ALGALON_DESPAWN_TIMER = 4131,
|
||||
WORLD_STATE_ALGALON_TIMER_ENABLED = 4132,
|
||||
WORLD_STATE_FLAME_LEVIATHAN_DESTROYED_TOWERS = 4129,
|
||||
WORLD_STATE_YOGG_SARON_KEEPERS = 4116,
|
||||
WORLD_STATE_ALGALON_DESPAWN_TIMER = 4131,
|
||||
WORLD_STATE_ALGALON_TIMER_ENABLED = 5636
|
||||
};
|
||||
|
||||
enum UlduarAchievementData
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
#include "TemporarySummon.h"
|
||||
#include "violet_hold.h"
|
||||
#include "WorldPacket.h"
|
||||
#include "WorldStatePackets.h"
|
||||
|
||||
/*
|
||||
* TODO:
|
||||
@@ -291,13 +290,6 @@ class instance_violet_hold : public InstanceMapScript
|
||||
}
|
||||
}
|
||||
|
||||
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates& data) override
|
||||
{
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_VH_SHOW), uint32(EventState == IN_PROGRESS ? 1 : 0));
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_VH_PRISON_STATE), uint32(DoorIntegrity));
|
||||
data.Worldstates.emplace_back(uint32(WORLD_STATE_VH_WAVE_COUNT), uint32(WaveCount));
|
||||
}
|
||||
|
||||
bool CheckRequiredBosses(uint32 bossId, Player const* player = nullptr) const override
|
||||
{
|
||||
if (_SkipCheckRequiredBosses(player))
|
||||
|
||||
Reference in new issue
Block a user