diff options
author | johnholiver <johnholiver@gmail.com> | 2011-05-05 18:18:02 -0300 |
---|---|---|
committer | johnholiver <johnholiver@gmail.com> | 2011-05-05 18:18:02 -0300 |
commit | a1c708d62c6af45aa4d02fbc5909b2ec41b87a8d (patch) | |
tree | a76aeff599d889deb90802443ed099ce97737f93 | |
parent | e617c1618fc1207f9fdbf0b248d7e6f36773b8cd (diff) |
Scripts/Oculus: Fix Eregos loot.
-rw-r--r-- | sql/updates/world/2011_05_05_02_world_gameobject.sql | 4 | ||||
-rw-r--r-- | src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp | 29 | ||||
-rw-r--r-- | src/server/scripts/Northrend/Nexus/Oculus/oculus.h | 4 |
3 files changed, 29 insertions, 8 deletions
diff --git a/sql/updates/world/2011_05_05_02_world_gameobject.sql b/sql/updates/world/2011_05_05_02_world_gameobject.sql new file mode 100644 index 00000000000..575f51ee43d --- /dev/null +++ b/sql/updates/world/2011_05_05_02_world_gameobject.sql @@ -0,0 +1,4 @@ +UPDATE `gameobject` SET `spawnMask`=1 WHERE `guid`=2853; +DELETE FROM `gameobject` WHERE `id`=193603; +INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) VALUES +(150,193603,578,2,1,1015.06,1051.09,605.619,0.017452,0,0,0,1,-608400,0,1);
\ No newline at end of file diff --git a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp index 41aa988583d..412a30abb3b 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp @@ -52,6 +52,8 @@ public: platformUrom = 0; centrifugueConstructCounter = 0; + eregosCacheGUID = 0; + azureDragonsList.clear(); gameObjectList.clear(); } @@ -124,14 +126,21 @@ public: void OnGameObjectCreate(GameObject* go) { - if (go->GetEntry() == GO_DRAGON_CAGE_DOOR) + switch (go->GetEntry()) { - if (GetBossState(DATA_DRAKOS_EVENT) == DONE) - go->SetGoState(GO_STATE_ACTIVE); - else - go->SetGoState(GO_STATE_READY); - - gameObjectList.push_back(go->GetGUID()); + case GO_DRAGON_CAGE_DOOR: + if (GetBossState(DATA_DRAKOS_EVENT) == DONE) + go->SetGoState(GO_STATE_ACTIVE); + else + go->SetGoState(GO_STATE_READY); + gameObjectList.push_back(go->GetGUID()); + break; + case GO_EREGOS_CACHE_N: + case GO_EREGOS_CACHE_H: + eregosCacheGUID = go->GetGUID(); + break; + default: + break; } } @@ -154,6 +163,10 @@ public: if (state == DONE) DoUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW, 0); break; + case DATA_EREGOS_EVENT: + if (state == DONE) + DoRespawnGameObject(eregosCacheGUID, 7*DAY); + break; } return true; @@ -257,6 +270,8 @@ public: uint8 platformUrom; uint8 centrifugueConstructCounter; + uint64 eregosCacheGUID; + std::string str_data; std::list<uint64> gameObjectList; diff --git a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h index 8c669b91917..e04f2c8aab9 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h +++ b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h @@ -48,7 +48,9 @@ enum Bosses enum GameObjects { - GO_DRAGON_CAGE_DOOR = 193995 + GO_DRAGON_CAGE_DOOR = 193995, + GO_EREGOS_CACHE_N = 191349, + GO_EREGOS_CACHE_H = 193603 }; enum SpellEvents |