From 13b23397f5618a83e93ac00bf2a0777940c722e3 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 09:17:48 +0100 Subject: [PATCH 01/87] fix(DB/Creature): Script Sawemba (#14920) --- .../updates/pending_db_world/rev_1675980081777637000.sql | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675980081777637000.sql diff --git a/data/sql/updates/pending_db_world/rev_1675980081777637000.sql b/data/sql/updates/pending_db_world/rev_1675980081777637000.sql new file mode 100644 index 000000000..59f705d93 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675980081777637000.sql @@ -0,0 +1,9 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (35008); + +DELETE FROM `smart_scripts` WHERE `entryorguid` = 35008 AND `id` IN (0,1,2,3); -- Sawemba +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(35008, 0, 0, 0, 23, 0, 100, 0, 12544, 0, 3000, 3000, 0, 11, 12544, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sawemba - On missing aura - Cast \'Frost Armor\''), +(35008, 0, 1, 0, 0, 0, 100, 0, 1000, 2000, 3000, 4000, 0, 11, 20692, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sawemba - IC - Cast Fireball'), +(35008, 0, 2, 0, 0, 0, 100, 0, 4000, 6000, 6000, 8000, 0, 11, 38534, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sawemba - IC - Cast Frostbolt'), +(35008, 0, 3, 0, 0, 0, 100, 0, 8000, 12000, 15000, 20000, 0, 11, 38896, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sawemba - IC - Cast Polymorph'); From a56f5fc075c7d3508b9b409e0d08780f3b25b291 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 09:18:26 +0100 Subject: [PATCH 02/87] fix(DB/SAI): Misc SAI updates (#14927) --- .../sql/updates/pending_db_world/rev_1675982982263104100.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675982982263104100.sql diff --git a/data/sql/updates/pending_db_world/rev_1675982982263104100.sql b/data/sql/updates/pending_db_world/rev_1675982982263104100.sql new file mode 100644 index 000000000..9884ce2a8 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675982982263104100.sql @@ -0,0 +1,5 @@ +-- + +UPDATE `smart_scripts` SET `target_type`=21, `target_param1`=30 WHERE `entryorguid` IN (2832700) AND `source_type`=9 AND `id` IN (0,1,2); +UPDATE `smart_scripts` SET `action_type`=69, `target_type`=8, `target_x`=5355.424805, `target_y`=4486.478027, `target_z`=-120.716667 WHERE `entryorguid` IN (2832700) AND `source_type`=9 AND `id` IN (4); +UPDATE `smart_scripts` SET `action_param4`=1 WHERE `entryorguid` IN (28327) AND `source_type`=0 AND `id` IN (1); From 0b92d21ac0a95bdc1891f56adeaa05808602bfd4 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 09:18:54 +0100 Subject: [PATCH 03/87] fix(DB/Creature): Knight-Lieutenant T'Maire Sydes (#14928) --- .../rev_1675983083671842600.sql | 95 +++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675983083671842600.sql diff --git a/data/sql/updates/pending_db_world/rev_1675983083671842600.sql b/data/sql/updates/pending_db_world/rev_1675983083671842600.sql new file mode 100644 index 000000000..d8a209419 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675983083671842600.sql @@ -0,0 +1,95 @@ +-- + +UPDATE `creature` SET `id1`=40607 WHERE `guid`=133917 AND `id1` = 34084; +DELETE FROM `npc_vendor` WHERE `entry`=40607; +INSERT INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`, `VerifiedBuild`) VALUES +(40607, 0, 40787, 0, 0, 2959, 0), +(40607, 0, 40788, 0, 0, 2959, 0), +(40607, 0, 40789, 0, 0, 2959, 0), +(40607, 0, 40807, 0, 0, 2960, 0), +(40607, 0, 40808, 0, 0, 2960, 0), +(40607, 0, 40809, 0, 0, 2960, 0), +(40607, 0, 40826, 0, 0, 2959, 0), +(40607, 0, 40827, 0, 0, 2959, 0), +(40607, 0, 40828, 0, 0, 2959, 0), +(40607, 0, 40847, 0, 0, 2958, 0), +(40607, 0, 40848, 0, 0, 2958, 0), +(40607, 0, 40849, 0, 0, 2958, 0), +(40607, 0, 40866, 0, 0, 2958, 0), +(40607, 0, 40868, 0, 0, 2958, 0), +(40607, 0, 40869, 0, 0, 2958, 0), +(40607, 0, 40907, 0, 0, 2959, 0), +(40607, 0, 40927, 0, 0, 2960, 0), +(40607, 0, 40933, 0, 0, 2959, 0), +(40607, 0, 40939, 0, 0, 2958, 0), +(40607, 0, 40963, 0, 0, 2958, 0), +(40607, 0, 40992, 0, 0, 2959, 0), +(40607, 0, 40993, 0, 0, 2959, 0), +(40607, 0, 41001, 0, 0, 2960, 0), +(40607, 0, 41007, 0, 0, 2960, 0), +(40607, 0, 41013, 0, 0, 2959, 0), +(40607, 0, 41019, 0, 0, 2959, 0), +(40607, 0, 41027, 0, 0, 2958, 0), +(40607, 0, 41033, 0, 0, 2958, 0), +(40607, 0, 41038, 0, 0, 2958, 0), +(40607, 0, 41044, 0, 0, 2958, 0), +(40607, 0, 41081, 0, 0, 2959, 0), +(40607, 0, 41087, 0, 0, 2959, 0), +(40607, 0, 41137, 0, 0, 2960, 0), +(40607, 0, 41143, 0, 0, 2960, 0), +(40607, 0, 41151, 0, 0, 2959, 0), +(40607, 0, 41157, 0, 0, 2959, 0), +(40607, 0, 41199, 0, 0, 2958, 0), +(40607, 0, 41205, 0, 0, 2958, 0), +(40607, 0, 41211, 0, 0, 2958, 0), +(40607, 0, 41217, 0, 0, 2958, 0), +(40607, 0, 41275, 0, 0, 2958, 0), +(40607, 0, 41281, 0, 0, 2958, 0), +(40607, 0, 41287, 0, 0, 2960, 0), +(40607, 0, 41293, 0, 0, 2960, 0), +(40607, 0, 41298, 0, 0, 2958, 0), +(40607, 0, 41304, 0, 0, 2958, 0), +(40607, 0, 41310, 0, 0, 2959, 0), +(40607, 0, 41316, 0, 0, 2959, 0), +(40607, 0, 41321, 0, 0, 2959, 0), +(40607, 0, 41327, 0, 0, 2959, 0), +(40607, 0, 41650, 0, 0, 2959, 0), +(40607, 0, 41655, 0, 0, 2958, 0), +(40607, 0, 41661, 0, 0, 2959, 0), +(40607, 0, 41667, 0, 0, 2958, 0), +(40607, 0, 41672, 0, 0, 2959, 0), +(40607, 0, 41678, 0, 0, 2959, 0), +(40607, 0, 41683, 0, 0, 2958, 0), +(40607, 0, 41715, 0, 0, 2958, 0), +(40607, 0, 41767, 0, 0, 2960, 0), +(40607, 0, 41773, 0, 0, 2960, 0), +(40607, 0, 41854, 0, 0, 2959, 0), +(40607, 0, 41859, 0, 0, 2959, 0), +(40607, 0, 41864, 0, 0, 2958, 0), +(40607, 0, 41869, 0, 0, 2958, 0), +(40607, 0, 41874, 0, 0, 2960, 0), +(40607, 0, 41915, 0, 0, 2959, 0), +(40607, 0, 41921, 0, 0, 2959, 0), +(40607, 0, 41927, 0, 0, 2958, 0), +(40607, 0, 41934, 0, 0, 2958, 0), +(40607, 0, 41940, 0, 0, 2960, 0), +(40607, 0, 41946, 0, 0, 2959, 0), +(40607, 0, 41953, 0, 0, 2959, 0), +(40607, 0, 41959, 0, 0, 2958, 0), +(40607, 0, 41965, 0, 0, 2958, 0), +(40607, 0, 41971, 0, 0, 2960, 0), +(40607, 0, 41993, 0, 0, 2959, 0), +(40607, 0, 41998, 0, 0, 2959, 0), +(40607, 0, 42005, 0, 0, 2958, 0), +(40607, 0, 42011, 0, 0, 2958, 0), +(40607, 0, 42017, 0, 0, 2960, 0), +(40607, 0, 42579, 0, 0, 2969, 0), +(40607, 0, 42584, 0, 0, 2969, 0), +(40607, 0, 42589, 0, 0, 2969, 0), +(40607, 0, 42598, 0, 0, 2969, 0), +(40607, 0, 42603, 0, 0, 2969, 0), +(40607, 0, 42608, 0, 0, 2969, 0), +(40607, 0, 42615, 0, 0, 2969, 0), +(40607, 0, 42621, 0, 0, 2969, 0), +(40607, 0, 42853, 0, 0, 2969, 0), +(40607, 0, 45706, 0, 0, 2596, 0); From 99acf12515ecd3473eccfd20d58b6528f37a4e52 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Fri, 10 Feb 2023 08:21:35 +0000 Subject: [PATCH 04/87] chore(DB): import pending files Referenced commit(s): 0b92d21ac0a95bdc1891f56adeaa05808602bfd4 --- .../rev_1675980081777637000.sql => db_world/2023_02_10_00.sql} | 1 + .../rev_1675982982263104100.sql => db_world/2023_02_10_01.sql} | 1 + .../rev_1675983083671842600.sql => db_world/2023_02_10_02.sql} | 1 + 3 files changed, 3 insertions(+) rename data/sql/updates/{pending_db_world/rev_1675980081777637000.sql => db_world/2023_02_10_00.sql} (96%) rename data/sql/updates/{pending_db_world/rev_1675982982263104100.sql => db_world/2023_02_10_01.sql} (91%) rename data/sql/updates/{pending_db_world/rev_1675983083671842600.sql => db_world/2023_02_10_02.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1675980081777637000.sql b/data/sql/updates/db_world/2023_02_10_00.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1675980081777637000.sql rename to data/sql/updates/db_world/2023_02_10_00.sql index 59f705d93..fcad57312 100644 --- a/data/sql/updates/pending_db_world/rev_1675980081777637000.sql +++ b/data/sql/updates/db_world/2023_02_10_00.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_09_00 -> 2023_02_10_00 -- UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (35008); diff --git a/data/sql/updates/pending_db_world/rev_1675982982263104100.sql b/data/sql/updates/db_world/2023_02_10_01.sql similarity index 91% rename from data/sql/updates/pending_db_world/rev_1675982982263104100.sql rename to data/sql/updates/db_world/2023_02_10_01.sql index 9884ce2a8..99b873fff 100644 --- a/data/sql/updates/pending_db_world/rev_1675982982263104100.sql +++ b/data/sql/updates/db_world/2023_02_10_01.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_00 -> 2023_02_10_01 -- UPDATE `smart_scripts` SET `target_type`=21, `target_param1`=30 WHERE `entryorguid` IN (2832700) AND `source_type`=9 AND `id` IN (0,1,2); diff --git a/data/sql/updates/pending_db_world/rev_1675983083671842600.sql b/data/sql/updates/db_world/2023_02_10_02.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1675983083671842600.sql rename to data/sql/updates/db_world/2023_02_10_02.sql index d8a209419..ae576fa8f 100644 --- a/data/sql/updates/pending_db_world/rev_1675983083671842600.sql +++ b/data/sql/updates/db_world/2023_02_10_02.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_01 -> 2023_02_10_02 -- UPDATE `creature` SET `id1`=40607 WHERE `guid`=133917 AND `id1` = 34084; From 73c79fb8a9056fd424aadfb252a45aabb90d6a12 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 09:52:31 +0100 Subject: [PATCH 05/87] fix(DB/SAI): Script Magister Savarin (#14921) --- .../updates/pending_db_world/rev_1675980251209377200.sql | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675980251209377200.sql diff --git a/data/sql/updates/pending_db_world/rev_1675980251209377200.sql b/data/sql/updates/pending_db_world/rev_1675980251209377200.sql new file mode 100644 index 000000000..0d5d1e6c8 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675980251209377200.sql @@ -0,0 +1,9 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (35602); + +DELETE FROM `smart_scripts` WHERE `entryorguid` = 35602 AND `id` IN (0,1,2,3); -- Magister Savarin +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(35602, 0, 0, 0, 23, 0, 100, 0, 12544, 0, 3000, 3000, 0, 11, 12544, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Magister Savarin - On missing aura - Cast \'Frost Armor\''), +(35602, 0, 1, 0, 0, 0, 100, 0, 1000, 2000, 3000, 4000, 0, 11, 20692, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Magister Savarin - IC - Cast Fireball'), +(35602, 0, 2, 0, 0, 0, 100, 0, 4000, 6000, 6000, 8000, 0, 11, 38534, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Magister Savarin - IC - Cast Frostbolt'), +(35602, 0, 3, 0, 0, 0, 100, 0, 8000, 12000, 15000, 20000, 0, 11, 38896, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Magister Savarin - IC - Cast Polymorph'); From 57bb13a1bb3790ef0ea3cf95e48ca54a9bc69417 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Fri, 10 Feb 2023 08:55:00 +0000 Subject: [PATCH 06/87] chore(DB): import pending files Referenced commit(s): 73c79fb8a9056fd424aadfb252a45aabb90d6a12 --- .../rev_1675980251209377200.sql => db_world/2023_02_10_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675980251209377200.sql => db_world/2023_02_10_03.sql} (96%) diff --git a/data/sql/updates/pending_db_world/rev_1675980251209377200.sql b/data/sql/updates/db_world/2023_02_10_03.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1675980251209377200.sql rename to data/sql/updates/db_world/2023_02_10_03.sql index 0d5d1e6c8..93eaebf9e 100644 --- a/data/sql/updates/pending_db_world/rev_1675980251209377200.sql +++ b/data/sql/updates/db_world/2023_02_10_03.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_02 -> 2023_02_10_03 -- UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (35602); From acfec9e3781f789034d24e78bfb80c32f7022189 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 14:15:38 +0100 Subject: [PATCH 07/87] fix(DB/Creature): Spawn Floating Skull (#14931) --- .../updates/pending_db_world/rev_1675983759485500400.sql | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675983759485500400.sql diff --git a/data/sql/updates/pending_db_world/rev_1675983759485500400.sql b/data/sql/updates/pending_db_world/rev_1675983759485500400.sql new file mode 100644 index 000000000..c3c541ec7 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675983759485500400.sql @@ -0,0 +1,8 @@ +-- +DELETE FROM `creature` WHERE `guid` IN (106326) AND `id1` IN (21365); +INSERT INTO `creature` (`guid`, `id1`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `VerifiedBuild`) VALUES +(106326, 21365, 530, 0, 0, 1, 1, 0, 38.3723, 2121.23, 128.975, 2.80337, 600, 0, 0, 42, 0, 0, 0, 0, 0, 0); + +DELETE FROM `creature_template_addon` WHERE `entry` IN (21365); +INSERT INTO `creature_template_addon` (`entry`, `auras`) VALUES +(21365, '36725 36727'); From 983614a0f7508f622da97330235eb1c44255554e Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 14:16:18 +0100 Subject: [PATCH 08/87] fix(DB/Creature): Spawn Warsong Hold Mount (#14930) --- .../updates/pending_db_world/rev_1675983591397096200.sql | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675983591397096200.sql diff --git a/data/sql/updates/pending_db_world/rev_1675983591397096200.sql b/data/sql/updates/pending_db_world/rev_1675983591397096200.sql new file mode 100644 index 000000000..9797de397 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675983591397096200.sql @@ -0,0 +1,7 @@ +-- + +DELETE FROM `creature` WHERE `guid` IN (104173, 104174, 104175); +INSERT INTO `creature` (`guid`, `id1`, `map`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`) VALUES +(104173, 18378, 571, 1, 1, 0, 2750.36, 6127.08, 208.856, 5.44543, 180, 0, 0, 4050, 0, 0), +(104174, 18379, 571, 1, 1, 0, 2761.16, 6137.27, 208.872, 5.35816, 180, 0, 0, 4050, 0, 0), +(104175, 18380, 571, 1, 1, 0, 2779.98, 6154.28, 208.92, 5.35816, 180, 0, 0, 4050, 0, 0); From d538277b3ed07104bfa1a579b14b139c6cb434bf Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Fri, 10 Feb 2023 13:18:47 +0000 Subject: [PATCH 09/87] chore(DB): import pending files Referenced commit(s): 983614a0f7508f622da97330235eb1c44255554e --- .../rev_1675983591397096200.sql => db_world/2023_02_10_04.sql} | 1 + .../rev_1675983759485500400.sql => db_world/2023_02_10_05.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1675983591397096200.sql => db_world/2023_02_10_04.sql} (93%) rename data/sql/updates/{pending_db_world/rev_1675983759485500400.sql => db_world/2023_02_10_05.sql} (93%) diff --git a/data/sql/updates/pending_db_world/rev_1675983591397096200.sql b/data/sql/updates/db_world/2023_02_10_04.sql similarity index 93% rename from data/sql/updates/pending_db_world/rev_1675983591397096200.sql rename to data/sql/updates/db_world/2023_02_10_04.sql index 9797de397..db25fc5e9 100644 --- a/data/sql/updates/pending_db_world/rev_1675983591397096200.sql +++ b/data/sql/updates/db_world/2023_02_10_04.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_03 -> 2023_02_10_04 -- DELETE FROM `creature` WHERE `guid` IN (104173, 104174, 104175); diff --git a/data/sql/updates/pending_db_world/rev_1675983759485500400.sql b/data/sql/updates/db_world/2023_02_10_05.sql similarity index 93% rename from data/sql/updates/pending_db_world/rev_1675983759485500400.sql rename to data/sql/updates/db_world/2023_02_10_05.sql index c3c541ec7..7d0f123e8 100644 --- a/data/sql/updates/pending_db_world/rev_1675983759485500400.sql +++ b/data/sql/updates/db_world/2023_02_10_05.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_04 -> 2023_02_10_05 -- DELETE FROM `creature` WHERE `guid` IN (106326) AND `id1` IN (21365); INSERT INTO `creature` (`guid`, `id1`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `VerifiedBuild`) VALUES From 1738e242e49869687c9ef1c8a08baeebd964ecd9 Mon Sep 17 00:00:00 2001 From: Angelo Venturini Date: Fri, 10 Feb 2023 10:54:36 -0300 Subject: [PATCH 10/87] fix(Scripts/Netherstorm): Crash in Netherstorm (#14934) --- src/server/scripts/Outland/zone_netherstorm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/scripts/Outland/zone_netherstorm.cpp b/src/server/scripts/Outland/zone_netherstorm.cpp index 980d00719..97aadbe9c 100644 --- a/src/server/scripts/Outland/zone_netherstorm.cpp +++ b/src/server/scripts/Outland/zone_netherstorm.cpp @@ -834,7 +834,7 @@ public: _actionEvents.ScheduleEvent(EVENT_KAYLAAN_RESSURECTION, 1000); break; case EVENT_KAYLAAN_RESSURECTION: - if (GetCreature(KAYLAAN_THE_LOST)) + if (GetCreature(KAYLAAN_THE_LOST) && GetCreature(ISHANAH_HIGH_PRIESTESS)) kaylaan->CastSpell(ishanah, REDEMPTION); _actionEvents.ScheduleEvent(EVENT_ISHANAH_IS_BACK_AGAIN, 11000); break; From 9deb8fecb7695c566ccc3e6f7f93954c4efdb47a Mon Sep 17 00:00:00 2001 From: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> Date: Fri, 10 Feb 2023 16:18:23 -0500 Subject: [PATCH 11/87] fix(DB/Creature): Remove bleed immunity from Escape from Durnholde bosses. (#14937) --- data/sql/updates/pending_db_world/durnholde-immunity.sql | 1 + 1 file changed, 1 insertion(+) create mode 100644 data/sql/updates/pending_db_world/durnholde-immunity.sql diff --git a/data/sql/updates/pending_db_world/durnholde-immunity.sql b/data/sql/updates/pending_db_world/durnholde-immunity.sql new file mode 100644 index 000000000..4d984ffd6 --- /dev/null +++ b/data/sql/updates/pending_db_world/durnholde-immunity.sql @@ -0,0 +1 @@ +UPDATE `creature_template` SET `mechanic_immune_mask` = `mechanic_immune_mask` &~ 16384 WHERE `entry` IN (17848, 17862, 18096, 20521, 20531, 20535); From b09d81f90b77af214e369403ee8cb2c99813485f Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Fri, 10 Feb 2023 21:21:02 +0000 Subject: [PATCH 12/87] chore(DB): import pending files Referenced commit(s): 9deb8fecb7695c566ccc3e6f7f93954c4efdb47a --- .../durnholde-immunity.sql => db_world/2023_02_10_06.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/durnholde-immunity.sql => db_world/2023_02_10_06.sql} (77%) diff --git a/data/sql/updates/pending_db_world/durnholde-immunity.sql b/data/sql/updates/db_world/2023_02_10_06.sql similarity index 77% rename from data/sql/updates/pending_db_world/durnholde-immunity.sql rename to data/sql/updates/db_world/2023_02_10_06.sql index 4d984ffd6..a1ef13924 100644 --- a/data/sql/updates/pending_db_world/durnholde-immunity.sql +++ b/data/sql/updates/db_world/2023_02_10_06.sql @@ -1 +1,2 @@ +-- DB update 2023_02_10_05 -> 2023_02_10_06 UPDATE `creature_template` SET `mechanic_immune_mask` = `mechanic_immune_mask` &~ 16384 WHERE `entry` IN (17848, 17862, 18096, 20521, 20531, 20535); From 4ec8af5bbb788b1fb8b44692e9fda7e94bea3ac3 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Fri, 10 Feb 2023 22:30:44 +0100 Subject: [PATCH 13/87] fix(DB/SAI): Script Wyrmcaller Vile (#14922) --- .../rev_1675980334913373700.sql | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675980334913373700.sql diff --git a/data/sql/updates/pending_db_world/rev_1675980334913373700.sql b/data/sql/updates/pending_db_world/rev_1675980334913373700.sql new file mode 100644 index 000000000..fedd44a23 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675980334913373700.sql @@ -0,0 +1,17 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (24029); + + +DELETE FROM `smart_scripts` WHERE `entryorguid` = 24029 AND `id` IN (0,1,2,3,4,5); -- Wyrmcaller Vile +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES + +(24029, 0, 0, 0, 1, 0, 100, 513, 0, 0, 3000, 3000, 0, 11, 43576, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - OOC - Cast \'Frost Power\''), +(24029, 0, 1, 0, 0, 0, 100, 0, 0, 0, 4000, 4000, 0, 11, 9672, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - IC - Cast \'Frostbolt\''), +(24029, 0, 2, 0, 0, 0, 100, 0, 0, 0, 6000, 10000, 0, 11, 15532, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - IC - Cast \'Frost Nova\''), +(24029, 0, 3, 0, 1, 0, 100, 512, 0, 0, 3000, 3000, 0, 45, 0, 1, 0, 0, 0, 0, 19, 23033, 10, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - OOC - Cast \'Set Data\''), +(24029, 0, 4, 0, 4, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - On Aggro - Say Line 0'), +(24029, 0, 5, 0, 23, 0, 100, 0, 12544, 0, 3000, 3000, 0, 11, 12544, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmcaller Vile - On missing aura - Cast Frost Armor'); + +DELETE FROM `creature_text` WHERE `CreatureID`=24029 AND `GroupID`=0 AND `ID`=0; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(24029, 0, 0, 'Did you really think that by facing me, you have any hope of saving your friends?', 12, 0, 100, 0, 0, 0, 23696, 0, 'Wyrmcaller Vile'); From d336b63f50e8cbf0ba00c3e29ec67c7d0243f688 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Fri, 10 Feb 2023 21:33:14 +0000 Subject: [PATCH 14/87] chore(DB): import pending files Referenced commit(s): 4ec8af5bbb788b1fb8b44692e9fda7e94bea3ac3 --- .../rev_1675980334913373700.sql => db_world/2023_02_10_07.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675980334913373700.sql => db_world/2023_02_10_07.sql} (97%) diff --git a/data/sql/updates/pending_db_world/rev_1675980334913373700.sql b/data/sql/updates/db_world/2023_02_10_07.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1675980334913373700.sql rename to data/sql/updates/db_world/2023_02_10_07.sql index fedd44a23..4d789fc0a 100644 --- a/data/sql/updates/pending_db_world/rev_1675980334913373700.sql +++ b/data/sql/updates/db_world/2023_02_10_07.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_10_06 -> 2023_02_10_07 -- UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` IN (24029); From fbaa48e2335792a0dd88cc16b158ebdbdd95f9b6 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 02:14:49 +0100 Subject: [PATCH 15/87] =?UTF-8?q?fix(Scripts/Underbog):=20Underbog=20Shamb?= =?UTF-8?q?ler's=20Allergies=20should=20periodica=E2=80=A6=20(#14563)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rev_1673174470902575400.sql | 2 ++ .../underbog/boss_the_black_stalker.cpp | 23 -------------- .../CoilfangReservoir/underbog/underbog.cpp | 31 +++++++++++++++++++ 3 files changed, 33 insertions(+), 23 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1673174470902575400.sql diff --git a/data/sql/updates/pending_db_world/rev_1673174470902575400.sql b/data/sql/updates/pending_db_world/rev_1673174470902575400.sql new file mode 100644 index 000000000..540097a54 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1673174470902575400.sql @@ -0,0 +1,2 @@ +-- +UPDATE `spell_script_names` SET `ScriptName`='spell_allergies' WHERE `spell_id`=31427; diff --git a/src/server/scripts/Outland/CoilfangReservoir/underbog/boss_the_black_stalker.cpp b/src/server/scripts/Outland/CoilfangReservoir/underbog/boss_the_black_stalker.cpp index 862f27301..c2b085fe2 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/underbog/boss_the_black_stalker.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/underbog/boss_the_black_stalker.cpp @@ -142,28 +142,6 @@ struct boss_the_black_stalker : public BossAI } }; -class spell_gen_allergies : public AuraScript -{ - PrepareAuraScript(spell_gen_allergies); - - void CalcPeriodic(AuraEffect const* /*effect*/, bool& isPeriodic, int32& amplitude) - { - isPeriodic = true; - amplitude = urand(10 * IN_MILLISECONDS, 200 * IN_MILLISECONDS); - } - - void Update(AuraEffect* /*effect*/) - { - SetDuration(0); - } - - void Register() override - { - DoEffectCalcPeriodic += AuraEffectCalcPeriodicFn(spell_gen_allergies::CalcPeriodic, EFFECT_0, SPELL_AURA_DUMMY); - OnEffectUpdatePeriodic += AuraEffectUpdatePeriodicFn(spell_gen_allergies::Update, EFFECT_0, SPELL_AURA_DUMMY); - } -}; - // 31704 - Levitate class spell_the_black_stalker_levitate : public SpellScript { @@ -252,7 +230,6 @@ class spell_the_black_stalker_magnetic_pull : public SpellScript void AddSC_boss_the_black_stalker() { RegisterUnderbogCreatureAI(boss_the_black_stalker); - RegisterSpellScript(spell_gen_allergies); RegisterSpellScript(spell_the_black_stalker_levitate); RegisterSpellScript(spell_the_black_stalker_levitation_pulse); RegisterSpellScript(spell_the_black_stalker_someone_grab_me); diff --git a/src/server/scripts/Outland/CoilfangReservoir/underbog/underbog.cpp b/src/server/scripts/Outland/CoilfangReservoir/underbog/underbog.cpp index 978b64ca5..6f68fcd74 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/underbog/underbog.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/underbog/underbog.cpp @@ -40,7 +40,38 @@ class spell_fungal_decay : public AuraScript } }; +enum AllergiesEnum +{ + SPELL_SNEEZE = 31428 +}; + +class spell_allergies : public AuraScript +{ + PrepareAuraScript(spell_allergies); + + void CalcPeriodic(AuraEffect const* /*effect*/, bool& isPeriodic, int32& amplitude) + { + isPeriodic = true; + amplitude = urand(10 * IN_MILLISECONDS, 60 * IN_MILLISECONDS); + } + + void Update(AuraEffect* /*effect*/) + { + if (Unit* target = GetUnitOwner()) + { + target->CastSpell(target, SPELL_SNEEZE, true); + } + } + + void Register() override + { + DoEffectCalcPeriodic += AuraEffectCalcPeriodicFn(spell_allergies::CalcPeriodic, EFFECT_0, SPELL_AURA_DUMMY); + OnEffectUpdatePeriodic += AuraEffectUpdatePeriodicFn(spell_allergies::Update, EFFECT_0, SPELL_AURA_DUMMY); + } +}; + void AddSC_underbog() { RegisterSpellScript(spell_fungal_decay); + RegisterSpellScript(spell_allergies); } From 0a0b30eb135c22a290f4ac68dd04eead505b95be Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 01:17:16 +0000 Subject: [PATCH 16/87] chore(DB): import pending files Referenced commit(s): fbaa48e2335792a0dd88cc16b158ebdbdd95f9b6 --- .../rev_1673174470902575400.sql => db_world/2023_02_11_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1673174470902575400.sql => db_world/2023_02_11_00.sql} (67%) diff --git a/data/sql/updates/pending_db_world/rev_1673174470902575400.sql b/data/sql/updates/db_world/2023_02_11_00.sql similarity index 67% rename from data/sql/updates/pending_db_world/rev_1673174470902575400.sql rename to data/sql/updates/db_world/2023_02_11_00.sql index 540097a54..1c3a47638 100644 --- a/data/sql/updates/pending_db_world/rev_1673174470902575400.sql +++ b/data/sql/updates/db_world/2023_02_11_00.sql @@ -1,2 +1,3 @@ +-- DB update 2023_02_10_07 -> 2023_02_11_00 -- UPDATE `spell_script_names` SET `ScriptName`='spell_allergies' WHERE `spell_id`=31427; From a6aeb23b238f8616ec586f5090f45a563bb14b4c Mon Sep 17 00:00:00 2001 From: Gultask <100873791+Gultask@users.noreply.github.com> Date: Fri, 10 Feb 2023 22:19:59 -0300 Subject: [PATCH 17/87] fix(DB/Creature): Add missing Thrash aura to Aeonus in Black Morass (#14884) --- data/sql/updates/pending_db_world/rev_1675649780091440100.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675649780091440100.sql diff --git a/data/sql/updates/pending_db_world/rev_1675649780091440100.sql b/data/sql/updates/pending_db_world/rev_1675649780091440100.sql new file mode 100644 index 000000000..e35eba65b --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675649780091440100.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template_addon` SET `auras` = '8876' WHERE (`entry` IN (17881, 20737)); From e4499862b21252ed60d3dc3604dfddafb27e5ffa Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 01:22:23 +0000 Subject: [PATCH 18/87] chore(DB): import pending files Referenced commit(s): a6aeb23b238f8616ec586f5090f45a563bb14b4c --- .../rev_1675649780091440100.sql => db_world/2023_02_11_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675649780091440100.sql => db_world/2023_02_11_01.sql} (67%) diff --git a/data/sql/updates/pending_db_world/rev_1675649780091440100.sql b/data/sql/updates/db_world/2023_02_11_01.sql similarity index 67% rename from data/sql/updates/pending_db_world/rev_1675649780091440100.sql rename to data/sql/updates/db_world/2023_02_11_01.sql index e35eba65b..0d1607c3e 100644 --- a/data/sql/updates/pending_db_world/rev_1675649780091440100.sql +++ b/data/sql/updates/db_world/2023_02_11_01.sql @@ -1,2 +1,3 @@ +-- DB update 2023_02_11_00 -> 2023_02_11_01 -- UPDATE `creature_template_addon` SET `auras` = '8876' WHERE (`entry` IN (17881, 20737)); From 21c2e7d3e512c500d2dee9908c461e619ae11d26 Mon Sep 17 00:00:00 2001 From: Gultask <100873791+Gultask@users.noreply.github.com> Date: Sat, 11 Feb 2023 00:00:56 -0300 Subject: [PATCH 19/87] fix(DB): Separate INSERTs from base sql into smaller sections part 2 (#14938) --- data/sql/base/db_world/broadcast_text_locale.sql | 2 +- data/sql/base/db_world/creature_text.sql | 9 +++++---- data/sql/base/db_world/creature_text_locale.sql | 2 +- .../base/db_world/creaturedisplayinfoextra_dbc.sql | 4 ++-- data/sql/base/db_world/gossip_menu_option_locale.sql | 2 +- data/sql/base/db_world/item_template_locale.sql | 2 +- data/sql/base/db_world/lfg_dungeon_template.sql | 2 +- data/sql/base/db_world/npc_text.sql | 12 ++++++++---- data/sql/base/db_world/npc_text_locale.sql | 2 +- data/sql/base/db_world/page_text_locale.sql | 2 +- data/sql/base/db_world/quest_offer_reward.sql | 6 ++++-- data/sql/base/db_world/quest_offer_reward_locale.sql | 2 +- .../sql/base/db_world/quest_request_items_locale.sql | 2 +- data/sql/base/db_world/quest_template_locale.sql | 2 +- data/sql/base/db_world/spell_dbc.sql | 12 ++++++++---- 15 files changed, 37 insertions(+), 26 deletions(-) diff --git a/data/sql/base/db_world/broadcast_text_locale.sql b/data/sql/base/db_world/broadcast_text_locale.sql index 6c8607b8a..a965c8c36 100644 --- a/data/sql/base/db_world/broadcast_text_locale.sql +++ b/data/sql/base/db_world/broadcast_text_locale.sql @@ -25,7 +25,7 @@ CREATE TABLE IF NOT EXISTS `broadcast_text_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.broadcast_text_locale: ~583,570 rows (approximately) +-- Dumping data for table acore_world.broadcast_text_locale: ~606,346 rows (approximately) DELETE FROM `broadcast_text_locale`; INSERT INTO `broadcast_text_locale` (`ID`, `locale`, `MaleText`, `FemaleText`, `VerifiedBuild`) VALUES (1, 'deDE', 'Hilfe, Hilfe! Ich werde bedrängt!', '', 18019), diff --git a/data/sql/base/db_world/creature_text.sql b/data/sql/base/db_world/creature_text.sql index 286956560..9f2fc41b6 100644 --- a/data/sql/base/db_world/creature_text.sql +++ b/data/sql/base/db_world/creature_text.sql @@ -7683,7 +7683,8 @@ INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Lan (19610, 8, 0, 'Don\'t worry. It\'s an improvement!', 12, 0, 100, 11, 0, 0, 20286, 0, 'Irradiated Worker'), (19616, 0, 0, '%s howls in response to Malukaz\'s call.', 16, 0, 100, 0, 0, 0, 17051, 0, 'Terokkar Wolf Spirit'), (19616, 1, 0, '%s expresses its approval.', 16, 0, 100, 0, 0, 0, 17086, 0, 'Terokkar Wolf Spirit'), - (19622, 0, 0, 'Energy. Power. My people are addicted to it... a dependence made manifest after the Sunwell was destroyed. Welcome to the future. A pity you are too late to stop it. No one can stop me now! Selama ashal\'anore!', 14, 0, 100, 0, 0, 11256, 20195, 0, 'kaelthas SAY_INTRO'), + (19622, 0, 0, 'Energy. Power. My people are addicted to it... a dependence made manifest after the Sunwell was destroyed. Welcome to the future. A pity you are too late to stop it. No one can stop me now! Selama ashal\'anore!', 14, 0, 100, 0, 0, 11256, 20195, 0, 'kaelthas SAY_INTRO'); +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES (19622, 1, 0, 'Capernian will see to it that your stay here is a short one.', 14, 0, 100, 0, 0, 11257, 19004, 0, 'kaelthas SAY_INTRO_CAPERNIAN'), (19622, 2, 0, 'Well done, you have proven worthy to test your skills against my master engineer, Telonicus.', 14, 0, 100, 0, 0, 11258, 19005, 0, 'kaelthas SAY_INTRO_TELONICUS'), (19622, 3, 0, 'Let us see how your nerves hold up against the Darkener, Thaladred! ', 14, 0, 100, 0, 0, 11259, 19006, 0, 'kaelthas SAY_INTRO_THALADRED'), @@ -10037,8 +10038,7 @@ INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Lan (24199, 0, 0, '%s loses all self control and begins to attack friend and foe alike!', 16, 0, 100, 0, 0, 0, 23081, 0, 'Plagued Dragonflayer Handler'), (24200, 0, 0, 'Dalronn! See if you can muster the nerve to join my attack!', 14, 0, 100, 0, 0, 13229, 29531, 0, 'skarvald YELL_SKARVALD_AGGRO'), (24200, 1, 0, 'Not... over... yet.', 14, 0, 100, 0, 0, 13230, 29534, 0, 'skarvald YELL_SKARVALD_DAL_DIED'), - (24200, 2, 0, 'A warrior\'s death.', 14, 0, 100, 0, 0, 13231, 29535, 0, 'skarvald YELL_SKARVALD_SKA_DIEDFIRST'); -INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES + (24200, 2, 0, 'A warrior\'s death.', 14, 0, 100, 0, 0, 13231, 29535, 0, 'skarvald YELL_SKARVALD_SKA_DIEDFIRST'), (24200, 3, 0, 'Jarggn olkt!', 14, 0, 100, 0, 0, 13232, 29532, 0, 'skarvald YELL_SKARVALD_KILL'), (24200, 4, 0, 'Pfagh! What sort of necromancer lets death stop him? I knew you were worthless!', 14, 0, 100, 0, 0, 13233, 29533, 0, 'skarvald YELL_SKARVALD_DAL_DIEDFIRST'), (24201, 0, 0, 'By all means, don\'t assess the situation, you halfwit! Just jump into the fray!', 14, 0, 100, 0, 0, 13199, 29527, 0, 'dalronn YELL_DALRONN_AGGRO'), @@ -14497,7 +14497,8 @@ INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Lan (30243, 0, 4, 'Sniveling pig!', 12, 0, 100, 0, 0, 14394, 30504, 0, 'Njorndar Spear-Sister'), (30243, 0, 5, 'Ugglin oo bjorr!', 12, 0, 100, 0, 0, 14395, 30505, 0, 'Njorndar Spear-Sister'), (30243, 0, 6, 'You come to die!', 12, 0, 100, 0, 0, 14392, 30502, 0, 'Njorndar Spear-Sister'), - (30243, 0, 7, 'Die, maggot!', 12, 0, 100, 0, 0, 14391, 30501, 0, 'Njorndar Spear-Sister'), + (30243, 0, 7, 'Die, maggot!', 12, 0, 100, 0, 0, 14391, 30501, 0, 'Njorndar Spear-Sister'); +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES (30243, 0, 8, 'Haraak foln!', 12, 0, 100, 0, 0, 14396, 30506, 0, 'Njorndar Spear-Sister'), (30243, 0, 9, 'Your entrails will make a fine necklace.', 12, 0, 100, 0, 0, 14386, 30500, 0, 'Njorndar Spear-Sister'), (30243, 0, 10, 'Die, maggot!', 12, 0, 100, 0, 0, 14387, 30501, 0, 'Njorndar Spear-Sister'), diff --git a/data/sql/base/db_world/creature_text_locale.sql b/data/sql/base/db_world/creature_text_locale.sql index e397d692b..de15d04af 100644 --- a/data/sql/base/db_world/creature_text_locale.sql +++ b/data/sql/base/db_world/creature_text_locale.sql @@ -25,7 +25,7 @@ CREATE TABLE IF NOT EXISTS `creature_text_locale` ( PRIMARY KEY (`CreatureID`,`GroupID`,`ID`,`Locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.creature_text_locale: ~14,241 rows (approximately) +-- Dumping data for table acore_world.creature_text_locale: ~14,464 rows (approximately) DELETE FROM `creature_text_locale`; INSERT INTO `creature_text_locale` (`CreatureID`, `GroupID`, `ID`, `Locale`, `Text`) VALUES (6, 0, 0, 'zhCN', '不许抢走我的蜡烛!'), diff --git a/data/sql/base/db_world/creaturedisplayinfoextra_dbc.sql b/data/sql/base/db_world/creaturedisplayinfoextra_dbc.sql index cd2df397b..83dc6f8c6 100644 --- a/data/sql/base/db_world/creaturedisplayinfoextra_dbc.sql +++ b/data/sql/base/db_world/creaturedisplayinfoextra_dbc.sql @@ -37,9 +37,9 @@ CREATE TABLE IF NOT EXISTS `creaturedisplayinfoextra_dbc` ( `NPCItemDisplay10` int unsigned NOT NULL DEFAULT '0', `NPCItemDisplay11` int unsigned NOT NULL DEFAULT '0', `Flags` int unsigned NOT NULL DEFAULT '0', - `BakeName` varchar(100) NOT NULL, + `BakeName` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, PRIMARY KEY (`ID`) -) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4; +) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci; -- Dumping data for table acore_world.creaturedisplayinfoextra_dbc: 0 rows DELETE FROM `creaturedisplayinfoextra_dbc`; diff --git a/data/sql/base/db_world/gossip_menu_option_locale.sql b/data/sql/base/db_world/gossip_menu_option_locale.sql index 02edf0b7b..af3ec880d 100644 --- a/data/sql/base/db_world/gossip_menu_option_locale.sql +++ b/data/sql/base/db_world/gossip_menu_option_locale.sql @@ -25,7 +25,7 @@ CREATE TABLE IF NOT EXISTS `gossip_menu_option_locale` ( PRIMARY KEY (`MenuID`,`OptionID`,`Locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.gossip_menu_option_locale: ~35,241 rows (approximately) +-- Dumping data for table acore_world.gossip_menu_option_locale: ~36,039 rows (approximately) DELETE FROM `gossip_menu_option_locale`; INSERT INTO `gossip_menu_option_locale` (`MenuID`, `OptionID`, `Locale`, `OptionText`, `BoxText`) VALUES (0, 0, 'deDE', 'GOSSIP_OPTION_QUESTGIVER', ''), diff --git a/data/sql/base/db_world/item_template_locale.sql b/data/sql/base/db_world/item_template_locale.sql index f4f633b81..f26127b06 100644 --- a/data/sql/base/db_world/item_template_locale.sql +++ b/data/sql/base/db_world/item_template_locale.sql @@ -25,7 +25,7 @@ CREATE TABLE IF NOT EXISTS `item_template_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.item_template_locale: ~313,250 rows (approximately) +-- Dumping data for table acore_world.item_template_locale: ~307,546 rows (approximately) DELETE FROM `item_template_locale`; INSERT INTO `item_template_locale` (`ID`, `locale`, `Name`, `Description`, `VerifiedBuild`) VALUES (17, 'deDE', 'Martinsfuror', '', 15050), diff --git a/data/sql/base/db_world/lfg_dungeon_template.sql b/data/sql/base/db_world/lfg_dungeon_template.sql index 8a3673084..68fd8ec40 100644 --- a/data/sql/base/db_world/lfg_dungeon_template.sql +++ b/data/sql/base/db_world/lfg_dungeon_template.sql @@ -18,7 +18,7 @@ DROP TABLE IF EXISTS `lfg_dungeon_template`; CREATE TABLE IF NOT EXISTS `lfg_dungeon_template` ( `dungeonId` int unsigned NOT NULL DEFAULT '0' COMMENT 'Unique id from LFGDungeons.dbc', - `name` varchar(255) CHARACTER SET latin1 DEFAULT NULL, + `name` varchar(255) CHARACTER SET latin1 COLLATE latin1_swedish_ci DEFAULT NULL, `position_x` float NOT NULL DEFAULT '0', `position_y` float NOT NULL DEFAULT '0', `position_z` float NOT NULL DEFAULT '0', diff --git a/data/sql/base/db_world/npc_text.sql b/data/sql/base/db_world/npc_text.sql index 2dcd4c0f4..65000e0a1 100644 --- a/data/sql/base/db_world/npc_text.sql +++ b/data/sql/base/db_world/npc_text.sql @@ -1735,7 +1735,8 @@ INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, (5435, 'I\'m just a student myself, really. Rhiannon\'s the expert. She\'s standing by the crates over there. You can learn a lot from her.', '', 8081, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (5436, 'Yes, I think you have potential. Maybe I can show you a thing or two.', '', 8082, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (5437, '', 'There is no greater way to clear the mind than to weave.', 8083, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 11723), - (5438, '', 'My education is ongoing, and your knowledge surpasses mine. If you wish to learn more you must speak to Me\'lynn. She will guide you.', 8084, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), + (5438, '', 'My education is ongoing, and your knowledge surpasses mine. If you wish to learn more you must speak to Me\'lynn. She will guide you.', 8084, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`, `text1_0`, `text1_1`, `BroadcastTextID1`, `lang1`, `Probability1`, `em1_0`, `em1_1`, `em1_2`, `em1_3`, `em1_4`, `em1_5`, `text2_0`, `text2_1`, `BroadcastTextID2`, `lang2`, `Probability2`, `em2_0`, `em2_1`, `em2_2`, `em2_3`, `em2_4`, `em2_5`, `text3_0`, `text3_1`, `BroadcastTextID3`, `lang3`, `Probability3`, `em3_0`, `em3_1`, `em3_2`, `em3_3`, `em3_4`, `em3_5`, `text4_0`, `text4_1`, `BroadcastTextID4`, `lang4`, `Probability4`, `em4_0`, `em4_1`, `em4_2`, `em4_3`, `em4_4`, `em4_5`, `text5_0`, `text5_1`, `BroadcastTextID5`, `lang5`, `Probability5`, `em5_0`, `em5_1`, `em5_2`, `em5_3`, `em5_4`, `em5_5`, `text6_0`, `text6_1`, `BroadcastTextID6`, `lang6`, `Probability6`, `em6_0`, `em6_1`, `em6_2`, `em6_3`, `em6_4`, `em6_5`, `text7_0`, `text7_1`, `BroadcastTextID7`, `lang7`, `Probability7`, `em7_0`, `em7_1`, `em7_2`, `em7_3`, `em7_4`, `em7_5`, `VerifiedBuild`) VALUES (5439, '', 'You will not be disappointed, traveler. Tailoring is a joyous endeavor.', 8085, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (5440, 'Hey mon, what can I be doin\' for you?', '', 8086, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), (5441, 'At dis point you know as much as I do, mon. Maybe you go see Magar in Orgrimmar. He not be da happiest tailor around, but he help you anyway.', '', 8087, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), @@ -3583,7 +3584,8 @@ INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, (9344, 'The waters of Quel\'thalas are teeming with fish; I take it they caught your eye? Drathen is quite experienced with the tricks of the fishing trade, and can be found on the Walk of Elders near the Royal Exchange.', 'The waters of Quel\'thalas are teeming with fish; I take it they caught your eye? Drathen is quite experienced with the tricks of the fishing trade, and can be found on the Walk of Elders near the Royal Exchange.', 15264, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (9345, 'Botanist Nathera has a keen eye for finding herbs, and I imagine she might impart her wisdom to the likes of you. You\'ll find her with the alchemists in an alcove of the Court of the Sun.', 'Botanist Nathera has a keen eye for finding herbs, and I imagine she might impart her wisdom to the likes of you. You\'ll find her with the alchemists in an alcove of the Court of the Sun.', 15266, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 11723), (9346, '', 'If jewelcrafting is what you seek, you\'ll find Telia\'s shop on the south end of the Royal Exchange.', 15268, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), - (9347, 'Along the southeast end of the Walk of Elders, Lynalis has set up a fine leatherworking stand. She\'ll train you... for a fee.', 'Along the southeast end of the Walk of Elders, Lynalis has set up a fine leatherworking stand. She\'ll train you... for a fee.', 15270, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), + (9347, 'Along the southeast end of the Walk of Elders, Lynalis has set up a fine leatherworking stand. She\'ll train you... for a fee.', 'Along the southeast end of the Walk of Elders, Lynalis has set up a fine leatherworking stand. She\'ll train you... for a fee.', 15270, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`, `text1_0`, `text1_1`, `BroadcastTextID1`, `lang1`, `Probability1`, `em1_0`, `em1_1`, `em1_2`, `em1_3`, `em1_4`, `em1_5`, `text2_0`, `text2_1`, `BroadcastTextID2`, `lang2`, `Probability2`, `em2_0`, `em2_1`, `em2_2`, `em2_3`, `em2_4`, `em2_5`, `text3_0`, `text3_1`, `BroadcastTextID3`, `lang3`, `Probability3`, `em3_0`, `em3_1`, `em3_2`, `em3_3`, `em3_4`, `em3_5`, `text4_0`, `text4_1`, `BroadcastTextID4`, `lang4`, `Probability4`, `em4_0`, `em4_1`, `em4_2`, `em4_3`, `em4_4`, `em4_5`, `text5_0`, `text5_1`, `BroadcastTextID5`, `lang5`, `Probability5`, `em5_0`, `em5_1`, `em5_2`, `em5_3`, `em5_4`, `em5_5`, `text6_0`, `text6_1`, `BroadcastTextID6`, `lang6`, `Probability6`, `em6_0`, `em6_1`, `em6_2`, `em6_3`, `em6_4`, `em6_5`, `text7_0`, `text7_1`, `BroadcastTextID7`, `lang7`, `Probability7`, `em7_0`, `em7_1`, `em7_2`, `em7_3`, `em7_4`, `em7_5`, `VerifiedBuild`) VALUES (9348, 'If digging in the dirt is the sort of pastime you find enjoyable, go share your insanity with Belil in Farstriders\' Square. I\'m certain he\'d be happy to see he\'s not the only crazy one.', 'If digging in the dirt is the sort of pastime you find enjoyable, go share your insanity with Belil in Farstriders\' Square. I\'m certain he\'d be happy to see he\'s not the only crazy one.', 15272, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (9349, 'Tyn is quite the talented skinner; she produces the finest lynx hides I\'ve yet seen. If you wish to learn from her, you\'ll find her on the southeast end of the Walk of Elders.', 'Tyn is quite the talented skinner; she produces the finest lynx hides I\'ve yet seen. If you wish to learn from her, you\'ll find her on the southeast end of the Walk of Elders.', 15274, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (9350, 'The tailor Keelen is always seeking more curious students to teach his delicate craft. His shop is somewhat difficult to uncover at first, but it\'s just north of the auction house in the Bazaar. You\'ll find him on the lower level of the building.', 'The tailor Keelen is always seeking more curious students to teach his delicate craft. His shop is somewhat difficult to uncover at first, but it\'s just north of the auction house in the Bazaar. You\'ll find him on the lower level of the building.', 15276, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 11159), @@ -5484,7 +5486,8 @@ INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, (13267, 'Malygos\' most powerful agents protect the rings above. Alone, you cannot hope to defeat them. We can grant you power to call upon drakes from our dragon flights. Mounted on the back of a drake, you will be able to fly here in the Oculus and command powerful dragon magic.', '', 28426, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), (13268, 'Belgaristrasz speaks the truth; time is running out!$B$BThe full power of your drakes has been unlocked. Use their power to defeat Eregos!', '', 28428, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), (13269, '', 'Belgaristrasz speaks the truth; the situation is grave indeed. $B$BThe full power of your drakes has been unlocked. Use their power to defeat Eregos!', 28429, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 11723), - (13270, 'None know the Scourge better than we death knights.$b$bBelieve me, $r, there\'s nothing more effective than fighting fire with fire....', '', 28437, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), + (13270, 'None know the Scourge better than we death knights.$b$bBelieve me, $r, there\'s nothing more effective than fighting fire with fire....', '', 28437, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`, `text1_0`, `text1_1`, `BroadcastTextID1`, `lang1`, `Probability1`, `em1_0`, `em1_1`, `em1_2`, `em1_3`, `em1_4`, `em1_5`, `text2_0`, `text2_1`, `BroadcastTextID2`, `lang2`, `Probability2`, `em2_0`, `em2_1`, `em2_2`, `em2_3`, `em2_4`, `em2_5`, `text3_0`, `text3_1`, `BroadcastTextID3`, `lang3`, `Probability3`, `em3_0`, `em3_1`, `em3_2`, `em3_3`, `em3_4`, `em3_5`, `text4_0`, `text4_1`, `BroadcastTextID4`, `lang4`, `Probability4`, `em4_0`, `em4_1`, `em4_2`, `em4_3`, `em4_4`, `em4_5`, `text5_0`, `text5_1`, `BroadcastTextID5`, `lang5`, `Probability5`, `em5_0`, `em5_1`, `em5_2`, `em5_3`, `em5_4`, `em5_5`, `text6_0`, `text6_1`, `BroadcastTextID6`, `lang6`, `Probability6`, `em6_0`, `em6_1`, `em6_2`, `em6_3`, `em6_4`, `em6_5`, `text7_0`, `text7_1`, `BroadcastTextID7`, `lang7`, `Probability7`, `em7_0`, `em7_1`, `em7_2`, `em7_3`, `em7_4`, `em7_5`, `VerifiedBuild`) VALUES (13271, 'Take it easy on old Nass. He\'s not as young and resilient as he once was.', '', 28438, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), (13282, 'Though my compatriots would have you take an active role in what is transpiring in Zul\'Drak, we Zandalari are primarily here to witness what is occurring and to chronicle the end of an empire.', '', 28480, 0, 1, 0, 1, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), (13287, 'Are you ready to face Mal\'Ganis with me?', '', 28506, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 12340), @@ -7483,7 +7486,8 @@ INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, (16801, 'There are no emotions. There are no morals. There are no zealots.$B$BThere is only the Brotherhood.$B$BHere, in the very chapel where Uther the Lightbringer joined the Order of the Silver Hand, I, Korfax, Champion of the Light, will inspire fear into the fearless.$B$BNothing will curb my fury - not the Scarlet Crusade, not the Argent Dawn, not my brothers, not even you.', '', 45425, 0, 1, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (16803, 'Shadow-Walker Zuru can help ya.$B$BYou\'ll find him on de lowest floor of de taller building in de southeast.', 'Shadow-Walker Zuru can help ya.$B$BYou\'ll find him on de lowest floor of de taller building in de southeast.', 45428, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (16804, 'Ku\'nanji, de Night-Stalker, is who yer lookin\' for.$B$BHe be just north of de valley\'s central building.', 'Ku\'nanji, de Night-Stalker, is who yer lookin\' for.$B$BHe be just north of de valley\'s central building.', 45429, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), - (16805, 'Witch Doctor Umbu spends his time walkin\' about de valley, tendin\' to de people and elemental spirits alike.$B$BLook for him around de central building.', 'Witch Doctor Umbu spends his time walkin\' about de valley, tendin\' to de people and elemental spirits alike.$B$BLook for him around de central building.', 45413, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), + (16805, 'Witch Doctor Umbu spends his time walkin\' about de valley, tendin\' to de people and elemental spirits alike.$B$BLook for him around de central building.', 'Witch Doctor Umbu spends his time walkin\' about de valley, tendin\' to de people and elemental spirits alike.$B$BLook for him around de central building.', 45413, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`, `text1_0`, `text1_1`, `BroadcastTextID1`, `lang1`, `Probability1`, `em1_0`, `em1_1`, `em1_2`, `em1_3`, `em1_4`, `em1_5`, `text2_0`, `text2_1`, `BroadcastTextID2`, `lang2`, `Probability2`, `em2_0`, `em2_1`, `em2_2`, `em2_3`, `em2_4`, `em2_5`, `text3_0`, `text3_1`, `BroadcastTextID3`, `lang3`, `Probability3`, `em3_0`, `em3_1`, `em3_2`, `em3_3`, `em3_4`, `em3_5`, `text4_0`, `text4_1`, `BroadcastTextID4`, `lang4`, `Probability4`, `em4_0`, `em4_1`, `em4_2`, `em4_3`, `em4_4`, `em4_5`, `text5_0`, `text5_1`, `BroadcastTextID5`, `lang5`, `Probability5`, `em5_0`, `em5_1`, `em5_2`, `em5_3`, `em5_4`, `em5_5`, `text6_0`, `text6_1`, `BroadcastTextID6`, `lang6`, `Probability6`, `em6_0`, `em6_1`, `em6_2`, `em6_3`, `em6_4`, `em6_5`, `text7_0`, `text7_1`, `BroadcastTextID7`, `lang7`, `Probability7`, `em7_0`, `em7_1`, `em7_2`, `em7_3`, `em7_4`, `em7_5`, `VerifiedBuild`) VALUES (16806, 'You be crazy, mon, meddlin\' with dat bad mojo. But I ain\'t one ta stop ya.$B$BUnjari Feltongue is in de taller building in de southeast, past de shadow priest\'s shrine.', 'You be crazy, mon, meddlin\' with dat bad mojo. But I ain\'t one ta stop ya.$B$BUnjari Feltongue is in de taller building in de southeast, past de shadow priest\'s shrine.', 45431, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (16807, 'Zamja be de best cook in Orgrimmar, mon.$B$BYou can find her just south of de valley\'s central building. Batamsi sells de food Zamja makes, too, if ya just be hungry.', 'Zamja be de best cook in Orgrimmar, mon.$B$BYou can find her just south of de valley\'s central building. Batamsi sells de food Zamja makes, too, if ya just be hungry.', 45433, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (16808, 'Jandi and Zeal\'aya work from a hut just north of de valley\'s central building.$B$BDey can help ya wit\' whatever ya need, mon.', 'Jandi and Zeal\'aya work from a hut just north of de valley\'s central building.$B$BDey can help ya wit\' whatever ya need, mon.', 45435, 1, 1, 396, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), diff --git a/data/sql/base/db_world/npc_text_locale.sql b/data/sql/base/db_world/npc_text_locale.sql index 34b983905..dbc8cafc4 100644 --- a/data/sql/base/db_world/npc_text_locale.sql +++ b/data/sql/base/db_world/npc_text_locale.sql @@ -38,7 +38,7 @@ CREATE TABLE IF NOT EXISTS `npc_text_locale` ( PRIMARY KEY (`ID`,`Locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; --- Dumping data for table acore_world.npc_text_locale: ~22,014 rows (approximately) +-- Dumping data for table acore_world.npc_text_locale: ~21,752 rows (approximately) DELETE FROM `npc_text_locale`; INSERT INTO `npc_text_locale` (`ID`, `Locale`, `Text0_0`, `Text0_1`, `Text1_0`, `Text1_1`, `Text2_0`, `Text2_1`, `Text3_0`, `Text3_1`, `Text4_0`, `Text4_1`, `Text5_0`, `Text5_1`, `Text6_0`, `Text6_1`, `Text7_0`, `Text7_1`) VALUES (1, 'deDE', '', 'Seid gegrüßt, $N', '', '', '', '', '', '', '', '', '', '', '', '', '', ''), diff --git a/data/sql/base/db_world/page_text_locale.sql b/data/sql/base/db_world/page_text_locale.sql index 3f810c06c..e0caef580 100644 --- a/data/sql/base/db_world/page_text_locale.sql +++ b/data/sql/base/db_world/page_text_locale.sql @@ -24,7 +24,7 @@ CREATE TABLE IF NOT EXISTS `page_text_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.page_text_locale: ~11,053 rows (approximately) +-- Dumping data for table acore_world.page_text_locale: ~11,054 rows (approximately) DELETE FROM `page_text_locale`; INSERT INTO `page_text_locale` (`ID`, `locale`, `Text`, `VerifiedBuild`) VALUES (15, 'deDE', 'Mein lieber Morgan,$B$Bdie Geschäfte hier in Goldhain gehen gut - so gut, dass ich bislang noch nicht einmal dazugekommen bin, dir eine Lieferung zu schicken!$B$BDie Person, die dir diese Notiz übergibt, hat gleichzeitig auch den Auftrag von mir, dir ein großes Paket Wachskerzen zu übergeben - du weißt schon, diese Dinger, wie sie Kobolde gern auf dem Kopf tragen.$B$BBitte zeig dich dankbar und entlohn die Person angemessen.', 0), diff --git a/data/sql/base/db_world/quest_offer_reward.sql b/data/sql/base/db_world/quest_offer_reward.sql index fb0846c7d..70a7f06c3 100644 --- a/data/sql/base/db_world/quest_offer_reward.sql +++ b/data/sql/base/db_world/quest_offer_reward.sql @@ -3855,7 +3855,8 @@ INSERT INTO `quest_offer_reward` (`ID`, `Emote1`, `Emote2`, `Emote3`, `Emote4`, (8885, 15, 66, 0, 0, 0, 0, 0, 0, 'At last! Though the Grimscale did not route. as hoped, it was entertaining to watch them panic in confusion when you laid low their so-called chieftain. You have my thanks, and the gratitude of the sin\'dorei of Silvermoon City!$B$BPlease, take one of these in thanks for the service that you have rendered. ', 12340), (8886, 0, 0, 0, 0, 0, 0, 0, 0, 'You did it! You\'ve saved me from ruin and delivered my revenge upon those disgusting creatures!$B$BNow if I can just get these pretty rangers here to help me with this cargo, I\'ll finally get out of here! I\'ll have to come back when Velendris has retaken the shipyard.$B$BHere, take this coin. It\'s what little I can afford, and the least that I can do to reward your efforts.', 12340), (5541, 4, 2, 0, 0, 0, 0, 0, 0, 'Great, more ammo! Old Loslor\'s shipment finally came through! The ammo might be late, but just like my grand daddy used to tell me: late\'s better than never!$b$bThank you much, $N. I already have buyers eager for this stuff!', 12340), - (5542, 1, 5, 0, 0, 0, 0, 0, 0, 'Well done, $N. Come. Rest. Let us eat and talk of days long past!', 12340), + (5542, 1, 5, 0, 0, 0, 0, 0, 0, 'Well done, $N. Come. Rest. Let us eat and talk of days long past!', 12340); +INSERT INTO `quest_offer_reward` (`ID`, `Emote1`, `Emote2`, `Emote3`, `Emote4`, `EmoteDelay1`, `EmoteDelay2`, `EmoteDelay3`, `EmoteDelay4`, `RewardText`, `VerifiedBuild`) VALUES (8889, 0, 0, 0, 0, 0, 0, 0, 0, 'I am grateful to you for your assistance, but saddened to hear that some of my fellow apprentices have fallen to their addiction.$B$BWith the power to the Spire cut off, I think I\'ll stay here a while and see if things calm down long enough for me to sneak in and retrieve their remains.', 12340), (5537, 1, 0, 0, 0, 0, 0, 0, 0, 'This\'ll work, $N! My turn now - I will imbue these with a suitable temper that will allow them to survive the intense forging process they will eventually go through.$B$BThe next step will be to get an appropriate mold for the key. I know a goblin blacksmith in Tanaris that has in the past made molds for similarly macabre items. He works for whom goblins usually work for - the highest bidder.', 12340), (5535, 0, 0, 0, 0, 0, 0, 0, 0, 'Well done, $c. Thank you for your help. The spirits are at peace, and the threats that their desire for the arcane draw have been lessened.$b$bI am sure that both sides of the conflict that ravishes Azeroth will see you are above such things.', 12340), @@ -7906,7 +7907,8 @@ INSERT INTO `quest_offer_reward` (`ID`, `Emote1`, `Emote2`, `Emote3`, `Emote4`, (13931, 0, 0, 0, 0, 0, 0, 0, 0, 'What\'s this? A stein voucher? So you like drinking? Great! After I give you this stein, go have a few drinks! Then a few more. Maybe have a few more after that... Then, now this is important, come see me.$b$bLook, I know you\'ll be back eventually. If you want your Brewfest tokens redeemed you have to see me.$b$bAnyways, here\'s the stein, and remember to talk to me later.', 12340), (13932, 0, 0, 0, 0, 0, 0, 0, 0, 'Aww, it\'s just a stein voucher... Maybe you\'re just playing hard to get. So here\'s this year\'s stein for you.$b$bBut I suspect I\'ll be seeing a lot more of you. After all, if you want any Brewfest tokens redeemed, I\'m your girl...$b$bOr maybe I\'m his girl...$b$bOooohhh... or his...', 12340), (223, 0, 0, 0, 0, 0, 0, 0, 0, 'Excuse me for my cold reception, $N, but as I\'m sure you can tell, I am an extremely busy man. I see that you have impressed Calor--and I assure you, that is no small feat--and that he has given his recommendation.$b$bThere are unsavory types afoot, $N, and we can use the help of all who have proven themselves. We battle against demons, the undead, and those who would provide them aid. Be vigilant, be wary, and trust none who would not give aid to our cause.$b$bGlory under the Light.', 12340), - (13934, 1, 1, 0, 0, 0, 0, 0, 0, 'See? Kekek never get tired of saying, "Kekek tell you so."$b$bMaybe now you believe other things Kekek tell you, like how sky is green.', 12340), + (13934, 1, 1, 0, 0, 0, 0, 0, 0, 'See? Kekek never get tired of saying, "Kekek tell you so."$b$bMaybe now you believe other things Kekek tell you, like how sky is green.', 12340); +INSERT INTO `quest_offer_reward` (`ID`, `Emote1`, `Emote2`, `Emote3`, `Emote4`, `EmoteDelay1`, `EmoteDelay2`, `EmoteDelay3`, `EmoteDelay4`, `RewardText`, `VerifiedBuild`) VALUES (13937, 0, 0, 0, 0, 0, 0, 0, 0, 'That was fun! We like toy store. Maybe orphan matron take us sometimes. We ask. Maybe you tell her too?', 12340), (13938, 1, 1, 0, 0, 0, 0, 0, 0, 'Kekek like playing with paper zeppelin. Not as good as hunting, but give something to do when bored at orphanage.', 12340), (13950, 0, 0, 0, 0, 0, 0, 0, 0, 'That was fun! We go again sometime? We can\'t wait to see our new friend again!', 12340), diff --git a/data/sql/base/db_world/quest_offer_reward_locale.sql b/data/sql/base/db_world/quest_offer_reward_locale.sql index 775274750..87f8148dc 100644 --- a/data/sql/base/db_world/quest_offer_reward_locale.sql +++ b/data/sql/base/db_world/quest_offer_reward_locale.sql @@ -24,7 +24,7 @@ CREATE TABLE IF NOT EXISTS `quest_offer_reward_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.quest_offer_reward_locale: ~49,414 rows (approximately) +-- Dumping data for table acore_world.quest_offer_reward_locale: ~50,987 rows (approximately) DELETE FROM `quest_offer_reward_locale`; INSERT INTO `quest_offer_reward_locale` (`ID`, `locale`, `RewardText`, `VerifiedBuild`) VALUES (1, 'frFR', 'Parlez à Kanrethad pour que vos talents, votre arme et votre monture vous soient rendus.', 18019), diff --git a/data/sql/base/db_world/quest_request_items_locale.sql b/data/sql/base/db_world/quest_request_items_locale.sql index ca5f3ebe0..f59d6a99c 100644 --- a/data/sql/base/db_world/quest_request_items_locale.sql +++ b/data/sql/base/db_world/quest_request_items_locale.sql @@ -24,7 +24,7 @@ CREATE TABLE IF NOT EXISTS `quest_request_items_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.quest_request_items_locale: ~42,027 rows (approximately) +-- Dumping data for table acore_world.quest_request_items_locale: ~38,918 rows (approximately) DELETE FROM `quest_request_items_locale`; INSERT INTO `quest_request_items_locale` (`ID`, `locale`, `CompletionText`, `VerifiedBuild`) VALUES (1, 'frFR', NULL, 18019), diff --git a/data/sql/base/db_world/quest_template_locale.sql b/data/sql/base/db_world/quest_template_locale.sql index 2e48a7a2b..09e8a3c58 100644 --- a/data/sql/base/db_world/quest_template_locale.sql +++ b/data/sql/base/db_world/quest_template_locale.sql @@ -32,7 +32,7 @@ CREATE TABLE IF NOT EXISTS `quest_template_locale` ( PRIMARY KEY (`ID`,`locale`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; --- Dumping data for table acore_world.quest_template_locale: ~61,287 rows (approximately) +-- Dumping data for table acore_world.quest_template_locale: ~48,881 rows (approximately) DELETE FROM `quest_template_locale`; INSERT INTO `quest_template_locale` (`ID`, `locale`, `Title`, `Details`, `Objectives`, `EndText`, `CompletedText`, `ObjectiveText1`, `ObjectiveText2`, `ObjectiveText3`, `ObjectiveText4`, `VerifiedBuild`) VALUES (1, 'deDE', 'Kanrethads Quest', 'Willkommen zurück vom Reich der Toten.$B$BEin ganzes Zeitalter ist es her, seit Ihr ein stolzer Held unter Euresgleichen wart. Doch nun seid Ihr $gein geschlagener Mann:eine geschlagene Frau; -gebrochen, ein Relikt vergangener Tage. Höret nun und ich werde der Legende, die Ihr einst wart, neues Leben einhauchen.$B$BIch werde Waffen und Kräfte, die Ihr verloren habt, wiederherstellen und Euch wieder ins Leben rufen.', 'Sprecht mit Kanrethad, um Eure Talente, Waffen und Euer Reittier wiederherzustellen.', '', 'Kehrt zu Kanrethad zurück.', 'An Eure Talente erinnern', '', '', '', 18019), diff --git a/data/sql/base/db_world/spell_dbc.sql b/data/sql/base/db_world/spell_dbc.sql index 926bea22c..7b9675a1a 100644 --- a/data/sql/base/db_world/spell_dbc.sql +++ b/data/sql/base/db_world/spell_dbc.sql @@ -1259,7 +1259,8 @@ INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes (28312, 0, 0, 0, 384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 103, 0, 0, 1, 0, 0, 0, 0, 0, 1999, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 922, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Increase Reputation', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (28316, 0, 0, 0, 754974976, 268435592, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 27, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Tent Prot (DND)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (28345, 0, 0, 0, 256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Communique Trigger', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), - (28349, 0, 0, 0, 8388864, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Despawner, other', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), + (28349, 0, 0, 0, 8388864, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Despawner, other', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes`, `AttributesEx`, `AttributesEx2`, `AttributesEx3`, `AttributesEx4`, `AttributesEx5`, `AttributesEx6`, `AttributesEx7`, `ShapeshiftMask`, `unk_320_2`, `ShapeshiftExclude`, `unk_320_3`, `Targets`, `TargetCreatureType`, `RequiresSpellFocus`, `FacingCasterFlags`, `CasterAuraState`, `TargetAuraState`, `ExcludeCasterAuraState`, `ExcludeTargetAuraState`, `CasterAuraSpell`, `TargetAuraSpell`, `ExcludeCasterAuraSpell`, `ExcludeTargetAuraSpell`, `CastingTimeIndex`, `RecoveryTime`, `CategoryRecoveryTime`, `InterruptFlags`, `AuraInterruptFlags`, `ChannelInterruptFlags`, `ProcTypeMask`, `ProcChance`, `ProcCharges`, `MaxLevel`, `BaseLevel`, `SpellLevel`, `DurationIndex`, `PowerType`, `ManaCost`, `ManaCostPerLevel`, `ManaPerSecond`, `ManaPerSecondPerLevel`, `RangeIndex`, `Speed`, `ModalNextSpell`, `CumulativeAura`, `Totem_1`, `Totem_2`, `Reagent_1`, `Reagent_2`, `Reagent_3`, `Reagent_4`, `Reagent_5`, `Reagent_6`, `Reagent_7`, `Reagent_8`, `ReagentCount_1`, `ReagentCount_2`, `ReagentCount_3`, `ReagentCount_4`, `ReagentCount_5`, `ReagentCount_6`, `ReagentCount_7`, `ReagentCount_8`, `EquippedItemClass`, `EquippedItemSubclass`, `EquippedItemInvTypes`, `Effect_1`, `Effect_2`, `Effect_3`, `EffectDieSides_1`, `EffectDieSides_2`, `EffectDieSides_3`, `EffectRealPointsPerLevel_1`, `EffectRealPointsPerLevel_2`, `EffectRealPointsPerLevel_3`, `EffectBasePoints_1`, `EffectBasePoints_2`, `EffectBasePoints_3`, `EffectMechanic_1`, `EffectMechanic_2`, `EffectMechanic_3`, `ImplicitTargetA_1`, `ImplicitTargetA_2`, `ImplicitTargetA_3`, `ImplicitTargetB_1`, `ImplicitTargetB_2`, `ImplicitTargetB_3`, `EffectRadiusIndex_1`, `EffectRadiusIndex_2`, `EffectRadiusIndex_3`, `EffectAura_1`, `EffectAura_2`, `EffectAura_3`, `EffectAuraPeriod_1`, `EffectAuraPeriod_2`, `EffectAuraPeriod_3`, `EffectMultipleValue_1`, `EffectMultipleValue_2`, `EffectMultipleValue_3`, `EffectChainTargets_1`, `EffectChainTargets_2`, `EffectChainTargets_3`, `EffectItemType_1`, `EffectItemType_2`, `EffectItemType_3`, `EffectMiscValue_1`, `EffectMiscValue_2`, `EffectMiscValue_3`, `EffectMiscValueB_1`, `EffectMiscValueB_2`, `EffectMiscValueB_3`, `EffectTriggerSpell_1`, `EffectTriggerSpell_2`, `EffectTriggerSpell_3`, `EffectPointsPerCombo_1`, `EffectPointsPerCombo_2`, `EffectPointsPerCombo_3`, `EffectSpellClassMaskA_1`, `EffectSpellClassMaskA_2`, `EffectSpellClassMaskA_3`, `EffectSpellClassMaskB_1`, `EffectSpellClassMaskB_2`, `EffectSpellClassMaskB_3`, `EffectSpellClassMaskC_1`, `EffectSpellClassMaskC_2`, `EffectSpellClassMaskC_3`, `SpellVisualID_1`, `SpellVisualID_2`, `SpellIconID`, `ActiveIconID`, `SpellPriority`, `Name_Lang_enUS`, `Name_Lang_enGB`, `Name_Lang_koKR`, `Name_Lang_frFR`, `Name_Lang_deDE`, `Name_Lang_enCN`, `Name_Lang_zhCN`, `Name_Lang_enTW`, `Name_Lang_zhTW`, `Name_Lang_esES`, `Name_Lang_esMX`, `Name_Lang_ruRU`, `Name_Lang_ptPT`, `Name_Lang_ptBR`, `Name_Lang_itIT`, `Name_Lang_Unk`, `Name_Lang_Mask`, `NameSubtext_Lang_enUS`, `NameSubtext_Lang_enGB`, `NameSubtext_Lang_koKR`, `NameSubtext_Lang_frFR`, `NameSubtext_Lang_deDE`, `NameSubtext_Lang_enCN`, `NameSubtext_Lang_zhCN`, `NameSubtext_Lang_enTW`, `NameSubtext_Lang_zhTW`, `NameSubtext_Lang_esES`, `NameSubtext_Lang_esMX`, `NameSubtext_Lang_ruRU`, `NameSubtext_Lang_ptPT`, `NameSubtext_Lang_ptBR`, `NameSubtext_Lang_itIT`, `NameSubtext_Lang_Unk`, `NameSubtext_Lang_Mask`, `Description_Lang_enUS`, `Description_Lang_enGB`, `Description_Lang_koKR`, `Description_Lang_frFR`, `Description_Lang_deDE`, `Description_Lang_enCN`, `Description_Lang_zhCN`, `Description_Lang_enTW`, `Description_Lang_zhTW`, `Description_Lang_esES`, `Description_Lang_esMX`, `Description_Lang_ruRU`, `Description_Lang_ptPT`, `Description_Lang_ptBR`, `Description_Lang_itIT`, `Description_Lang_Unk`, `Description_Lang_Mask`, `AuraDescription_Lang_enUS`, `AuraDescription_Lang_enGB`, `AuraDescription_Lang_koKR`, `AuraDescription_Lang_frFR`, `AuraDescription_Lang_deDE`, `AuraDescription_Lang_enCN`, `AuraDescription_Lang_zhCN`, `AuraDescription_Lang_enTW`, `AuraDescription_Lang_zhTW`, `AuraDescription_Lang_esES`, `AuraDescription_Lang_esMX`, `AuraDescription_Lang_ruRU`, `AuraDescription_Lang_ptPT`, `AuraDescription_Lang_ptBR`, `AuraDescription_Lang_itIT`, `AuraDescription_Lang_Unk`, `AuraDescription_Lang_Mask`, `ManaCostPct`, `StartRecoveryCategory`, `StartRecoveryTime`, `MaxTargetLevel`, `SpellClassSet`, `SpellClassMask_1`, `SpellClassMask_2`, `SpellClassMask_3`, `MaxTargets`, `DefenseType`, `PreventionType`, `StanceBarOrder`, `EffectChainAmplitude_1`, `EffectChainAmplitude_2`, `EffectChainAmplitude_3`, `MinFactionID`, `MinReputation`, `RequiredAuraVision`, `RequiredTotemCategoryID_1`, `RequiredTotemCategoryID_2`, `RequiredAreasID`, `SchoolMask`, `RuneCostID`, `SpellMissileID`, `PowerDisplayID`, `EffectBonusMultiplier_1`, `EffectBonusMultiplier_2`, `EffectBonusMultiplier_3`, `SpellDescriptionVariableID`, `SpellDifficultyID`) VALUES (28359, 0, 0, 0, 256, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 0, 0, 7, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Trigger Teslas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (28364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 2, 0, 0, 401, 0, 0, 0, 0, 0, 3799, 0, 0, 0, 0, 0, 6, 0, 0, 46, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Damage vs. Guards', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (28384, 0, 0, 0, 448, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 6, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 23, 0, 0, 10000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 28389, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Portal of Shadows', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), @@ -2261,7 +2262,8 @@ INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes (36715, 0, 0, 0, 537133312, 136, 67108864, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, -1, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Injured', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (36724, 0, 0, 0, 256, 268435456, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 41, 6, 0, 1, 1, 0, 0, 0, 0, 0, 9999, 0, 0, 0, 0, 18, 1, 0, 0, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21364, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Summon Phoenix Egg', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (36726, 0, 0, 0, 8388992, 0, 5, 268435456, 0, 0, 8192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 77, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Despawn Target', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), - (36793, 0, 0, 0, 536871168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 38, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Start Cannon Channeler (dnd)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), + (36793, 0, 0, 0, 536871168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 38, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Start Cannon Channeler (dnd)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes`, `AttributesEx`, `AttributesEx2`, `AttributesEx3`, `AttributesEx4`, `AttributesEx5`, `AttributesEx6`, `AttributesEx7`, `ShapeshiftMask`, `unk_320_2`, `ShapeshiftExclude`, `unk_320_3`, `Targets`, `TargetCreatureType`, `RequiresSpellFocus`, `FacingCasterFlags`, `CasterAuraState`, `TargetAuraState`, `ExcludeCasterAuraState`, `ExcludeTargetAuraState`, `CasterAuraSpell`, `TargetAuraSpell`, `ExcludeCasterAuraSpell`, `ExcludeTargetAuraSpell`, `CastingTimeIndex`, `RecoveryTime`, `CategoryRecoveryTime`, `InterruptFlags`, `AuraInterruptFlags`, `ChannelInterruptFlags`, `ProcTypeMask`, `ProcChance`, `ProcCharges`, `MaxLevel`, `BaseLevel`, `SpellLevel`, `DurationIndex`, `PowerType`, `ManaCost`, `ManaCostPerLevel`, `ManaPerSecond`, `ManaPerSecondPerLevel`, `RangeIndex`, `Speed`, `ModalNextSpell`, `CumulativeAura`, `Totem_1`, `Totem_2`, `Reagent_1`, `Reagent_2`, `Reagent_3`, `Reagent_4`, `Reagent_5`, `Reagent_6`, `Reagent_7`, `Reagent_8`, `ReagentCount_1`, `ReagentCount_2`, `ReagentCount_3`, `ReagentCount_4`, `ReagentCount_5`, `ReagentCount_6`, `ReagentCount_7`, `ReagentCount_8`, `EquippedItemClass`, `EquippedItemSubclass`, `EquippedItemInvTypes`, `Effect_1`, `Effect_2`, `Effect_3`, `EffectDieSides_1`, `EffectDieSides_2`, `EffectDieSides_3`, `EffectRealPointsPerLevel_1`, `EffectRealPointsPerLevel_2`, `EffectRealPointsPerLevel_3`, `EffectBasePoints_1`, `EffectBasePoints_2`, `EffectBasePoints_3`, `EffectMechanic_1`, `EffectMechanic_2`, `EffectMechanic_3`, `ImplicitTargetA_1`, `ImplicitTargetA_2`, `ImplicitTargetA_3`, `ImplicitTargetB_1`, `ImplicitTargetB_2`, `ImplicitTargetB_3`, `EffectRadiusIndex_1`, `EffectRadiusIndex_2`, `EffectRadiusIndex_3`, `EffectAura_1`, `EffectAura_2`, `EffectAura_3`, `EffectAuraPeriod_1`, `EffectAuraPeriod_2`, `EffectAuraPeriod_3`, `EffectMultipleValue_1`, `EffectMultipleValue_2`, `EffectMultipleValue_3`, `EffectChainTargets_1`, `EffectChainTargets_2`, `EffectChainTargets_3`, `EffectItemType_1`, `EffectItemType_2`, `EffectItemType_3`, `EffectMiscValue_1`, `EffectMiscValue_2`, `EffectMiscValue_3`, `EffectMiscValueB_1`, `EffectMiscValueB_2`, `EffectMiscValueB_3`, `EffectTriggerSpell_1`, `EffectTriggerSpell_2`, `EffectTriggerSpell_3`, `EffectPointsPerCombo_1`, `EffectPointsPerCombo_2`, `EffectPointsPerCombo_3`, `EffectSpellClassMaskA_1`, `EffectSpellClassMaskA_2`, `EffectSpellClassMaskA_3`, `EffectSpellClassMaskB_1`, `EffectSpellClassMaskB_2`, `EffectSpellClassMaskB_3`, `EffectSpellClassMaskC_1`, `EffectSpellClassMaskC_2`, `EffectSpellClassMaskC_3`, `SpellVisualID_1`, `SpellVisualID_2`, `SpellIconID`, `ActiveIconID`, `SpellPriority`, `Name_Lang_enUS`, `Name_Lang_enGB`, `Name_Lang_koKR`, `Name_Lang_frFR`, `Name_Lang_deDE`, `Name_Lang_enCN`, `Name_Lang_zhCN`, `Name_Lang_enTW`, `Name_Lang_zhTW`, `Name_Lang_esES`, `Name_Lang_esMX`, `Name_Lang_ruRU`, `Name_Lang_ptPT`, `Name_Lang_ptBR`, `Name_Lang_itIT`, `Name_Lang_Unk`, `Name_Lang_Mask`, `NameSubtext_Lang_enUS`, `NameSubtext_Lang_enGB`, `NameSubtext_Lang_koKR`, `NameSubtext_Lang_frFR`, `NameSubtext_Lang_deDE`, `NameSubtext_Lang_enCN`, `NameSubtext_Lang_zhCN`, `NameSubtext_Lang_enTW`, `NameSubtext_Lang_zhTW`, `NameSubtext_Lang_esES`, `NameSubtext_Lang_esMX`, `NameSubtext_Lang_ruRU`, `NameSubtext_Lang_ptPT`, `NameSubtext_Lang_ptBR`, `NameSubtext_Lang_itIT`, `NameSubtext_Lang_Unk`, `NameSubtext_Lang_Mask`, `Description_Lang_enUS`, `Description_Lang_enGB`, `Description_Lang_koKR`, `Description_Lang_frFR`, `Description_Lang_deDE`, `Description_Lang_enCN`, `Description_Lang_zhCN`, `Description_Lang_enTW`, `Description_Lang_zhTW`, `Description_Lang_esES`, `Description_Lang_esMX`, `Description_Lang_ruRU`, `Description_Lang_ptPT`, `Description_Lang_ptBR`, `Description_Lang_itIT`, `Description_Lang_Unk`, `Description_Lang_Mask`, `AuraDescription_Lang_enUS`, `AuraDescription_Lang_enGB`, `AuraDescription_Lang_koKR`, `AuraDescription_Lang_frFR`, `AuraDescription_Lang_deDE`, `AuraDescription_Lang_enCN`, `AuraDescription_Lang_zhCN`, `AuraDescription_Lang_enTW`, `AuraDescription_Lang_zhTW`, `AuraDescription_Lang_esES`, `AuraDescription_Lang_esMX`, `AuraDescription_Lang_ruRU`, `AuraDescription_Lang_ptPT`, `AuraDescription_Lang_ptBR`, `AuraDescription_Lang_itIT`, `AuraDescription_Lang_Unk`, `AuraDescription_Lang_Mask`, `ManaCostPct`, `StartRecoveryCategory`, `StartRecoveryTime`, `MaxTargetLevel`, `SpellClassSet`, `SpellClassMask_1`, `SpellClassMask_2`, `SpellClassMask_3`, `MaxTargets`, `DefenseType`, `PreventionType`, `StanceBarOrder`, `EffectChainAmplitude_1`, `EffectChainAmplitude_2`, `EffectChainAmplitude_3`, `MinFactionID`, `MinReputation`, `RequiredAuraVision`, `RequiredTotemCategoryID_1`, `RequiredTotemCategoryID_2`, `RequiredAreasID`, `SchoolMask`, `RuneCostID`, `SpellMissileID`, `PowerDisplayID`, `EffectBonusMultiplier_1`, `EffectBonusMultiplier_2`, `EffectBonusMultiplier_3`, `SpellDescriptionVariableID`, `SpellDifficultyID`) VALUES (36794, 0, 0, 0, 256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 38, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Stop Cannon Channeler (dnd)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (36799, 0, 0, 0, 384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 24, 0, 0, 1, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30499, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Create Brightsong Wine', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (36818, 0, 0, 0, 256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21419, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Attacking Infernal', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), @@ -3261,7 +3263,8 @@ INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes (50076, 0, 0, 0, 384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Helmsman Broadcast 02', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (50136, 0, 0, 0, 256, 0, 0, 268435456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Summon Silvermoon Dragonhawk', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (50157, 0, 0, 0, 536871168, 0, 4, 268435456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Instakill Other', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), - (50158, 0, 0, 0, 384, 268437504, 1, 1048576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmrest Temple - Protector Transform (Red)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), + (50158, 0, 0, 0, 384, 268437504, 1, 1048576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmrest Temple - Protector Transform (Red)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes`, `AttributesEx`, `AttributesEx2`, `AttributesEx3`, `AttributesEx4`, `AttributesEx5`, `AttributesEx6`, `AttributesEx7`, `ShapeshiftMask`, `unk_320_2`, `ShapeshiftExclude`, `unk_320_3`, `Targets`, `TargetCreatureType`, `RequiresSpellFocus`, `FacingCasterFlags`, `CasterAuraState`, `TargetAuraState`, `ExcludeCasterAuraState`, `ExcludeTargetAuraState`, `CasterAuraSpell`, `TargetAuraSpell`, `ExcludeCasterAuraSpell`, `ExcludeTargetAuraSpell`, `CastingTimeIndex`, `RecoveryTime`, `CategoryRecoveryTime`, `InterruptFlags`, `AuraInterruptFlags`, `ChannelInterruptFlags`, `ProcTypeMask`, `ProcChance`, `ProcCharges`, `MaxLevel`, `BaseLevel`, `SpellLevel`, `DurationIndex`, `PowerType`, `ManaCost`, `ManaCostPerLevel`, `ManaPerSecond`, `ManaPerSecondPerLevel`, `RangeIndex`, `Speed`, `ModalNextSpell`, `CumulativeAura`, `Totem_1`, `Totem_2`, `Reagent_1`, `Reagent_2`, `Reagent_3`, `Reagent_4`, `Reagent_5`, `Reagent_6`, `Reagent_7`, `Reagent_8`, `ReagentCount_1`, `ReagentCount_2`, `ReagentCount_3`, `ReagentCount_4`, `ReagentCount_5`, `ReagentCount_6`, `ReagentCount_7`, `ReagentCount_8`, `EquippedItemClass`, `EquippedItemSubclass`, `EquippedItemInvTypes`, `Effect_1`, `Effect_2`, `Effect_3`, `EffectDieSides_1`, `EffectDieSides_2`, `EffectDieSides_3`, `EffectRealPointsPerLevel_1`, `EffectRealPointsPerLevel_2`, `EffectRealPointsPerLevel_3`, `EffectBasePoints_1`, `EffectBasePoints_2`, `EffectBasePoints_3`, `EffectMechanic_1`, `EffectMechanic_2`, `EffectMechanic_3`, `ImplicitTargetA_1`, `ImplicitTargetA_2`, `ImplicitTargetA_3`, `ImplicitTargetB_1`, `ImplicitTargetB_2`, `ImplicitTargetB_3`, `EffectRadiusIndex_1`, `EffectRadiusIndex_2`, `EffectRadiusIndex_3`, `EffectAura_1`, `EffectAura_2`, `EffectAura_3`, `EffectAuraPeriod_1`, `EffectAuraPeriod_2`, `EffectAuraPeriod_3`, `EffectMultipleValue_1`, `EffectMultipleValue_2`, `EffectMultipleValue_3`, `EffectChainTargets_1`, `EffectChainTargets_2`, `EffectChainTargets_3`, `EffectItemType_1`, `EffectItemType_2`, `EffectItemType_3`, `EffectMiscValue_1`, `EffectMiscValue_2`, `EffectMiscValue_3`, `EffectMiscValueB_1`, `EffectMiscValueB_2`, `EffectMiscValueB_3`, `EffectTriggerSpell_1`, `EffectTriggerSpell_2`, `EffectTriggerSpell_3`, `EffectPointsPerCombo_1`, `EffectPointsPerCombo_2`, `EffectPointsPerCombo_3`, `EffectSpellClassMaskA_1`, `EffectSpellClassMaskA_2`, `EffectSpellClassMaskA_3`, `EffectSpellClassMaskB_1`, `EffectSpellClassMaskB_2`, `EffectSpellClassMaskB_3`, `EffectSpellClassMaskC_1`, `EffectSpellClassMaskC_2`, `EffectSpellClassMaskC_3`, `SpellVisualID_1`, `SpellVisualID_2`, `SpellIconID`, `ActiveIconID`, `SpellPriority`, `Name_Lang_enUS`, `Name_Lang_enGB`, `Name_Lang_koKR`, `Name_Lang_frFR`, `Name_Lang_deDE`, `Name_Lang_enCN`, `Name_Lang_zhCN`, `Name_Lang_enTW`, `Name_Lang_zhTW`, `Name_Lang_esES`, `Name_Lang_esMX`, `Name_Lang_ruRU`, `Name_Lang_ptPT`, `Name_Lang_ptBR`, `Name_Lang_itIT`, `Name_Lang_Unk`, `Name_Lang_Mask`, `NameSubtext_Lang_enUS`, `NameSubtext_Lang_enGB`, `NameSubtext_Lang_koKR`, `NameSubtext_Lang_frFR`, `NameSubtext_Lang_deDE`, `NameSubtext_Lang_enCN`, `NameSubtext_Lang_zhCN`, `NameSubtext_Lang_enTW`, `NameSubtext_Lang_zhTW`, `NameSubtext_Lang_esES`, `NameSubtext_Lang_esMX`, `NameSubtext_Lang_ruRU`, `NameSubtext_Lang_ptPT`, `NameSubtext_Lang_ptBR`, `NameSubtext_Lang_itIT`, `NameSubtext_Lang_Unk`, `NameSubtext_Lang_Mask`, `Description_Lang_enUS`, `Description_Lang_enGB`, `Description_Lang_koKR`, `Description_Lang_frFR`, `Description_Lang_deDE`, `Description_Lang_enCN`, `Description_Lang_zhCN`, `Description_Lang_enTW`, `Description_Lang_zhTW`, `Description_Lang_esES`, `Description_Lang_esMX`, `Description_Lang_ruRU`, `Description_Lang_ptPT`, `Description_Lang_ptBR`, `Description_Lang_itIT`, `Description_Lang_Unk`, `Description_Lang_Mask`, `AuraDescription_Lang_enUS`, `AuraDescription_Lang_enGB`, `AuraDescription_Lang_koKR`, `AuraDescription_Lang_frFR`, `AuraDescription_Lang_deDE`, `AuraDescription_Lang_enCN`, `AuraDescription_Lang_zhCN`, `AuraDescription_Lang_enTW`, `AuraDescription_Lang_zhTW`, `AuraDescription_Lang_esES`, `AuraDescription_Lang_esMX`, `AuraDescription_Lang_ruRU`, `AuraDescription_Lang_ptPT`, `AuraDescription_Lang_ptBR`, `AuraDescription_Lang_itIT`, `AuraDescription_Lang_Unk`, `AuraDescription_Lang_Mask`, `ManaCostPct`, `StartRecoveryCategory`, `StartRecoveryTime`, `MaxTargetLevel`, `SpellClassSet`, `SpellClassMask_1`, `SpellClassMask_2`, `SpellClassMask_3`, `MaxTargets`, `DefenseType`, `PreventionType`, `StanceBarOrder`, `EffectChainAmplitude_1`, `EffectChainAmplitude_2`, `EffectChainAmplitude_3`, `MinFactionID`, `MinReputation`, `RequiredAuraVision`, `RequiredTotemCategoryID_1`, `RequiredTotemCategoryID_2`, `RequiredAreasID`, `SchoolMask`, `RuneCostID`, `SpellMissileID`, `PowerDisplayID`, `EffectBonusMultiplier_1`, `EffectBonusMultiplier_2`, `EffectBonusMultiplier_3`, `SpellDescriptionVariableID`, `SpellDifficultyID`) VALUES (50159, 0, 0, 0, 384, 268437504, 1, 1048576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmrest Temple - Protector Transform (Green)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (50160, 0, 0, 0, 384, 268437504, 1, 1048576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Wyrmrest Temple - Protector Transform (Bronze)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (50209, 0, 0, 0, 384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 24, 0, 0, 1, 0, 0, 0, 0, 0, 99, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Create Path of Illidan', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), @@ -4256,7 +4259,8 @@ INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes (74805, 0, 0, 0, 0, 0, 0, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 76, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 202796, 202796, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Halion - Summon Twilight Portals', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), (74810, 0, 0, 0, 256, 268435456, 4, 0, 0, 0, 16785408, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 22, 0, 0, 300, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Halion - Copy Damage', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (74816, 0, 0, 0, 384, 268435456, 4, 196608, 0, 392, 16384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 181, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Dummy Nuke', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), - (74818, 0, 0, 0, 2432, 268435456, 0, 67108864, 0, 0, 0, 1073741824, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Damage Counter', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), + (74818, 0, 0, 0, 2432, 268435456, 0, 67108864, 0, 0, 0, 1073741824, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Damage Counter', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0); +INSERT INTO `spell_dbc` (`ID`, `Category`, `DispelType`, `Mechanic`, `Attributes`, `AttributesEx`, `AttributesEx2`, `AttributesEx3`, `AttributesEx4`, `AttributesEx5`, `AttributesEx6`, `AttributesEx7`, `ShapeshiftMask`, `unk_320_2`, `ShapeshiftExclude`, `unk_320_3`, `Targets`, `TargetCreatureType`, `RequiresSpellFocus`, `FacingCasterFlags`, `CasterAuraState`, `TargetAuraState`, `ExcludeCasterAuraState`, `ExcludeTargetAuraState`, `CasterAuraSpell`, `TargetAuraSpell`, `ExcludeCasterAuraSpell`, `ExcludeTargetAuraSpell`, `CastingTimeIndex`, `RecoveryTime`, `CategoryRecoveryTime`, `InterruptFlags`, `AuraInterruptFlags`, `ChannelInterruptFlags`, `ProcTypeMask`, `ProcChance`, `ProcCharges`, `MaxLevel`, `BaseLevel`, `SpellLevel`, `DurationIndex`, `PowerType`, `ManaCost`, `ManaCostPerLevel`, `ManaPerSecond`, `ManaPerSecondPerLevel`, `RangeIndex`, `Speed`, `ModalNextSpell`, `CumulativeAura`, `Totem_1`, `Totem_2`, `Reagent_1`, `Reagent_2`, `Reagent_3`, `Reagent_4`, `Reagent_5`, `Reagent_6`, `Reagent_7`, `Reagent_8`, `ReagentCount_1`, `ReagentCount_2`, `ReagentCount_3`, `ReagentCount_4`, `ReagentCount_5`, `ReagentCount_6`, `ReagentCount_7`, `ReagentCount_8`, `EquippedItemClass`, `EquippedItemSubclass`, `EquippedItemInvTypes`, `Effect_1`, `Effect_2`, `Effect_3`, `EffectDieSides_1`, `EffectDieSides_2`, `EffectDieSides_3`, `EffectRealPointsPerLevel_1`, `EffectRealPointsPerLevel_2`, `EffectRealPointsPerLevel_3`, `EffectBasePoints_1`, `EffectBasePoints_2`, `EffectBasePoints_3`, `EffectMechanic_1`, `EffectMechanic_2`, `EffectMechanic_3`, `ImplicitTargetA_1`, `ImplicitTargetA_2`, `ImplicitTargetA_3`, `ImplicitTargetB_1`, `ImplicitTargetB_2`, `ImplicitTargetB_3`, `EffectRadiusIndex_1`, `EffectRadiusIndex_2`, `EffectRadiusIndex_3`, `EffectAura_1`, `EffectAura_2`, `EffectAura_3`, `EffectAuraPeriod_1`, `EffectAuraPeriod_2`, `EffectAuraPeriod_3`, `EffectMultipleValue_1`, `EffectMultipleValue_2`, `EffectMultipleValue_3`, `EffectChainTargets_1`, `EffectChainTargets_2`, `EffectChainTargets_3`, `EffectItemType_1`, `EffectItemType_2`, `EffectItemType_3`, `EffectMiscValue_1`, `EffectMiscValue_2`, `EffectMiscValue_3`, `EffectMiscValueB_1`, `EffectMiscValueB_2`, `EffectMiscValueB_3`, `EffectTriggerSpell_1`, `EffectTriggerSpell_2`, `EffectTriggerSpell_3`, `EffectPointsPerCombo_1`, `EffectPointsPerCombo_2`, `EffectPointsPerCombo_3`, `EffectSpellClassMaskA_1`, `EffectSpellClassMaskA_2`, `EffectSpellClassMaskA_3`, `EffectSpellClassMaskB_1`, `EffectSpellClassMaskB_2`, `EffectSpellClassMaskB_3`, `EffectSpellClassMaskC_1`, `EffectSpellClassMaskC_2`, `EffectSpellClassMaskC_3`, `SpellVisualID_1`, `SpellVisualID_2`, `SpellIconID`, `ActiveIconID`, `SpellPriority`, `Name_Lang_enUS`, `Name_Lang_enGB`, `Name_Lang_koKR`, `Name_Lang_frFR`, `Name_Lang_deDE`, `Name_Lang_enCN`, `Name_Lang_zhCN`, `Name_Lang_enTW`, `Name_Lang_zhTW`, `Name_Lang_esES`, `Name_Lang_esMX`, `Name_Lang_ruRU`, `Name_Lang_ptPT`, `Name_Lang_ptBR`, `Name_Lang_itIT`, `Name_Lang_Unk`, `Name_Lang_Mask`, `NameSubtext_Lang_enUS`, `NameSubtext_Lang_enGB`, `NameSubtext_Lang_koKR`, `NameSubtext_Lang_frFR`, `NameSubtext_Lang_deDE`, `NameSubtext_Lang_enCN`, `NameSubtext_Lang_zhCN`, `NameSubtext_Lang_enTW`, `NameSubtext_Lang_zhTW`, `NameSubtext_Lang_esES`, `NameSubtext_Lang_esMX`, `NameSubtext_Lang_ruRU`, `NameSubtext_Lang_ptPT`, `NameSubtext_Lang_ptBR`, `NameSubtext_Lang_itIT`, `NameSubtext_Lang_Unk`, `NameSubtext_Lang_Mask`, `Description_Lang_enUS`, `Description_Lang_enGB`, `Description_Lang_koKR`, `Description_Lang_frFR`, `Description_Lang_deDE`, `Description_Lang_enCN`, `Description_Lang_zhCN`, `Description_Lang_enTW`, `Description_Lang_zhTW`, `Description_Lang_esES`, `Description_Lang_esMX`, `Description_Lang_ruRU`, `Description_Lang_ptPT`, `Description_Lang_ptBR`, `Description_Lang_itIT`, `Description_Lang_Unk`, `Description_Lang_Mask`, `AuraDescription_Lang_enUS`, `AuraDescription_Lang_enGB`, `AuraDescription_Lang_koKR`, `AuraDescription_Lang_frFR`, `AuraDescription_Lang_deDE`, `AuraDescription_Lang_enCN`, `AuraDescription_Lang_zhCN`, `AuraDescription_Lang_enTW`, `AuraDescription_Lang_zhTW`, `AuraDescription_Lang_esES`, `AuraDescription_Lang_esMX`, `AuraDescription_Lang_ruRU`, `AuraDescription_Lang_ptPT`, `AuraDescription_Lang_ptBR`, `AuraDescription_Lang_itIT`, `AuraDescription_Lang_Unk`, `AuraDescription_Lang_Mask`, `ManaCostPct`, `StartRecoveryCategory`, `StartRecoveryTime`, `MaxTargetLevel`, `SpellClassSet`, `SpellClassMask_1`, `SpellClassMask_2`, `SpellClassMask_3`, `MaxTargets`, `DefenseType`, `PreventionType`, `StanceBarOrder`, `EffectChainAmplitude_1`, `EffectChainAmplitude_2`, `EffectChainAmplitude_3`, `MinFactionID`, `MinReputation`, `RequiredAuraVision`, `RequiredTotemCategoryID_1`, `RequiredTotemCategoryID_2`, `RequiredAreasID`, `SchoolMask`, `RuneCostID`, `SpellMissileID`, `PowerDisplayID`, `EffectBonusMultiplier_1`, `EffectBonusMultiplier_2`, `EffectBonusMultiplier_3`, `SpellDescriptionVariableID`, `SpellDifficultyID`) VALUES (74821, 0, 0, 0, 536871296, 268435456, 4, 262144, 0, 0, 8192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Reset Check', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (74822, 0, 0, 0, 384, 268435456, 4, 0, 0, 0, 8192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Reset Check', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), (74823, 0, 0, 0, 256, 268437504, 4, 268435456, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Compare Damage Periodic', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0), From 2a29acac74032c1308ab28f0b3c0aaa05ab18d8f Mon Sep 17 00:00:00 2001 From: Mathematical Shitpost Emissary Date: Fri, 10 Feb 2023 22:07:14 -0500 Subject: [PATCH 20/87] fix(DB/SAI) Warp Aberration should keep up Arcane Shield out of combat (#14832) --- data/sql/updates/pending_db_world/rev_1675208727018608900.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675208727018608900.sql diff --git a/data/sql/updates/pending_db_world/rev_1675208727018608900.sql b/data/sql/updates/pending_db_world/rev_1675208727018608900.sql new file mode 100644 index 000000000..6fe4e9bec --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675208727018608900.sql @@ -0,0 +1,4 @@ +-- + +UPDATE `smart_scripts` SET `event_type` = 1 WHERE `entryorguid` = 18865 AND `source_type` = 0 AND `id` = 0; + From da70db415beb9e6239bcb857ed48500a0be4af07 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 04:08:28 +0100 Subject: [PATCH 21/87] =?UTF-8?q?fix(Core/Config):=20Added=20new=20config?= =?UTF-8?q?=20to=20make=20pet's=20health=20be=20modified=20b=E2=80=A6=20(#?= =?UTF-8?q?14051)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/apps/worldserver/worldserver.conf.dist | 8 ++++++++ src/server/game/Entities/Pet/Pet.cpp | 5 +++++ src/server/game/World/IWorld.h | 1 + src/server/game/World/World.cpp | 2 ++ 4 files changed, 16 insertions(+) diff --git a/src/server/apps/worldserver/worldserver.conf.dist b/src/server/apps/worldserver/worldserver.conf.dist index 576f80eba..dc296e4ab 100644 --- a/src/server/apps/worldserver/worldserver.conf.dist +++ b/src/server/apps/worldserver/worldserver.conf.dist @@ -3820,6 +3820,14 @@ QuestPOI.Enabled = 1 ChangeFaction.MaxMoney = 0 +# +# Pet.RankMod.Health +# Description: Allows pet health to be modified by rank health rates (set in config) +# Default: 1 - Enabled +# 0 - Disabled + +Pet.RankMod.Health = 1 + # ################################################################################################### diff --git a/src/server/game/Entities/Pet/Pet.cpp b/src/server/game/Entities/Pet/Pet.cpp index 55537b8a6..7c9b35048 100644 --- a/src/server/game/Entities/Pet/Pet.cpp +++ b/src/server/game/Entities/Pet/Pet.cpp @@ -1108,6 +1108,11 @@ bool Guardian::InitStatsForLevel(uint8 petlevel) float factorHealth = owner->GetTypeId() == TYPEID_PLAYER ? std::min(1.0f, cinfo->ModHealth) : cinfo->ModHealth; float factorMana = owner->GetTypeId() == TYPEID_PLAYER ? std::min(1.0f, cinfo->ModMana) : cinfo->ModMana; + if (sWorld->getBoolConfig(CONFIG_ALLOWS_RANK_MOD_FOR_PET_HEALTH)) + { + factorHealth *= _GetHealthMod(cinfo->rank); + } + SetCreateHealth(std::max(1, stats->BaseHealth[cinfo->expansion]*factorHealth)); SetModifierValue(UNIT_MOD_HEALTH, BASE_VALUE, GetCreateHealth()); SetCreateMana(stats->BaseMana * factorMana); diff --git a/src/server/game/World/IWorld.h b/src/server/game/World/IWorld.h index 47d6e34ab..38d6a4c0b 100644 --- a/src/server/game/World/IWorld.h +++ b/src/server/game/World/IWorld.h @@ -179,6 +179,7 @@ enum WorldBoolConfigs CONFIG_OBJECT_SPARKLES, CONFIG_LOW_LEVEL_REGEN_BOOST, CONFIG_OBJECT_QUEST_MARKERS, + CONFIG_ALLOWS_RANK_MOD_FOR_PET_HEALTH, BOOL_CONFIG_VALUE_COUNT }; diff --git a/src/server/game/World/World.cpp b/src/server/game/World/World.cpp index 8110e1028..fba75e240 100644 --- a/src/server/game/World/World.cpp +++ b/src/server/game/World/World.cpp @@ -1282,6 +1282,8 @@ void World::LoadConfigSettings(bool reload) _int_configs[CONFIG_CHANGE_FACTION_MAX_MONEY] = sConfigMgr->GetOption("ChangeFaction.MaxMoney", 0); + _bool_configs[CONFIG_ALLOWS_RANK_MOD_FOR_PET_HEALTH] = sConfigMgr->GetOption("Pet.RankMod.Health", true); + ///- Read the "Data" directory from the config file std::string dataPath = sConfigMgr->GetOption("DataDir", "./"); if (dataPath.empty() || (dataPath.at(dataPath.length() - 1) != '/' && dataPath.at(dataPath.length() - 1) != '\\')) From aa2627bf7c186517ae4365c9f202fa62746760e8 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 03:10:57 +0000 Subject: [PATCH 22/87] chore(DB): import pending files Referenced commit(s): da70db415beb9e6239bcb857ed48500a0be4af07 --- .../rev_1675208727018608900.sql => db_world/2023_02_11_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675208727018608900.sql => db_world/2023_02_11_02.sql} (72%) diff --git a/data/sql/updates/pending_db_world/rev_1675208727018608900.sql b/data/sql/updates/db_world/2023_02_11_02.sql similarity index 72% rename from data/sql/updates/pending_db_world/rev_1675208727018608900.sql rename to data/sql/updates/db_world/2023_02_11_02.sql index 6fe4e9bec..6613b6a79 100644 --- a/data/sql/updates/pending_db_world/rev_1675208727018608900.sql +++ b/data/sql/updates/db_world/2023_02_11_02.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_01 -> 2023_02_11_02 -- UPDATE `smart_scripts` SET `event_type` = 1 WHERE `entryorguid` = 18865 AND `source_type` = 0 AND `id` = 0; From 4f2aa6eb1fc484771c3c78d29f4dc07b1a53689a Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 09:50:56 +0100 Subject: [PATCH 23/87] fix(Core/Vehicles): Crashfix. (#14941) --- src/server/game/Entities/Vehicle/Vehicle.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/server/game/Entities/Vehicle/Vehicle.cpp b/src/server/game/Entities/Vehicle/Vehicle.cpp index c51c44aef..daf0d5e50 100644 --- a/src/server/game/Entities/Vehicle/Vehicle.cpp +++ b/src/server/game/Entities/Vehicle/Vehicle.cpp @@ -491,11 +491,10 @@ void Vehicle::RemovePassenger(Unit* unit) if (_me->IsFlying() && !_me->GetInstanceId() && unit->GetTypeId() == TYPEID_PLAYER && !(unit->ToPlayer()->GetDelayedOperations() & DELAYED_VEHICLE_TELEPORT) && _me->GetEntry() != 30275 /*NPC_WILD_WYRM*/) _me->CastSpell(unit, VEHICLE_SPELL_PARACHUTE, true); - bool isCreature = _me->GetTypeId() == TYPEID_UNIT; - if (isCreature && _me->ToCreature()->IsAIEnabled) + if (_me->GetTypeId() == TYPEID_UNIT && _me->ToCreature()->IsAIEnabled) _me->ToCreature()->AI()->PassengerBoarded(unit, seat->first, false); - if (isCreature) + if (_me && _me->GetTypeId() == TYPEID_UNIT) sScriptMgr->OnRemovePassenger(this, unit); } From 15731486eb90c1fb640ec37d6f359ac463e0d6e4 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 11:54:25 +0100 Subject: [PATCH 24/87] fix(Scripts/AzjolNerub): Fixed Hadronox being killed by mobs. (#14123) --- .../AzjolNerub/AzjolNerub/boss_hadronox.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp index a3ae4a994..a7133a2fd 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp @@ -155,6 +155,21 @@ public: return false; } + void DamageTaken(Unit* who, uint32& damage, DamageEffectType /*damageType*/, SpellSchoolMask /*damageSchoolMask*/) override + { + if ((!who || !who->IsControlledByPlayer()) && me->HealthBelowPct(70)) + { + if (me->HealthBelowPctDamaged(5, damage)) + { + damage = 0; + } + else + { + damage *= (me->GetHealthPct() - 5.0f) / 65.0f; + } + } + } + void UpdateAI(uint32 diff) override { if (!UpdateVictim()) From 41d270a4cc53ce2155a24b4e897c376381e70a33 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 12:02:09 +0100 Subject: [PATCH 25/87] fix(Scripts/Karazhan): Fixed Wizard of Oz encounter. (#14942) --- src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp | 4 ++++ src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp index a9be06b0a..19b47131f 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp @@ -201,6 +201,7 @@ public: if (AggroTimer <= diff) { me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToPC(false); AggroTimer = 0; } else @@ -400,6 +401,7 @@ public: if (AggroTimer <= diff) { me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToPC(false); AggroTimer = 0; } else @@ -512,6 +514,7 @@ public: if (AggroTimer <= diff) { me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToPC(false); AggroTimer = 0; } else @@ -626,6 +629,7 @@ public: if (AggroTimer <= diff) { me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToPC(false); AggroTimer = 0; } else diff --git a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp index 7884189fb..38ca0452d 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp @@ -348,7 +348,6 @@ public: break; case GOSSIP_ACTION_INFO_DEF+2: CloseGossipMenuFor(player); - pBarnesAI->m_uiEventId = urand(EVENT_OZ, EVENT_RAJ); pBarnesAI->StartEvent(); break; case GOSSIP_ACTION_INFO_DEF+3: From 636d9a79e2ece936304bc75e8f9ccaac9bb7da88 Mon Sep 17 00:00:00 2001 From: Mathematical Shitpost Emissary Date: Sat, 11 Feb 2023 06:02:41 -0500 Subject: [PATCH 26/87] fix(DB/SAI) Sundered Rumblers wrong use of Summon Sundered Shard (#14831) Co-authored-by: Skjalf <47818697+Nyeriah@users.noreply.github.com> --- .../pending_db_world/rev_1675207681546911800.sql | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675207681546911800.sql diff --git a/data/sql/updates/pending_db_world/rev_1675207681546911800.sql b/data/sql/updates/pending_db_world/rev_1675207681546911800.sql new file mode 100644 index 000000000..de3137a2a --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675207681546911800.sql @@ -0,0 +1,10 @@ +-- + +DELETE FROM `creature_text` WHERE `CreatureID` = 18881; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(18881,0,0,"%s shatters into shards.",16,0,100,0,0,0,19115,0,"Sundered Rumbler - Emote"); + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 18881) AND (`source_type` = 0) AND (`id` IN (2, 3)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18881, 0, 2, 0, 6, 0, 100, 0, 0, 0, 0, 0, 0, 11, 35310, 3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, "Sundered Rumbler - On Just Died - Cast \'Summon Sundered Shard\'"), +(18881, 0, 3, 0, 6, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, "Sundered Rumbler - On Just Died - Say Line 0"); From 26b6cedaf7e689e9d7093c0b03b30a2d563f7af5 Mon Sep 17 00:00:00 2001 From: ICXCNIKA <84076297+ohkasdasf@users.noreply.github.com> Date: Sat, 11 Feb 2023 12:03:54 +0100 Subject: [PATCH 27/87] fix(DB/Locale): deDE fix offer reward texts #01 (#14614) Co-authored-by: Samsequel <20357406+Samsequel@users.noreply.github.com> --- .../deDE-locale-fix-01-reward.sql | 212 ++++++++++++++++++ 1 file changed, 212 insertions(+) create mode 100644 data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql diff --git a/data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql b/data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql new file mode 100644 index 000000000..f31b0f770 --- /dev/null +++ b/data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql @@ -0,0 +1,212 @@ +DELETE FROM `quest_offer_reward_locale` WHERE `ID` IN (53, 82, 162, 184, 216, 218, 219, 235, 348, 452, 522, 599, 601, 603, 622, 629, 646, 655, 662, 742, 755, 758, 763, 792, 793, 794, 805, 826, 827, 832, 858, 863, 892, 906, 910, 911, 929, 933, 935, 944, 950, 952, 1000, 1004, 1015, 1016, 1018, 1019, 1046, 1047, 1069, 1096, 1106, 1115, 1119, 1133, 1145, 1180, 1433, 1483, 1488, 1499, 1501, 1642, 1644, 1681, 1780, 1781, 1786, 1788, 1842, 2864, 2867, 2869, 2870, 2872, 2874, 2939, 2996, 3001, 3109, 3110, 3117, 3119, 3130, 3764, 3787, 3788, 3791, 3792, 3906, 3907, 3924, 4122, 4125, 4131, 4281, 4508, 4581, 4731, 4734, 4769, 4867, 4974, 4981, 4983, 5002, 5088, 5154, 5168, 5181, 5206, 5210, 5211, 5237, 5241, 5405, 5503, 5538, 5730, 5941, 6023, 6028, 6029, 6121, 6126, 6130, 6185, 6382, 6388, 6391, 6392, 6541, 6542, 6543, 6565, 6761, 6801, 6821, 6921, 6922, 6943, 6983, 6985, 7142, 7162, 7165, 7168, 7169, 7383, 7627, 7641, 7725, 7726, 8041, 8042, 8043, 8044, 8045, 8046, 8047, 8048, 8049, 8050, 8051, 8052, 8058, 8061, 8063, 8065, 8066, 8067, 8069, 8070, 8071, 8072, 8073, 8074, 8075, 8076, 8077, 8101, 8102, 8103, 8104, 8105, 8106, 8107, 8108, 8109, 8110, 8111, 8112, 8113, 8116, 8117, 8118, 8119, 8141, 8142, 8143, 8144, 8145, 8146, 8147, 8148, 8187, 8188, 8860, 11451) AND `locale` = 'deDE'; +INSERT INTO `quest_offer_reward_locale` (`ID`, `locale`, `RewardText`, `VerifiedBuild`) VALUES +(53, 'deDE', 'Im Fasse gealtert, gefiltert durch Kohle,$BRinnt er durch die Kehle zu jedermanns Wohle.$BSo lasset uns trinken und prosten mit dem Gebräu.$BAuf Euch und auf mich, Schnapsbart Donnerbräu!', 0), +(82, 'deDE', 'Gute Arbeit... ich werde jetzt mit der Analyse dieser Dinger beginnen! Eines kann ich Euch aber direkt sagen... es handelt sich hier um keine mir bekannte Insektenform. Es scheint fast so, als würden diese Käfer von einer fremden Macht kontrolliert oder so was.$B$BIhr müsst auf der Stelle mit Rutenwünschels sprechen; anscheinend gibt es einen Notfall, bei dem er Eure Hilfe benötigt. Ich bin mir nicht sicher, aber ich glaube, es geht um weitere Käfer in der Tanariswüste!', 0), +(162, 'deDE', 'Dieser Bericht... wir Nachtelfen kennen den Schrecken, der hier erwähnt wird. Rutenwünschels hat gut daran getan, dies und Euch zu mir zu schicken.$B$BDiese Kreaturen werden die Tanariswüste schnell verzehren; sie stellen so ziemlich die größte Bedrohung dar, der wir uns je gegenübersehen werden. Macht Euch mit diesem Namen vertraut, $N: Silithid. Die hier erwähnten Insekten sind die Silithid und sie sind das Werkzeug einer der größten Bedrohungen, der sich die Horde und die Allianz gegenübersehen.$B$BWenn wir nur früher schon klug genug gewesen wären, das zu verstehen.', 0), +(184, 'deDE', 'Vielen, vielen Dank, $N! Wie schon gesagt, diese Gegend ist kein Ort mehr für ehrliche Leute, aber wenn die Dinge besser werden sollten, dann können wir mit dieser Besitzurkunde unser Land zurückfordern.$B$BIch habe nicht viel, was ich Euch anbieten kann, aber hier: Nehmt das.', 0), +(216, 'deDE', 'Gut gemacht, $C, gut gemacht! Ich werde weiterhin Truppen aussenden, um die Population der Furbolgs niedrig zu halten, aber ich kann auf mindestens einen weiteren Pfad zählen, der frei von Verstrickungen der Allianz ist. Die Eroberung des Eschentals durch die Horde ist jetzt in vollem Gang!$B$BIhr habt Euch heute Eure Bezahlung verdient. Ich ziehe den Hut vor Euch!', 0), +(218, 'deDE', 'Großartig, $N! Vielen Dank, dass Ihr mein Notizbuch zurückgeholt habt. Nun, es scheint, als sei das Trollproblem hier im Eisklammtal unter Kontrolle und als müssten wir uns nicht allzu viele Sorgen machen.$B$BNachdem ich meinem Bericht den letzten Schliff gegeben habe, werde ich jemanden brauchen, der ihn meinem Bruder Senir bringt.', 0), +(219, 'deDE', 'Ihr habt dem Königreich gut gedient, $C. Danke, dass Ihr Korporal Keeshan bei seiner Flucht vor den gefürchteten Orcs des Schwarzfelsklans geholfen habt. Eure tapferen Taten an diesem Tag sollen nicht unbelohnt bleiben.', 0), +(235, 'deDE', 'Willkommen an der neuen Grenze, $N. Das Eschental ist ein Land der unbegrenzten Möglichkeiten, eines, in dem jemand Eurer Art, $C, jede Menge Gelegenheiten finden wird, seinen Mumm unter Beweis zu stellen. Schaut Euch hier im Außenposten um und begebt Euch auf jeden Fall auch einmal hinaus zum Zoramstrand, denn die Horde hat dort noch einen weiteren Außenposten.$B$BEure Anwesenheit hier sagt mir, dass Ihr gekommen seid, um mehr über die Jagd zu lernen. Hört mir genau zu, und ich werde euch gern mitteilen, was Ihr wissen müsst.', 0), +(348, 'deDE', '... fühle die Kraft zurückkehren... $B$BWo bin ich? Beutebucht? Ach du meine Güte! Ich hatte einen seltsamen Traum... $B$B... die Schwäche hat mich nicht vollständig verlassen...', 0), +(452, 'deDE', 'Ihr habt wie ein wahrer Jünger der dunklen Fürstin gekämpft, $N. Nachdem der Rat nun tot ist, können wir vielleicht ein für alle Mal die Kontrolle über diesen Ort erlangen und Arugal aus der Burg Schattenfang vertreiben. Ich ziehe den Hut vor Euch!', 0), +(522, 'deDE', '$B$BDas erklärt den letzten Angriff auf Süderstade. Das Syndikat ist bestimmt auch hinter mir her, so wie hinter dem letzten Magistraten!', 0), +(599, 'deDE', 'Blutsegelbukaniere wollen die Beutebucht angreifen? Da können sie sich doch gleich die Aussichtsklippen runterstürzen. Aber egal, Ihr habt meiner Flotte von Schwadroneuren einen großen Dienst erwiesen, indem Ihr mir diese Information zugetragen habt. Die Schwarzmeerräuber danken Euch.', 0), +(601, 'deDE', 'Hmm, ich bin nicht geeignet, diese Armschienen zu untersuchen, um zu sehen, ob sie von Nutzen sind, aber ich bin sicher, dass zumindest ein Teil uns nützlich sein wird. Bringt sie nach Dalaran und lasst einen Magier einen Blick darauf werfen.$B$BSchließlich kann ich Beutebucht nicht einfach so verlassen, nur um mit einem dieser nervigen alten Magier ein Schwätzchen zu halten.$B$BNicht, dass ich mir Sorgen machte, irgendjemand könnte sich in der Zwischenzeit zum neuen Baron machen. Wer Revilgaz verärgert, lebt nicht mehr lang genug, um davon zu erzählen.', 0), +(603, 'deDE', 'Mein Dolch? Was seid Ihr denn für ein Komiker?$B$BWas? Soll ich Euch die ganze Geschichte noch einmal erzählen, wie ich vom besten Messerkämpfer in Beutebucht zur Witzfigur der ganzen Piratenschaft wurde?$B$BIch habe einen Messerkampf gegen einen dieser Blutsegelbukaniere verloren - eine echte Bande von Bastarden! -, und er nahm meine Klinge als Beute.$B$BAls könnte ich nur mit Beleidigungen und meiner scharfen Zunge ausgestattet, noch irgendwas bei Messerkämpfen werden.', 0), +(622, 'deDE', 'Er ist wieder heile! Das ist toll, jetzt kann ich endlich mit dem Abendessen anfangen! Ich danke Euch vielmals, $N.$B$BIch hoffe, es erging Euch gut in Beutebucht. Dort kann es ganz schön rau hergehen, und... ich habe Gerüchte gehört, dass die Goblins manchmal betrunkene Seeleute in ihre Sklavenboote zerren...$B$B... wo sie gezwungen werden, wer weiß wo hinzusegeln und wer weiß was zu tun...', 0), +(629, 'deDE', 'Das ist gut. Wenn ich nach Orgrimmar zurückkehre, werde ich diesen Splitter an einen geheiligten Ort legen. Er wird uns an die Macht und Ehre von Gri\'lek erinnern.$B$BIch danke Euch, $N. Eure Taten sind ein Zeichen wachsender Freundschaft mit dem Dunkelspeerstamm.', 0), +(646, 'deDE', 'Generation um Generation haben die Streitkräfte von Strom und Arathor die Trolle vernichtet. Jetzt ist ihre größte Waffe in unseren Händen. Unsere winzigen Fortschritte in den dampfenden Wäldern von Zul\'Gurub gehören der Vergangenheit an.$B$BIhr wart eine große Hilfe, $N, und die Trolle der Dunkelspeere stehen tief in Eurer Schuld.$B$BIch werde sicherstellen, dass das Schwert zu Nimboya in Grom\'gol gebracht wird.', 0), +(655, 'deDE', 'Ach, Ihr sprecht von Gor\'mul. Ja, von dem, was er so erzählt, scheint es, als hätte er sich niemals ganz vom Tod Schicksalshammers erholt.$B$BGor\'mul war Gefangener hier als Thrall und Orgrimm um die Befreiung des Lagers kämpften, aber als die Erde bebte und unsere Brüder entkamen, blieb er hier zurück. Er wanderte jahrelang allein und verloren ohne Richtung oder Hoffnung umher, bis wir zurückkamen, um uns hier in Hammerfall eine Heimat aufzubauen.', 0), +(662, 'deDE', 'Dass diese Informationen gesichert sind, wird das Kommando in Beutebucht etwas beruhigen. Gut gemacht, $N.', 0), +(742, 'deDE', 'Willkommen an der neuen Grenze, $N. Das Eschental ist ein Land der unbegrenzten Möglichkeiten, eines, in dem jemand Eurer Art, $C, jede Menge Gelegenheiten finden wird, seinen Mumm unter Beweis zu stellen. Schaut Euch hier im Außenposten um und begebt Euch auf jeden Fall auch einmal hinaus zum Zoramstrand, denn die Horde hat dort noch einen weiteren Außenposten.$B$BEure Anwesenheit hier sagt mir, dass Ihr gekommen seid, um mehr über die Jagd zu lernen. Hört mir genau zu, und ich werde euch gern mitteilen, was Ihr wissen müsst.', 0), +(755, 'deDE', 'Häuptling Falkenwind hat Euch geschickt? Die Riten der Erdenmutter zu bestehen ist keine leichte Aufgabe...', 0), +(758, 'deDE', 'Die Vorfahren des Donnerhörnerklans haben in einem Traum zu mir gesprochen und Eure Handlungen in der Nähe ihres Brunnens gepriesen.$B$BSie möchten hiermit ihrer Dankbarkeit Ausdruck verleihen...', 0), +(763, 'deDE', 'Eine Nachricht von meinem guten Freund Häuptling Falkenwind! Ah, seine Schnitzereien sagen mir, dass Ihr von besonderer Art seid.', 0), +(792, 'deDE', 'Das habt Ihr gut gemacht, $N.$B$BDie elenden Familiare waren zwar nur Schoßtiere der dunkleren Mächte der Brennenden Klinge, aber Euer Sieg über sie lässt mich ahnen, dass noch größere Taten folgen werden.', 0), +(793, 'deDE', 'Der schwarze Drachenschwarm ist weiter mit den abtrünnigen Orcs des Schwarzfels verbündet, und beide müssen entweder zur Einsicht gebracht oder ausgelöscht werden. Da Schattenbringer und Hematus tot sind, können wir unsere Aufmerksamkeit westwärts auf die Schwarzfelsspitze richten.', 0), +(794, 'deDE', 'Ihr habt es! Gut gemacht!$B$BEure Bemühungen im Koven der Brennenden Klinge sind der Schlüssel für die Ausrottung dieses Kults im Tal der Prüfungen. Ich fürchte jedoch, dass sie in unserem Land noch mehr vorhaben.$B$BNoch sind wir sie nicht endgültig los.', 0), +(805, 'deDE', 'Hm... Euer Bericht kommt zu einem schlechten Zeitpunkt. Die Brennende Klinge wurde hier in Sen\'jin noch nicht gesehen, aber das Böse ist vor der Küste auf den Echoinseln auf fruchtbaren Boden gefallen.$B$BDie Orcs sind Freunde der Dunkelspeertrolle. Ehrenhafte Freunde. Wir wollen den Orcs helfen, aber... wir benötigen ebenfalls Hilfe.', 0), +(826, 'deDE', 'Jetzt, da Zalazane beseitigt ist, kann unser Stamm wieder ruhig schlafen.$B$BIch danke Euch, $N. Der Dunkelspeerstamm schuldet Euch viel. Falls Ihr unter einem Gebrechen leidet, besucht meinen Assistenten Bom\'bay, da hinter mir. Sein Voodoo ist stark...', 0), +(827, 'deDE', 'Gut. In diesen Senghalsbändern verbirgt sich das Geheimnis der Brennenden Klinge. Und ich werde dieses Geheimnis lüften...', 0), +(832, 'deDE', '$B$BFaszinierend. Die Stimme, die Ihr hörtet, nannte meinen Namen? Ich bin dafür bekannt, Feinden unseres Kriegshäuptlings nachzustellen, aber... es ist doch seltsam, dass man gerade mich so hervorhebt. Noch seltsamer, dass die Kultisten der Brennenden Klinge, von denen Ihr diesen Anhänger habt, einen Namen wissen, der meinem so ähnlich ist.$B$BIch muss diesen Anhänger studieren. Ich muss ihn studieren und darüber nachdenken, was diese Nachricht bedeuten könnte.$B$BVielen Dank, dass Ihr ihn mir gebracht habt, $N. Ihr habt unserem Volk einen großen Dienst erwiesen.', 0), +(858, 'deDE', 'Ja, das sieht nach dem richtigen Schlüssel aus. Lasst mich nur kurz sehen, wie dieses Ding funktioniert...$B$BHmm... Rotationssteuerung... Damit werden Tempo und Stabilität reguliert... präzise Auslegersteuerung. Seht Euch das nur mal an! Ich fasse es nicht, dass die Venture Company etwas entwickelt hat, das so viel besser ist als unseres. Ich muss das nach Ratschet bringen!', 0), +(863, 'deDE', 'Hoffentlich liefert uns dieser Prototyp-Schrotthaufen etwas Brauchbares... mir läuft langsam die Zeit davon! Ich schicke schnellstens ein Bergungsteam zu Kurbelwizz\' Standort.$B$BOh, hier habt Ihr noch etwas für Eure Bemühungen.', 0), +(892, 'deDE', 'Keine Chance, was? Dann müssen es wohl die Freibeuter gewesen sein... Flunkerblick ist ein aufrichtiger Kerl, er würde mich nicht auf diese Weise hintergehen. Immerhin steht er auf meiner Gehaltsliste.$B$BDann müssen wohl noch ein paar Sachen abgeholt werden, $N. Was meint Ihr?', 0), +(906, 'deDE', 'Ihr habt den Anführer der Grimmhauer gefunden und eigenhändig getötet, $N? Erstaunlich.$B$BMir fehlen die Worte, aber das bedeutet nicht, dass ich nicht dankbar bin. Die Leute vom Wegekreuz sollten Respekt vor Eurer Kraft haben.$B$BIch muss gestehen, dass ich dachte, der Anführer all dieser Überfälle auf unsere Nachschublinien wäre ebenfalls ein Stacheleber. Nochmals danke, $N.', 0), +(910, 'deDE', 'Wow, das Meer ist RIESIG! Da sind so viele Seemöwen und anderes Zeug - Und es ist wirklich so laut und hektisch, wie ich es mir immer vorgestellt habe. Sogar Piraten gibt es da - der Hammer!$B$BDanke, dass du mich mit nach Ratschet genommen hast, $N. Das war einfach nur toll!', 0), +(911, 'deDE', 'Wow, im Eschental kann man wahre Abenteuer erleben! Hast du schon einmal im Eschental gekämpft, $N? Wenn ich erstmal erwachsen und ein Held bin, werde ich ins Eschental gehen und für die Ehre der Horde kämpfen!$B$BDanke, dass du mir das Grenzland gezeigt hast, $N. Du bist der Beste.', 0), +(929, 'deDE', 'Nach der Schlacht am Berg Hyjal waren wir wie verloren. Nordrassil lag unter einer Rauchwolke der Feuer, die darin loderten, und unsere Unsterblichkeit - die Essenz unseres Seins! - war dahin.$B$BIn dieser schwierigen Zeit wurde der Verräter aus seinem Gefängnis befreit und Shan\'do Sturmgrimm verschwand spurlos. Das war eine böse Zeit für uns alle.', 0), +(933, 'deDE', 'Shan\'do Sturmgrimm tauchte nie wieder auf und die Druiden waren in heller Aufregung. Bis zum heutigen Tag weiß niemand, was aus ihm geworden ist. Da Malfurion unauffindbar war, übernahm der Erzdruide Fandral Hirschhaupt die Führung der Druiden und überzeugte den Kreis der Urtume in Dunkelküste davon, dass es an der Zeit wäre, unser Volk neu zu organisieren und dass es ebenfalls an der Zeit wäre, unsere Unsterblichkeit wiederzuerlangen.$B$BMit Zustimmung des Kreises pflanzten Hirschhaupt und die mächtigsten der Druiden Teldrassil, den neuen Weltbaum.', 0), +(935, 'deDE', 'Ah ja, das Wasser, um das ich gebeten habe. Tenaron und Corithras haben sich mit der Lieferung wirklich Zeit gelassen... vielleicht haben sie sich nicht gerade den zuverlässigsten Boten ausgesucht... hmmm.$B$BNun denn, jetzt kann ich endlich wieder an meine Arbeit gehen. Das Gewicht von Teldrassils Problemen lastet auf meinen Schultern. Ein Joch, dessen ich mich liebend gern so bald wie möglich entledigen möchte.$B$BNehmt das, Ihr werdet es bestimmt irgendwie gebrauchen können.', 0), +(944, 'deDE', 'Der Klan der Schattenhammer ist bei der Meistergleve?$B$BDas ist schlecht.$B$BDer alte Lord, der damals bei der Gleve gepfählt wurde, ist schon lange tot, aber das bedeutet nicht, dass nicht noch immer Teile seiner Macht dort verblieben sind.$B$BDer Klan der Schattenhammer muss auf diese Macht aus sein.', 0), +(950, 'deDE', 'Dieses Pergament voller Gekritzel umgibt eine chaotische, primitive Magie. Ich spüre das Wirken der Altvorderen darin.$B$BHoffen wir, dass es uns Aufschluss über die Absichten des Klans der Schattenhammer in Dunkelküste gibt...', 0), +(952, 'deDE', 'Ah. Danke, $N. Es ist jedoch seltsam. Der Erzdruide scheint immer so in Eile zu sein. Der Wald weiß, dass gut Ding Weile braucht. Shan’do Sturmgrimm hat das verstanden.', 0), +(1000, 'deDE', 'Seid gegrüßt, $C.$B$BEs freut mich zu sehen, dass jemandem wie Euch das Wohlergehen der Natur am Herzen liegt. Die Geschichten über Eure großartigen Taten sind Euch vorausgeeilt und Ihr seid hier herzlich willkommen. Wenn ich Euch so sehe, erweckt Ihr in mir ein Gefühl der Zuversicht, dass der Zirkel des Cenarius genau die Hilfe bekommt, die er braucht.$B$BUnsere Verbindung zum Zirkel des Cenarius in der Mondlichtung überwindet selbst völkische und politische Abgründe. Denkt daran, wenn Ihr im Namen des Zirkels agiert, dann wird Euch alles gut gelingen.', 0), +(1004, 'deDE', 'Seid gegrüßt, $C.$B$BEs freut mich zu sehen, dass jemandem wie Euch das Wohlergehen der Natur am Herzen liegt. Die Geschichten über Eure großartigen Taten sind Euch vorausgeeilt und Ihr seid hier herzlich willkommen. Wenn ich Euch so sehe, erweckt Ihr in mir ein Gefühl der Zuversicht, dass der Zirkel des Cenarius genau die Hilfe bekommt, die er braucht.$B$BUnsere Verbindung zum Zirkel des Cenarius in der Mondlichtung überwindet selbst völkische und politische Abgründe. Denkt daran, wenn Ihr im Namen des Zirkels agiert, dann wird Euch alles gut gelingen.', 0), +(1015, 'deDE', 'Was macht Euch glauben, dass ich mich von Euresgleichen belästigen lasse, $C? Wartet - lasst mich meine wichtigen Tagesgeschäfte unterbrechen, damit ich Euch helfen kann, irgendwo ein Dingelchen zu finden. Wahrhaftig, das Wohlergehen von Darnassus - ach was, von ganz Teldrassil ist nicht so wichtig wie die Beschaffung von Flitterzeug für Eure Sammlung.$B$BDiese Narren in der Mondlichtung vergeuden meine Zeit mit ihrem Hilferuf, und jetzt muss ich mir das hier antun!', 0), +(1016, 'deDE', 'Gut gemacht, $N, das sollte uns die Informationen liefern, die wir brauchen, um den Schuldigen zu entlarven. Hättet Ihr nicht Lust, den Magier auszuschalten, der unsere Teiche mit verderbten Elementaren überschwemmt? Die Verderbnis des Eschentals und darüber hinaus dreht mir ja bereits den Magen um. Dass ein Hexer versucht, es noch weiter zu zerstören, macht mich ganz krank. Wir sollten ihn dafür bezahlen lassen.', 0), +(1018, 'deDE', 'Seid gegrüßt, $C.$B$BEs freut mich zu sehen, dass jemandem wie Euch das Wohlergehen der Natur am Herzen liegt. Die Geschichten über Eure großartigen Taten sind Euch vorausgeeilt und Ihr seid hier herzlich willkommen. Wenn ich Euch so sehe, erweckt Ihr in mir ein Gefühl der Zuversicht, dass der Zirkel des Cenarius genau die Hilfe bekommt, die er braucht.$B$BUnsere Verbindung zum Zirkel des Cenarius in der Mondlichtung überwindet selbst völkische und politische Abgründe. Denkt daran, wenn Ihr im Namen des Zirkels agiert, dann wird Euch alles gut gelingen.', 0), +(1019, 'deDE', 'Was macht Euch glauben, dass ich mich von Euresgleichen belästigen lasse, $C? Wartet - lasst mich meine wichtigen Tagesgeschäfte unterbrechen, damit ich Euch helfen kann, irgendwo ein Dingelchen zu finden. Wahrhaftig, das Wohlergehen von Darnassus - ach was, von ganz Teldrassil ist nicht so wichtig wie die Beschaffung von Flitterzeug für Eure Sammlung.$B$BDiese Narren in der Mondlichtung vergeuden meine Zeit mit ihrem Hilferuf, und jetzt muss ich mir das hier antun!', 0), +(1046, 'deDE', 'Das ist also der Schädel des wildesten Furbolg vom Eschental?$B$BIch bin von Euren Fähigkeiten mehr als angetan, $N. Die Schildwachen können Euch nicht genug danken. Ich hoffe, wir können uns auch in Zukunft darauf berufen, dass Ihr unserem Volk helft.$B$BDiesen Schädel und Dartols Rute werde ich an einem Ehrenplatz aufbewahren, damit jeder sie bewundern kann.$B$BTeronis wäre stolz. Nochmals danke.', 0), +(1047, 'deDE', 'Was macht Euch glauben, dass ich mich von Euresgleichen belästigen lasse, $C? Wartet - lasst mich meine wichtigen Tagesgeschäfte unterbrechen, damit ich Euch helfen kann, irgendwo ein Dingelchen zu finden. Wahrhaftig, das Wohlergehen von Darnassus - ach was, von ganz Teldrassil ist nicht so wichtig wie die Beschaffung von Flitterzeug für Eure Sammlung.$B$BDiese Narren in der Mondlichtung vergeuden meine Zeit mit ihrem Hilferuf, und jetzt muss ich mir das hier antun!', 0), +(1069, 'deDE', 'Ihr habt sie! Danke!$B$BIch werde sie Flunkerblick schicken, der sie dann nach Beutebucht verschifft. Ich kann den Profit schon fast schmecken!$B$BHier ist Euer Anteil, $N. Ohne Euch hätte ich dieses Geschäft nicht machen können.', 0), +(1096, 'deDE', 'Man sehe sich dieses Ding an... so was kann sich auch nur ein Gnom ausdenken. Ich kann nicht verstehen, warum man sich einen Arm abschneidet und durch so was ersetzt, wenn man doch beide Arme behalten und einfach einen dritten ansetzen könnte!$B$BGnome, ich sag\'s Euch...$B$BZumindest ist Gerenzo jetzt außer Gefecht. Hoffentlich ist das Beweis genug und Stotterspritter bringt mich in einer der Tüftlerverband-Werkstätten in Gadgetzan oder sogar Lorenhall unter.', 18019), +(1106, 'deDE', 'Fizzel hat Euch geschickt? Also das ändert die Sachlage! Natürlich helfe ich Euch. Fizzel und sein Bruder sind zwei der wenigen Leute, die mich nicht tot sehen wollen!$B$BFizzel will also Kolben herstellen, was? Kolben, die stark genug sind, um großen Belastungen standhalten zu können; was auch immer ihm vorschweben mag. Und wie ich Fizzel kenne, wird sein neuer Wagen ein Vulkan auf Rädern!', 0), +(1115, 'deDE', 'Ihr wollt etwas über Nazz Kesseldampf wissen? Er ist Rennfahrer draußen in der schimmernden Ebene, nicht?$B$BKlar kann ich über den was rauskriegen... aber leicht wird das nicht. Und es dauert.$B$BUnd kostet.', 0), +(1119, 'deDE', 'Großartig! Zischelbub kam durch! Ich werde daran denken, wenn ich ihn wiedersehe.$B$BUnd habt Dank, $N. Ihr macht Eure Sache großartig und wir werden beide eine Menge Geld damit verdienen...', 0), +(1133, 'deDE', 'Seid Ihr hier, um der Allianz Eure Dienste anzubieten, $N? Wir sind dankbar für die Unterstützung, denn wiewohl seine Schönheit ungebrochen ist... ist das Eschental nicht mehr so friedlich wie einst.', 0), +(1145, 'deDE', 'Ah, eine Notiz von Korran. Er ist schon seit langer Zeit ein treuer Diener. Ich fragte mich schon, wie es um seine Pflichten im Wegekreuz bestellt ist.', 0), +(1180, 'deDE', 'Lieferungen nach Ratschet? Lasst mich in den Logbüchern nachsehen...$B$BNein, die letzte vermerkte Sendung nach Ratschet waren Stiefel von Drizzlik. Sonst nicht viel, abgesehen von Baustoffen und Werkzeugen. Definitiv keine Rennwagenteile.', 0), +(1433, 'deDE', 'Ah, ja. Hilfe von denen, die dem Kriegshäuptling loyal sind, ist immer willkommen.$B$BMein Name ist Maurin. Ich bin hier auf Geheiß von Keldran und dem jungen Kriegshäuptling Thrall. Es ist mein Wunsch, dem jungen Anführer gegen das Böse beizustehen, das seine Regentschaft zu stören droht.$B$BKommt, kommt näher, $C. Ich erkläre Euch meinen Plan, wie man die Eiterbeule, die Brennende Klinge beseitigen kann.', 0), +(1483, 'deDE', 'Ich dachte, die Bosse der Venture Company wären Sklaventreiber, doch dann traf ich Stotterspritter, den Grausamsten von ihnen!$B$BHa! Aber immer noch besser als arbeitslos zu sein, denke ich... Oder schlimmer, mit diesem Gerenzo zu arbeiten. Wenn Ihr helfen wollt, habe ich etwas für Euch zu tun.', 0), +(1488, 'deDE', 'Ein großer Sieg für uns alle, $N. Feiern wir unseren Erfolg. Ich gehe jetzt davon aus, dass unsere Zukunft hier nicht so trostlos ist, wie ich einst dachte.$B$BDie Dämonen werden besiegt werden, die Bemühungen der Brennenden Klinge sind zum Scheitern verurteilt und wir haben vielleicht eines Tages einen Ort, den wir eine sichere Heimat nennen dürfen.', 0), +(1499, 'deDE', 'Ihr habt Eure Sache gut gemacht, $N.$B$BDie abscheulichen Familiare waren zwar nur Schoßtierchen der dunkleren Mächte bei der Brennenden Klinge, doch Euer Erfolg gegen sie lässt kommende Großtaten ahnen.', 0), +(1501, 'deDE', 'Gut. Ich hoffe, Ihr habt der Brennenden Klinge weitere Verluste zugefügt, als Ihr dies beschafft habt.$B$BSie sind dem Kriegshäuptling ein Dorn im Auge und eine echte Pest für die $C im Allgemeinen.', 0), +(1642, 'deDE', 'Abermals hallo, $N. Was machen Eure Studien des Folianten der Offenbarung?$B$BDann solltet Ihr bereit sein, Euch prüfen zu lassen. Es gibt in der Stadt und unseren Ländern immer etwas zu tun; barmherzige und verständnisvolle Taten; Menschen, die Hilfe brauchen; Kreaturen, die besiegt werden müssen.$B$BWenn Ihr beweist, dass Ihr die Geduld habt, anderen zu helfen, besonders jenen, die nicht so glücklich sind, beweist Ihr, dass Ihr ein Diener des Lichts und bei klarem Verstand seid.', 0), +(1644, 'deDE', 'Danke $N, vielen, vielen Dank!$B$BDie Kinder werden sich freuen und Ihr habt mir so viel Zeit gespart. Jetzt kann ich mich auf die anderen Bedürfnisse der Kinder konzentrieren und mein John hoffentlich früher heimkehren als wir dachten.$B$BNochmals danke, $N. Ich wusste, ich kann mich auf die Barmherzigkeit anderer verlassen. Das Licht sei mit Euch.', 0), +(1681, 'deDE', 'Ihr habt es gefunden! Gut gemacht!$B$BIch hoffe, Ihr habt im Lauf der Suche eine Menge Dunkeleisenzwerge getötet. Ich fürchte, wir werden sie in Eisenbands Lager nicht zum letzten Mal gesehen haben.$B$BAber danke für das Erz, $N. Ich brenne darauf, seine Eigenschaften herauszufinden.', 0), +(1780, 'deDE', 'Ihr kehrt so schnell zurück, $N. Und was habt Ihr während Eurer Abwesenheit von der Kathedrale erreicht?$B$BHabt Ihr bei einer edlen Sache geholfen? Vielleicht habt Ihr den Wert der Barmherzigkeit gelernt, oder etwas mehr über Eure Verpflichtung gegenüber den Bürgern von Azeroth erfahren. Sagt mir, wem Ihr geholfen habt, und wie ... Ich bin beeindruckt, $N, das sind gewiss Taten von einem, der dem Licht folgt und andere höher schätzt als sich selbst.$B$BSolche Opfer werden im Laufe der Zeit immer belohnt.', 0), +(1781, 'deDE', '*husten*$B$BWelch Freude, Euch zu sehen, $C. Schenkt meinen Wunden keine Beachtung, die guten Priester hier flicken den alten Gazin wieder zusammen. Ich brauche die Macht des Symbols des Lebens nicht, das Ihr da habt... noch nicht.$B$BDuthorian schickt Euch, um mit mir zu sprechen, hm? Schön und gut. Ich werde Euch genau schildern, was mir und meinem Freund Henze zugestoßen ist. Und mit etwas Glück und Geschick Eurerseits könnt Ihr vielleicht doch uns allen helfen.', 0), +(1786, 'deDE', 'Danke, $GBruder:Schwester.$B$BDa Ihr das Symbol des Lebens tragt, darf ich wohl annehmen, dass Euch Duthorian oder Gazin geschickt hat.$B$BIch wurde Opfer der Zauberer der Defias, als Gazin und ich ihnen ihre Pläne abnehmen wollten. Ich hielt lange genug durch, dass Gazin entkommen konnte, aber am Ende überwältigte mich ihre Magie.$B$BDoch Ihr konntet mich zurückholen: Nicht jeder besitzt die Fähigkeit, das Symbol zu benutzen, $N. Es spricht für Euch, dass Ihr fähig wart, es durch Euren eigenen Glauben mächtig werden zu lassen.', 0), +(1788, 'deDE', 'Ihr habt Eure Sache heute gut gemacht, $N. Ihr solltet stolz auf Eure Leistungen sein.$B$BUnd noch stolzer solltet Ihr auf Eure Fähigkeiten sein. Nicht jeder kann die Macht des Symbols des Lebens nutzen. Da Ihr das Licht rufen könnt, um die Toten zu erwecken, seid Ihr bereit für eine der größten Ehren eines Paladins: die Macht der Auferstehung.$B$BIhr werdet die Macht haben, gefallene Gefährten zurückbringen zu können, wie das bei Henze geschah.$B$BGehabt Euch wohl, $N. Das Licht scheint auf Euch und Ihr solltet dankbar sein.', 0), +(1842, 'deDE', 'Ah, Ihr habt sie! Jetzt werde ich die Macht in diesen Hufen absaugen und in meine Rüstung einfließen lassen, so wie die Satyrn die Stärke des Eschentals absaugten.', 0), +(2864, 'deDE', 'Hallo!$B$BOh, Ihr habt mit meinem Vetter Krazek gesprochen? Wie geht es ihm? Ich hoffe, Beutebucht bekommt ihm gut...$B$BSkarabäuspanzerschalen, sagt Ihr? Nun... lasst mich Euch eine Geschichte erzählen...', 0), +(2867, 'deDE', 'Willkommen, $N. Euer Bericht über diesen Pavillon ist höchst... Besorgnis erregend. Selbst wenn die Naga dort keinen Angriff geplant hatten, ist ihre fortwährende Gegenwart doch schlecht für unseren Vormarsch nach Feralas. Wie auch immer, hier ist die Entschädigung für Eure Nachforschungen.$B$BEs sieht so aus, als könnte die Mondfederfeste dringend zusätzliche Hilfe bezüglich der Hasskämme gebrauchen. Ich würde Euch diesen Auftrag gern anbieten, wenn Ihr Interesse daran habt. Es gibt viel zu tun.', 0), +(2869, 'deDE', 'Ja, doch, diese Schuppen sind mehr als zufrieden stellend. Tatsächlich denke ich, dass ich sie zu Pratt hinunterschicken werde, damit er einen Blick darauf wirft. Vielleicht kann er etwas Nützliches daraus herstellen.$B$BWas Euch betrifft, ich habe eine weitere Mission, auf die ich Euch schicken möchte. Doch zuerst habt Ihr hier einmal Eure Belohnung für die Schuppen. Dass Ihr weiterhin im Dienste des Generals und der Mondfederfeste steht, ist ein Segen angesichts so großer Not.', 0), +(2870, 'deDE', 'Gut gespielt, $N! Lord Shalzarus Untergang wird die Naga für eine ganze Weile, wenn nicht sogar für immer in Verwirrung stürzen. Die Bedrohung, die sie darstellen, ist nun besser unter unserer Kontrolle als je zuvor und wir haben Euch dafür zu danken.$B$BHier habt Ihr weiteres Kopfgeld aus der Schatzkammer der Festung - Ihr habt Euch jedes Kupferstück davon verdient. Ihr und die Eurigen seid jederzeit in der Mondfederfeste willkommen, mein Freund.$B$BBevor Ihr abreist, hätte ich da noch eine Kleinigkeit, $N... wenn Ihr vielleicht...', 0), +(2872, 'deDE', 'Ach, Ihr habt also mit MacKinley gesprochen, ja?$B$BEs ist nicht so, wie er denkt! Ich habe keine Angst, ihm etwas Dampfdruckrum zu geben...$B$BIch habe nur keinen Rum, den ich ihm geben könnte!', 0), +(2874, 'deDE', 'Hm, dann lasst uns mal probieren...$B$BIch kann es nicht glauben! Dieses Zeug ist... schrecklich! Großartig!$B$BNun, ich schätze Stoley kann das Geld behalten, das er mir schuldet. Er hat nicht übertrieben, als er vom Dampfdruckrum erzählte. Dieses Zeug ist zähflüssig wie Sirup und brennt wie Lava!', 0), +(2939, 'deDE', 'Oh, Troyas Mondhauch hat Euch also geschickt?$B$B... ständig geht er mir mit seinen wilden Hoffnungen auf die Nerven, dass er etwas Wichtiges gefunden hat...$B$BSeht, $N, ich sage es Euch ganz unverblümt. Troyas glaubt jedes Mal, dass er in diesen Ruinen etwas Wichtiges gefunden hat. Die Wahrheit ist aber, dass alles, was wirklich wertvoll war, wahrscheinlich vor langer Zeit schon von den Ogern oder Harpyien eingesackt wurde, die jetzt dort leben.$B$BIhr könnt Euch gern umsehen, aber ich weiß nicht, ob Ihr hier irgendwelche Bücher finden werdet, die Euch weiterhelfen.', 0), +(2996, 'deDE', 'Ein geschäftiger Tag in Ratschet, nicht wahr? Ich liebe es, dem Treiben einer Hafenstadt zuzusehen. So viel Wundersames, so viel Abenteuer... so viel Ignoranz.$B$BSehe ich da Hass in Euren Augen, $N? Gut, wir werden daraus einen Vorteil ziehen.', 0), +(3001, 'deDE', 'Ein geschäftiger Tag in Ratschet, nicht wahr? Ich liebe es, dem Treiben einer Hafenstadt zuzusehen. So viel Wundersames, so viel Abenteuer... so viel Ignoranz.$B$BSehe ich da Hass in Euren Augen, $N? Gut, wir werden daraus einen Vorteil ziehen.', 0), +(3109, 'deDE', 'Wie dem auch sei, wenn Ihr Euch in Eisklamm umseht, werdet Ihr wahrscheinlich irgendwann in einigen Dingen eine Ausbildung benötigen. Kommt einfach zu mir zurück, wann immer Ihr das Bedürfnis nach Unterweisung verspürt, und ich werde Euch lehren, was ich weiß - einen Trick hier, ein kleines Manöver dort. Ihr wisst schon, alles Mögliche, was einen am Leben erhält und einige Münzen extra einbringt.$B$BHaltet auch Ausschau nach unseren gnomischen Freunden ... bei der Zerstörung von Gnomeregan haben sie wohl ... den Kürzeren gezogen. Sie brauchen unsere Hilfe, um sich hier zu Hause zu fühlen.', 0), +(3110, 'deDE', 'Ich kann Euch unterweisen, während Ihr lernt, Euch im Eisklammtal zurechtzufinden. Wenn Ihr Euch bereit fühlt, kommt zurück zu mir und wir werden sehen, ob Ihr schon so weit seid, einen oder zwei neue Zauber zu lernen, um das Tal gegen die verdammten Troggs zu verteidigen.$B$BIhr habt das Licht sowie ganz Eisenschmiede auf Eurer Seite, $N, ... kein Druck lastet auf Euch, etwas Besonderes zu werden..', 0), +(3117, 'deDE', 'Während Ihr erlebt was das Laubschattental Euch lehren kann, kommt und besucht mich - ich kann Euch dabei behilflich sein, Eure Aufgabe als $C besser zu verstehen und zu erkennen, zu was Ihr fähig seid.$B$BWir leben in gefährlichen Zeiten, $N, nehmt die Fertigkeiten Eurer Tiere nicht als gegeben an - es gibt in dieser Welt gefährlichere Dinge als Ihr Euch vorzustellen vermögt. Geht mit Elune und kommt wieder zu mir zurück.', 0), +(3119, 'deDE', 'Aber im Moment müsst Ihr Euch nicht um die Welt unterhalb von Teldrassil kümmern. Dafür ist später noch Gelegenheit. Geht nun und sprecht mit den anderen im Laubschattental - sie können Euch mehr von den Ereignissen berichten, die sich zugetragen haben. Helft Ihnen so gut Ihr es vermögt, und wenn Ihr das Gefühl habt, weitere Ausbildung zu benötigen, kommt zu mir zurück und ich werde Euch lehren, was ich weiß.', 0), +(3130, 'deDE', 'Exzellent, $N... ich schätze eine "Geht klar"-Einstellung bei Leuten, mit denen ich arbeite.$B$BIch wurde von General Mondfeder beauftragt, die Naga direkt anzugehen. Mein Plan besteht aus zwei Teilen: Abschnitt eins sieht vor, dass wir sie sowohl zahlenmäßig als auch hinsichtlich ihrer Befehlshaber schwächen, und danach werden wir herausfinden, was sie in den Ruinen vorhaben. Mit Eurer Hilfe werden wir den Naga entgegentreten, ohne die allgemeine Sicherheit der Festung zu beeinträchtigen.', 0), +(3764, 'deDE', 'Ladet Eure wertvolle Fracht hier ab, edler $C. Es muss eine rechte Bürde gewesen sein... ähnlich der Bürde, die ich als Visionär mit mir herumtrage. Hier ist eine Entlohnung für Eure Arbeit, wie es der Erzdruide höchstpersönlich angewiesen hat.$B$BErzdruide Hirschhaupt möchte erneut mit Euch sprechen, $N, aber für seine nächste Aufgabe wäre Euch geholfen, wenn Ihr über das Wissen eines Gesellen der Kräuterkunde verfügt. Falls Ihr nicht über dieses Wissen verfügt, werdet Ihr dennoch hilfreich für den Zirkel sein.', 0), +(3787, 'deDE', 'Ich danke Euch für Euer Kommen, $Gmüder Reisender:müde Reisende;! Erlaubt mir, mich vorzustellen - ich bin Quintis Lebenshand, Druide und bescheidener Diener von Malfurion und dem Zirkel des Cenarius. Meine Kollegen (General Shandris Mondfeder und das Protektorat - vielleicht habt Ihr schon von uns gehört) und ich möchten mit Euch über die Arbeit sprechen, die Ihr für Fandral Hirschhaupt in Darnassus erledigt.$B$BBevor wir weitermachen, möchte ich Euch jedoch bitten, unser Gespräch für Euch zu behalten. Wenn Ihr damit kein Problem habt, dann können wir fortfahren.', 0), +(3788, 'deDE', 'Ich danke Euch für Euer Kommen, $Gmüder Reisender:müde Reisende;! Erlaubt mir, mich vorzustellen - ich bin Quintis Lebenshand, Druide und bescheidener Diener von Malfurion und dem Zirkel des Cenarius. Meine Kollegen (General Shandris Mondfeder und das Protektorat - vielleicht habt Ihr schon von uns gehört) und ich möchten mit Euch über die Arbeit sprechen, die Ihr für Fandral Hirschhaupt in Darnassus erledigt.$B$BBevor wir weitermachen, möchte ich Euch jedoch bitten, unser Gespräch für Euch zu behalten. Wenn Ihr damit kein Problem habt, dann können wir fortfahren.', 0), +(3791, 'deDE', 'Gah, durch dieses Morgenkorn fühle ich mich... merkwürdig. Was in Elunes Namen will Hirschhaupt mit diesen Dingern?$B$BEgal, nochmals danke für Eure Hilfe. Hier habt Ihr eine Kleinigkeit... Ihr wisst schon, für Eure Mühe. Meine Forschungen zum Thema Morgenkorn werden einige Zeit dauern, und ich werde zweifellos mehr davon benötigen. Wo ich gerade dabei bin: Ich denke, ich könnte die Zeit vielleicht nutzen um herauszufinden, ob Morgenkorn eine brauchbare alchimistische Verwendung hat. Trotzdem fühle ich mich in seiner Umgebung äußerst unwohl.', 0), +(3792, 'deDE', 'Vielen Dank, $N; ich werde das erst einmal zu meinem Vorrat legen. Und wenn ich auch nicht über die Mittel wie Hirschhaupt verfüge, so bin ich doch in der Lage, Euch etwas für Eure Bemühungen zu geben. Denn schließlich, wer kann schon wissen, was geschehen wird, wenn Hirschhaupt Morgenkorn um Morgenkorn bekommt. Hier geht etwas Merkwürdiges vor sich, denkt an meine Worte.$B$BVergesst nicht, dass ich immer nach weiterem Morgenkorn suche. Ich nehme Euch immer jeweils fünf Einheiten ab.', 0), +(3906, 'deDE', 'Das kann nicht sein... es darf nicht sein. Die Vernichtung Pyrons hat lediglich einen Schleier gelüftet. In den Tiefen vom Schwarzfels befindet sich eine noch weit heimtückischere Quelle der Verderbnis.', 0), +(3907, 'deDE', '$B$BRagnaros... hier...$B$BDie Ältesten hatten Recht, die vom Schwarzfels ausgehende Verderbnis zu fürchten. Ein General der Alten Götter! IN UNSERER WELT! Wir müssen unsere Position hier in Kargath völlig neu überdenken. Wir müssen entscheiden, ob wir bleiben und kämpfen oder ob wir aus Furcht vor einer neuen Teilung flüchten.$B$BHütet Euch vor jeder weiteren Erforschung des Schwarzfels, $N. Ein Übel, das viel größer ist als alles, was in dieser Welt existiert, haust dort unten in den feurigen Tiefen.', 0), +(3924, 'deDE', 'Ihr habt das Handbuch! Ich kann es kaum erwarten, es zu lesen und herauszufinden, wie man das Samophlang reparieren kann! Ich habe mit Stotterspritter in Ratschet gesprochen - er möchte Euch für Eure Hilfe danken und Euch für Eure Mühe belohnen.$B$BIch möchte Euch ebenfalls danken - und falls es mir gelingt, dieses Ding hier jemals zu reparieren, lasse ich es Euch wissen ...', 0), +(4122, 'deDE', 'Seht Ihr denn nicht, welche Macht wir gewinnen, wenn wir uns der Schwarzfelslegion anschließen?', 0), +(4125, 'deDE', 'Ihr habt etwas gefunden, das wie ein havariertes Ruderboot aussieht. Durch das etwas schlammige Wasser seht Ihr backbords etliche klaffende Löcher: Das ganze Boot ist fast bis auf sein einfaches hölzernes Grundgerüst zerfetzt. Was auch immer dieses Boot so zugerichtet hat, muss versucht haben, es entzweizubrechen. Steuerbords ist das Boot mit einem kleinen Wappen der Mondfederfeste bemalt.$B$BIm Matsch am Boden des Bootes seht Ihr etwas metallisch aufblitzen ...', 0), +(4131, 'deDE', 'An einen Baum in der Nähe sind zwei große Lederrucksäcke genagelt. Beide tragen auf der Vorderseite klein die Insignien der Mondfederfeste...', 0), +(4281, 'deDE', 'Elune sei gepriesen, die Lieferung von der Mondfederfeste ist endlich eingetroffen!$B$BEure Anwesenheit hier sagt mir, dass Raschal, unseren eigentlichen Kurier, wohl ein böses Schicksal ereilt hat. Ich hoffe, dass sich alles zum Guten wenden wird. Ich weiß, dass die Waldpfoten seit kurzem wegen irgendetwas, das sich südlich von ihnen ereignet hat, äußerst aufgebracht sind. Vielleicht ist er dort der Wildnis zum Opfer gefallen. Ich an Eurer Stelle wäre vorsichtig.$B$BNun denn, nochmals danke. Hier ist Eure Entlohnung für die Auslieferung des Pakets.', 0), +(4508, 'deDE', 'Ich weiß dies zwar wirklich zu schätzen, aber leider bin ich mir nicht sicher, ob es uns irgendetwas bringen wird. Die Allianz ignoriert alle Bedrohungen, die nicht von der Horde ausgehen, und sogar unsere eigenen Anführer hier in Darnassus können sich nicht darauf einigen, was diese Bedrohung eigentlich ist. Narren wie Fandral Hirschhaupt sind der Ansicht, dass die Silithiden längst nicht die Gefahr aus der Vergangenheit darstellen, für die ich sie halte. Seine Unwissenheit wird nur noch von seiner Arroganz übertroffen.$B$BIhr habt die Bedrohung doch selbst gesehen, $N. Wir müssen weiterhin alles tun, um die Silithiden zu besiegen!', 0), +(4581, 'deDE', 'Ah, Shindrells Bericht! Vielen Dank, $N. Shindrell ist, wie eine gute Schildwache sein muss: mutig und aufmerksam. Ich muss das hier lesen; vielleicht finden sich darin Hinweise auf ein Übel, von dem ich fürchte, dass es durch das Eschental zieht.', 0), +(4731, 'deDE', 'Ich habe schon von solchen Sänften gehört, wie Ihr sie auf dem Rücken jener Meeresschildkröte gefunden habt. Ich glaube, es handelt sich dabei um Nagasänften, die diese sowohl im Kampf verwenden als auch, um Vorräte an Land zu befördern. Die Zeichen auf dem Kasten, den Ihr gefunden habt, stammen von den Naga ... könnte die Kreatur, die Ihr entdeckt habt, getötet worden sein, als sie gerade unterwegs nach Süden war... zum Eschental vielleicht?$B$BIch werde es nicht versäumen, diesen Kasten zusammen mit Euren übrigen Entdeckungen nach Darnassus zu schicken. Das ist für Euch - nochmals danke für Eure Hilfe.', 0), +(4734, 'deDE', 'Es hat funktioniert? Ausgezeichnet! Ich hab\'s gewusst!$B$BWährend Ihr weg wart, habe ich an einer neuen Version des Eiszilloskops gearbeitet. Es hat jetzt eine viel größere Reichweite.$B$BHier, Ihr könnt eines davon haben, falls Ihr noch mal zur Schwarzfelsspitze zurückgeht.', 0), +(4769, 'deDE', 'Das stimmt. Ich glaube, dass es auf der Schwarzfelsspitze eine Schrifttafel gibt, die alte alchimistische Rezepte enthält. Ich bin froh, dass Ihr hier seid, denn ich brauche Hilfe, um an diese Schrifttafel zu gelangen.$B$BMacht es Euch bequem, dann erkläre ich es Euch näher.', 0), +(4867, 'deDE', 'Aha! Ich kann bereits fühlen, wie meine Macht zu mir zurückkehrt. Und meine Gedanken werden nicht mehr von Uroks Fluch gestört.$B$BDanke, $N! Bescheidenheit ist unter meiner Würde, aber ich muss Eure Hilfe anerkennen.$B$BUnd ich wünsche Euch Glück auf Euren Reisen durch die Schwarzfelsspitze. Ihr seid ein Narr zu denken, Ihr könntet es bis an die Spitze schaffen, aber Euer Mut steht außer Frage.', 0), +(4974, 'deDE', 'Ihr habt der Streitmacht von Schwarzfels einen schweren Schlag versetzt, $N. Da ihr Kriegshäuptling jetzt tot ist, wird die Schwarzfelslegion erneut im Sumpf des Chaos versinken.$B$BZu Ehren Euer Heldentaten wird Euch das Volk von Kalimdor belohnen!', 0), +(4981, 'deDE', 'Ich kann Euch nicht belügen, $R. Ich brauchte das Geld! Kibler bezahlt mich sehr, sehr gut - viel besser als es das KEK je könnte.$B$BAber bitte zweifelt nicht an meiner Loyalität! Warum, glaubt Ihr, bin ich wohl hier? Um diesem verrückten Goblin ein paar Eier von exotischen Tieren oder ähnlichen Unfug zu bringen? Nein, nur jemand, der wirklich absolut dämlich ist, würde zur Schwarzfelsspitze kommen, um nach Tieren zu suchen. Tja, ich glaube nicht, dass es allzu viele Leute dieser Art auf der Welt gibt.$B$B$B$BDas würde uns gerade noch fehlen, dass sich solche Leute noch vermehren.', 0), +(4983, 'deDE', 'Eines muss man ihr lassen, sie hat es wieder einmal geschafft, sich aus einer heiklen Situation herauszulavieren! Diese Berichte werden sich als unschätzbar erweisen, wenn wir es wieder mit den Orcs des Schwarzfelsklans zu tun bekommen.$B$BNatürlich werdet Ihr für Eure harte Arbeit belohnt werden.', 0), +(5002, 'deDE', 'Das passt zu einem großen Teil dessen, was wir bereits wissen. Dennoch ist es interessant und höchst unerfreulich.$B$BDie Markierungen auf dieser Karte werden sich bei der Ausdünnung der Schwarzfelsbedrohung als wertvoll erweisen.', 0), +(5088, 'deDE', 'Das ergibt keinen Sinn. Warum sollte Arikara hinter Cairne Bluthuf her sein? Magatha kann sich nicht irren, sie ist unsere mächtigste Schamanin.$B$B$B$BWie dem auch sei, Eure große Tat für die Horde soll nicht unbemerkt bleiben - wählt bitte einen dieser Gegenstände als Belohnung für Eure Hilfe.', 0), +(5154, 'deDE', 'Sehr schön, Ihr habt es gefunden!$B$BHabt Ihr es gelesen? Wird Joseph Rotpfad erwähnt? Falls er erwähnt wird, dann können wir ihn vielleicht retten!$B$BAh. Die \'Annalen von Darroheim\' erzählen eine sehr beunruhigende Geschichte. Darin heißt es, dass Joseph Rotpfad während des Kampfes verderbt wurde und sich in die Ränge der Geißel eingereiht hat! Dann verriet er die Verteidiger von Darroheim.$B$BDas ist ein übles Schicksal. Wir sollten versuchen, dieses Schicksal zu ändern, so das möglich ist, meint Ihr nicht?', 0), +(5168, 'deDE', 'Ihr habt den Buchband und den Schild!$B$BIhre Geschichte ist mit der Geschichte von Darroheim verbunden und irgendwie weiß ich, dass das Schicksal sie wieder zusammenführen wird.', 0), +(5181, 'deDE', 'Ihr habt sie gefunden! Gut gemacht, $N! Diese Relikte enthalten eine Macht, die ich nicht ganz verstehe, eine Macht, die Ihr eines Tages beherrschen werdet.$B$BSie wecken aber auch dunkle Erinnerungen in meinen Gedanken, Erinnerungen an Tod und Verrat und an die letzte Nacht von Darroheim...', 0), +(5206, 'deDE', 'Ihr habt sie gefunden! Großartig!$B$BWenn ich auch nicht genau weiß, inwiefern sie uns helfen werden, so spüre ich doch ihre Macht und fühle es in meinen Knochen, dass sie irgendwie mit meinem Heimatdorf Darroheim verbunden sind.', 0), +(5210, 'deDE', 'Was ist mit diesem Buch? \'Die Annalen von Darroheim\'? Das war mein Heim vor dem Krieg... mein Heim vor der Schlacht, die es zerstörte! Warum habt Ihr mir dieses Buch gebracht?$B$BAber seht doch nur hier! Am Ende sind Seiten, die Geschichten von den Tagen nach der Schlacht erzählen! Hier ist eine Passage über mich! Und eine über meinen Bruder Joseph! Ist dieses Buch echt?$B$BWir müssen die Wahrheit erfahren!', 0), +(5211, 'deDE', 'Es ist gut zu hören, dass Ihr die gequälten Seelen meiner Brüder gefunden und befreit habt. Mein Herz wird weniger weinen, da es weiß, dass zumindest einige der Verteidiger von Darroheim nicht mehr länger in der widerlichen Dienerschaft der Geißel gefangen sind.', 0), +(5237, 'deDE', '$N, Eure erfolgreiche Umarbeitung der Kessel ist ein überwältigender Sieg für uns!$B$BAlle, die sich hier in meinem Umfeld befinden, mögen Folgendes hören: Für Dienste am Königreich Sturmwind und der Allianz, die über die gebotenen Pflichten hinausgingen - trotz wenig Erfolg versprechender Chancen und im Angesicht unglaublicher Gefahren, möchte ich $N dies geben und ihn unserer unvergänglichen Dankbarkeit als wahren Helden der Allianz versichern. Danke, sage ich!', 0), +(5241, 'deDE', 'Ihr habt Pamela gesehen? Sie lebt?$B$BSie ist tot? Nein! Oh, Pamela! Warum leidet dein Geist nur immer noch in dieser Welt... Warum bist du umgekommen, während das Schicksal mich am Leben erhält? Ich würde sofort mit dir tauschen und durch das tote Darroheim wandern, als Geisterscheinung und allein!$B$BAch, aber diese Neuigkeiten können das Schicksal nicht ändern. Ich danke Euch, $N. Jetzt brennt meine Pflicht, meine Pflicht zur Rache, so heiß wie noch nie.', 0), +(5405, 'deDE', 'Alle, die für die Argentumdämmerung das Böse bekämpfen, müssen unsere Anstecknadel tragen. Wenn Ihr eine solche tragt, erhaltet Ihr das Recht, Belohnungen in Anspruch zu nehmen, die unsere Rüstmeister anzubieten haben.$B$BWährend Ihr die Nadel tragt, könnt Ihr Euch Geißelsteine von erschlagenen Mitgliedern der Geißel holen; das sind Insignien, die sie manchmal besitzen. Beschafft Euch diese Insignien und bringt sie mir. Für alle, die Ihr abgebt, erhaltet Ihr unsere Marke des Heldentums - die Ehrenmarke der Argentumdämmerung.$B$BErfüllt Euer Schicksal, $C...stürzt Euch noch heute in den Kampf!', 0), +(5503, 'deDE', 'Alle, die für die Argentumdämmerung das Böse bekämpfen, müssen unsere Anstecknadel tragen. Wenn Ihr eine solche tragt, erhaltet Ihr das Recht, Belohnungen in Anspruch zu nehmen, die unsere Rüstmeister anzubieten haben.$B$BWährend Ihr die Nadel tragt, könnt Ihr Euch Geißelsteine von erschlagenen Mitgliedern der Geißel holen; das sind Insignien, die sie manchmal besitzen. Beschafft Euch diese Insignien und bringt sie mir. Für alle, die Ihr abgebt, erhaltet Ihr unsere Marke des Heldentums - die Ehrenmarke der Argentumdämmerung.$B$BErfüllt Euer Schicksal, $C...stürzt Euch noch heute in den Kampf!', 0), +(5538, 'deDE', 'Arbington sagte, dass Ihr die Sachen liefern würdet, und das habt Ihr auch getan! Ein Handel ist ein Handel; dann werde ich jetzt mal die Fragmente für Euch in die Form packen.$B$BHat Arbington sie bereits mit Magie erfüllt? Hervorragend... anderenfalls wäre es für Euch ein langer Weg zurück zur Zugwindspitze gewesen.', 0), +(5730, 'deDE', 'Das Eschental? Hmm, ich hatte nichts von der Anwesenheit des Rates oder der Brennenden Klinge im Eschental gewusst. Meine Spione werden das untersuchen, $N. Das habt Ihr gut gemacht.$B$BJetzt ruht Euch erst einmal aus und beschäftigt Euch mit anderen Aufgaben. Ich werde Euch bald wieder benötigen.$B$BLok-Tar Ogar!', 0), +(5941, 'deDE', 'Ach ja, da sind sie ja. Gemeinsam weben sie einen mächtigen Zauber, einen, der die Geister von Darroheim wiedererwecken wird.$B$BMit diesem Zauber und etwas Glück können wir Joseph Rotpfad retten!', 0), +(6023, 'deDE', 'Danke, $N. Ihr habt mir mehr geholfen als ich hoffen durfte. Die Luft hier scheint mir die Willenskraft auszusaugen. Ich bin müde und spüre, dass es sich nicht bessern wird, solange ich hier bin.$B$BIch habe wirklich keine Ahnung, wie ich nach Herdweiler hineingelangen und melden soll, wie stark die Präsenz des Scharlachroten Kreuzzugs dort ist.$B$BAber das ist ein anderes Thema. Bevor Ihr geht, hier, nehmt dies... als Bezahlung für Eure Hilfe. Nochmals danke.', 0), +(6028, 'deDE', 'Gregor ist außerordentlich findig. Er hat schon seit geraumer Zeit mit dem Dampfdruckkartell zu tun und ist ein Experte in der \'Kunst\' von Goblin-Verhandlungen geworden. Es stimmt zwar, dass die Goblins weitgehend denen mit den größten Geldbörsen gegenüber loyal sind, aber sie kennen und achten auch den Wert der Diplomatie. Sie bringt ihnen immerhin Kunden ein, die wiederkommen ...$B$BWie auch immer, die Argentumdämmerung dankt Euch für Eure Bemühungen. Bitte nehmt dies mit unserem Dank.', 0), +(6029, 'deDE', 'Gregor ist außerordentlich findig für einen Menschen. Er hat schon seit geraumer Zeit mit dem Dampfdruckkartell zu tun und ist ein Experte in der \'Kunst\' von Goblin-Verhandlungen geworden. Es stimmt zwar, dass die Goblins weitgehend denen mit den größten Geldbörsen gegenüber loyal sind, aber sie kennen und achten auch den Wert der Diplomatie. Sie bringt ihnen immerhin Kunden ein, die wiederkommen ...$B$BWie auch immer, die Argentumdämmerung dankt Euch für Eure Bemühungen. Bitte nehmt dies mit unserem Dank.', 0), +(6121, 'deDE', 'Seid gegrüßt, junger $C, ich sehe mit Freuden, dass Ihr begierig seid, etwas über die Heilung von Vergiftungen zu lernen.$B$BFrüher wurden die meisten Druiden vorab geplanten Prüfungen unterzogen, doch das trifft auf Euch nicht zu. In Auberdine traten vermehrt Fälle von Tiervergiftungen auf und die Dorfbewohner konnten sie nicht heilen. Aus diesem Grund bat ein Repräsentant die Mondlichtung um Hilfe. Wir schicken Euch zu ihrer Unterstützung dorthin. Dies ist keine Übung - es handelt sich um eine echte Aufgabe. Vergesst das nicht.', 0), +(6126, 'deDE', 'Seid gegrüßt, junger $C, ich sehe mit Freuden, dass Ihr begierig seid, etwas über die Heilung von Vergiftungen zu lernen.$B$BFrüher wurden die meisten Druiden vorab geplanten Prüfungen unterzogen, doch das trifft auf Euch nicht zu. Beim Wegekreuz im Brachland traten vermehrt Fälle von Tiervergiftungen auf, die nicht unter Kontrolle zu bringen sind. Jemand dort bat die Mondlichtung um Hilfe. Wir schicken Euch zu ihrer Unterstützung dorthin. Dies ist keine Übung - es handelt sich um eine echte Aufgabe. Vergesst das nicht.', 0), +(6130, 'deDE', 'Willkommen - ich verfolge Eure Fortschritte in dieser Lektion seit Eurem Aufbruch und muss gestehen, ich war überrascht, als ich von der Situation im Wegekreuz erfuhr. Dies erfordert weitere Untersuchungen, da die Freisetzung solcher Gifte in die Umwelt das Gleichgewicht empfindlich stört.$B$BIhr habt Euch unter großem Druck wacker gehalten. Dafür finde ich keine bessere Möglichkeit, als Euch mit permanenter Macht über Gift zu belohnen. Verwendet sie weise, $N... verwendet sie weise.', 0), +(6185, 'deDE', 'Rutger. Fredo. Turyen. Alle... tot...$B$B$B$BWo waren sie? Habt Ihr weitere Informationen über diesen Dreckskerl, diesen Pestrufer, gefunden?', 0), +(6382, 'deDE', 'Willkommen an der neuen Grenze, $N. Das Eschental ist ein Land der unbegrenzten Möglichkeiten, eines, in dem jemand Eurer Art, $C, jede Menge Gelegenheiten finden wird, seinen Mumm unter Beweis zu stellen. Schaut Euch hier im Außenposten um und begebt Euch auf jeden Fall auch einmal hinaus zum Zoramstrand, denn die Horde hat dort noch einen weiteren Außenposten.$B$BEure Anwesenheit hier sagt mir, dass Ihr gekommen seid, um mehr über die Jagd zu lernen. Hört mir genau zu, und ich werde euch gern mitteilen, was Ihr wissen müsst.', 0), +(6388, 'deDE', 'Ihr müsst das nach Thelsamar bringen, hm? Das wird gar kein Problem sein. Wenn Ihr schon in Thelsamar gewesen seid und mit Thorgrum Borrelson gesprochen habt, dann könnt Ihr einen meiner Greifen zurück zu ihm nehmen.', 0), +(6391, 'deDE', 'Ah, die neueste Liste von Brocks Meisterschülern. Ich habe schon ein paar Ehrenhacken bereit. Ich muss nur noch die Namen der Studenten eingravieren...', 0), +(6392, 'deDE', 'Ihr habt die Hacken. Großartig! Ich werde sie meinen Bergbaustudenten bringen. Sie können es sicher kaum erwarten, sich damit auf die Erzvorkommen von Loch Modan zu stürzen.$B$BDanke für Eure Hilfe, $N. Ich stehe in Eurer Schuld, hoffe jedoch, dieses Geld wird wenigstens Eure Reisekosten decken.', 0), +(6541, 'deDE', 'Das Eschental ist ein geteiltes Land, aber unsere jüngsten Bemühungen waren sehr erfolgreich. Wir haben jetzt nicht nur einen Außenposten am Zoramstrand, sondern noch einen weiteren nördlich von hier. Er heißt Splitterholzposten.', 0), +(6542, 'deDE', 'Das Eschental ist ein geteiltes Land, aber unsere jüngsten Bemühungen waren sehr erfolgreich. Wir haben jetzt nicht nur einen Außenposten am Zoramstrand, sondern noch einen weiteren nördlich von hier. Er heißt Splitterholzposten.', 0), +(6543, 'deDE', 'Wie ich sehe, kann ich auf Euch zählen. Diese Neuigkeiten sind unerlässlich für unsere Pläne, unsere Position im Eschental zu festigen. Jetzt können wir unseren nächsten Schritt planen.', 0), +(6565, 'deDE', 'Sehr gut! Danke, $N. Wir mögen zwar die Schattenhammer nicht vollständig aufgehalten haben, aber zumindest habt Ihr einen weiteren ihrer Pläne durchkreuzt, die Alten Götter wieder mächtig zu machen.$B$BWer weiß, welche Pläne sie sonst noch verfolgen mochten, aber wir können vorerst beruhigt sein.', 0), +(6761, 'deDE', 'Vielen Dank, dass Ihr gekommen seid, $C. Ich entschuldige mich für das Missverständnis... es gibt viel Misstrauen zwischen dem Erzdruiden hier und dem Bewahrer Remulos in der Mondlichtung. Jeder verdächtigt den anderen der Schikane und die Tatsache, dass die merkwürdige Verderbnis von Teldrassil auch weiterhin nicht nachlässt, ist hier immer noch ein Thema. Das trägt wenig dazu bei, das Misstrauen zu lindern.$B$BTrotzdem bleibt unsere Pflicht gegenüber dem Zirkel des Cenarius bestehen... auch wenn diejenigen, die ihn leiten, untereinander uneins sind.', 0), +(6801, 'deDE', 'Das Blut unserer Feinde wurde vergossen. Ich werde nun dieses Blut, mit dem restlichen gesammelten Blut vermischen. Sobald unser Opfer abgeschlossen ist, wird der Eislord diesen Hunden von der Sturmlanzengarde den ganzen Zorn des Frostwolfklans vor Augen führen!', 0), +(6821, 'deDE', 'Ah, Ihr habt also die Kraft. Und Ihr habt auch die benötigte Schlauheit, denn die Schwarzfelsspitze erfordert mehr als rohe Gewalt.$B$BIn der Tat, $N, Ihr könntet Euch für uns noch als geschätzter Verbündeter erweisen...', 0), +(6921, 'deDE', 'Genau das brauche ich! Ein Tiefenkern ist ein unglaublicher Quell an Informationen, aus denen wir guten Nutzen ziehen können. Was auch immer die Schattenhammer da unten im Schilde führen - und glaubt mir, wenn ich sage, dass es nichts Gutes sein kann -, meine Kollegen und ich werden es jetzt aufdecken.$B$BIhr habt Eure Sache hier heute gut gemacht. Der Irdene Ring ist Euch sehr dankbar für Eure Hilfe. Ihr habt außerdem der Horde als Ganzes geholfen, und darauf solltet Ihr stolz sein.', 0), +(6922, 'deDE', 'Das... das ist ein wichtiger Fund, $N.$B$BIhr habt dies von Baron Aquanis aus der Tiefschwarzen Grotte, sagt Ihr? Man hatte Baron Aquanis schon lange im Verdacht, eine verderbte Elementarkraft zu sein. Diese Kugel wird zeigen, was genau ihn verdorben hat. Es würde mich nicht im Geringsten überraschen, wenn es sich dabei um die Twilight-Hammer handelt. Aber unsere Studien werden auch aufzeigen, wie sie das getan haben.$B$BIhr habt das Richtige getan, indem Ihr dies zu mir brachtet. Bitte, nehmt dies zusammen mit den wärmsten Empfehlungen des Irdenen Rings.', 0), +(6943, 'deDE', 'Seht Ihr es? Schaut sie Euch an! Sie rappeln sich wieder auf... Bald wird Ichmans Klan erneut im Herzen des Tales zuschlagen! Sturmlanze wird den Himmel beherrschen!', 0), +(6983, 'deDE', 'Ihr habt es gefunden! Ihr habt das Winterhauchfest für Kokelwälder gerettet!$B$BArmer Sacks... wir werden ein Team rausschicken und uns eine Möglichkeit überlegen, wie wir ihn wieder auftauen. Hoffentlich ist er rechtzeitig zum Festtag zurück. Allerdings muss er noch die ganze Arbeit aufholen, die inzwischen liegen geblieben ist. Aber ohne Euch wäre auch das nicht möglich!', 0), +(6985, 'deDE', 'Ihr habt Sie! Gute Arbeit, $N! Hoffentlich habt Ihr unterwegs noch ein paar Zwerge getroffen und ihr Blut im Namen der Frostwölfe vergossen!', 0), +(7142, 'deDE', 'Gute Arbeit, $N! Die Sturmlanzen haben ihre närrische Invasion bereits verloren.$B$BHah! Das Einzige was sie bisher erreicht haben, ist ihr toter General!', 0), +(7162, 'deDE', 'Nehmt dieses Abzeichen und tragt es mit Stolz, $N. Mit der Zeit werdet Ihr in den Rängen der Sturmlanzengarde aufsteigen. Kehrt dann zu mir zurück und ich werde Euer Abzeichen gegen andere, ranghöhere Abzeichen eintauschen.$B$BVielleicht werdet Ihr eines Tages zu einer Legende dieses Schlachtfeldes heranwachsen. Sollte dieser Tag jemals kommen, wird man Euch mit Sicherheit das Auge der Führung verleihen.', 0), +(7165, 'deDE', '$B$BSie haben schon angefangen, Geschichten über Eure Taten zu erzählen, Soldat. Die Sturmlanzen zittern vor Angst, wenn man euren Namen ausspricht. Weiter so!', 0), +(7168, 'deDE', 'Lasst unsere Feinde sehen, dass ein angesehener Soldat sie besiegt hat! Kämpft für den Ruhm der Sturmlanzen!', 0), +(7169, 'deDE', 'Der König hat von Euren Heldentaten an der Frontlinie gehört, $C. Macht weiter so in Eurer wackeren Verteidigung der Sturmlanzengarde!', 0), +(7383, 'deDE', 'In der Nähe des Orakelbaums... kann man fast spüren, wie die Weisheit Gestalt annimmt. Lasst mich mit der Geschichte fortfahren...$B$BTeldrassil wuchs und gedieh, und der Erzdruide wandte sich an die Großdrachen, um deren Segen zu erhalten, den sie in längst vergangenen Zeiten über Nordrassil verbreitet hatten. Nozdormu jedoch, der Lord der Zeit, weigerte sich, seinen Segen zu spenden und tadelte den Druiden wegen seiner Arroganz. Einig mit Nozdormu widersetzte sich auch Alexstrasza Hirschhaupt und ohne ihren Segen entartete Teldrassil und wuchs auf unvorhersehbare Weise...', 0), +(7627, 'deDE', 'Wie ich sehe, habt Ihr alles! Ich hörte, dass Dunkeleisenerz nur in den Schwarzfelstiefen zu finden ist, und ich bin mir sicher, dass es nicht viel einfacher war, an diese Splitter zu gelangen. Die Hingabe, mit der ihr $C Eurer Tätigkeit nachgeht, beeindruckt mich immer wieder. Ihr solltet Eure Energien lieber in die Kunst des Käferfangens investieren, oh... einen solchen Schmaus würdet Ihr lieben!$B$BEntschuldigt, ich schweife vom Thema ab. Ich werde das Rad jetzt herstellen und es aufbewahren, bis Ihr für das Ritual bereit seid.', 0), +(7641, 'deDE', 'Hallo da, Kumpel - Lord Schattenbruch hat mich von Eurer Ankuft informiert und das Ihr mich sehen wollt. Ich werde Euch das Pferdegeschirr anfertigen. Aber um eines klarzustellen, es wird weder einfach noch billig sein.$B$BIch werde nur das eine sagen, und Grayson wird mir zustimmen... Nirgendwo in ganz Azeroth werdet Ihr ein besseres Pferdegeschirr finden, als hier.', 0), +(7725, 'deDE', 'Einfach fantastisch, $N! Wieder einmal habt Ihr mir einen großen Gefallen getan und dafür danke ich Euch.$B$BVielen Dank!$B$BDiese Belohnung mag vielleicht ein wenig kleiner ausgefallen sein, als Ihr es vielleicht gewohnt seid, aber seid Euch sicher, dass Eure großen Taten im Namen der Goblins, überall in den großen Hallen des Dampfdruckkartells wiederhallen. Solltet Ihr mal wieder Arbeit suchen, dann um der Götter Willen, redet mit mir!', 0), +(7726, 'deDE', 'Erstklassik, $N, erstklassik! Diese Belohnung mag vielleicht nicht die wertvollste sein, die Ihr je erhalten habt. Stattdessen seid Euch sicher, dass meine Kameraden im Dampfdruckkartell von Euren Bemühungen erfahren werden!$B$BLasst es mich wissen, wenn Ihr mal wieder nach Arbeit sucht. Ich kann immer einige weitere Elementarkerne gebrauchen.', 0), +(8041, 'deDE', 'Seid gegrüßt, $C. Ich bin Jin\'rokh der Zerstörer, Troll von Mugamba. Wir vom Stamm der Zandalari erkennen Eure Leistungen an. Wir begrüßen Eure Hartnäckigkeit und Willenskraft.$B$BTragt diesen Talisman um Euren Hals, $C. Lasst die Stärke des Bergs Mugamba durch Euch hindurch fließen. Fühlt die Macht, wenn Ihr unsere Feinde niederstreckt!', 0), +(8042, 'deDE', 'Unsere Wege werden sich erneut kreuzen, $C.', 0), +(8043, 'deDE', 'Nutzt Eure wiedererlangte Stärke, um die Gurubashi zu vernichten!', 0), +(8044, 'deDE', 'Zul\'jin würde Euch beneiden, $C. Zieht hinfort und siegt!', 0), +(8045, 'deDE', 'Wisset, Ungläubiger: eine Katastrophe hat uns vereint. Eure heidnischen Wege werden von den Zandalari weder verstanden, noch geschätzt, aber wir sind ein faires Volk. Tragt dieses Emblem um Euren Hals. Es soll unseren Feinden als Warnung und den Zandalari als Zeichen der Freundschaft dienen.$B$BDient auch weiterhin unserem Stamm und ich werde die Macht des Emblems verstärken.', 0), +(8046, 'deDE', 'Tut, was Ihr tun müsst, um unsere Feinde zu vernichten, $C. Selbst wenn Ihr dafür das Licht kanalisieren müsst.', 0), +(8047, 'deDE', 'Unsere Überzeugungen unterscheiden sich zwar, aber unsere Gründe sind gerechtfertigt. Bezwingt unsere Feinde, $Gedler:edle; $C.', 0), +(8048, 'deDE', 'Wachsamkeit, Ehre, Treue, Mut... Ihr verkörpert alle diese Eigenschaften und so soll es auch Euer Emblem tun.', 0), +(8049, 'deDE', 'Nehmt diesen Talisman als Zeichen unserer Wertschätzung an, $C.$B$BDas Auge von Zuldazar wird umso mächtiger, je stärker Euer Bund mit den Trollen von Zandalar wird. Kommt von Zeit zu Zeit zu mir zurück und ich werde das Juwel mit Macht erfüllen.', 0), +(8050, 'deDE', 'Führt Euren Kampf gegen den Seelenschinder und seine Diener fort, $N. Er darf die Grenzen Zul\'Gurubs niemals überschreiten.', 0), +(8051, 'deDE', 'Geht entschlossen bei Euren Bestrebungen vor, $N. Der Seelenschinder wird versuchen Euch Euren Lebenswillen zu entziehen.', 0), +(8052, 'deDE', 'Tötet sie alle und überlasst Hakkar das Aufräumen...', 0), +(8058, 'deDE', 'Ihr habt heute ausreichend Rache walten lassen. Ihr habt das Antlitz des Vollstreckers angenommen und die Diener des Blutgottes in die Knie gezwungen.$B$BNehmt dies. Eure Rache wird damit für die Zukunft geschürt. Ihr seid nun ein Freund der Zandalari.', 0), +(8061, 'deDE', 'Hervorragend, $N! Diese Aufgabe war nicht gerade eine Kleinigkeit. Es besteht kein Zweifel daran, dass Ihr heute wie einer unserer Glaubenshüter gehandelt habt und uns somit vor der Bedrohung Hakkars beschützt habt. Diese Handlappen sind für einen Freund des Stammes, so wie Ihr einer seid, nur angemessen!', 0), +(8063, 'deDE', 'Sehr schön, $N... mit Euren Leistungen in Zul\'Gurub habt Ihr Euch das Recht verdient, den Stamm der Zandalari Euren Freund nennen zu dürfen. Ich werde mich um die Symbole kümmern; nehmt diese Belohnung bitte als Dank für Eure Bemühungen an!', 0), +(8065, 'deDE', 'Beeindruckend... Ihr habt das erforderliche Symbol der Macht erfolgreich beschafft, $N. Eure vollbrachten Taten in Zul\'Gurub im Namen der Zandalari sind sagenhaft; von nun an werdet Ihr in unserem Stamm angesehen werden. Hier ist Eure Tunika, $Gmächtiger:mächtige; $C!', 0), +(8066, 'deDE', 'Ich habe Euer Kommen bereits gespürt, $N, wenn auch beschwerlich. Was Euch verraten hat, war das Symbol der Macht, welches Ihr bei Euch tragt. Ich muss es nicht einmal sehen, ich kann seine Macht spüren; das in ihm ruhende Mojo - rohe Magie, könnte man sagen - schürt auch weiterhin unser Streben nach Vereitelung der teuflischen Pläne des Blugottes Hakkar an.$B$BMan kann Euch weiterempfehlen, und für Euren Erfolg belohnen. Im Stamm sieht man Euch mit Wohlwollen entgegen, ebenso verdient Ihr es, den Gürtel des Zandalariraubtiers zu tragen.', 0), +(8067, 'deDE', 'Erfolg... Ihr werdet vom Stamm respektiert werden, $N. Die Beschaffung des Symbols der Macht, welches für den Mantel von Nöten ist, war eine waghalsige Leistung, die Ihr auf tödlichste Art und Weise unserer Jäger gemeistert habt. Ihr habt Euch Euren Platz unter ihresgleichen verdient und sicherlich auch das Recht, ihren Mantel tragen zu dürfen.', 0), +(8069, 'deDE', 'Wenigstens jemand, der würdig ist die Robe des Illusionisten zu tragen! Euer Erfolg in Zul\'Gurub hat Euch für alle Zeit Respekt von unserem Stamm eingebracht. Tragt sie mit Stolz, $N!', 0), +(8070, 'deDE', 'Erfolg! Es wird noch eine Zeit brauchen, um Macht gegen die Auferstehung Hakkars aufzubauen. Mit Eurer Hilfe konnten wir einen ausschlaggebenden Schritt vorangehen und somit sicherstellen, dass der Blutgott uns nicht alle zerstören wird.$B$BIhr habt Euch heute das Wohlwollen unseres Stammes verdient, $N. Nehmt dies hier, die Bindungen des Zandalariglaubenshüters, als Zeichen unseres Dankes.', 0), +(8071, 'deDE', 'Gut gemacht, $N - die Diener Hakkars haben heute dank Euch zweifellos die Vergeltung der Zandalari zu spüren bekommen. Eure Taten haben Euch auf Dauer zu Respekt in unserem Stamm verholfen. Ihr habt unseren Segen, betrachtet den Mantel des Zandalariglaubenshüters bitte als den Eurigen!', 0), +(8072, 'deDE', 'Heute ist der Sieg auf unserer Seite, dank des Wahnsinns, den Ihr über unsere gemeinsamen Feinde habt hereinbrechen lassen! Das Wohlwollen der Zandalari ist Euch sicher und wir könnten unserem Dank für Eure Taten nicht besser Ausdruck verleihen, als wenn wir Euch den Mantel des Zandalariwildfangs überreichen würden!', 0), +(8073, 'deDE', 'Beeindruckend... Ihr habt heute vollbracht, was kaum für möglich gehalten wurde. Ihr könnt Euch dem Respekt unseres Stammes auf Lebenszeit sicher sein, $N. Nehmt die Tunika des Zandalariwildfangs entgegen, Ihr habt sie Euch verdient. Ihr habt unseren Segen.', 0), +(8074, 'deDE', 'Ich kann den Sieg über das Böse wittern, $N. Es ist ein süßer Duft... einer, der Euch sicherlich vertraut ist.$B$BIch weiß, dass die Beschaffung des Symbols, das für den Gürtel benötigt wird, nicht gerade einfach war. Eure Taten haben nicht nur unseren Stamm, sondern auch Euch selbst zu Ehren gebracht. Hier - nehmt den Gürtel des Zandalariweissagers und macht weiter so!', 0), +(8075, 'deDE', 'Ich weiß, was Ihr durchgemacht habt, um mir das Symbol der Macht zu beschaffen, $N. Es war nicht einfach das Böse zu bezwingen, das aus Zul\'Gurub wie fauler Schlick sickert, ja - jetzt, nachdem alles gesagt und getan ist, kann ich Euch jedoch als im Stamm der Zandalari respektiert bezeichnen - und das für Lebzeiten!$B$BHier - nehmt die Halsberge des Zandalariweissagers und tragt sie mit Stolz!', 0), +(8076, 'deDE', 'Gut gemacht, $N. Die Symbole der Macht von Zul\'Gurub sollten als Beweis für verschwendete Macht dienen. Die Gurubashi waren zu ihren Hochzeiten stark, aber sie gestatteten sich selbst davon aufgezehrt zu werden. Der Besessene weiß, dass die Spiele, die von ihm gespielt werden, ähnlich sind, jedoch ist die Macht, die dabei freigegeben wird, oft das Ausschlaggebende zum Überleben.$B$BVerwendet diesen Mantel als jemand, der von den Zandalari mit Wohlwollen als Verbündeter betrachtet wird... er wird Euch noch nützlich sein.', 0), +(8077, 'deDE', 'Beeindruckend - Euer Sieg in Zul\'Gurub hat uns bewiesen - ach, was sage ich denn da, der ganzen Welt - dass Hakkar sich nicht durchsetzen wird. Die Zeit, in der Ihr dem Blutgott direkt gegenüberstehen werdet, wird noch kommen... sollte es soweit sein, dann wisst, dass Euch der Respekt der Zandalari sicher ist.$B$BOh, ich denke Euch wird auch diese einfache Robe behilflich sein.$B$B', 0), +(8101, 'deDE', '$R, der Stein, der von diesem Talisman umrahmt wird, kommt vom Berg Kajaro in den südlichen Meeren. Das Gebiet rund um den Berg Kajaro wird von Unbeständigkeit geplagt; insbesondere durch heftige und oft auch magische Vulkanausbrüche.$B$BJe stärker Euer Bund mit den Trollen Zandalars wird, umso mächtiger wird dieser Stein. Nutzt die Macht des Steins, um unsere Feinde zu vernichten. Seid wie der Berg: schnell, explosiv, tödlich...', 0), +(8102, 'deDE', 'Seid unaufhaltsam, wie die geschmolzenen Wogen des Kajaro.', 0), +(8103, 'deDE', 'Führt Eure Vernichtung der Trolle von Zul\'Gurub noch weiter fort. Hakkar muss erkennen, dass die Welt sich nicht seinem unbezwingbaren Willen beugt.', 0), +(8104, 'deDE', '$B$BSeht Ihr? Der Stein ist das, was wir eine kristallgefüllte Hohlkugel nennen. In ihm befinden sich mächtige Kristalle, die mit den latenten Energien dieser Welt getränkt sind. Indem ich das Juwel entzwei schnitt, ließ ich ihn endlich sein wahres Potential entfalten. Nutzt ihn, um Vernichtung über unsere Feinde zu bringen.', 0), +(8105, 'deDE', '$N, Ich erhielt Kunde von Euren Heldentaten im Arathibecken. Hervorragende Arbeit! Wenn sich noch mehr Freiwillige als ebenso fähig erweisen wie Ihr, bin ich zuversichtlich, dass wir eines Tages unsere Heimat zurückerobern werden.', 0), +(8106, 'deDE', 'Bitte nehmt diesen Talisman, $C. Nutzt seine Macht, um unsere gemeinsamen Feinde niederzuschmettern.$B$BSeid Euch bewusst, dass Ihr ein Stück Geschichte um Euren Hals tragt. Kezan war einst ein großes Territorium des Imperiums von Zandalar. Doch im Laufe der Zeit zwang der schändliche Einfluss der Goblin-Handelsfürsten meine stolzen Brüder und Schwestern, Kezan den Rücken zu kehren.$B$BKezan beherbergt jetzt Lorenhall, die Hauptstadt der Goblins; doch wisset, dass sie einst wahre Größe ausstrahlte. Noch heute gilt Kezan meinem Volk als heiliges Land.', 0), +(8107, 'deDE', 'Der Dunkelheit entsprungen, $C. Begrüßt den Schatten. Lasst Kezans Schmach Eure dunkle Einmischung ergänzen.', 0), +(8108, 'deDE', 'Wir werden den Seelenschinder nur mit vereinten Kräften aufhalten können.', 0), +(8109, 'deDE', 'Reißt das Fleisch von ihren Körpern. Beobachtet, wie die Schatten die Hakkari verzehren. Zieht Macht aus ihrer Furcht, $C. Lasst Kezans Schmach mächtiger werden...', 0), +(8110, 'deDE', 'Unglaublich! Ihr habt sie gefunden! Ihr seid ein wahrer Held, $N!$B$BDas ist eine gute Sache, denn ich habe die Schrifttafeln gelesen, die Ihr mir zuvor gebracht habt, und nach dem, was ich herausgefunden habe... tja, da werden wir wohl einen Helden brauchen, der aufhält, was kommt...', 0), +(8111, 'deDE', 'Hey, der Halsschmuck ist nicht zum Rauchen gedacht! Ihr müsst ihn im Kampf gegen das Böse einsetzen.', 0), +(8112, 'deDE', 'Jetzt nehmt Ihr Euch die bösen Trolle in Zul\'Gurub vor und zeigt ihnen, was Eure Naturkräfte so alles können!', 0), +(8113, 'deDE', '$N, Mann, es war eine gute Reise. Fahrt fort Hakkar und seine Diener zu töten und zu unterdrücken.', 0), +(8116, 'deDE', 'Ihr und Maywiki haben etwas gemeinsam. Wir sind beide Schamanen! Auch wenn Maywiki eher geheimnisvoll ist und Ihr vielmehr grob daher kommt. Trotzdem, wir wissen beide von der Macht der Geister.$B$BIch gebe Euch diese Kugel als Geschenk, tragt sie um den Hals. Schaut tief in sie hinein und seht die Stadt von Voodress in den südlichen Meeren! Lasst sie Eure Geister beflügeln!', 0), +(8117, 'deDE', 'Seht sie Euch jetzt an, $N. Noch mehr sichtbare Voodress, oder? Lasst die urzeitliche Macht durch Euch fließen.', 0), +(8118, 'deDE', 'Hütet Euch vor den bösen Geistern der Hakkari. Sie sind wirklich unheimlich.', 0), +(8119, 'deDE', 'Eines Tages, $N, werdet Ihr diese Kugel nutzen können, um direkt mit mir zu kommunizieren. Wann auch immer der Kampf gegen Hakkar vorüber sein wird und Maywiki nach Hause zurückkehrt. Lasst uns die Geister anrufen und darum bitten, dass dieser Tag bald sein wird.', 0), +(8141, 'deDE', 'Ihr macht rasch Fortschritte, $C. Vielleicht ist es an der Zeit Euch in Shera Ali\'kh einzuweihen - zandalarianisch für die Hand des Todes. Tausende von Jahren übernahmen wir die Rolle der Meuchelmörder für das Imperium der Zandalari. Zu lange saßen wir untätig herum und erlaubten es den Hakkari an Macht zu gewinnen. Noch einmal stehen wir Hakkar gegenüber, aber diesmal ohne die Unterstützung einer vereinten Trollfront. Ihr und Eure Verbündeten müssen uns dabei helfen den Blutgott und seine Diener zu vernichten!$B$BTragt diesen Talisman und lasst ihn Euch bei Euren Taten unterstützen.', 0), +(8142, 'deDE', 'Einem Meuchelmörder von Eurem Kaliber sollte man besser aus dem Weg gehen. Eure Feinde müssen Euch zu respektieren lernen! Ihr werdet genau das bekommen, sobald der Feind die Hand des Todes wahrnimmt... zu spät...', 0), +(8143, 'deDE', 'Es gibt nur noch eine weitere Verstärkung für den Talisman, $C. Wenn die Zeit dafür gekommen ist, werde ich auch diese anwenden.', 0), +(8144, 'deDE', 'Dies ist das letzte Mal, dass wir unter der Schirmherrschaft von Shera Ali\'kh miteinander sprechen. Ihr wisst alles, was Ihr wissen müsst. Nehmt den Talisman und setzt Eurer Schlachten fort. Hakkar darf Zul\'Gurub niemals verlassen.', 0), +(8145, 'deDE', 'Unter den Zandalari wird der Stand des Jägers hoch verehrt. Die mächtigsten unserer Jäger reisen bis an den Rand des Maelstroms, um ihre Entschlossenheit unter Beweis zu stellen.$B$BAus dem tiefsten Herzen der See, ernten sie eine seltene Seetangart, die Maelstromranke. Die Seetangstränge werden in einen Talisman gewoben, welcher anschließend verzaubert wird, um die Treffsicherheit und Macht des Trägers zu verstärken.$B$BIch werde Euch jetzt die erste Maelstromranke in einen Talisman einweben. Wenn Euer Bund mit den Zandalari stärker wird, werde ich Euch mehr Ranken in den Talisman weben und so dessen Macht verstärken.', 0), +(8146, 'deDE', 'Mögen Sie am spitzen Ende Eurer Klinge Sühne finden.', 0), +(8147, 'deDE', 'Es kann nur noch eine weitere Ranke in Euren Talisman gewoben werden, $C.', 0), +(8148, 'deDE', 'Eure Reise hat gerade erst begonnen, $Gjunger:junge; $C. Vielleicht werdet Ihr eines Tages selbst den Maelstrom besuchen und in das Herz der Welt blicken.$B$BIch wünsche Euch innere Stärke und Tapferkeit, $Gmein Freund:meine Freundin;!', 0), +(8187, 'deDE', 'Nutzt es weise, $C. Zeigt keine Gnade mit den Hakkari!', 0), +(8188, 'deDE', 'Nutzt es weise, $C. Zeigt keine Gnade mit den Hakkari!', 0), +(8860, 'deDE', 'Oh, meine Vorräte von Kokelwälder! Großartig! Die brauche ich dringend, um all die hungrigen Mäuler während der Feierlichkeiten zu stopfen!$B$BVielen Dank für Eure Hilfe, $N. Bitte, nehmt dies als Belohnung an und vergesst nicht mit den anderen draußen zu trinken und zu tanzen!', 0), +(11451, 'deDE', 'Was für ein anrührendes Gedicht. Habt vielen Dank!', 0); From 07b458afdac567d5d477905a082889fc4abe51d0 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 11:06:16 +0000 Subject: [PATCH 28/87] chore(DB): import pending files Referenced commit(s): 26b6cedaf7e689e9d7093c0b03b30a2d563f7af5 --- .../deDE-locale-fix-01-reward.sql => db_world/2023_02_11_03.sql} | 1 + .../rev_1675207681546911800.sql => db_world/2023_02_11_04.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/deDE-locale-fix-01-reward.sql => db_world/2023_02_11_03.sql} (99%) rename data/sql/updates/{pending_db_world/rev_1675207681546911800.sql => db_world/2023_02_11_04.sql} (96%) diff --git a/data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql b/data/sql/updates/db_world/2023_02_11_03.sql similarity index 99% rename from data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql rename to data/sql/updates/db_world/2023_02_11_03.sql index f31b0f770..020615064 100644 --- a/data/sql/updates/pending_db_world/deDE-locale-fix-01-reward.sql +++ b/data/sql/updates/db_world/2023_02_11_03.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_02 -> 2023_02_11_03 DELETE FROM `quest_offer_reward_locale` WHERE `ID` IN (53, 82, 162, 184, 216, 218, 219, 235, 348, 452, 522, 599, 601, 603, 622, 629, 646, 655, 662, 742, 755, 758, 763, 792, 793, 794, 805, 826, 827, 832, 858, 863, 892, 906, 910, 911, 929, 933, 935, 944, 950, 952, 1000, 1004, 1015, 1016, 1018, 1019, 1046, 1047, 1069, 1096, 1106, 1115, 1119, 1133, 1145, 1180, 1433, 1483, 1488, 1499, 1501, 1642, 1644, 1681, 1780, 1781, 1786, 1788, 1842, 2864, 2867, 2869, 2870, 2872, 2874, 2939, 2996, 3001, 3109, 3110, 3117, 3119, 3130, 3764, 3787, 3788, 3791, 3792, 3906, 3907, 3924, 4122, 4125, 4131, 4281, 4508, 4581, 4731, 4734, 4769, 4867, 4974, 4981, 4983, 5002, 5088, 5154, 5168, 5181, 5206, 5210, 5211, 5237, 5241, 5405, 5503, 5538, 5730, 5941, 6023, 6028, 6029, 6121, 6126, 6130, 6185, 6382, 6388, 6391, 6392, 6541, 6542, 6543, 6565, 6761, 6801, 6821, 6921, 6922, 6943, 6983, 6985, 7142, 7162, 7165, 7168, 7169, 7383, 7627, 7641, 7725, 7726, 8041, 8042, 8043, 8044, 8045, 8046, 8047, 8048, 8049, 8050, 8051, 8052, 8058, 8061, 8063, 8065, 8066, 8067, 8069, 8070, 8071, 8072, 8073, 8074, 8075, 8076, 8077, 8101, 8102, 8103, 8104, 8105, 8106, 8107, 8108, 8109, 8110, 8111, 8112, 8113, 8116, 8117, 8118, 8119, 8141, 8142, 8143, 8144, 8145, 8146, 8147, 8148, 8187, 8188, 8860, 11451) AND `locale` = 'deDE'; INSERT INTO `quest_offer_reward_locale` (`ID`, `locale`, `RewardText`, `VerifiedBuild`) VALUES (53, 'deDE', 'Im Fasse gealtert, gefiltert durch Kohle,$BRinnt er durch die Kehle zu jedermanns Wohle.$BSo lasset uns trinken und prosten mit dem Gebräu.$BAuf Euch und auf mich, Schnapsbart Donnerbräu!', 0), diff --git a/data/sql/updates/pending_db_world/rev_1675207681546911800.sql b/data/sql/updates/db_world/2023_02_11_04.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1675207681546911800.sql rename to data/sql/updates/db_world/2023_02_11_04.sql index de3137a2a..05ec73e7a 100644 --- a/data/sql/updates/pending_db_world/rev_1675207681546911800.sql +++ b/data/sql/updates/db_world/2023_02_11_04.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_03 -> 2023_02_11_04 -- DELETE FROM `creature_text` WHERE `CreatureID` = 18881; From f496535cc8346da29b0ebc4c5ff3c8c08769c54f Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 16:06:17 +0100 Subject: [PATCH 29/87] fix(Core/AI): Fixed mobs attacking in defensive state. (#14947) --- src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp | 2 +- src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp | 2 +- src/server/game/AI/SmartScripts/SmartAI.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp index 584f5515c..fc8212b0c 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp @@ -141,7 +141,7 @@ void npc_escortAI::MoveInLineOfSight(Unit* who) if (HasEscortState(STATE_ESCORT_ESCORTING) && AssistPlayerInCombatAgainst(who)) return; - if (me->CanStartAttack(who)) + if (me->HasReactState(REACT_AGGRESSIVE) && me->CanStartAttack(who)) { if (me->HasUnitState(UNIT_STATE_DISTRACTED)) { diff --git a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp index 5930e0fb4..c53a0e6f1 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp @@ -99,7 +99,7 @@ void FollowerAI::MoveInLineOfSight(Unit* who) if (HasFollowState(STATE_FOLLOW_INPROGRESS) && AssistPlayerInCombatAgainst(who)) return; - if (me->CanStartAttack(who)) + if (me->HasReactState(REACT_AGGRESSIVE) && me->CanStartAttack(who)) { if (me->HasUnitState(UNIT_STATE_DISTRACTED)) { diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp index bbbc57b56..05d311de6 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.cpp +++ b/src/server/game/AI/SmartScripts/SmartAI.cpp @@ -704,7 +704,7 @@ void SmartAI::MoveInLineOfSight(Unit* who) if (me->HasReactState(REACT_PASSIVE) || AssistPlayerInCombatAgainst(who)) return; - if (me->CanStartAttack(who)) + if (me->HasReactState(REACT_AGGRESSIVE) && me->CanStartAttack(who)) { if (me->HasUnitState(UNIT_STATE_DISTRACTED)) { From 102f7680a2d2d11d2eea414b7e8a70a51e079cc6 Mon Sep 17 00:00:00 2001 From: Gultask <100873791+Gultask@users.noreply.github.com> Date: Sat, 11 Feb 2023 14:02:17 -0300 Subject: [PATCH 30/87] fix(DB/TheBotanica): Re-Construct The Botanica (#14932) --- .../rev_1675895905789106400.sql | 1438 +++++++++++++++++ 1 file changed, 1438 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675895905789106400.sql diff --git a/data/sql/updates/pending_db_world/rev_1675895905789106400.sql b/data/sql/updates/pending_db_world/rev_1675895905789106400.sql new file mode 100644 index 000000000..2b824e68d --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675895905789106400.sql @@ -0,0 +1,1438 @@ +-- Cleanup +DELETE FROM `creature` WHERE `id1` IN (17975,17976,17977,17978,17980,17993,17994,18155,18404,18405,18419,18420,18421,18422,18587,18721,19486,19505,19507,19508,19509,19511,19512,19513,19557,19598,19608,19633,19843,19865) AND `map`=553 AND `guid` IN (40252,82977,82978,82979,82980,82981,82982,82983,82984,82985,82986,82987,82988,82989,82990,82991,82992,82993,82994,82995,82996,82997,82998,82999,83000,83001,83002,83003,83004,83005,83006,83007,83008,83009,83010,83011,83012,83013,83014,83015,83016,83017,83018,83019,83020,83021,83024,83025,83028,83029,83030,83031,83032,83033,83034,83035,83036,83037,83038,83039,83040,83041,83042,83043,83044,83045,83046,83047,83048,83049,83050,83051,83052,83053,83054,83055,83056,83057,83058,83059,83060,83061,83062,83063,83064,83065,83066,83067,83068,83069,83070,83071,83072,83073,83074,83075,83076,83077,83078,83079,83080,83081,83082,83083,83084,83085,83086,83087,83088,83089,83090,83091,83092,83093,83094,83095,83096,83097,83098,83099,83100,83101,83102,83103,83104,83105,83106,83107,83108,83109,83110,83111,83112,83113,83114,83115,83116,83117,83118,83119,83120,83121,83122,83123,83124,83125,83126,83127,83128,83129,83130,83131,83132,83133,83134,83135,83136,83137,83138,83139,83140,83141,83142,83143,83144,83145,83146,83147,83148,83149,83150,83151,83152,83153,83154,83155,83156,83157,83158,83159,1971524,1971525,1971526,1971527,1971528,1971529,1971530,1971531,1971532,1971533,1971534,1971535,1971536,1971537,1971538,1971539,1971540,1971541); +DELETE FROM `creature_addon` WHERE `guid` IN (40252,82977,82978,82979,82980,82981,82982,82983,82984,82985,82986,82987,82988,82989,82990,82991,82992,82993,82994,82995,82996,82997,82998,82999,83000,83001,83002,83003,83004,83005,83006,83007,83008,83009,83010,83011,83012,83013,83014,83015,83016,83017,83018,83019,83020,83021,83024,83025,83028,83029,83030,83031,83032,83033,83034,83035,83036,83037,83038,83039,83040,83041,83042,83043,83044,83045,83046,83047,83048,83049,83050,83051,83052,83053,83054,83055,83056,83057,83058,83059,83060,83061,83062,83063,83064,83065,83066,83067,83068,83069,83070,83071,83072,83073,83074,83075,83076,83077,83078,83079,83080,83081,83082,83083,83084,83085,83086,83087,83088,83089,83090,83091,83092,83093,83094,83095,83096,83097,83098,83099,83100,83101,83102,83103,83104,83105,83106,83107,83108,83109,83110,83111,83112,83113,83114,83115,83116,83117,83118,83119,83120,83121,83122,83123,83124,83125,83126,83127,83128,83129,83130,83131,83132,83133,83134,83135,83136,83137,83138,83139,83140,83141,83142,83143,83144,83145,83146,83147,83148,83149,83150,83151,83152,83153,83154,83155,83156,83157,83158,83159,1971524,1971525,1971526,1971527,1971528,1971529,1971530,1971531,1971532,1971533,1971534,1971535,1971536,1971537,1971538,1971539,1971540,1971541); +-- Delete now unused script +DELETE FROM `waypoint_scripts` WHERE `id`=49 AND `guid`=68; +-- Delete old waypoints +DELETE FROM `waypoint_data` WHERE `id` IN (402520,829770,829810,829830,829860,829870,829920,829930,829940,830030,830070,830080,830090,830100,830170,830300,830520,830720,830730,830860,830870,831570); +-- Delete guid SAI +DELETE FROM `smart_scripts` WHERE `source_type` = 0 AND `entryorguid` IN (-83035, -83056, -83066, -83067); +-- Delete linked_respawn +DELETE FROM `linked_respawn` WHERE `linkedguid` IN (82986,83076,82987,82989,82990) AND `guid` IN (82977,82978,82979,82980,82981,82982,82983,82984,82985,82988,82991,82992,82993,82994,82995,82996,82997,82998,82999,83000,83001,83002,83003,83004,83005,83006,83007,83008,83009,83010,83011,83012,83013,83014,83015,83016,83017,83018,83019,83020,83021,83024,83025,83028,83029,83030,83031,83032,83033,83034,83035,83036,83037,83038,83039,83040,83041,83042,83043,83044,83045,83046,83047,83048,83049,83050,83051,83052,83053,83054,83055,83056,83057,83058,83059,83060,83061,83062,83063,83064,83065,83066,83067,83068,83069,83070,83071,83072,83073,83074,83075,83077,83078,83079,83080,83081,83082,83083,83084,83085,83086,83087,83088,83089,83090,83091,83092,83093,83094,83095,83096,83097,83098,83099,83100,83101,83102,83103,83104,83105,83106,83107,83108,83109,83110,83111,83112,83113,83114,83115,83116,83117,83118,83119,83120,83121,83122,83123,83124,83125,83126,83127,83128,83129,83130,83131,83132,83133,83134,83135,83136,83137,83138,83139,83140,83141,83142,83143,83144,83145,83146,83147,83148,83149,83150,83151,83152,83153,83154,83155,83156,83157,83158,83159); +-- Delete old condition +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceGroup`=1 AND `SourceEntry`=34156 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=31 AND `ConditionTarget`=0 AND `ConditionValue1`=3 AND `ConditionValue2`=18721 AND `ConditionValue3`=0; + +-- Adds all creatures +SET @CGUID := 147000; + +DELETE FROM `creature` WHERE `map`=553 AND `id1` IN (17975,17976,17977,17978,17980,17993,17994,18155,18404,18405,18419,18420,18421,18422,18587,19486,19505,19507,19508,19509,19511,19512,19513,19555,19557,19598,19608,19633,19843,19865) AND `guid` BETWEEN @CGUID+0 AND @CGUID+187; +INSERT INTO `creature` (`guid`, `id1`, `id2`, `id3`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `MovementType`, `curhealth`, `curmana`, `currentwaypoint`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`) VALUES +(@CGUID+0 , 17975, 0, 0, 553, 3847, 3847, 3, 1, 0, 116.326, 455.57, -4.9414, 3.38594, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+1 , 17976, 0, 0, 553, 3847, 3847, 3, 1, 1, 149.329, 297.64, -4.45642, 2.35736, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+2 , 17977, 0, 0, 553, 3847, 3847, 3, 1, 0, 63.8407, 391.882, -27.8938, 3.21141, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+3 , 17978, 0, 0, 553, 3847, 3847, 3, 1, 0, 4.9486, 596.578, -15.0783, 4.69494, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+4 , 17980, 0, 0, 553, 3847, 3847, 3, 1, 0, -204.125, 391.249, -11.1943, 0.0174533, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+5 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 75.0124, 283.882, -5.39203, 1.76278, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+6 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 32.7476, 292.832, -5.56217, 5.32325, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+7 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 75.302, 292.336, -5.38124, 4.95674, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+8 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 151.661, 281.789, -4.33475, 1.8326, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+9 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 153.757, 281.744, -4.0086, 1.8326, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+10 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 161.403, 285.599, -3.09818, 2.68781, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+11 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 163.108, 287.899, -3.3132, 2.23402, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+12 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 164.969, 292.952, -4.00805, 2.84489, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+13 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 165.165, 295.535, -4.37166, 3.15905, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+14 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -161.206, 391.88, -17.6449, 1.95477, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+15 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -166.664, 391.763, -17.6139, 1.32645, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+16 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -157.669, 471.719, -17.7416, 1.76278, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+17 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -164.989, 473.034, -17.7416, 1.5708, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+18 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 32.3466, 283.21, -5.56045, 1.8326, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+19 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 2.69318, 59.1548, -5.60355, 3.14169, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+20 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 6.78807, 151.432, -5.45704, 5.51524, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+21 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -6.33425, 59.407, -5.55881, 0.030197, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+22 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 8.47522, 99.6128, -5.55404, 2.61651, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+23 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -8.16851, 101.299, -5.53842, 0.524085, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+24 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -8.37349, 150.827, -5.45702, 0.191986, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +-- (@CGUID+25 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 6.90713, 230.813, -5.45704, 3.45575, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +-- (@CGUID+26 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -8.30962, 231.934, -5.45701, 0.349066, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+25 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, 6.880586, 213.50626, -5.5403757, 4.729842185974121093, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+26 , 17993, 0, 0, 553, 3847, 3847, 3, 1, 1, -7.061299, 213.17163, -5.54035, 4.729842185974121093, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+27 , 17994, 0, 0, 553, 3847, 3847, 3, 1, 1, -35.5817, 287.674, -1.76399, 5.65487, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+28 , 17994, 0, 0, 553, 3847, 3847, 3, 1, 1, 102.214, 287.182, -6.71081, 5.04669, 86400, 2, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+29 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, -27.6921, 289.047, -1.84732, 3.65739, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+30 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, 100.543, 280.201, -6.79088, 2.39325, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+31 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, -36.5632, 293.421, -1.76399, 4.00287, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+32 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, 109.553, 279.506, -6.83397, 4.41568, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+33 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, 99.7353, 294.242, -6.62196, 4.53898, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+34 , 18155, 0, 0, 553, 3847, 3847, 3, 1, 0, -37.1861, 282.761, -1.84732, 2.96967, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+35 , 18404, 0, 0, 553, 3847, 3847, 3, 1, 1, 76.7734, 282.637, -5.33021, 1.81514, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+36 , 18404, 0, 0, 553, 3847, 3847, 3, 1, 1, 149.565, 281.787, -4.65385, 1.48353, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+37 , 18404, 0, 0, 553, 3847, 3847, 3, 1, 1, 159.136, 283.813, -3.27211, 2.3911, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+38 , 18404, 0, 0, 553, 3847, 3847, 3, 1, 1, 165.194, 298.208, -4.77445, 2.96706, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+39 , 18405, 0, 0, 553, 3847, 3847, 3, 1, 0, -11.2885, 288.159, -0.21232, 0.0174371, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+40 , 18405, 0, 0, 553, 3847, 3847, 3, 1, 0, -15.7445, 180.821, -5.48012, 4.69594, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+41 , 18405, 0, 0, 553, 3847, 3847, 3, 1, 0, -0.657082, 114.127, -5.49865, 4.69533, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+42 , 18405, 0, 0, 553, 3847, 3847, 3, 1, 0, 1.71903, 199.112, -5.47897, 2.17535, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+43 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, -19.3633, 197.066, -5.45702, 1.36136, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+44 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, -6.18938, 166.711, -5.45703, 1.78024, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+45 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, 15.8812, 195.363, -5.45708, 0.244346, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+46 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, -4.45333, 252.871, -5.39659, 2.40855, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+47 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, 13.1902, 198.497, -5.45706, 0.855211, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+48 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, -14.2483, 197.646, -5.45702, 2.49582, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+49 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, 3.13933, 253.476, -5.3924, 1.0821, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+50 , 18419, 0, 0, 553, 3847, 3847, 3, 1, 0, -3.43691, 163.531, -5.45704, 1.15192, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+51 , 18420, 0, 0, 553, 3847, 3847, 3, 1, 1, 159.738, 450.842, -5.41347, 4.69494, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+52 , 18420, 0, 0, 553, 3847, 3847, 3, 1, 1, 89.4469, 492.11, -5.42828, 6.24828, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+53 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 152.396, 375.262, -5.30307, 5.42797, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+54 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 170.202, 387.448, -5.30306, 0.541052, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+55 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 152.883, 411.747, -5.30312, 5.37561, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+56 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 158.615, 411.407, -5.30312, 3.78736, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+57 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 197.545, 377.96, -5.40067, 5.63741, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+58 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 164.13808, 501.65262, -2.169621, 0.418879032135009765, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+59 , 18421, 0, 0, 553, 3847, 3847, 3, 1, 1, 170.102, 499.288, -2.20102, 1.29154, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+60 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 158.949, 369.891, -5.30307, 0.471239, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+61 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 161.327, 377.632, -5.38641, 3.89208, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+62 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 161.586, 402.931, -5.38644, 2.26893, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+63 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 194.021, 381.961, -5.3712, 5.16617, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+64 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 161.187, 408.951, -5.30312, 6.26573, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+65 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 174.261, 496.247, -2.47682, 2.21657, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+66 , 18422, 0, 0, 553, 3847, 3847, 3, 1, 1, 161.825, 508.441, -2.50882, 5.48033, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+67 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 155.634, 431.37, -6.6656, 0.341256, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+68 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 146.464, 430.336, -6.55964, 5.46936, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+69 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 148.293, 437.387, -6.61002, 0.541052, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+70 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 168.333, 433.326, -6.88213, 1.1565, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+71 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 164.494, 436.609, -6.85249, 0.482658, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+72 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 155.004, 441.406, -6.76741, 1.48074, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+73 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 170.075, 438.384, -6.9189, 4.1424, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+74 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 102.482, 478.421, -6.62876, 4.53808, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+75 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 166.262, 443.45, -6.89592, 3.69224, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+76 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 98.4055, 487.476, -6.74783, 1.36306, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+77 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 97.5751, 494.773, -6.82732, 4.39194, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+78 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 106.753, 497.009, -6.88633, 1.85695, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+79 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 102.242, 497.175, -6.87164, 4.53179, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+80 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 107.655, 489.229, -6.78036, 6.10342, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+81 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 98.0962, 502.715, -6.91908, 4.16586, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+82 , 18587, 0, 0, 553, 3847, 3847, 3, 1, 0, 112.471, 506.305, -7.01248, 0.637195, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+83 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 152.061, 369.717, -5.30307, 0.785398, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+84 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 175.843, 387.166, -5.30306, 2.23402, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+85 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 152.395, 406.044, -5.30312, 0.855211, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+86 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 199.583, 372.112, -5.43548, 0.663225, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+87 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 176.38, 392.68, -5.30307, 3.76991, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+88 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 198.131, 373.662, -5.42373, 0.471239, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+89 , 19486, 0, 0, 553, 3847, 3847, 3, 1, 1, 165.405, 504.418, -2.20859, 0.10472, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+90 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, -9.7173, 588.702, -17.6519, 1.55334, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+91 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, -4.28845, 505.214, -5.22576, 0.820305, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+92 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, -20.1536, 505.03, -5.22962, 1.27409, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+93 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, 1.54828, 505.512, -5.23187, 2.28638, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+94 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, -15.6348, 505.633, -5.2228, 2.47837, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+95 , 19505, 0, 0, 553, 3847, 3847, 3, 1, 0, 20, 588.383, -17.6722, 1.58825, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+96 , 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -152.4, 372.664, -17.6055, 0.331613, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+97 , 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -164.275, 375.683, -17.6169, 2.75762, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+98 , 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -154.356, 386.376, -17.7216, 4.43314, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+99 , 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -172.32, 380.316, -17.6107, 0.890118, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+100, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -177.095, 378.248, -17.6081, 5.18363, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+101, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -173.274, 390.129, -17.6073, 3.50811, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+102, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -150.54, 400.302, -17.7579, 2.75762, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+103, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -166.857, 398.471, -17.6142, 4.2237, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+104, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -179.922, 401.107, -17.6042, 0.488692, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+105, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -157.634, 411.701, -17.6124, 1.27409, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+106, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -172.605, 403.925, -17.6111, 4.7473, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+107, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -177.217, 408.964, -17.6069, 2.07694, 86400, 0, 0, 0, 0, 0, 0, 33948422, 40, '', 46924), +(@CGUID+108, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -160.49, 499.152, -17.7416, 3.19395, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+109, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -131.527, 507.604, -17.7416, 4.15388, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+110, 19507, 0, 0, 553, 3847, 3847, 3, 1, 0, -150.399, 526.537, -17.7416, 3.63028, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+111, 19508, 0, 0, 553, 3847, 3847, 3, 1, 1, -16.2608, 482.706, -5.38576, 3.94444, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+112, 19508, 0, 0, 553, 3847, 3847, 3, 1, 1, -17.3213, 485.099, -5.36875, 2.96706, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+113, 19508, 0, 0, 553, 3847, 3847, 3, 1, 1, -129.174, 503.963, -17.7416, 3.38594, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+114, 19508, 0, 0, 553, 3847, 3847, 3, 1, 1, -163.527, 504.29, -17.7416, 3.90954, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+115, 19509, 0, 0, 553, 3847, 3847, 3, 1, 1, -15.0387, 479.981, -5.40512, 1.39626, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+116, 19509, 0, 0, 553, 3847, 3847, 3, 1, 1, -161.771, 495.03, -17.7416, 2.93215, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+117, 19509, 0, 0, 553, 3847, 3847, 3, 1, 1, -135.687, 508.005, -17.7416, 4.7822, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+118, 19509, 0, 0, 553, 3847, 3847, 3, 1, 1, -149.586, 522.217, -17.7416, 2.82743, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+119, 19509, 0, 0, 553, 3847, 3847, 3, 1, 1, -154.478, 529.907, -17.7416, 3.75246, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+120, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, 13.7186, 579.122, -17.7867, 1.98968, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+121, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, -7.54216, 483.758, -5.48296, 5.60109, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+122, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, 1.56623, 493.788, -5.43364, 2.7642, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+123, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, -45.387, 532.178, -15.3885, 5.50128, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+124, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, 30.5061, 554.694, -18.2601, 3.01657, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+125, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, 13.1327, 569.824, -17.9185, 1.79769, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+126, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, -0.867442, 569.955, -17.8747, 1.44862, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+127, 19511, 0, 0, 553, 3847, 3847, 3, 1, 1, -9.98952, 577.369, -17.7983, 1.13446, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+128, 19512, 0, 0, 553, 3847, 3847, 3, 1, 1, -41.7851, 537.039, -17.1612, 4.67166, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+129, 19512, 0, 0, 553, 3847, 3847, 3, 1, 1, -8.29304, 568.918, -17.9035, 1.25664, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+130, 19512, 0, 0, 553, 3847, 3847, 3, 1, 1, 20.6579, 570.267, -17.9328, 2.04204, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+131, 19512, 0, 0, 553, 3847, 3847, 3, 1, 1, 22.3027, 579.251, -17.8083, 2.25147, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+132, 19512, 0, 0, 553, 3847, 3847, 3, 1, 1, 0.125824, 576.989, -17.7821, 1.41372, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+133, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -157.757, 376.544, -17.6102, 2.07694, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+134, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -173.101, 371.972, -17.6119, 0.698132, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+135, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -155.913, 404.689, -17.6097, 1.11701, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+136, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -170.727, 408.12, -17.6117, 0.680678, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+137, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -158.333, 409.194, -17.6105, 5.95157, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+138, 19513, 0, 0, 553, 3847, 3847, 3, 1, 0, -178.098, 414.293, -17.6069, 5.61996, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+139, 19555, 0, 0, 553, 3847, 3847, 3, 1, 0, -1.83877, 510.545, 0.624383, 2.58309, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+140, 19555, 0, 0, 553, 3847, 3847, 3, 1, 0, -18.0924, 509.914, 1.61268, 3.52557, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+141, 19555, 0, 0, 553, 3847, 3847, 3, 1, 0, 20.0907, 599.71, -8.29904, 3.14159, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+142, 19555, 0, 0, 553, 3847, 3847, 3, 1, 0, -9.87732, 599.763, -8.5421, 6.03884, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+143, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 160.619, 371.029, -5.30307, 3.24631, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+144, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 154.009, 399.012, -5.38644, 2.90003, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+145, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 166.836, 403.544, -5.38643, 3.86121, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+146, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 194.849, 380.179, -5.3831, 1.67552, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+147, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 163.089, 409.039, -5.30312, 2.60054, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+148, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 172.615, 498.358, -2.31229, 4.43314, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+149, 19557, 0, 0, 553, 3847, 3847, 3, 1, 0, 163.761, 507.106, -2.36096, 3.50811, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+150, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -127.188, 508.097, -17.7416, 0.680678, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+151, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -129.022, 515.347, -17.8249, 2.95071, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+152, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -152.105, 499.975, -17.8249, 4.08054, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+153, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -157.032, 506.463, -17.8249, 0.767585, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+154, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -143.65, 522.046, -17.8249, 4.94884, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+155, 19598, 0, 0, 553, 3847, 3847, 3, 1, 0, -150.033, 530.878, -17.8249, 2.32775, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+156, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 11.4405, 359.739, -27.9089, 4.32122, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+157, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 17.0454, 359, -27.4179, 3.72482, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+158, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 4.39982, 365.464, -27.7524, 2.28376, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+159, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 28.2538, 367.298, -25.7301, 1.70034, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+160, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 12.2952, 370.77, -26.7367, 5.844, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+161, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 0.420135, 374.572, -27.5664, 5.34399, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+162, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 18.3876, 373.111, -26.5595, 5.03616, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+163, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 25.979, 376.722, -26.6886, 2.39683, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+164, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 12.8884, 379.785, -27.6479, 3.36757, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+165, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 20.9522, 380.282, -27.3528, 5.57957, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+166, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, -11.4655, 403.684, -28.9729, 6.07067, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+167, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 15.6301, 403.499, -27.5909, 3.98517, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+168, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, -14.7986, 409.728, -29.0519, 4.28779, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+169, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 4.01691, 407.446, -27.7113, 4.80471, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+170, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, -6.54189, 406.709, -28.8525, 3.19496, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+171, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, -2.81249, 404.491, -28.8971, 0.289019, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+172, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 1.23909, 413.528, -28.2706, 0.105794, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+173, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 3.47161, 412.26, -27.8663, 3.88872, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+174, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 3.57343, 420.337, -28.4988, 0.043863, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+175, 19608, 0, 0, 553, 3847, 3847, 3, 1, 0, 2.19094, 421.783, -28.7573, 0.307776, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+176, 19633, 0, 0, 553, 3847, 3847, 3, 1, 0, 5.66246, 166.799, -5.45705, 3.48662, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+177, 19633, 0, 0, 553, 3847, 3847, 3, 1, 0, 10.6196, 202.391, -5.45705, 4.13643, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+178, 19633, 0, 0, 553, 3847, 3847, 3, 1, 0, -0.755704, 255.12, -5.40764, 1.67552, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+179, 19633, 0, 0, 553, 3847, 3847, 3, 1, 0, -11.2663, 201.123, -5.45702, 5.51524, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+180, 19843, 0, 0, 553, 3847, 3847, 3, 1, 1, -67.0428, 560.303, -17.7856, 3.31579, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+181, 19843, 0, 0, 553, 3847, 3847, 3, 1, 1, -81.9598, 547.3, -17.7915, 4.42682, 86400, 5, 1, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+182, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -164.314, 371.267, -17.6188, 5.89921, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+183, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -168.994, 383.447, -17.6124, 4.7822, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+184, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -157.645, 396.704, -17.6893, 5.75959, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+185, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -151.525, 413.861, -17.6048, 3.735, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+186, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -174.267, 401.28, -17.6078, 5.37561, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924), +(@CGUID+187, 19865, 0, 0, 553, 3847, 3847, 3, 1, 0, -172.983, 418.549, -17.631, 2.54818, 86400, 0, 0, 0, 0, 0, 0, 0, 0, '', 46924); + +-- Commander Sarannis Double Attack Aura +UPDATE `creature_template_addon` SET `auras` = '19818' WHERE (`entry` = 17976); + +-- Pathing for Tempest-Forge Peacekeeper Entry: 18405 +SET @NPC := @CGUID+41; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-0.755125,`position_y`=111.97571,`position_z`=-5.5790524 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-0.755125,111.97571,-5.5790524,NULL,500,0,0,100,0), +(@PATH,2,-1.29136,76.94684,-5.6723366,NULL,0,0,0,100,0), +(@PATH,3,-1.203372,40.81776,-5.697605,NULL,500,0,0,100,0), +(@PATH,4,-1.29136,76.94684,-5.6723366,NULL,0,0,0,100,0); +-- 0x2041DC452011F94000099800018E350E .go xyz -0.755125 111.97571 -5.5790524 + +-- Pathing for Tempest-Forge Peacekeeper Entry: 18405 +SET @NPC := @CGUID+40; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-16.622828,`position_y`=182.00102,`position_z`=-5.5403466 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-16.622828,182.00102,-5.5403466,NULL,500,0,0,100,0), +(@PATH,2,-15.95655,167.93321,-5.5403438,NULL,0,0,0,100,0), +(@PATH,3,-0.681508,156.79243,-5.54037,NULL,0,0,0,100,0), +(@PATH,4,-0.733345,122.92154,-5.54038,NULL,500,0,0,100,0), +(@PATH,5,-0.681508,156.79243,-5.54037,NULL,0,0,0,100,0), +(@PATH,6,-15.95655,167.93321,-5.5403438,NULL,0,0,0,100,0); +-- 0x2041DC452011F94000099800000E350E .go xyz -16.622828 182.00102 -5.5403466 + +-- Pathing for Tempest-Forge Peacekeeper Entry: 18405 +SET @NPC := @CGUID+42; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=14.184935,`position_y`=177.34564,`position_z`=-5.5404077 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,14.184935,177.34564,-5.5404077,NULL,0,0,0,100,0), +(@PATH,2,14.394636,191.62259,-5.5404058,NULL,0,0,0,100,0), +(@PATH,3,9.744885,197.85094,-5.5403934,NULL,0,0,0,100,0), +(@PATH,4,-0.7083383,202.68777,-5.540371,NULL,0,0,0,100,0), +(@PATH,5,-0.863688,242.40205,-5.576286,NULL,10000,0,0,100,0), +(@PATH,6,-0.863688,242.40205,-5.576286,NULL,0,0,0,100,0), +(@PATH,7,-0.771556,202.71703,-5.5403705,NULL,0,0,0,100,0), +(@PATH,8,9.744885,197.85094,-5.5403934,NULL,0,0,0,100,0), +(@PATH,9,14.394636,191.62259,-5.5404058,NULL,0,0,0,100,0); +-- 0x2041DC452011F94000099800008E350E .go xyz 14.184935 177.34564 -5.5404077 + +-- Pathing for Tempest-Forge Peacekeeper Entry: 18405 +SET @NPC := @CGUID+39; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-15.361143,`position_y`=288.29004,`position_z`=-0.9933744 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-15.361143,288.29004,-0.9933744,NULL,500,0,0,100,0), +(@PATH,2,-2.241252,288.31714,1.0406964,NULL,0,0,0,100,0), +(@PATH,3,9.004453,288.18857,-0.0030922033,NULL,0,0,0,100,0), +(@PATH,4,48.18709,287.5947,-5.6754208,NULL,500,0,0,100,0), +(@PATH,5,9.004453,288.18857,-0.0030922033,NULL,0,0,0,100,0), +(@PATH,6,-2.241252,288.31714,1.0406964,NULL,0,0,0,100,0); +-- 0x2041DC452011F94000099800010E350E .go xyz -15.361143 288.29004 -0.9933744 + +-- Pathing for Commander Sarannis Entry: 17976 +SET @NPC := @CGUID+1; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=150.96367,`position_y`=296.03403,`position_z`=-4.5677114 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,3, '19818'); -- 17976 Double Attack +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,150.96367,296.03403,-4.5677114,NULL,500,0,0,100,0), +(@PATH,2,125.72935,321.18497,-3.6359427,NULL,500,0,0,100,0); +-- 0x2041DC4520118E0000099800000E350E .go xyz 150.96367 296.03403 -4.5677114 + +-- Pathing for Bloodwarder Greenkeeper Entry: 18419 +SET @NPC := @CGUID+44; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-6.24241,`position_y`=166.6921,`position_z`=-5.5403643 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,69,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-6.24241,166.6921,-5.5403643,1.780235767364501953,45000,0,0,100,0), +(@PATH,2,-3.464332,161.02238,-5.5403714,NULL,0,0,0,100,0), +(@PATH,3,0.992403,160.6039,-5.5403724,NULL,0,0,0,100,0), +(@PATH,4,2.213683,163.03323,-5.5403814,NULL,0,0,0,100,0), +(@PATH,5,2.213683,163.03323,-5.5403814,2.251474618911743164,25000,0,0,100,0), +(@PATH,6,-4.294355,161.2607,-5.540369,NULL,0,0,0,100,0), +(@PATH,7,-6.205455,163.51398,-5.5403643,NULL,0,0,0,100,0), +(@PATH,8,-6.24241,166.6921,-5.5403643,NULL,0,0,0,100,0); +-- 0x2041DC452011FCC000099800000E350F .go xyz -6.24241 166.6921 -5.5403643 + +-- Pathing for Bloodwarder Greenkeeper Entry: 18419 +SET @NPC := @CGUID+43; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-19.617546,`position_y`=196.94617,`position_z`=-5.5403457 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,69,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-19.617546,196.94617,-5.5403457,1.361356854438781738,30000,0,0,100,0), +(@PATH,2,-14.249623,195.31355,-5.540352,NULL,0,0,0,100,0), +(@PATH,3,-10.832382,198.47723,-5.5403476,NULL,0,0,0,100,0), +(@PATH,4,-7.085683,202.04625,-5.540354,NULL,0,0,0,100,0), +(@PATH,5,-8.21974,204.3309,-5.54035,NULL,0,0,0,100,0), +(@PATH,6,-8.21974,204.3309,-5.54035,3.560471534729003906,25000,0,0,100,0), +(@PATH,7,-10.741502,199.82332,-5.540348,NULL,0,0,0,100,0), +(@PATH,8,-12.490674,195.6114,-5.5403466,NULL,0,0,0,100,0), +(@PATH,9,-16.424341,194.29588,-5.540349,NULL,0,0,0,100,0), +(@PATH,10,-19.617546,196.94617,-5.5403457,NULL,0,0,0,100,0); +-- 0x2041DC452011FCC000099800008E350F .go xyz -19.617546 196.94617 -5.5403457 + +-- Pathing for Bloodwarder Greenkeeper Entry: 18419 +SET @NPC := @CGUID+47; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=13.118124,`position_y`=198.47266,`position_z`=-5.5404043 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,69,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,13.118124,198.47266,-5.5404043,0.855211317539215087,27000,0,0,100,0), +(@PATH,2,17.342175,193.04478,-5.540413,NULL,0,0,0,100,0), +(@PATH,3,17.342175,193.04478,-5.540413,0.942477762699127197,30000,0,0,100,0), +(@PATH,4,13.038144,196.03471,-5.5404077,NULL,0,0,0,100,0), +(@PATH,5,13.118124,198.47266,-5.5404043,NULL,0,0,0,100,0); +-- 0x2041DC452011FCC000099800028E350E .go xyz 13.118124 198.47266 -5.5404043 + +SET @GREENKEEPER_TALK := 1841900; +SET @GREENKEEPER_WORK := 1841901; + +DELETE FROM `waypoint_scripts` WHERE `id` IN (@GREENKEEPER_TALK, @GREENKEEPER_WORK) AND `guid` IN (@GREENKEEPER_TALK, @GREENKEEPER_WORK); +INSERT INTO `waypoint_scripts` (`id`, `command`, `datalong`, `datalong2`, `guid`) VALUES +(@GREENKEEPER_TALK, 1, 378, 1, @GREENKEEPER_TALK), +(@GREENKEEPER_WORK, 1, 69 , 1, @GREENKEEPER_WORK); + +-- Pathing for Bloodwarder Greenkeeper Entry: 18419 +SET @NPC := @CGUID+46; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-4.453328,`position_y`=252.87134,`position_z`=-5.3965907 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4.453328,252.87134,-5.3965907,0.069813169538974761,6000,0,@GREENKEEPER_TALK,100,0), -- EmoteState: 378 +(@PATH,2,-4.453328,252.87134,-5.3965907,2.146754980087280273,20000,0,@GREENKEEPER_WORK,100,0); -- EmoteState: 69 +-- 0x2041DC452011FCC000099800018E350E .go xyz -4.453328 252.87134 -5.3965907 + +-- Pathing for Bloodwarder Greenkeeper Entry: 18419 +SET @NPC := @CGUID+49; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=3.139327,`position_y`=253.47603,`position_z`=-5.3923993 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3.139327,253.47603,-5.3923993,3.141592741012573242,6000,0,@GREENKEEPER_TALK,100,0), +(@PATH,2,3.139327,253.47603,-5.3923993,0.977384388446807861,20000,0,@GREENKEEPER_WORK,100,0); +-- 0x2041DC452011FCC000099800020E350E .go xyz 3.139327 253.47603 -5.3923993 + +-- Pathing for Sunseeker Botanist Entry: 18422 +SET @NPC := @CGUID+61; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=161.32674,`position_y`=377.6318,`position_z`=-5.3864074 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,161.32674,377.6318,-5.3864074,3.892084121704101562,16000,0,0,100,0), +(@PATH,2,164.73518,383.69333,-5.3864126,NULL,0,0,0,100,0), +(@PATH,3,164.08838,388.16116,-5.3864183,NULL,0,0,0,100,0), +(@PATH,4,161.8422,392.52505,-5.3864245,NULL,0,0,0,100,0), +(@PATH,5,159.04375,394.92587,-5.386429,NULL,0,0,0,100,0), +(@PATH,6,154.68452,398.07758,-5.386435,NULL,0,0,0,100,0), +(@PATH,7,153.94124,401.8906,-5.38644,NULL,0,0,0,100,0), +(@PATH,8,153.94124,401.8906,-5.38644,0.942477762699127197,18000,0,0,100,0), +(@PATH,9,155.4246,397.5377,-5.3864336,NULL,0,0,0,100,0), +(@PATH,10,157.82056,395.40057,-5.3864303,NULL,0,0,0,100,0), +(@PATH,11,160.73982,392.51236,-5.386425,NULL,0,0,0,100,0), +(@PATH,12,163.7198,388.017,-5.3864183,NULL,0,0,0,100,0), +(@PATH,13,163.84503,385.06787,-5.386415,NULL,0,0,0,100,0), +(@PATH,14,163.11421,380.81992,-5.38641,NULL,0,0,0,100,0), +(@PATH,15,161.32674,377.6318,-5.3864074,NULL,0,0,0,100,0); +-- 0x2041DC452011FD8000099800008E350E .go xyz 161.32674 377.6318 -5.3864074 + +-- Pathing for Sunseeker Botanist Entry: 18422 +SET @NPC := @CGUID+62; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=161.58592,`position_y`=402.9305,`position_z`=-5.386437 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,161.58592,402.9305,-5.386437,2.268928050994873046,17000,0,0,100,0), +(@PATH,2,165.13728,399.90314,-5.386431,NULL,0,0,0,100,0), +(@PATH,3,168.7618,399.839,-5.3864293,NULL,0,0,0,100,0), +(@PATH,4,172.81506,400.5747,-5.386428,NULL,0,0,0,100,0), +(@PATH,5,177.91023,400.0075,-5.3864245,NULL,0,0,0,100,0), +(@PATH,6,181.75496,397.46924,-5.38642,NULL,0,0,0,100,0), +(@PATH,7,182.47469,393.09888,-5.3864145,NULL,0,0,0,100,0), +(@PATH,8,183.03293,388.3197,-5.3864083,NULL,0,0,0,100,0), +(@PATH,9,185.39342,384.4199,-5.500157,NULL,0,0,0,100,0), +(@PATH,10,188.07881,383.3712,-5.505682,NULL,0,0,0,100,0), +(@PATH,11,191.3777,384.4846,-5.5123386,NULL,0,0,0,100,0), +(@PATH,12,191.3777,384.4846,-5.5123386,0.767944872379302978,19000,0,0,100,0), +(@PATH,13,186.81783,385.4778,-5.5029993,NULL,0,0,0,100,0), +(@PATH,14,183.88887,388.4998,-5.49687,NULL,0,0,0,100,0), +(@PATH,15,182.7735,392.4268,-5.3864136,NULL,0,0,0,100,0), +(@PATH,16,181.82643,397.84805,-5.3864202,NULL,0,0,0,100,0), +(@PATH,17,177.46024,402.43765,-5.386428,NULL,0,0,0,100,0), +(@PATH,18,169.00165,404.75284,-5.386435,NULL,0,0,0,100,0), +(@PATH,19,161.58592,402.9305,-5.386437,NULL,0,0,0,100,0); +-- 0x2041DC452011FD8000099800028E350E .go xyz 161.58592 402.9305 -5.386437 + +-- Pathing for High Botanist Freywinn Entry: 17975 +SET @NPC := @CGUID+0; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,69,3, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,116.32591,455.5696,-4.941401,3.385938644409179687,15000,0,0,100,0), +(@PATH,2,120.16402,450.68173,-4.894922,4.555309295654296875,15000,0,0,100,0); +-- 0x2041DC4520118DC000099800000E350E .go xyz 116.32591 455.5696 -4.941401 + +-- Pathing for Nethervine Inciter Entry: 19511 +SET @NPC := @CGUID+121; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=1.63937,`position_y`=482.49994,`position_z`=-5.534588 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1.63937,482.49994,-5.534588,NULL,0,0,0,100,0), +(@PATH,2,-6.525395,482.93228,-5.4948173,NULL,0,0,0,100,0), +(@PATH,3,-13.819373,488.85602,-5.425375,NULL,0,0,0,100,0), +(@PATH,4,-17.635359,496.55002,-5.3706923,NULL,0,0,0,100,0), +(@PATH,5,-16.294327,503.0782,-5.324291,NULL,0,0,0,100,0), +(@PATH,6,-6.525395,482.93228,-5.4948173,NULL,0,0,0,100,0); +-- 0x2041DC4520130DC000099800000E350E .go xyz 1.63937 482.49994 -5.534588 + +-- Pathing for Nethervine Inciter Entry: 19511 +SET @NPC := @CGUID+122; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-10.506299,`position_y`=509.9379,`position_z`=-5.275531 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-10.506299,509.9379,-5.275531,NULL,0,0,0,100,0), +(@PATH,2,-10.811854,498.69476,-5.355443,NULL,0,0,0,100,0), +(@PATH,3,2.500325,493.41788,-5.4415383,NULL,0,0,0,100,0), +(@PATH,4,15.093162,496.89648,-5.4699764,NULL,0,0,0,100,0), +(@PATH,5,2.500325,493.41788,-5.4415383,NULL,0,0,0,100,0), +(@PATH,6,-10.811854,498.69476,-5.355443,NULL,0,0,0,100,0); +-- 0x2041DC4520130DC000099800008E350E .go xyz -10.506299 509.9379 -5.275531 + +-- Pathing for Nethervine Inciter Entry: 19511 +SET @NPC := @CGUID+123; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-21.582249,`position_y`=517.7063,`position_z`=-6.475253 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-21.582249,517.7063,-6.475253,NULL,0,0,0,100,0), +(@PATH,2,-9.34382,516.5084,-5.6364603,NULL,0,0,0,100,0), +(@PATH,3,4.990617,518.1604,-7.1384296,NULL,0,0,0,100,0), +(@PATH,4,19.445581,526.3201,-11.257864,NULL,0,0,0,100,0), +(@PATH,5,23.91135,540.4265,-18.37715,NULL,0,0,0,100,0), +(@PATH,6,18.103956,548.5428,-18.29796,NULL,0,0,0,100,0), +(@PATH,7,-1.83314,553.56354,-18.135887,NULL,0,0,0,100,0), +(@PATH,8,-17.958172,553.2923,-18.191553,NULL,0,0,0,100,0), +(@PATH,9,-30.428175,550.3372,-18.304739,NULL,0,0,0,100,0), +(@PATH,10,-43.321644,544.68585,-18.359991,NULL,0,0,0,100,0), +(@PATH,11,-46.765606,533.5467,-15.893292,NULL,0,0,0,100,0), +(@PATH,12,-37.181698,524.0293,-10.164318,NULL,0,0,0,100,0); +-- 0x2041DC4520130DC000099800038E350E .go xyz -21.582249 517.7063 -6.475253 + +-- Pathing for Nethervine Inciter Entry: 19511 +SET @NPC := @CGUID+124; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `wander_distance`=0,`MovementType`=2,`position_x`=-29.17254,`position_y`=568.2135,`position_z`=-17.990519 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`visibilityDistanceType`,`auras`) VALUES (@NPC,@PATH,0,0,1,0,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-29.17254,568.2135,-17.990519,NULL,0,0,0,100,0), +(@PATH,2,-11.505647,559.82526,-18.09619,NULL,0,0,0,100,0), +(@PATH,3,13.711286,556.805,-18.137554,NULL,0,0,0,100,0), +(@PATH,4,34.537453,554.1877,-18.282408,NULL,0,0,0,100,0), +(@PATH,5,13.711286,556.805,-18.137554,NULL,0,0,0,100,0), +(@PATH,6,-11.505647,559.82526,-18.09619,NULL,0,0,0,100,0); +-- 0x2041DC4520130DC000099800010E350E .go xyz -29.17254 568.2135 -17.990519 + +-- Patrol formations +DELETE FROM `creature_formations` WHERE `leaderGUID` IN (@CGUID+61, @CGUID+62, @CGUID+123) AND `memberGUID` IN (@CGUID+61, @CGUID+62, @CGUID+123, @CGUID+128, @CGUID+144, @CGUID+145); +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(@CGUID+61, @CGUID+61, 0, 0, 3), +(@CGUID+61, @CGUID+144, 3, 180, 515), +(@CGUID+62, @CGUID+62, 0, 0, 3), +(@CGUID+62, @CGUID+145, 3, 180, 515), +(@CGUID+123, @CGUID+123, 0, 0, 3), +(@CGUID+123, @CGUID+128, 3.5, 90, 515); + +-- SmartAI for Sunseeker Botanist +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 18422); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18422, 0, 0, 0, 14, 0, 100, 2, 2000, 40, 12000, 16000, 0, 11, 34361, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Normal Dungeon)'), +(18422, 0, 1, 0, 14, 0, 100, 4, 2000, 40, 12000, 16000, 0, 11, 39125, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Heroic Dungeon)'), +(18422, 0, 2, 0, 0, 0, 100, 0, 3000, 5000, 20000, 20000, 0, 11, 34350, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - In Combat - Cast \'Nature`s Rage\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 18422); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18422, 0, 0, 0, 14, 0, 100, 2, 2000, 40, 12000, 16000, 0, 11, 34361, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Normal Dungeon)'), +(18422, 0, 1, 0, 14, 0, 100, 4, 2000, 40, 12000, 16000, 0, 11, 39125, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Heroic Dungeon)'), +(18422, 0, 2, 0, 0, 0, 100, 0, 3000, 5000, 20000, 20000, 0, 11, 34350, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - In Combat - Cast \'Nature`s Rage\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+65), -(@CGUID+66))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+65), 0, 0, 0, 14, 0, 100, 2, 2000, 40, 12000, 16000, 0, 11, 34361, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Normal Dungeon)'), +(-(@CGUID+65), 0, 1, 0, 14, 0, 100, 4, 2000, 40, 12000, 16000, 0, 11, 39125, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Heroic Dungeon)'), +(-(@CGUID+65), 0, 2, 0, 0, 0, 100, 0, 3000, 5000, 20000, 20000, 0, 11, 34350, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - In Combat - Cast \'Nature`s Rage\''), +(-(@CGUID+65), 0, 1001, 0, 1, 0, 100, 0, 0, 60000, 45000, 120000, 0, 80, 1842200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Out of Combat - Run Script'), +(-(@CGUID+66), 0, 0, 0, 14, 0, 100, 2, 2000, 40, 12000, 16000, 0, 11, 34361, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Normal Dungeon)'), +(-(@CGUID+66), 0, 1, 0, 14, 0, 100, 4, 2000, 40, 12000, 16000, 0, 11, 39125, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Friendly At 2000 Health - Cast \'Regrowth\' (Heroic Dungeon)'), +(-(@CGUID+66), 0, 2, 0, 0, 0, 100, 0, 3000, 5000, 20000, 20000, 0, 11, 34350, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - In Combat - Cast \'Nature`s Rage\''), +(-(@CGUID+66), 0, 1001, 0, 1, 0, 100, 0, 0, 60000, 45000, 120000, 0, 80, 1842200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Out of Combat - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1842200); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1842200, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Actionlist - Say Line 0'), +(1842200, 9, 1, 0, 0, 0, 100, 0, 3400, 3400, 0, 0, 0, 11, 34254, 0, 0, 0, 0, 0, 19, 19557, 5, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Actionlist - Cast \'Rejuvenate Plant\''), +(1842200, 9, 2, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Botanist - Actionlist - Say Line 1'); + +DELETE FROM `creature_text` WHERE `CreatureID`=18422; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES +(18422, 0, 'Hmm...', 12, 100, 274, 17000, 'Sunseeker Botanist'), +(18422, 1, 'Yes. That did the trick.', 12, 100, 273, 16999, 'Sunseeker Botanist'); + +-- Sunseeker Geomancer +DELETE FROM `waypoints` WHERE `point_comment`='Sunseeker Geomancer' AND `entry` BETWEEN 1842000 AND 1842003; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +-- Geo 1 Go 0x2041DC452011FD0000099800000E350E +(1842000,1,161.05328,446.54932,-6.882456,NULL,'Sunseeker Geomancer'), +(1842000,2,162.57597,441.6976,-6.8499804,NULL,'Sunseeker Geomancer'), +(1842000,3,162.00397,439.0201,-6.8342767,NULL,'Sunseeker Geomancer'), +(1842000,4,157.23569,436.5563,-6.7741537,NULL,'Sunseeker Geomancer'), +-- Geo 1 Back +(1842001,1,162.69269,439.46976,-6.843295,NULL,'Sunseeker Geomancer'), +(1842001,2,163.46931,442.2841,-6.8616896,NULL,'Sunseeker Geomancer'), +(1842001,3,161.09004,446.55927,-6.8829055,NULL,'Sunseeker Geomancer'), +(1842001,4,159.73839,450.8425,-5.4134717,4.694935798645019531,'Sunseeker Geomancer'), +-- Geo 2 Go 0x2041DC452011FD0000099800008E350E +(1842002,1,98.24995,491.0886,-6.7881303,NULL,'Sunseeker Geomancer'), +(1842002,2,101.62144,492.35785,-6.8148685,NULL,'Sunseeker Geomancer'), +-- Geo 2 Back +(1842003,1,96.16563,490.70752,-6.7761664,NULL,'Sunseeker Geomancer'), +(1842003,2,92.9932,491.44473,-6.772856,NULL,'Sunseeker Geomancer'), +(1842003,3,89.44688,492.10977,-5.428278,6.248278617858886718,'Sunseeker Geomancer'); + +DELETE FROM `creature_text` WHERE `CreatureID`=18420; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES +(18420, 0, 'Hmm...Frost, Fire, and Arcane defenses respond faster than Batch 7, but Nature defenses remain passive.', 12, 100, 0, 17178, 'Sunseeker Geomancer'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 18420); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18420, 0, 0, 0, 9, 0, 100, 0, 0, 8, 3600, 8400, 0, 11, 35124, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Within 0-8 Range - Cast \'Arcane Explosion\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` IN (1842000, 1842001, 1842002, 1842003)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1842000, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 4.6949357986450195, 'Sunseeker Geomancer - Actionlist - Set Orientation 4.6949357986450195'), +(1842000, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34167, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Blizzard\''), +(1842000, 9, 2, 0, 0, 0, 100, 0, 20600, 20600, 0, 0, 0, 11, 34169, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Rain of Fire\''), +(1842000, 9, 3, 0, 0, 0, 100, 0, 20400, 20400, 0, 0, 0, 53, 0, 1842000, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Start Waypoint'), + +(1842001, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.6185169219970703, 'Sunseeker Geomancer - Actionlist - Set Orientation 3.6185169219970703'), +(1842001, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842001, 9, 2, 0, 0, 0, 100, 0, 2400, 2400, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842001, 9, 3, 0, 0, 0, 100, 0, 2400, 2400, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842001, 9, 4, 0, 0, 0, 100, 0, 2600, 2600, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Say Line 0'), +(1842001, 9, 5, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 0, 53, 0, 1842001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Start Waypoint'), + +(1842002, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 6.248278617858886718, 'Sunseeker Geomancer - Actionlist - Set Orientation 6.248278617858886718'), +(1842002, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34183, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Blizzard\''), +(1842002, 9, 2, 0, 0, 0, 100, 0, 20600, 20600, 0, 0, 0, 11, 34185, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Rain of Fire\''), +(1842002, 9, 3, 0, 0, 0, 100, 0, 20400, 20400, 0, 0, 0, 53, 0, 1842002, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Start Waypoint'), + +(1842003, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0.360056608915328979, 'Sunseeker Geomancer - Actionlist - Set Orientation 0.360056608915328979'), +(1842003, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842003, 9, 2, 0, 0, 0, 100, 0, 2400, 2400, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842003, 9, 3, 0, 0, 0, 100, 0, 2400, 2400, 0, 0, 0, 11, 34170, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Cast \'Arcane Explosion\''), +(1842003, 9, 4, 0, 0, 0, 100, 0, 2600, 2600, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Say Line 0'), +(1842003, 9, 5, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 0, 53, 0, 1842003, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Actionlist - Start Waypoint'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+51), -(@CGUID+52))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+51), 0, 0, 0, 9, 0, 100, 0, 0, 8, 3600, 8400, 0, 11, 35124, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Within 0-8 Range - Cast \'Arcane Explosion\''), +(-(@CGUID+51), 0, 1001, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Respawn - Set Event Phase 1'), +(-(@CGUID+51), 0, 1002, 1003, 1, 1, 100, 0, 1200, 2400, 1200, 2400, 0, 80, 1842000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Out of Combat - Run Script (Phase 1)'), +(-(@CGUID+51), 0, 1003, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Out of Combat - Set Event Phase 0 (Phase 1)'), +(-(@CGUID+51), 0, 1004, 0, 58, 0, 100, 0, 4, 1842000, 0, 0, 0, 80, 1842001, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Waypoint Finished - Run Script'), +(-(@CGUID+51), 0, 1005, 0, 58, 0, 100, 0, 4, 1842001, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Waypoint Finished - Set Event Phase 1'), + +(-(@CGUID+52), 0, 0, 0, 9, 0, 100, 0, 0, 8, 3600, 8400, 0, 11, 35124, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Within 0-8 Range - Cast \'Arcane Explosion\''), +(-(@CGUID+52), 0, 1001, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Respawn - Set Event Phase 1'), +(-(@CGUID+52), 0, 1002, 1003, 1, 1, 100, 0, 1200, 2400, 1200, 2400, 0, 80, 1842002, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Out of Combat - Run Script (Phase 1)'), +(-(@CGUID+52), 0, 1003, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - Out of Combat - Set Event Phase 0 (Phase 1)'), +(-(@CGUID+52), 0, 1004, 0, 58, 0, 100, 0, 2, 1842002, 0, 0, 0, 80, 1842003, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Waypoint Finished - Run Script'), +(-(@CGUID+52), 0, 1005, 0, 58, 0, 100, 0, 3, 1842003, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Geomancer - On Waypoint Finished - Set Event Phase 1'); + +-- Corrects Spell Target Pos +UPDATE `spell_target_position` SET `PositionX`=102.702, `PositionY`=489.666, `PositionZ`=-6.74601 WHERE `ID` IN (34183, 34185); +UPDATE `spell_target_position` SET `PositionX`=158.252, `PositionY`=435.927, `PositionZ`=-6.78686 WHERE `ID` IN (34183, 34185); + +-- Bloodwarder Falconer and Bloodfalcons +DELETE FROM `waypoints` WHERE `point_comment`='Bloodfalcon' AND `entry` BETWEEN 1815500 AND 1815504; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +(1815500,1,-12.859056,292.17502,-0.47123554,NULL,'Bloodfalcon'), +(1815500,2,-4.634653,291.63293,0.8281061,NULL,'Bloodfalcon'), +(1815500,3,-3.132143,288.05878,0.97123027,NULL,'Bloodfalcon'), +(1815500,4,-12.779606,283.8108,-0.5313738,NULL,'Bloodfalcon'), +(1815500,5,-23.234816,285.8802,-1.8473223,NULL,'Bloodfalcon'), +(1815500,6,-29.06995,287.01328,-1.8473244,NULL,'Bloodfalcon'), +(1815500,7,-28.19163,288.61743,-1.8473233,NULL,'Bloodfalcon'), +(1815501,1,-32.633892,313.6926,-2.9892433,NULL,'Bloodfalcon'), +(1815501,2,-36.44413,294.66745,-1.8473231,NULL,'Bloodfalcon'), +(1815501,3,-42.860966,291.474,-1.8473233,NULL,'Bloodfalcon'), +(1815501,4,-42.836784,283.74088,-1.8473245,NULL,'Bloodfalcon'), +(1815501,5,-29.824219,283.9159,-1.8473248,NULL,'Bloodfalcon'), +(1815501,6,-29.392775,291.65842,-1.8473237,NULL,'Bloodfalcon'), +(1815501,7,-36.823017,294.92844,-1.847323,NULL,'Bloodfalcon'), +(1815502,1,-30.482723,259.80405,-3.4442947,NULL,'Bloodfalcon'), +(1815502,2,-36.03879,280.80167,-1.8473252,NULL,'Bloodfalcon'), +(1815502,3,-30.454828,284.31418,-1.8473248,NULL,'Bloodfalcon'), +(1815502,4,-30.297646,292.20926,-1.8473235,NULL,'Bloodfalcon'), +(1815502,5,-36.54842,295.91965,-1.8473228,NULL,'Bloodfalcon'), +(1815502,6,-43.99062,283.76346,-1.8473245,NULL,'Bloodfalcon'), +(1815502,7,-36.486675,280.83936,-1.8473252,NULL,'Bloodfalcon'), +(1815503,1,85.99113,289.54016,-5.441046,NULL,'Bloodfalcon'), +(1815503,2,79.673256,286.72223,-5.466302,NULL,'Bloodfalcon'), +(1815503,3,77.98022,270.55414,-5.47999,NULL,'Bloodfalcon'), +(1815503,4,84.07146,264.81665,-5.459437,NULL,'Bloodfalcon'), +(1815503,5,92.041145,267.70798,-5.4278765,NULL,'Bloodfalcon'), +(1815503,6,99.9794,272.1951,-6.95119,NULL,'Bloodfalcon'), +(1815503,7,100.84679,280.37253,-6.861873,NULL,'Bloodfalcon'), +(1815504,1,106.60388,296.39322,-6.722094,NULL,'Bloodfalcon'), +(1815504,2,114.86026,296.71304,-5.403351,NULL,'Bloodfalcon'), +(1815504,3,120.55673,289.947,-5.4101934,NULL,'Bloodfalcon'), +(1815504,4,119.758934,278.0228,-5.4230533,NULL,'Bloodfalcon'), +(1815504,5,114.74198,276.31375,-6.958809,NULL,'Bloodfalcon'), +(1815504,6,109.52783,279.67487,-6.901642,NULL,'Bloodfalcon'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 17994); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(17994, 0, 0, 1, 0, 0, 100, 512, 2000, 4000, 15000, 15000, 0, 64, 1, 0, 0, 0, 0, 0, 5, 40, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Store Targetlist'), +(17994, 0, 1, 2, 61, 0, 100, 512, 0, 0, 0, 0, 0, 11, 34852, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Call of the Falcon\''), +(17994, 0, 2, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Say Line 0'), +(17994, 0, 3, 0, 0, 0, 100, 0, 4000, 6000, 22000, 25000, 0, 11, 31567, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Deterrence\''), +(17994, 0, 4, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 34879, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Multi-Shot\''), +(17994, 0, 5, 0, 2, 0, 100, 0, 0, 5, 10000, 10000, 0, 11, 32908, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Between 0-5% Health - Cast \'Wing Clip\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+27), -(@CGUID+28))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+27), 0, 0, 1, 0, 0, 100, 512, 2000, 4000, 15000, 15000, 0, 64, 1, 0, 0, 0, 0, 0, 5, 40, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Store Targetlist'), +(-(@CGUID+27), 0, 1, 2, 61, 0, 100, 512, 0, 0, 0, 0, 0, 11, 34852, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Call of the Falcon\''), +(-(@CGUID+27), 0, 2, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Say Line 1'), +(-(@CGUID+27), 0, 3, 0, 0, 0, 100, 0, 4000, 6000, 22000, 25000, 0, 11, 31567, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Deterrence\''), +(-(@CGUID+27), 0, 4, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 34879, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Multi-Shot\''), +(-(@CGUID+27), 0, 5, 0, 2, 0, 100, 0, 0, 5, 10000, 10000, 0, 11, 32908, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Between 0-5% Health - Cast \'Wing Clip\''), +(-(@CGUID+27), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Data Set 1 1 - Set Event Phase 1'), +(-(@CGUID+27), 0, 1002, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Respawn - Set Event Phase 1'), +(-(@CGUID+27), 0, 1003, 1004, 1, 1, 100, 0, 1200, 10000, 1200, 10000, 0, 87, 1799400, 1799401, 1799402, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Out of Combat - Run Random Script (Phase 1)'), +(-(@CGUID+27), 0, 1004, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Link - Set Event Phase 0 (Phase 1)'), + +(-(@CGUID+28), 0, 0, 1, 0, 0, 100, 512, 2000, 4000, 15000, 15000, 0, 64, 1, 0, 0, 0, 0, 0, 5, 40, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Store Targetlist'), +(-(@CGUID+28), 0, 1, 2, 61, 0, 100, 512, 0, 0, 0, 0, 0, 11, 34852, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Call of the Falcon\''), +(-(@CGUID+28), 0, 2, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Say Line 1'), +(-(@CGUID+28), 0, 3, 0, 0, 0, 100, 0, 4000, 6000, 22000, 25000, 0, 11, 31567, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Deterrence\''), +(-(@CGUID+28), 0, 4, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 34879, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - In Combat - Cast \'Multi-Shot\''), +(-(@CGUID+28), 0, 5, 0, 2, 0, 100, 0, 0, 5, 10000, 10000, 0, 11, 32908, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Between 0-5% Health - Cast \'Wing Clip\''), +(-(@CGUID+28), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Data Set 1 1 - Set Event Phase 1'), +(-(@CGUID+28), 0, 1002, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Respawn - Set Event Phase 1'), +(-(@CGUID+28), 0, 1003, 1004, 1, 1, 100, 0, 1200, 10000, 1200, 10000, 0, 87, 1799403, 1799404, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Out of Combat - Run Random Script (Phase 1)'), +(-(@CGUID+28), 0, 1004, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - On Link - Set Event Phase 0 (Phase 1)'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` BETWEEN 1799400 AND 1799404); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1799400, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 6.2657318115234375, 'Bloodwarder Falconer - Actionlist - Set Orientation 6.2657318115234375'), +(1799400, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Say Line 0'), +(1799400, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 147029, 18155, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Set Data 1 1'), + +(1799401, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 1.570796370506286621, 'Bloodwarder Falconer - Actionlist - Set Orientation 1.570796370506286621'), +(1799401, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Say Line 0'), +(1799401, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 147031, 18155, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Set Data 1 1'), + +(1799402, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 4.78220224380493164, 'Bloodwarder Falconer - Actionlist - Set Orientation 4.78220224380493164'), +(1799402, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Say Line 0'), +(1799402, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 147034, 18155, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Set Data 1 1'), + +(1799403, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 2.932153224945068359, 'Bloodwarder Falconer - Actionlist - Set Orientation 2.932153224945068359'), +(1799403, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Say Line 0'), +(1799403, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 147030, 18155, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Set Data 1 1'), + +(1799404, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0.837758064270019531, 'Bloodwarder Falconer - Actionlist - Set Orientation 0.837758064270019531'), +(1799404, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Say Line 0'), +(1799404, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 147032, 18155, 0, 0, 0, 0, 0, 0, 'Bloodwarder Falconer - Actionlist - Set Data 1 1'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 18155); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18155, 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(18155, 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(18155, 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(18155, 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(18155, 0, 4, 0, 58, 0, 100, 0, 7, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+29), -(@CGUID+31), -(@CGUID+34), -(@CGUID+30), -(@CGUID+32))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+29), 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(-(@CGUID+29), 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(-(@CGUID+29), 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(-(@CGUID+29), 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(-(@CGUID+29), 0, 4, 0, 58, 0, 100, 0, 7, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'), +(-(@CGUID+29), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 1, 1815500, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Data Set 1 1 - Start Waypoint'), + +(-(@CGUID+31), 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(-(@CGUID+31), 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(-(@CGUID+31), 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(-(@CGUID+31), 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(-(@CGUID+31), 0, 4, 0, 58, 0, 100, 0, 7, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'), +(-(@CGUID+31), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 1, 1815501, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Data Set 1 1 - Start Waypoint'), + +(-(@CGUID+34), 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(-(@CGUID+34), 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(-(@CGUID+34), 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(-(@CGUID+34), 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(-(@CGUID+34), 0, 4, 0, 58, 0, 100, 0, 7, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'), +(-(@CGUID+34), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 1, 1815502, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Data Set 1 1 - Start Waypoint'), + +(-(@CGUID+30), 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(-(@CGUID+30), 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(-(@CGUID+30), 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(-(@CGUID+30), 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(-(@CGUID+30), 0, 4, 0, 58, 0, 100, 0, 7, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'), +(-(@CGUID+30), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 1, 1815503, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Data Set 1 1 - Start Waypoint'), + +(-(@CGUID+32), 0, 0, 0, 9, 0, 100, 0, 8, 25, 10000, 10000, 0, 11, 32323, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - Within 8-25 Range - Cast \'Charge\''), +(-(@CGUID+32), 0, 1, 0, 13, 0, 100, 0, 15000, 15000, 0, 0, 0, 11, 18144, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Victim Casting \'null\' - Cast \'Swoop\''), +(-(@CGUID+32), 0, 2, 0, 0, 0, 100, 0, 1000, 6000, 20000, 25000, 0, 11, 34856, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - In Combat - Cast \'Bloodburn\''), +(-(@CGUID+32), 0, 3, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 89, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Respawn - Start Random Movement'), +(-(@CGUID+32), 0, 4, 0, 58, 0, 100, 0, 6, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 17994, 20, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Waypoint Finished - Set Data 1 1'), +(-(@CGUID+32), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 1, 1815504, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodfalcon - On Data Set 1 1 - Start Waypoint'); + +DELETE FROM `creature_text` WHERE `CreatureID`=17994; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES +(17994, 0, 'Do as I say, Fly!', 12, 100, 25, 16783, 'Bloodwarder Falconer'), +(17994, 1, 'Kill $n!', 14, 100, 0, 17624, 'Bloodwarder Falconer'); + +-- Sunseeker Researcher +DELETE FROM `waypoints` WHERE `point_comment`='Sunseeker Researcher' AND `entry` BETWEEN 1842100 AND 1842101; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +-- Go +(1842100,1,158.66127,492.3432,-4.393021,NULL,'Sunseeker Researcher'), +(1842100,2,156.15257,489.36734,-4.8574643,NULL,'Sunseeker Researcher'), +(1842100,3,150.52888,483.8496,-4.5219054,NULL,'Sunseeker Researcher'), +(1842100,4,138.15617,471.4412,-1.7105865,NULL,'Sunseeker Researcher'), +(1842100,5,125.0919,458.282,-4.0026045,NULL,'Sunseeker Researcher'), +(1842100,6,121.70873,455.64517,-4.806524,NULL,'Sunseeker Researcher'), +-- Return +(1842101,1,130.02815,463.01624,-2.582287,NULL,'Sunseeker Researcher'), +(1842101,2,136.78746,469.63675,-1.535325,NULL,'Sunseeker Researcher'), +(1842101,3,143.60991,477.3061,-2.8752491,NULL,'Sunseeker Researcher'), +(1842101,4,151.29646,484.3168,-4.5590487,NULL,'Sunseeker Researcher'), +(1842101,5,157.28519,490.94662,-4.8154874,NULL,'Sunseeker Researcher'), +(1842101,6,158.17474,496.27377,-3.8682454,NULL,'Sunseeker Researcher'), +(1842101,7,159.99934,499.248,-2.3276987,NULL,'Sunseeker Researcher'), +(1842101,8,164.13808,501.65262,-2.169621,0.418879032135009765,'Sunseeker Researcher'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = -(@CGUID+58)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+58), 0, 0, 0, 0, 0, 100, 0, 0, 0, 30000, 30000, 0, 11, 34355, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - In Combat - Cast \'Poison Shield\''), +(-(@CGUID+58), 0, 1, 0, 0, 0, 70, 0, 2000, 2000, 10000, 14000, 0, 11, 34352, 0, 0, 0, 0, 0, 5, 20, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - In Combat - Cast \'Mind Shock\''), +(-(@CGUID+58), 0, 2, 0, 0, 0, 70, 0, 5000, 5000, 10000, 14000, 0, 11, 34353, 0, 0, 0, 0, 0, 5, 20, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - In Combat - Cast \'Frost Shock\''), +(-(@CGUID+58), 0, 3, 0, 0, 0, 70, 0, 8000, 8000, 10000, 14000, 0, 11, 34354, 0, 0, 0, 0, 0, 5, 20, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - In Combat - Cast \'Flame Shock\''), +(-(@CGUID+58), 0, 1001, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - On Respawn - Set Event Phase 1'), +(-(@CGUID+58), 0, 1002, 1003, 1, 1, 100, 0, 10000, 60000, 10000, 60000, 0, 53, 0, 1842100, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Out of Combat - Start Waypoint (Phase 1)'), +(-(@CGUID+58), 0, 1003, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Out of Combat - Set Event Phase 0 (Phase 1)'), +(-(@CGUID+58), 0, 1004, 0, 58, 0, 100, 0, 6, 1842100, 0, 0, 0, 80, 1842100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - On Waypoint Finished - Run Script'), +(-(@CGUID+58), 0, 1005, 0, 58, 0, 100, 0, 8, 1842101, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - On Waypoint Finished - Set Event Phase 1'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1842100); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1842100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 17975, 15, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Set Orientation Closest Creature \'High Botanist Freywinn\''), +(1842100, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Say Line 0'), +(1842100, 9, 2, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 17975, 15, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Set Orientation Closest Creature \'High Botanist Freywinn\''), +(1842100, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Say Line 0'), +(1842100, 9, 4, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Say Line 1'), +(1842100, 9, 5, 0, 0, 0, 100, 0, 2200, 2200, 0, 0, 0, 53, 0, 1842101, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Researcher - Actionlist - Start Waypoint'); + +DELETE FROM `creature_text` WHERE `CreatureID`=18421; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES +(18421, 0, 'High Botanist?', 12, 100, 6, 16942, 'Sunseeker Researcher'), +(18421, 1, '%s sighs.', 16, 100, 0, 16944, 'Sunseeker Researcher'); + +-- Sunseeker Channeler +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 13) AND (`SourceEntry` IN (34156, 34200, 34221)); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 34156, 0, 0, 31, 0, 3, 19555, 0, 0, 0, 0, '', 'Crystal Channel (34156) targets TK Atrium Channel Target'), +(13, 1, 34200, 0, 0, 31, 0, 3, 19511, 0, 0, 0, 0, '', 'Crystal Channel (34200) targets Nethervine Inciter'), +(13, 1, 34221, 0, 0, 31, 0, 3, 19555, 0, 0, 0, 0, '', 'Crystal Channel (34156) targets TK Atrium Channel Target'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 19505); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19505, 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Blessing\''), +(19505, 0, 1, 0, 0, 0, 100, 0, 12000, 15000, 30000, 34000, 0, 11, 34634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Aura\''), +(19505, 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 34637, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Soul Channel\''), +(19505, 0, 3, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 1 1 - Cast \'Crystal Channel\''), +(19505, 0, 4, 0, 38, 0, 100, 0, 2, 2, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 2 2 - Play Emote 11'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+91), -(@CGUID+94))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+91), 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Blessing\''), +(-(@CGUID+91), 0, 1, 0, 0, 0, 100, 0, 12000, 15000, 30000, 34000, 0, 11, 34634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Aura\''), +(-(@CGUID+91), 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 34637, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Soul Channel\''), +(-(@CGUID+91), 0, 3, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 1 1 - Cast \'Crystal Channel\''), +(-(@CGUID+91), 0, 4, 0, 38, 0, 100, 0, 2, 2, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 2 2 - Play Emote 11'), +(-(@CGUID+91), 0, 1001, 0, 1, 0, 100, 0, 0, 30000, 68000, 100000, 0, 80, 1950500, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Out of Combat - Run Script'), + +(-(@CGUID+94), 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Blessing\''), +(-(@CGUID+94), 0, 1, 0, 0, 0, 100, 0, 12000, 15000, 30000, 34000, 0, 11, 34634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Aura\''), +(-(@CGUID+94), 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 34637, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Soul Channel\''), +(-(@CGUID+94), 0, 3, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 1 1 - Cast \'Crystal Channel\''), +(-(@CGUID+94), 0, 4, 0, 38, 0, 100, 0, 2, 2, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 2 2 - Play Emote 11'), +(-(@CGUID+94), 0, 1001, 0, 1, 0, 100, 0, 0, 30000, 68000, 100000, 0, 80, 1950500, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Out of Combat - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1950500); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1950500, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Crystal Channel\''), +(1950500, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 26, 7, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Set Data 1 1'), +(1950500, 9, 2, 0, 0, 0, 100, 0, 12200, 12200, 0, 0, 0, 11, 34200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Crystal Channel\''), +(1950500, 9, 3, 0, 0, 0, 100, 0, 7100, 7100, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Play Emote 11'), +(1950500, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 26, 7, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Set Data 2 2'); + +DELETE FROM `waypoints` WHERE `point_comment`='Sunseeker Channeler' AND `entry` BETWEEN 1950500 AND 1950503; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +-- Left go +(1950500,1,-5.630207,580.3536,-17.832804,NULL,'Sunseeker Channeler'), +(1950500,2,-5.105361,573.27606,-17.917185,NULL,'Sunseeker Channeler'), +-- Left return +(1950501,1,-6.470564,582.909,-17.803976,NULL,'Sunseeker Channeler'), +(1950501,2,-9.860264,588.5002,-17.744814,2.115804195404052734,'Sunseeker Channeler'), +-- Right go +(1950502,1,17.958559,579.54846,-17.843096,NULL,'Sunseeker Channeler'), +(1950502,2,18.16002,574.67346,-17.937551,NULL,'Sunseeker Channeler'), +-- Right return +(1950503,1,18.734104,581.6368,-17.843632,NULL,'Sunseeker Channeler'), +(1950503,2,20.113728,588.08594,-17.759863,1.360049724578857421,'Sunseeker Channeler'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+90), -(@CGUID+95))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+90), 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Blessing\''), +(-(@CGUID+90), 0, 1, 0, 0, 0, 100, 0, 12000, 15000, 30000, 34000, 0, 11, 34634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Aura\''), +(-(@CGUID+90), 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 34637, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Soul Channel\''), +(-(@CGUID+90), 0, 3, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 1 1 - Cast \'Crystal Channel\''), +(-(@CGUID+90), 0, 4, 0, 38, 0, 100, 0, 2, 2, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 2 2 - Play Emote 11'), +(-(@CGUID+90), 0, 1001, 0, 1, 0, 100, 0, 0, 60000, 60000, 65000, 0, 80, 1950501, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Out of Combat - Run Script'), +(-(@CGUID+90), 0, 1002, 0, 58, 0, 100, 0, 2, 1950500, 0, 0, 0, 80, 1950502, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Waypoint Finished - Run Script'), + +(-(@CGUID+95), 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Blessing\''), +(-(@CGUID+95), 0, 1, 0, 0, 0, 100, 0, 12000, 15000, 30000, 34000, 0, 11, 34634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Sunseeker Aura\''), +(-(@CGUID+95), 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 34637, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - In Combat - Cast \'Soul Channel\''), +(-(@CGUID+95), 0, 3, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 1 1 - Cast \'Crystal Channel\''), +(-(@CGUID+95), 0, 4, 0, 38, 0, 100, 0, 2, 2, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Data Set 2 2 - Play Emote 11'), +(-(@CGUID+95), 0, 1001, 0, 1, 0, 100, 0, 0, 60000, 60000, 65000, 0, 80, 1950503, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Out of Combat - Run Script'), +(-(@CGUID+95), 0, 1002, 0, 58, 0, 100, 0, 2, 1950502, 0, 0, 0, 80, 1950504, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - On Waypoint Finished - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` IN (1950501, 1950502, 1950503, 1950504)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1950501, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34221, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Crystal Channel\''), +(1950501, 9, 1, 0, 0, 0, 100, 0, 25000, 25000, 0, 0, 0, 53, 0, 1950500, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Start Waypoint'), +(1950501, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 28, 34221, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Remove Aura \'Crystal Channel\''), + +(1950502, 9, 0, 0, 0, 0, 100, 0, 3600, 3600, 0, 0, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Sunseeker Blessing\''), +(1950502, 9, 1, 0, 0, 0, 100, 0, 1200, 1200, 0, 0, 0, 53, 0, 1950501, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Start Waypoint'), + +(1950503, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 11, 34221, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Crystal Channel\''), +(1950503, 9, 1, 0, 0, 0, 100, 0, 25000, 25000, 0, 0, 0, 53, 0, 1950502, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Start Waypoint'), +(1950503, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 28, 34221, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Remove Aura \'Crystal Channel\''), + +(1950504, 9, 0, 0, 0, 0, 100, 0, 3600, 3600, 0, 0, 0, 11, 34222, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Cast \'Sunseeker Blessing\''), +(1950504, 9, 1, 0, 0, 0, 100, 0, 1200, 1200, 0, 0, 0, 53, 0, 1950503, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Channeler - Actionlist - Start Waypoint'); + +-- Satyrs cast 34173 on self when hit by 34200 or 34222 +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 19511); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19511, 0, 0, 0, 0, 0, 100, 0, 7000, 10000, 20000, 24000, 0, 11, 34616, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - In Combat - Cast \'Deadly Poison\''), +(19511, 0, 1, 0, 0, 0, 100, 0, 1000, 3000, 30000, 34000, 0, 11, 34615, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - In Combat - Cast \'Mind-numbing Poison\''), +(19511, 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 15000, 24000, 0, 11, 30621, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - In Combat - Cast \'Kidney Shot\''), +(19511, 0, 3, 0, 8, 0, 100, 0, 34222, 0, 1200, 1200, 0, 11, 34173, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - On Spellhit \'Sunseeker Blessing\' - Cast \'Sunseeker Blessing\''), +(19511, 0, 4, 0, 8, 0, 100, 0, 34200, 0, 1200, 1200, 0, 11, 34173, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - On Spellhit \'Crystal Channel\' - Cast \'Sunseeker Blessing\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 19512); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19512, 0, 0, 0, 1, 0, 50, 0, 5000, 20000, 30000, 30000, 0, 11, 34156, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Reaper - Out of Combat - Cast \'Crystal Channel\''), +(19512, 0, 1, 0, 0, 0, 100, 0, 2000, 6000, 10000, 15000, 0, 11, 15284, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Reaper - In Combat - Cast \'Cleave\''), +(19512, 0, 2, 0, 8, 0, 100, 0, 34222, 0, 1200, 1200, 0, 11, 34173, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - On Spellhit \'Sunseeker Blessing\' - Cast \'Sunseeker Blessing\''), +(19512, 0, 3, 0, 8, 0, 100, 0, 34200, 0, 1200, 1200, 0, 11, 34173, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Nethervine Inciter - On Spellhit \'Crystal Channel\' - Cast \'Sunseeker Blessing\''); + +-- Dead Gene-Splicers +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 19507) AND (`source_type` = 0) AND (`id` IN (2)); + +DELETE FROM `creature_addon` WHERE `guid` IN (@CGUID+96 ,@CGUID+97 ,@CGUID+98 ,@CGUID+99 ,@CGUID+100,@CGUID+101,@CGUID+102,@CGUID+103,@CGUID+104,@CGUID+105,@CGUID+106,@CGUID+107); +INSERT INTO `creature_addon` (`guid`, `path_id`, `mount`, `bytes1`, `bytes2`, `emote`, `visibilityDistanceType`, `auras`) VALUES +(@CGUID+96 , 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+97 , 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+98 , 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+99 , 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+100, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+101, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+102, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+103, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+104, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+105, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+106, 0, 0, 7, 0, 65, 0, NULL), +(@CGUID+107, 0, 0, 7, 0, 65, 0, NULL); + +DELETE FROM `waypoints` WHERE `point_comment`='Bloodwarder Protector' AND `entry` BETWEEN 1799300 AND 1799313; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +-- @CGUID+19 +(1799300,1,5.7746835,59.15512,-5.463491,NULL,'Bloodwarder Protector'), +(1799300,2,3.708891,59.154926,-5.5573835,NULL,'Bloodwarder Protector'), +(1799300,3,1.6430982,59.15473,-5.651276,NULL,'Bloodwarder Protector'), +(1799300,4,0.29167658,59.154602,-5.6744356,NULL,'Bloodwarder Protector'), +(1799300,5,0.24531683,56.65638,-5.6514306,NULL,'Bloodwarder Protector'), +(1799300,6,0.13369003,50.64106,-5.650581,NULL,'Bloodwarder Protector'), +(1799300,7,0.07970157,47.731743,-5.508974,NULL,'Bloodwarder Protector'), +(1799300,8,0.06524,46.952442,-5.6114807,NULL,'Bloodwarder Protector'), +(1799300,9,2.616398,46.717686,-5.6120386,4.817108631134033,'Bloodwarder Protector'), +-- @CGUID+21 +(1799301,1,-8.353355,59.346046,-5.4726477,NULL,'Bloodwarder Protector'), +(1799301,2,-6.334253,59.407036,-5.5588064,NULL,'Bloodwarder Protector'), +(1799301,3,-4.31515,59.468025,-5.644965,NULL,'Bloodwarder Protector'), +(1799301,4,-2.545163,59.521492,-5.6595936,NULL,'Bloodwarder Protector'), +(1799301,5,-2.500346,57.27325,-5.653243,NULL,'Bloodwarder Protector'), +(1799301,6,-2.3677022,50.619164,-5.6505823,NULL,'Bloodwarder Protector'), +(1799301,7,-2.3097265,47.710815,-5.508974,NULL,'Bloodwarder Protector'), +(1799301,8,-2.28679,46.5602,-5.6193786,NULL,'Bloodwarder Protector'), +(1799301,9,-5.080652,46.597015,-5.6218123,4.817108631134033,'Bloodwarder Protector'), +-- @CGUID+22 +(1799302,1,11.51519,97.85166,-5.4874277,NULL,'Bloodwarder Protector'), +(1799302,2,8.475217,99.61279,-5.5540433,NULL,'Bloodwarder Protector'), +(1799302,3,5.435243,101.373924,-5.620659,NULL,'Bloodwarder Protector'), +(1799302,4,1.004796,103.94058,-5.6249914,NULL,'Bloodwarder Protector'), +(1799302,5,0.660349,104.14013,-5.6080203,NULL,'Bloodwarder Protector'), +(1799302,6,0.660349,104.14013,-5.6080203,NULL,'Bloodwarder Protector'), +(1799302,7,-0.022206,89.449295,-5.6595817,4.817108631134033,'Bloodwarder Protector'), +-- @CGUID+23 +(1799303,1,-13.440834,98.251755,-5.611049,NULL,'Bloodwarder Protector'), +(1799303,2,-9.540711,100.50602,-5.5573215,NULL,'Bloodwarder Protector'), +(1799303,3,-5.6405883,102.760284,-5.503594,NULL,'Bloodwarder Protector'), +(1799303,4,-3.2292671,104.15403,-5.527762,NULL,'Bloodwarder Protector'), +(1799303,5,-2.998425,104.28745,-5.6285086,NULL,'Bloodwarder Protector'), +(1799303,6,-2.998425,104.28745,-5.6285086,NULL,'Bloodwarder Protector'), +(1799303,7,-2.644504,89.42896,-5.659579,4.817108631134033,'Bloodwarder Protector'), +-- @CGUID+20 +(1799304,1,2.362805,147.59216,-5.540365,NULL,'Bloodwarder Protector'), +(1799304,2,1.4508866,134.90887,-5.5403733,NULL,'Bloodwarder Protector'), +(1799304,3,4.29729,131.94543,-5.540382,4.729842185974121093,'Bloodwarder Protector'), +-- @CGUID+24 +(1799305,1,-4.11074,148.59384,-5.5403647,NULL,'Bloodwarder Protector'), +(1799305,2,-2.929497,133.55092,-5.5403686,NULL,'Bloodwarder Protector'), +(1799305,3,-5.799148,131.35872,-5.5403614,4.729842185974121093,'Bloodwarder Protector'), +-- @CGUID+18 +(1799306,1 ,32.371803,285.14008,-5.3366117,NULL,'Bloodwarder Protector'), +(1799306,2 ,32.621803,287.14008,-5.3366117,NULL,'Bloodwarder Protector'), +(1799306,3 ,30.121803,287.14008,-5.3366117,NULL,'Bloodwarder Protector'), +(1799306,4 ,29.371803,287.14008,-5.3366117,NULL,'Bloodwarder Protector'), +(1799306,5 ,26.896982,287.0706,-4.1127753,NULL,'Bloodwarder Protector'), +(1799306,6 ,23.770767,286.69357,-1.7302599,NULL,'Bloodwarder Protector'), +(1799306,7 ,21.520767,286.69357,-1.7302599,NULL,'Bloodwarder Protector'), +(1799306,8 ,20.110651,286.30273,-1.8092577,NULL,'Bloodwarder Protector'), +(1799306,9 ,17.292475,284.6513,-1.4869981,NULL,'Bloodwarder Protector'), +(1799306,10,16.271194,284.02432,-1.5828131,3.071779489517211914,'Bloodwarder Protector'), +-- @CGUID+06 +(1799307,1,33.169704,289.29724,-5.1912584,NULL,'Bloodwarder Protector'), +(1799307,2,32.669704,289.29724,-5.1912584,NULL,'Bloodwarder Protector'), +(1799307,3,29.669704,289.29724,-5.1912584,NULL,'Bloodwarder Protector'), +(1799307,4,29.169704,289.29724,-5.1912584,NULL,'Bloodwarder Protector'), +(1799307,5,23.669704,289.54724,-1.6912587,NULL,'Bloodwarder Protector'), +(1799307,6,22.919704,289.54724,-1.6912587,NULL,'Bloodwarder Protector'), +(1799307,7,21.091858,289.26254,-1.8203477,NULL,'Bloodwarder Protector'), +(1799307,8,17.260101,291.32886,-1.6820656,NULL,'Bloodwarder Protector'), +(1799307,9,16.016445,291.94034,-1.5188627,3.071779489517211914,'Bloodwarder Protector'), +-- @CGUID+26 +(1799308,1,-2.520844,231.52274,-5.540374,NULL,'Bloodwarder Protector'), +(1799308,2,-2.5827603,229.59877,-5.270405,NULL,'Bloodwarder Protector'), +(1799308,3,-2.8327603,226.59877,-5.270405,NULL,'Bloodwarder Protector'), +(1799308,4,-3.3327603,216.09877,-5.270405,NULL,'Bloodwarder Protector'), +(1799308,5,-3.372449,213.47765,-5.5403595,NULL,'Bloodwarder Protector'), +(1799308,6,-7.061299,213.17163,-5.54035,4.729842185974121093,'Bloodwarder Protector'), +-- @CGUID+25 +(1799309,1,1.560038,230.91458,-5.540377,NULL,'Bloodwarder Protector'), +(1799309,2,1.6776221,229.287,-5.2722683,NULL,'Bloodwarder Protector'), +(1799309,3,1.6776221,226.287,-5.2722683,NULL,'Bloodwarder Protector'), +(1799309,4,1.6776221,215.787,-5.2722683,NULL,'Bloodwarder Protector'), +(1799309,5,1.471469,212.70377,-5.540376,NULL,'Bloodwarder Protector'), +(1799309,6,1.6818352,213.04912,-5.290371,NULL,'Bloodwarder Protector'), +(1799309,7,6.880586,213.50626,-5.5403757,4.729842185974121093,'Bloodwarder Protector'), +-- @CGUID+5 +(1799310,1,75.063675,286.6582,-5.2814426,NULL,'Bloodwarder Protector'), +(1799310,2,74.063675,286.6582,-5.2814426,NULL,'Bloodwarder Protector'), +(1799310,3,71.063675,286.4082,-5.5314426,NULL,'Bloodwarder Protector'), +(1799310,4,64.313675,285.9082,-5.5314426,NULL,'Bloodwarder Protector'), +(1799310,5,57.563675,285.1582,-5.5314426,NULL,'Bloodwarder Protector'), +(1799310,6,47.614925,284.43405,-5.670856,3.071779489517211914,'Bloodwarder Protector'), +-- @CGUID+7 +(1799311,1,74.85999,290.37897,-5.275877,NULL,'Bloodwarder Protector'), +(1799311,2,74.10999,290.37897,-5.275877,NULL,'Bloodwarder Protector'), +(1799311,3,71.10999,290.62897,-5.525877,NULL,'Bloodwarder Protector'), +(1799311,4,65.35999,290.12897,-5.525877,NULL,'Bloodwarder Protector'), +(1799311,5,63.359993,290.37897,-5.525877,NULL,'Bloodwarder Protector'), +(1799311,6,50.859993,291.87897,-5.525877,NULL,'Bloodwarder Protector'), +(1799311,7,47.417965,291.92233,-5.670514,3.071779489517211914,'Bloodwarder Protector'), +-- Suicider Left +(1799312,1,-161.20561,391.88025,-17.6449,NULL,'Bloodwarder Protector'), +(1799312,2,-162.18033,409.83426,-17.708645,NULL,'Bloodwarder Protector'), +(1799312,3,-162.64375,427.75867,-17.793741,NULL,'Bloodwarder Protector'), +-- Suicider Right +(1799313,1,-166.55185,392.07892,-17.679216,NULL,'Bloodwarder Protector'), +(1799313,2,-168.30185,403.07892,-17.679216,NULL,'Bloodwarder Protector'), +(1799313,3,-169.05185,407.07892,-17.429216,NULL,'Bloodwarder Protector'), +(1799313,4,-169.05185,409.32892,-17.429216,NULL,'Bloodwarder Protector'), +(1799313,5,-171.43996,422.89474,-17.744581,NULL,'Bloodwarder Protector'); + +-- @CGUID+35 +DELETE FROM `waypoints` WHERE `point_comment`='Bloodwarder Steward' AND `entry` BETWEEN 1840400 AND 1840401; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `point_comment`) VALUES +(1840400,1,77.12443,287.8911,-5.4754553,NULL,'Bloodwarder Steward'), +(1840400,2,77.08272,287.98236,-5.266903,NULL,'Bloodwarder Steward'), +(1840400,3,74.08272,287.98236,-5.266903,NULL,'Bloodwarder Steward'), +(1840400,4,71.08272,287.98236,-5.516903,NULL,'Bloodwarder Steward'), +(1840400,5,64.83272,287.98236,-5.516903,NULL,'Bloodwarder Steward'), +(1840400,6,60.832714,287.73236,-5.516903,NULL,'Bloodwarder Steward'), +-- Repeat +(1840401,1,50.185688,282.52002,-5.6333885,NULL,'Bloodwarder Steward'), +(1840401,2,50.01569,292.96957,-5.647004,NULL,'Bloodwarder Steward'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+19), -(@CGUID+21), -(@CGUID+22), -(@CGUID+23), -(@CGUID+20), -(@CGUID+24), -(@CGUID+26), -(@CGUID+25), -(@CGUID+6), -(@CGUID+18), -(@CGUID+5), -(@CGUID+7))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+19), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+19), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+19), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+19), 0, 1001, 0, 58, 0, 100, 1, 9, 1799300, 0, 0, 0, 80, 1799300, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+19), 0, 1002, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 53, 0, 1799300, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Start Waypoint'), +(-(@CGUID+19), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+21), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+21), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+21), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+21), 0, 1001, 0, 58, 0, 100, 1, 9, 1799301, 0, 0, 0, 80, 1799300, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+21), 0, 1002, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 53, 0, 1799301, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Start Waypoint'), +(-(@CGUID+21), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+22), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+22), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+22), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+22), 0, 1001, 0, 58, 0, 100, 1, 7, 1799302, 0, 0, 0, 80, 1799300, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+22), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799302, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+22), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), +(-(@CGUID+22), 0, 1004, 1005, 10, 0, 100, 1, 0, 45, 0, 0, 1, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+20, 17993, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-45 Range Out of Combat LoS - Set Data 1 1'), +(-(@CGUID+22), 0, 1005, 0, 61, 0, 100, 1, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+24, 17993, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-45 Range Out of Combat LoS - Set Data 1 1'), + +(-(@CGUID+23), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+23), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+23), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+23), 0, 1001, 0, 58, 0, 100, 1, 7, 1799303, 0, 0, 0, 80, 1799300, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+23), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799303, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+23), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+20), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+20), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+20), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+20), 0, 1001, 0, 58, 0, 100, 1, 3, 1799304, 0, 0, 0, 80, 1799301, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+20), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799304, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+20), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+24), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+24), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+24), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+24), 0, 1001, 0, 58, 0, 100, 1, 3, 1799305, 0, 0, 0, 80, 1799301, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+24), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799305, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+24), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +-- (-(@CGUID+26), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +-- (-(@CGUID+26), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +-- (-(@CGUID+26), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +-- (-(@CGUID+26), 0, 1001, 0, 58, 0, 100, 1, 6, 1799308, 0, 0, 0, 80, 1799301, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +-- (-(@CGUID+26), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799308, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +-- (-(@CGUID+26), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +-- (-(@CGUID+25), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +-- (-(@CGUID+25), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +-- (-(@CGUID+25), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +-- (-(@CGUID+25), 0, 1001, 0, 58, 0, 100, 1, 7, 1799309, 0, 0, 0, 80, 1799301, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +-- (-(@CGUID+25), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799309, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +-- (-(@CGUID+25), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+6), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+6), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+6), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+6), 0, 1001, 0, 58, 0, 100, 1, 9, 1799307, 0, 0, 0, 80, 1799302, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+6), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799307, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+6), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), +(-(@CGUID+6), 0, 1004, 1005, 10, 0, 100, 1, 0, 45, 0, 0, 1, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+35, 18404, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-45 Range Out of Combat LoS - Set Data 1 1'), +(-(@CGUID+6), 0, 1005, 1006, 61, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+5, 17993, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-45 Range Out of Combat LoS - Set Data 1 1'), +(-(@CGUID+6), 0, 1006, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+7, 17993, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-45 Range Out of Combat LoS - Set Data 1 1'), + +(-(@CGUID+18), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+18), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+18), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+18), 0, 1001, 0, 58, 0, 100, 1, 10, 1799306, 0, 0, 0, 80, 1799302, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+18), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799306, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+18), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+5), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+5), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+5), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+5), 0, 1001, 0, 58, 0, 100, 1, 6, 1799310, 0, 0, 0, 80, 1799302, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+5), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799310, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+5), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'), + +(-(@CGUID+7), 0, 0, 0, 0, 0, 100, 1, 2000, 4000, 0, 0, 0, 11, 34784, 0, 0, 0, 0, 0, 26, 20, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Intervene\' (No Repeat)'), +(-(@CGUID+7), 0, 1, 0, 0, 0, 100, 0, 4000, 6000, 9000, 11000, 0, 11, 29765, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Crystal Strike\''), +(-(@CGUID+7), 0, 2, 0, 0, 0, 100, 0, 8000, 10000, 15000, 20000, 0, 11, 35399, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - In Combat - Cast \'Spell Reflection\''), +(-(@CGUID+7), 0, 1001, 0, 58, 0, 100, 1, 7, 1799311, 0, 0, 0, 80, 1799302, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Run Script'), +(-(@CGUID+7), 0, 1002, 0, 38, 0, 100, 1, 1, 1, 0, 0, 0, 53, 0, 1799311, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+7), 0, 1003, 0, 11, 0, 100, 1, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Respawn - Set Sheath Unarmed'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` IN (1799300, 1799301, 1799302)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1799300, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 4.817108631134033, 'Bloodwarder Protector - Actionlist - Set Orientation 4.817108631134033'), +(1799300, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Home Position'), +(1799300, 9, 2, 0, 0, 0, 100, 0, 800, 800, 0, 0, 0, 5, 66, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Play Emote 66'), +(1799300, 9, 3, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 0, 40, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Sheath Melee'), +(1799300, 9, 4, 0, 0, 0, 100, 0, 1200, 1200, 0, 0, 0, 17, 333, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Emote State 333'), + +(1799301, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 4.729842185974121093, 'Bloodwarder Protector - Actionlist - Set Orientation 4.729842185974121093'), +(1799301, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Home Position'), +(1799301, 9, 2, 0, 0, 0, 100, 0, 800, 800, 0, 0, 0, 5, 66, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Play Emote 66'), +(1799301, 9, 3, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 0, 40, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Sheath Melee'), +(1799301, 9, 4, 0, 0, 0, 100, 0, 1200, 1200, 0, 0, 0, 17, 333, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Emote State 333'), + +(1799302, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.071779489517211914, 'Bloodwarder Protector - Actionlist - Set Orientation 3.071779489517211914'), +(1799302, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Home Position'), +(1799302, 9, 2, 0, 0, 0, 100, 0, 800, 800, 0, 0, 0, 5, 66, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Play Emote 66'), +(1799302, 9, 3, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 0, 40, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Sheath Melee'), +(1799302, 9, 4, 0, 0, 0, 100, 0, 1200, 1200, 0, 0, 0, 17, 333, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Actionlist - Set Emote State 333'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+41), -(@CGUID+40), -(@CGUID+39))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+41), 0, 0, 0, 0, 0, 100, 0, 2500, 3000, 12500, 13000, 0, 11, 34793, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - In Combat - Cast \'Arcane Blast\''), +(-(@CGUID+41), 0, 1, 0, 2, 0, 100, 1, 60, 80, 0, 0, 0, 11, 34791, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 60-80% Health - Cast \'Arcane Explosion\' (No Repeat)'), +(-(@CGUID+41), 0, 2, 0, 2, 0, 100, 1, 20, 40, 0, 0, 0, 11, 34785, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 20-40% Health - Cast \'Arcane Volley\' (No Repeat)'), +(-(@CGUID+41), 0, 1001, 1002, 10, 0, 100, 1, 0, 90, 0, 0, 1, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+22, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'), +(-(@CGUID+41), 0, 1002, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+23, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'), + +-- (-(@CGUID+40), 0, 0, 0, 0, 0, 100, 0, 2500, 3000, 12500, 13000, 0, 11, 34793, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - In Combat - Cast \'Arcane Blast\''), +-- (-(@CGUID+40), 0, 1, 0, 2, 0, 100, 1, 60, 80, 0, 0, 0, 11, 34791, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 60-80% Health - Cast \'Arcane Explosion\' (No Repeat)'), +-- (-(@CGUID+40), 0, 2, 0, 2, 0, 100, 1, 20, 40, 0, 0, 0, 11, 34785, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 20-40% Health - Cast \'Arcane Volley\' (No Repeat)'), +-- (-(@CGUID+40), 0, 1001, 1002, 10, 0, 100, 1, 0, 90, 0, 0, 1, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+25, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'), +-- (-(@CGUID+40), 0, 1002, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+26, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'), + +(-(@CGUID+39), 0, 0, 0, 0, 0, 100, 0, 2500, 3000, 12500, 13000, 0, 11, 34793, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - In Combat - Cast \'Arcane Blast\''), +(-(@CGUID+39), 0, 1, 0, 2, 0, 100, 1, 60, 80, 0, 0, 0, 11, 34791, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 60-80% Health - Cast \'Arcane Explosion\' (No Repeat)'), +(-(@CGUID+39), 0, 2, 0, 2, 0, 100, 1, 20, 40, 0, 0, 0, 11, 34785, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Between 20-40% Health - Cast \'Arcane Volley\' (No Repeat)'), +(-(@CGUID+39), 0, 1001, 1002, 10, 0, 100, 1, 0, 90, 0, 0, 1, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+6, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'), +(-(@CGUID+39), 0, 1002, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+18, 17993, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Within 0-90 Range Out of Combat LoS - Set Data 1 1'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = -(@CGUID+35)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-(@CGUID+35), 0, 0, 0, 0, 0, 100, 0, 4000, 6000, 15000, 20000, 0, 11, 34821, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Steward - In Combat - Cast \'Arcane Flurry\''), +(-(@CGUID+35), 0, 1001, 0, 38, 0, 100, 0, 1, 1, 0, 0, 0, 53, 0, 1840400, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Steward - On Data Set 1 1 - Start Waypoint'), +(-(@CGUID+35), 0, 1002, 1003, 58, 0, 100, 0, 6, 1840400, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Steward - On Waypoint Finished - Play Emote 5'), +(-(@CGUID+35), 0, 1003, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 67, 1, 2400, 2400, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Steward - On Waypoint Finished - Create Timed Event'), +(-(@CGUID+35), 0, 1004, 0, 59, 0, 100, 0, 1, 0, 0, 0, 0, 53, 0, 1840401, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Steward - On Timed Event 0 Triggered - Start Waypoint'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` IN (-(@CGUID+14), -(@CGUID+15))); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +-- Suicider Left +(-(@CGUID+14), 0, 0, 1, 10, 0, 100, 1, 0, 90, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-90 Range Out of Combat LoS - Say Line 0 (No Repeat)'), +(-(@CGUID+14), 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 53, 1, 1799312, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-90 Range Out of Combat LoS - Start Waypoint'), +(-(@CGUID+14), 0, 2, 0, 58, 0, 100, 0, 3, 1799312, 0, 0, 0, 11, 7, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Cast \'Suicide\''), +(-(@CGUID+14), 0, 3, 4, 11, 0, 100, 512, 0, 0, 0, 0, 0, 18, 33555200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Initialize - Set Flags Immune To Players & Immune To NPC\'s & Not Selectable'), +(-(@CGUID+14), 0, 4, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 121, 90, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Initialize - Set Sight Distance'), +-- Suicider Right +(-(@CGUID+15), 0, 0, 1, 10, 0, 100, 1, 0, 90, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-90 Range Out of Combat LoS - Say Line 1 (No Repeat)'), +(-(@CGUID+15), 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 53, 1, 1799313, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - Within 0-90 Range Out of Combat LoS - Start Waypoint'), +(-(@CGUID+15), 0, 2, 0, 58, 0, 100, 0, 5, 1799313, 0, 0, 0, 11, 7, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Waypoint Finished - Cast \'Suicide\''), +(-(@CGUID+15), 0, 3, 4, 11, 0, 100, 512, 0, 0, 0, 0, 0, 18, 33555200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Initialize - Set Flags Immune To Players & Immune To NPC\'s & Not Selectable'), +(-(@CGUID+15), 0, 4, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 121, 90, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Bloodwarder Protector - On Initialize - Set Sight Distance'); + +-- Addons for EmoteState and StandStates +DELETE FROM `creature_addon` WHERE `guid` IN (@CGUID+45,@CGUID+48,@CGUID+50,@CGUID+53,@CGUID+55,@CGUID+57,@CGUID+59,@CGUID+60,@CGUID+63,@CGUID+64,@CGUID+83,@CGUID+87,@CGUID+108,@CGUID+109,@CGUID+110,@CGUID+113,@CGUID+114,@CGUID+116,@CGUID+117,@CGUID+118,@CGUID+119,@CGUID+178); +INSERT INTO `creature_addon` (`guid`, `path_id`, `mount`, `bytes1`, `bytes2`, `emote`, `visibilityDistanceType`, `auras`) VALUES +(@CGUID+45 , 0, 0, 8, 0, 0, 0, NULL), +(@CGUID+48 , 0, 0, 8, 0, 0, 0, NULL), +(@CGUID+50 , 0, 0, 0, 0, 69, 0, NULL), +(@CGUID+53 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+55 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+57 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+59 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+60 , 0, 0, 8, 0, 0, 0, NULL), +(@CGUID+63 , 0, 0, 8, 0, 0, 0, NULL), +(@CGUID+64 , 0, 0, 8, 0, 0, 0, NULL), +(@CGUID+83 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+87 , 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+108, 0, 0, 0, 0, 69, 0, NULL), +(@CGUID+109, 0, 0, 0, 0, 69, 0, NULL), +(@CGUID+110, 0, 0, 0, 0, 69, 0, NULL), +(@CGUID+113, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+114, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+116, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+117, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+118, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+119, 0, 0, 0, 1, 69, 0, NULL), +(@CGUID+178, 0, 0, 8, 0, 0, 0, NULL); + +-- Addons for Bytes2 +DELETE FROM `creature_template_addon` WHERE (`entry` IN (17993,17994,18404,18420,18421,18422,19486,19508,19509,19511,19512,19843)); +INSERT INTO `creature_template_addon` (`entry`, `path_id`, `mount`, `bytes1`, `bytes2`, `emote`, `visibilityDistanceType`, `auras`) VALUES +(17993, 0, 0, 0, 1, 0, 0, ''), +(17994, 0, 0, 0, 1, 0, 0, ''), +(18404, 0, 0, 0, 1, 0, 0, ''), +(18420, 0, 0, 0, 1, 0, 0, ''), +(18421, 0, 0, 0, 1, 0, 0, ''), +(18422, 0, 0, 0, 1, 0, 0, ''), +(19486, 0, 0, 0, 1, 0, 0, ''), +(19508, 0, 0, 0, 1, 0, 0, ''), +(19509, 0, 0, 0, 1, 0, 0, ''), +(19511, 0, 0, 0, 1, 0, 0, ''), +(19512, 0, 0, 0, 1, 0, 0, ''), +(19843, 0, 0, 0, 1, 0, 0, ''); + +-- Static Formations +DELETE FROM `creature_formations` WHERE `groupAI`=3 AND `leaderGUID` IN (@CGUID+05,@CGUID+06,@CGUID+08,@CGUID+10,@CGUID+12,@CGUID+16,@CGUID+19,@CGUID+20,@CGUID+22,@CGUID+27,@CGUID+28,@CGUID+43,@CGUID+44,@CGUID+45,@CGUID+46,@CGUID+51,@CGUID+52,@CGUID+53,@CGUID+54,@CGUID+55,@CGUID+59,@CGUID+65,@CGUID+66,@CGUID+91,@CGUID+92,@CGUID+108,@CGUID+109,@CGUID+110,@CGUID+111,@CGUID+120,@CGUID+126,@CGUID+133,@CGUID+135,@CGUID+136,@CGUID+146,@CGUID+156,@CGUID+166) AND `memberGUID` IN (@CGUID+19,@CGUID+21,@CGUID+22,@CGUID+23,@CGUID+20,@CGUID+24,@CGUID+44,@CGUID+50,@CGUID+176,@CGUID+45,@CGUID+47,@CGUID+177,@CGUID+43,@CGUID+48,@CGUID+179,@CGUID+46,@CGUID+49,@CGUID+178,@CGUID+27,@CGUID+34,@CGUID+31,@CGUID+29,@CGUID+06,@CGUID+18,@CGUID+05,@CGUID+07,@CGUID+35,@CGUID+28,@CGUID+30,@CGUID+32,@CGUID+33,@CGUID+08,@CGUID+09,@CGUID+36,@CGUID+10,@CGUID+11,@CGUID+37,@CGUID+12,@CGUID+13,@CGUID+38,@CGUID+53,@CGUID+143,@CGUID+60,@CGUID+83,@CGUID+54,@CGUID+84,@CGUID+87,@CGUID+146,@CGUID+63,@CGUID+57,@CGUID+88,@CGUID+86,@CGUID+55,@CGUID+147,@CGUID+64,@CGUID+56,@CGUID+85,@CGUID+51,@CGUID+68,@CGUID+69,@CGUID+67,@CGUID+72,@CGUID+70,@CGUID+75,@CGUID+71,@CGUID+73,@CGUID+59,@CGUID+89,@CGUID+66,@CGUID+149,@CGUID+52,@CGUID+74,@CGUID+80,@CGUID+76,@CGUID+78,@CGUID+77,@CGUID+79,@CGUID+81,@CGUID+82,@CGUID+91,@CGUID+93,@CGUID+92,@CGUID+94,@CGUID+111,@CGUID+112,@CGUID+115,@CGUID+120,@CGUID+125,@CGUID+130,@CGUID+131,@CGUID+126,@CGUID+132,@CGUID+129,@CGUID+127,@CGUID+110,@CGUID+154,@CGUID+118,@CGUID+119,@CGUID+155,@CGUID+109,@CGUID+113,@CGUID+117,@CGUID+151,@CGUID+150,@CGUID+108,@CGUID+152,@CGUID+153,@CGUID+114,@CGUID+116,@CGUID+16,@CGUID+17,@CGUID+136,@CGUID+186,@CGUID+138,@CGUID+187,@CGUID+135,@CGUID+137,@CGUID+185,@CGUID+184,@CGUID+133,@CGUID+183,@CGUID+182,@CGUID+134,@CGUID+65,@CGUID+148,@CGUID+166,@CGUID+168,@CGUID+170,@CGUID+171,@CGUID+172,@CGUID+173,@CGUID+174,@CGUID+175,@CGUID+169,@CGUID+167,@CGUID+156,@CGUID+161,@CGUID+160,@CGUID+164,@CGUID+158,@CGUID+157,@CGUID+162,@CGUID+163,@CGUID+165,@CGUID+159); +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(@CGUID+19, @CGUID+19, 0, 0, 3), +(@CGUID+19, @CGUID+21, 0, 0, 3), +(@CGUID+22, @CGUID+22, 0, 0, 3), +(@CGUID+22, @CGUID+23, 0, 0, 3), +(@CGUID+20, @CGUID+20, 0, 0, 3), +(@CGUID+20, @CGUID+24, 0, 0, 3), +(@CGUID+44, @CGUID+44, 0, 0, 3), +(@CGUID+44, @CGUID+50, 0, 0, 3), +(@CGUID+44, @CGUID+176, 0, 0, 3), +(@CGUID+45, @CGUID+45, 0, 0, 3), +(@CGUID+45, @CGUID+47, 0, 0, 3), +(@CGUID+45, @CGUID+177, 0, 0, 3), +(@CGUID+43, @CGUID+43, 0, 0, 3), +(@CGUID+43, @CGUID+48, 0, 0, 3), +(@CGUID+43, @CGUID+179, 0, 0, 3), +(@CGUID+46, @CGUID+46, 0, 0, 3), +(@CGUID+46, @CGUID+49, 0, 0, 3), +(@CGUID+46, @CGUID+178, 0, 0, 3), +(@CGUID+27, @CGUID+27, 0, 0, 3), +(@CGUID+27, @CGUID+34, 0, 0, 3), +(@CGUID+27, @CGUID+31, 0, 0, 3), +(@CGUID+27, @CGUID+29, 0, 0, 3), +(@CGUID+06, @CGUID+06, 0, 0, 3), +(@CGUID+06, @CGUID+18, 0, 0, 3), +(@CGUID+05, @CGUID+05, 0, 0, 3), +(@CGUID+05, @CGUID+07, 0, 0, 3), +(@CGUID+05, @CGUID+35, 0, 0, 3), +(@CGUID+28, @CGUID+28, 0, 0, 3), +(@CGUID+28, @CGUID+30, 0, 0, 3), +(@CGUID+28, @CGUID+32, 0, 0, 3), +(@CGUID+28, @CGUID+33, 0, 0, 3), +(@CGUID+08, @CGUID+08, 0, 0, 3), +(@CGUID+08, @CGUID+09, 0, 0, 3), +(@CGUID+08, @CGUID+36, 0, 0, 3), +(@CGUID+10, @CGUID+10, 0, 0, 3), +(@CGUID+10, @CGUID+11, 0, 0, 3), +(@CGUID+10, @CGUID+37, 0, 0, 3), +(@CGUID+12, @CGUID+12, 0, 0, 3), +(@CGUID+12, @CGUID+13, 0, 0, 3), +(@CGUID+12, @CGUID+38, 0, 0, 3), +(@CGUID+53, @CGUID+53, 0, 0, 3), +(@CGUID+53, @CGUID+143, 0, 0, 3), +(@CGUID+53, @CGUID+60, 0, 0, 3), +(@CGUID+53, @CGUID+83, 0, 0, 3), +(@CGUID+54, @CGUID+54, 0, 0, 3), +(@CGUID+54, @CGUID+84, 0, 0, 3), +(@CGUID+54, @CGUID+87, 0, 0, 3), +(@CGUID+146, @CGUID+146, 0, 0, 3), +(@CGUID+146, @CGUID+63, 0, 0, 3), +(@CGUID+146, @CGUID+57, 0, 0, 3), +(@CGUID+146, @CGUID+88, 0, 0, 3), +(@CGUID+146, @CGUID+86, 0, 0, 3), +(@CGUID+55, @CGUID+55, 0, 0, 3), +(@CGUID+55, @CGUID+147, 0, 0, 3), +(@CGUID+55, @CGUID+64, 0, 0, 3), +(@CGUID+55, @CGUID+56, 0, 0, 3), +(@CGUID+55, @CGUID+85, 0, 0, 3), +(@CGUID+51, @CGUID+51, 0, 0, 3), +(@CGUID+51, @CGUID+68, 0, 0, 3), +(@CGUID+51, @CGUID+69, 0, 0, 3), +(@CGUID+51, @CGUID+67, 0, 0, 3), +(@CGUID+51, @CGUID+72, 0, 0, 3), +(@CGUID+51, @CGUID+70, 0, 0, 3), +(@CGUID+51, @CGUID+75, 0, 0, 3), +(@CGUID+51, @CGUID+71, 0, 0, 3), +(@CGUID+51, @CGUID+73, 0, 0, 3), +(@CGUID+59, @CGUID+59, 0, 0, 3), +(@CGUID+59, @CGUID+89, 0, 0, 3), +(@CGUID+66, @CGUID+66, 0, 0, 3), +(@CGUID+66, @CGUID+149, 0, 0, 3), +(@CGUID+52, @CGUID+52, 0, 0, 3), +(@CGUID+52, @CGUID+74, 0, 0, 3), +(@CGUID+52, @CGUID+80, 0, 0, 3), +(@CGUID+52, @CGUID+76, 0, 0, 3), +(@CGUID+52, @CGUID+78, 0, 0, 3), +(@CGUID+52, @CGUID+77, 0, 0, 3), +(@CGUID+52, @CGUID+79, 0, 0, 3), +(@CGUID+52, @CGUID+81, 0, 0, 3), +(@CGUID+52, @CGUID+82, 0, 0, 3), +(@CGUID+91, @CGUID+91, 0, 0, 3), +(@CGUID+91, @CGUID+93, 0, 0, 3), +(@CGUID+92, @CGUID+92, 0, 0, 3), +(@CGUID+92, @CGUID+94, 0, 0, 3), +(@CGUID+111, @CGUID+111, 0, 0, 3), +(@CGUID+111, @CGUID+112, 0, 0, 3), +(@CGUID+111, @CGUID+115, 0, 0, 3), +(@CGUID+120, @CGUID+120, 0, 0, 3), +(@CGUID+120, @CGUID+125, 0, 0, 3), +(@CGUID+120, @CGUID+130, 0, 0, 3), +(@CGUID+120, @CGUID+131, 0, 0, 3), +(@CGUID+126, @CGUID+126, 0, 0, 3), +(@CGUID+126, @CGUID+132, 0, 0, 3), +(@CGUID+126, @CGUID+129, 0, 0, 3), +(@CGUID+126, @CGUID+127, 0, 0, 3), +(@CGUID+110, @CGUID+110, 0, 0, 3), +(@CGUID+110, @CGUID+154, 0, 0, 3), +(@CGUID+110, @CGUID+118, 0, 0, 3), +(@CGUID+110, @CGUID+119, 0, 0, 3), +(@CGUID+110, @CGUID+155, 0, 0, 3), +(@CGUID+109, @CGUID+109, 0, 0, 3), +(@CGUID+109, @CGUID+113, 0, 0, 3), +(@CGUID+109, @CGUID+117, 0, 0, 3), +(@CGUID+109, @CGUID+151, 0, 0, 3), +(@CGUID+109, @CGUID+150, 0, 0, 3), +(@CGUID+108, @CGUID+108, 0, 0, 3), +(@CGUID+108, @CGUID+152, 0, 0, 3), +(@CGUID+108, @CGUID+153, 0, 0, 3), +(@CGUID+108, @CGUID+114, 0, 0, 3), +(@CGUID+108, @CGUID+116, 0, 0, 3), +(@CGUID+16, @CGUID+16, 0, 0, 3), +(@CGUID+16, @CGUID+17, 0, 0, 3), +(@CGUID+136, @CGUID+136, 0, 0, 3), +(@CGUID+136, @CGUID+186, 0, 0, 3), +(@CGUID+136, @CGUID+138, 0, 0, 3), +(@CGUID+136, @CGUID+187, 0, 0, 3), +(@CGUID+135, @CGUID+135, 0, 0, 3), +(@CGUID+135, @CGUID+137, 0, 0, 3), +(@CGUID+135, @CGUID+185, 0, 0, 3), +(@CGUID+135, @CGUID+184, 0, 0, 3), +(@CGUID+133, @CGUID+133, 0, 0, 3), +(@CGUID+133, @CGUID+183, 0, 0, 3), +(@CGUID+133, @CGUID+182, 0, 0, 3), +(@CGUID+133, @CGUID+134, 0, 0, 3), +(@CGUID+65, @CGUID+65, 0, 0, 3), +(@CGUID+65, @CGUID+148, 0, 0, 3), +(@CGUID+166, @CGUID+166, 0, 0, 3), +(@CGUID+166, @CGUID+168, 0, 0, 3), +(@CGUID+166, @CGUID+170, 0, 0, 3), +(@CGUID+166, @CGUID+171, 0, 0, 3), +(@CGUID+166, @CGUID+172, 0, 0, 3), +(@CGUID+166, @CGUID+173, 0, 0, 3), +(@CGUID+166, @CGUID+174, 0, 0, 3), +(@CGUID+166, @CGUID+175, 0, 0, 3), +(@CGUID+166, @CGUID+169, 0, 0, 3), +(@CGUID+166, @CGUID+167, 0, 0, 3), +(@CGUID+156, @CGUID+156, 0, 0, 3), +(@CGUID+156, @CGUID+161, 0, 0, 3), +(@CGUID+156, @CGUID+160, 0, 0, 3), +(@CGUID+156, @CGUID+164, 0, 0, 3), +(@CGUID+156, @CGUID+158, 0, 0, 3), +(@CGUID+156, @CGUID+157, 0, 0, 3), +(@CGUID+156, @CGUID+162, 0, 0, 3), +(@CGUID+156, @CGUID+163, 0, 0, 3), +(@CGUID+156, @CGUID+165, 0, 0, 3), +(@CGUID+156, @CGUID+159, 0, 0, 3); + +-- Gameobjects +SET @OGUID := 105183; +SET @POOL := 8353; + +DELETE FROM `gameobject` WHERE `map`=553 AND `id` IN (181270, 181279, 181271, 181277) AND `guid` BETWEEN @OGUID+0 AND @OGUID+12; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `ScriptName`, `VerifiedBuild`) VALUES +(@OGUID+0 , 181270, 553, 3847, 3847, 3, 1, 41.4327, 356.078, -26.0174, 1.8675, 0, 0, 0.803857, 0.594823, 86400, 255, 1, '', 48001), +(@OGUID+1 , 181270, 553, 3847, 3847, 3, 1, 9.8574, 418.206, -27.5923, 5.20108, 0, 0, -0.515038, 0.857168, 86400, 255, 1, '', 48001), +(@OGUID+2 , 181270, 553, 3847, 3847, 3, 1, 63.4501, 427.082, -25.5068, 0.541051, 0, 0, 0.267238, 0.963631, 86400, 255, 1, '', 48001), +(@OGUID+3 , 181279, 553, 3847, 3847, 3, 1, -0.459927, 256.711, -4.35613, 3.82227, 0, 0, -0.942641, 0.333808, 86400, 255, 1, '', 48001), +(@OGUID+4 , 181271, 553, 3847, 3847, 3, 1, 0.634392, 165.962, -3.67233, 3.76991, 0, 0, -0.951056, 0.309017, 86400, 255, 1, '', 48001), +(@OGUID+5 , 181270, 553, 3847, 3847, 3, 1, 93.4825, 371.747, -27.3115, 4.92183, 0, 0, -0.62932, 0.777146, 86400, 255, 1, '', 48001), +(@OGUID+6 , 181270, 553, 3847, 3847, 3, 1, 173.042, 388.688, -3.90029, 4.79966, 0, 0, -0.67559, 0.737278, 86400, 255, 1, '', 48001), +(@OGUID+7 , 181271, 553, 3847, 3847, 3, 1, 155.018, 409.847, -3.52534, 6.19592, 0, 0, -0.0436192, 0.999048, 86400, 255, 1, '', 48001), +(@OGUID+8 , 181279, 553, 3847, 3847, 3, 1, 115.816, 450.617, -3.82386, 0.279252, 0, 0, 0.139173, 0.990268, 86400, 255, 1, '', 48001), +(@OGUID+9 , 181271, 553, 3847, 3847, 3, 1, -22.2003, 502.644, -4.84003, 0.314158, 0, 0, 0.156434, 0.987688, 86400, 255, 1, '', 48001), +(@OGUID+10, 181277, 553, 3847, 3847, 3, 1, -165.293, 495.911, -15.0749, 4.39823, 0, 0, -0.809016, 0.587786, 86400, 255, 1, '', 48001), +(@OGUID+11, 181270, 553, 3847, 3847, 3, 1, -154.192, 523.518, -16.0193, 3.35105, 0, 0, -0.994521, 0.104536, 86400, 255, 1, '', 48001), +(@OGUID+12, 181279, 553, 3847, 3847, 3, 1, 169.234, 504.449, 0.050639, 2.32129, 0, 0, 0.91706, 0.39875, 86400, 255, 1, '', 48001); + +DELETE FROM `pool_gameobject` WHERE `guid` IN (@OGUID+0,@OGUID+1,@OGUID+2,@OGUID+5) AND `pool_entry`=@POOL AND `description`='Felweed - The Botanica'; +INSERT INTO `pool_gameobject` (`guid`, `pool_entry`, `chance`, `description`) VALUES +(@OGUID+0, @POOL, 0, 'Felweed - The Botanica'), +(@OGUID+1, @POOL, 0, 'Felweed - The Botanica'), +(@OGUID+2, @POOL, 0, 'Felweed - The Botanica'), +(@OGUID+5, @POOL, 0, 'Felweed - The Botanica'); + +DELETE FROM `pool_template` WHERE `entry`=@POOL AND `description`='The Botanica - Felweed'; +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@POOL, 1, 'The Botanica - Felweed'); From da6e21f740f7df7bb6fddbc829b86101c88e0518 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 14:03:32 -0300 Subject: [PATCH 31/87] refactor(Scripts/Karazhan): Move Barnes/Medivh/Arcanagos texts to the DB (#14949) Co-authored-by: lee --- .../rev_1676128806964865300.sql | 19 ++++++ .../EasternKingdoms/Karazhan/karazhan.cpp | 58 +++++++++---------- 2 files changed, 48 insertions(+), 29 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1676128806964865300.sql diff --git a/data/sql/updates/pending_db_world/rev_1676128806964865300.sql b/data/sql/updates/pending_db_world/rev_1676128806964865300.sql new file mode 100644 index 000000000..6b617df69 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676128806964865300.sql @@ -0,0 +1,19 @@ +-- +-- Karazhan Image of Medivh (17651) and Image of Arcanagos (17652) missing creature text +DELETE FROM `creature_text` WHERE `CreatureID` IN (17651,17652); +INSERT INTO `creature_text`(`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(17651, 0, 0, "You've got my attention, dragon. You'll find I'm not as easily scared as the villagers below.", 14, 0, 100, 0, 0, 0, 14295, 0, 'Image of Medivh'), +(17651, 1, 0, "You dare challenge me at my own dwelling? Your arrogance is astounding, even for a dragon!", 14, 0, 100, 0, 0, 0, 14297, 0, 'Image of Medivh'), +(17651, 2, 0, "I do not know what you speak of, dragon... but I will not be bullied by this display of insolence. I'll leave Karazhan when it suits me!", 14, 0, 100, 0, 0, 0, 14299, 0, 'Image of Medivh'), +(17651, 3, 0, "%s begins to cast a spell of great power, weaving his own essence into the magic.", 16, 0, 100, 0, 0, 0, 14308, 0, 'Image of Medivh'), +(17651, 4, 0, "He should not have angered me. I must go... recover my strength now...", 12, 0, 100, 0, 0, 0, 14316, 0, 'Image of Medivh'), + +(17652, 0, 0, "Your dabbling in the arcane has gone too far, Medivh. You've attracted the attention of powers beyond your understanding. You must leave Karazhan at once!", 14, 0, 100, 0, 0, 0, 14296, 0, 'Image of Arcanagos'), +(17652, 1, 0, "A dark power seeks to use you, Medivh! If you stay, dire days will follow. You must hurry, we don't have much time!", 14, 0, 100, 0, 0, 0, 14298, 0, 'Image of Arcanagos'), +(17652, 2, 0, "You leave me no alternative. I will stop you by force if you won't listen to reason!", 14, 0, 100, 0, 0, 0, 14300, 0, 'Image of Arcanagos'), +(17652, 3, 0, "What have you done, wizard? This cannot be! I'm burning from... within!", 14, 0, 100, 0, 0, 0, 14294, 0, 'Image of Arcanagos'); + +DELETE FROM `gossip_menu_option` WHERE `MenuID` IN (7421, 7422) AND `OptionID`=0; +INSERT INTO `gossip_menu_option`(`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(7421, 0, 0, 'I\'m not an actor.', 14052, 0, 0, 0, 0, 0, 0, NULL, 0, 0), +(7422, 0, 0, 'Ok, I\'ll give it a try, then.', 14054, 0, 0, 0, 0, 0, 0, NULL, 0, 0); diff --git a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp index 38ca0452d..78e941fe1 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp @@ -61,16 +61,13 @@ enum Creatures # npc_barnesAI ######*/ -#define GOSSIP_READY "I'm not an actor." - -#define SAY_READY "Splendid, I'm going to get the audience ready. Break a leg!" -#define SAY_OZ_INTRO1 "Finally, everything is in place. Are you ready for your big stage debut?" -#define OZ_GOSSIP1 "I'm not an actor." -#define SAY_OZ_INTRO2 "Don't worry, you'll be fine. You look like a natural!" -#define OZ_GOSSIP2 "Ok, I'll give it a try, then." - -#define SAY_RAJ_INTRO1 "The romantic plays are really tough, but you'll do better this time. You have TALENT. Ready?" -#define RAJ_GOSSIP1 "I've never been more ready." +enum Misc +{ + OZ_GOSSIP1_MID = 7421, // I'm not an actor. + OZ_GOSSIP1_OID = 0, + OZ_GOSSIP2_MID = 7422, // Ok, I'll give it a try, then. + OZ_GOSSIP2_OID = 0, +}; #define OZ_GM_GOSSIP1 "[GM] Change event to EVENT_OZ" #define OZ_GM_GOSSIP2 "[GM] Change event to EVENT_HOOD" @@ -343,7 +340,7 @@ public: switch (action) { case GOSSIP_ACTION_INFO_DEF+1: - AddGossipItemFor(player, GOSSIP_ICON_CHAT, OZ_GOSSIP2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); + AddGossipItemFor(player, OZ_GOSSIP2_MID, OZ_GOSSIP2_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); SendGossipMenuFor(player, 8971, creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+2: @@ -374,7 +371,7 @@ public: // Check for death of Moroes and if opera event is not done already if (instance->GetBossState(DATA_MOROES) == DONE && instance->GetBossState(DATA_OPERA_PERFORMANCE) != DONE) { - AddGossipItemFor(player, GOSSIP_ICON_CHAT, OZ_GOSSIP1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, OZ_GOSSIP1_MID, OZ_GOSSIP1_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); if (player->IsGameMaster()) { @@ -409,15 +406,18 @@ public: # npc_image_of_medivh ####*/ -#define SAY_DIALOG_MEDIVH_1 "You've got my attention, dragon. You'll find I'm not as easily scared as the villagers below." -#define SAY_DIALOG_ARCANAGOS_2 "Your dabbling in the arcane has gone too far, Medivh. You've attracted the attention of powers beyond your understanding. You must leave Karazhan at once!" -#define SAY_DIALOG_MEDIVH_3 "You dare challenge me at my own dwelling? Your arrogance is astounding, even for a dragon!" -#define SAY_DIALOG_ARCANAGOS_4 "A dark power seeks to use you, Medivh! If you stay, dire days will follow. You must hurry, we don't have much time!" -#define SAY_DIALOG_MEDIVH_5 "I do not know what you speak of, dragon... but I will not be bullied by this display of insolence. I'll leave Karazhan when it suits me!" -#define SAY_DIALOG_ARCANAGOS_6 "You leave me no alternative. I will stop you by force if you won't listen to reason!" -#define EMOTE_DIALOG_MEDIVH_7 "begins to cast a spell of great power, weaving his own essence into the magic." -#define SAY_DIALOG_ARCANAGOS_8 "What have you done, wizard? This cannot be! I'm burning from... within!" -#define SAY_DIALOG_MEDIVH_9 "He should not have angered me. I must go... recover my strength now..." +enum MedivhTexts +{ + SAY_DIALOG_MEDIVH_1 = 0, + SAY_DIALOG_ARCANAGOS_2 = 0, + SAY_DIALOG_MEDIVH_3 = 1, + SAY_DIALOG_ARCANAGOS_4 = 1, + SAY_DIALOG_MEDIVH_5 = 2, + SAY_DIALOG_ARCANAGOS_6 = 2, + EMOTE_DIALOG_MEDIVH_7 = 3, + SAY_DIALOG_ARCANAGOS_8 = 3, + SAY_DIALOG_MEDIVH_9 = 4 +}; //static float MedivPos[4] = {-11161.49f, -1902.24f, 91.48f, 1.94f}; static float ArcanagosPos[4] = {-11169.75f, -1881.48f, 107.39f, 4.83f}; @@ -487,25 +487,25 @@ public: switch(nextStep) { case 1: - me->Yell(SAY_DIALOG_MEDIVH_1, LANG_UNIVERSAL); + Talk(SAY_DIALOG_MEDIVH_1); return 10000; case 2: if (Creature* arca = ObjectAccessor::GetCreature((*me), ArcanagosGUID)) - arca->Yell(SAY_DIALOG_ARCANAGOS_2, LANG_UNIVERSAL); + arca->AI()->Talk(SAY_DIALOG_ARCANAGOS_2); return 20000; case 3: - me->Yell(SAY_DIALOG_MEDIVH_3, LANG_UNIVERSAL); + Talk(SAY_DIALOG_MEDIVH_3); return 10000; case 4: if (Creature* arca = ObjectAccessor::GetCreature((*me), ArcanagosGUID)) - arca->Yell(SAY_DIALOG_ARCANAGOS_4, LANG_UNIVERSAL); + arca->AI()->Talk(SAY_DIALOG_ARCANAGOS_4); return 20000; case 5: - me->Yell(SAY_DIALOG_MEDIVH_5, LANG_UNIVERSAL); + Talk(SAY_DIALOG_MEDIVH_5); return 20000; case 6: if (Creature* arca = ObjectAccessor::GetCreature((*me), ArcanagosGUID)) - arca->Yell(SAY_DIALOG_ARCANAGOS_6, LANG_UNIVERSAL); + arca->AI()->Talk(SAY_DIALOG_ARCANAGOS_6); ATimer = 5500; MTimer = 6600; @@ -526,7 +526,7 @@ public: return 1000; case 11: if (Creature* arca = ObjectAccessor::GetCreature((*me), ArcanagosGUID)) - arca->Yell(SAY_DIALOG_ARCANAGOS_8, LANG_UNIVERSAL); + arca->AI()->Talk(SAY_DIALOG_ARCANAGOS_8); return 5000; case 12: if (Creature* arca = ObjectAccessor::GetCreature((*me), ArcanagosGUID)) @@ -537,7 +537,7 @@ public: } return 10000; case 13: - me->Yell(SAY_DIALOG_MEDIVH_9, LANG_UNIVERSAL); + Talk(SAY_DIALOG_MEDIVH_9); return 10000; case 14: if (me->GetMap()->IsDungeon()) From f4d861c2663245f8cc52114bd775e0399134efa6 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 14:04:36 -0300 Subject: [PATCH 32/87] =?UTF-8?q?fix(DB/SAI):=20Fix=20Phantom=20Guardsmen?= =?UTF-8?q?=20timers=20and=20remove=20rep=20from=20their=20s=E2=80=A6=20(#?= =?UTF-8?q?14943)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../updates/pending_db_world/rev_1676116579574233800.sql | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676116579574233800.sql diff --git a/data/sql/updates/pending_db_world/rev_1676116579574233800.sql b/data/sql/updates/pending_db_world/rev_1676116579574233800.sql new file mode 100644 index 000000000..b4078df99 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676116579574233800.sql @@ -0,0 +1,9 @@ +-- +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 16425); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(16425, 0, 0, 0, 0, 0, 100, 0, 20000, 60000, 40000, 60000, 0, 11, 29537, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Phantom Guardsman - In Combat - Cast \'Summon Phantom Hound\''), +(16425, 0, 1, 0, 0, 0, 100, 0, 15000, 16000, 15000, 16000, 0, 11, 29684, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Phantom Guardsman - In Combat - Cast \'Shield Slam\''), +(16425, 0, 2, 0, 4, 0, 30, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Phantom Guardsman - On Aggro - Say Line 0'), +(16425, 0, 3, 0, 6, 0, 30, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Phantom Guardsman - On Just Died - Say Line 1'); + +DELETE FROM `creature_onkill_reputation` WHERE `creature_id` = 17067; From af88c2428b9132bc181c20fe41f7fd08e00868c4 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 17:06:58 +0000 Subject: [PATCH 33/87] chore(DB): import pending files Referenced commit(s): f4d861c2663245f8cc52114bd775e0399134efa6 --- .../rev_1675895905789106400.sql => db_world/2023_02_11_05.sql} | 1 + .../rev_1676116579574233800.sql => db_world/2023_02_11_06.sql} | 1 + .../rev_1676128806964865300.sql => db_world/2023_02_11_07.sql} | 1 + 3 files changed, 3 insertions(+) rename data/sql/updates/{pending_db_world/rev_1675895905789106400.sql => db_world/2023_02_11_05.sql} (99%) rename data/sql/updates/{pending_db_world/rev_1676116579574233800.sql => db_world/2023_02_11_06.sql} (96%) rename data/sql/updates/{pending_db_world/rev_1676128806964865300.sql => db_world/2023_02_11_07.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1675895905789106400.sql b/data/sql/updates/db_world/2023_02_11_05.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1675895905789106400.sql rename to data/sql/updates/db_world/2023_02_11_05.sql index 2b824e68d..d1ca66db7 100644 --- a/data/sql/updates/pending_db_world/rev_1675895905789106400.sql +++ b/data/sql/updates/db_world/2023_02_11_05.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_04 -> 2023_02_11_05 -- Cleanup DELETE FROM `creature` WHERE `id1` IN (17975,17976,17977,17978,17980,17993,17994,18155,18404,18405,18419,18420,18421,18422,18587,18721,19486,19505,19507,19508,19509,19511,19512,19513,19557,19598,19608,19633,19843,19865) AND `map`=553 AND `guid` IN (40252,82977,82978,82979,82980,82981,82982,82983,82984,82985,82986,82987,82988,82989,82990,82991,82992,82993,82994,82995,82996,82997,82998,82999,83000,83001,83002,83003,83004,83005,83006,83007,83008,83009,83010,83011,83012,83013,83014,83015,83016,83017,83018,83019,83020,83021,83024,83025,83028,83029,83030,83031,83032,83033,83034,83035,83036,83037,83038,83039,83040,83041,83042,83043,83044,83045,83046,83047,83048,83049,83050,83051,83052,83053,83054,83055,83056,83057,83058,83059,83060,83061,83062,83063,83064,83065,83066,83067,83068,83069,83070,83071,83072,83073,83074,83075,83076,83077,83078,83079,83080,83081,83082,83083,83084,83085,83086,83087,83088,83089,83090,83091,83092,83093,83094,83095,83096,83097,83098,83099,83100,83101,83102,83103,83104,83105,83106,83107,83108,83109,83110,83111,83112,83113,83114,83115,83116,83117,83118,83119,83120,83121,83122,83123,83124,83125,83126,83127,83128,83129,83130,83131,83132,83133,83134,83135,83136,83137,83138,83139,83140,83141,83142,83143,83144,83145,83146,83147,83148,83149,83150,83151,83152,83153,83154,83155,83156,83157,83158,83159,1971524,1971525,1971526,1971527,1971528,1971529,1971530,1971531,1971532,1971533,1971534,1971535,1971536,1971537,1971538,1971539,1971540,1971541); DELETE FROM `creature_addon` WHERE `guid` IN (40252,82977,82978,82979,82980,82981,82982,82983,82984,82985,82986,82987,82988,82989,82990,82991,82992,82993,82994,82995,82996,82997,82998,82999,83000,83001,83002,83003,83004,83005,83006,83007,83008,83009,83010,83011,83012,83013,83014,83015,83016,83017,83018,83019,83020,83021,83024,83025,83028,83029,83030,83031,83032,83033,83034,83035,83036,83037,83038,83039,83040,83041,83042,83043,83044,83045,83046,83047,83048,83049,83050,83051,83052,83053,83054,83055,83056,83057,83058,83059,83060,83061,83062,83063,83064,83065,83066,83067,83068,83069,83070,83071,83072,83073,83074,83075,83076,83077,83078,83079,83080,83081,83082,83083,83084,83085,83086,83087,83088,83089,83090,83091,83092,83093,83094,83095,83096,83097,83098,83099,83100,83101,83102,83103,83104,83105,83106,83107,83108,83109,83110,83111,83112,83113,83114,83115,83116,83117,83118,83119,83120,83121,83122,83123,83124,83125,83126,83127,83128,83129,83130,83131,83132,83133,83134,83135,83136,83137,83138,83139,83140,83141,83142,83143,83144,83145,83146,83147,83148,83149,83150,83151,83152,83153,83154,83155,83156,83157,83158,83159,1971524,1971525,1971526,1971527,1971528,1971529,1971530,1971531,1971532,1971533,1971534,1971535,1971536,1971537,1971538,1971539,1971540,1971541); diff --git a/data/sql/updates/pending_db_world/rev_1676116579574233800.sql b/data/sql/updates/db_world/2023_02_11_06.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1676116579574233800.sql rename to data/sql/updates/db_world/2023_02_11_06.sql index b4078df99..f84e7b903 100644 --- a/data/sql/updates/pending_db_world/rev_1676116579574233800.sql +++ b/data/sql/updates/db_world/2023_02_11_06.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_05 -> 2023_02_11_06 -- DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 16425); INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES diff --git a/data/sql/updates/pending_db_world/rev_1676128806964865300.sql b/data/sql/updates/db_world/2023_02_11_07.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1676128806964865300.sql rename to data/sql/updates/db_world/2023_02_11_07.sql index 6b617df69..407553bed 100644 --- a/data/sql/updates/pending_db_world/rev_1676128806964865300.sql +++ b/data/sql/updates/db_world/2023_02_11_07.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_06 -> 2023_02_11_07 -- -- Karazhan Image of Medivh (17651) and Image of Arcanagos (17652) missing creature text DELETE FROM `creature_text` WHERE `CreatureID` IN (17651,17652); From 76c9eb9159387efb5122a6e10333d71ebbefe29e Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 17:23:57 -0300 Subject: [PATCH 34/87] feat(Core/AI): Implement delay option to the Talk() function (#14950) --- src/server/game/AI/CreatureAI.cpp | 21 +++++++++- src/server/game/AI/CreatureAI.h | 3 +- .../boss_captain_skarloc.cpp | 41 ++++++++----------- 3 files changed, 39 insertions(+), 26 deletions(-) diff --git a/src/server/game/AI/CreatureAI.cpp b/src/server/game/AI/CreatureAI.cpp index b1a101da7..df37d78b6 100644 --- a/src/server/game/AI/CreatureAI.cpp +++ b/src/server/game/AI/CreatureAI.cpp @@ -40,9 +40,26 @@ void CreatureAI::OnCharmed(bool /*apply*/) AISpellInfoType* UnitAI::AISpellInfo; AISpellInfoType* GetAISpellInfo(uint32 i) { return &CreatureAI::AISpellInfo[i]; } -void CreatureAI::Talk(uint8 id, WorldObject const* target /*= nullptr*/) +/** + * @brief Causes the creature to talk/say the text assigned to their entry in the `creature_text` database table. + * + * @param uint8 id Text ID from `creature_text`. + * @param WorldObject target The target of the speech, in case it has elements such as $n, where the target's name will be referrenced. + * @param Milliseconds delay Delay until the creature says the text line. Creatures will talk immediately by default. + */ +void CreatureAI::Talk(uint8 id, WorldObject const* target /*= nullptr*/, Milliseconds delay /*= 0s*/) { - sCreatureTextMgr->SendChat(me, id, target); + if (delay > Seconds::zero()) + { + me->m_Events.AddEventAtOffset([this, id, target]() + { + sCreatureTextMgr->SendChat(me, id, target); + }, delay); + } + else + { + sCreatureTextMgr->SendChat(me, id, target); + } } inline bool IsValidCombatTarget(Creature* source, Player* target) diff --git a/src/server/game/AI/CreatureAI.h b/src/server/game/AI/CreatureAI.h index c4343a548..5cf63a319 100644 --- a/src/server/game/AI/CreatureAI.h +++ b/src/server/game/AI/CreatureAI.h @@ -92,7 +92,8 @@ public: EVADE_REASON_OTHER }; - void Talk(uint8 id, WorldObject const* whisperTarget = nullptr); + void Talk(uint8 id, WorldObject const* whisperTarget = nullptr, Milliseconds delay = 0s); + void Talk(uint8 id, Milliseconds delay) { Talk(id, nullptr, delay); } explicit CreatureAI(Creature* creature) : UnitAI(creature), me(creature), _boundary(nullptr), _negateBoundary(false), m_MoveInLineOfSight_locked(false) { } diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp index e994c7d5b..b213e8295 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp @@ -67,13 +67,11 @@ public: boss_captain_skarlocAI(Creature* creature) : ScriptedAI(creature), summons(me) { } EventMap events; - EventMap events2; SummonList summons; void Reset() override { events.Reset(); - events2.Reset(); summons.DespawnAll(); } @@ -130,8 +128,24 @@ public: if (me->movespline->Finalized()) { - events2.ScheduleEvent(EVENT_INITIAL_TALK, 500); - events2.ScheduleEvent(EVENT_START_FIGHT, 8000); + Talk(SAY_ENTER, 500ms); + + me->m_Events.AddEventAtOffset([this]() + { + me->SetImmuneToAll(false); + me->SetInCombatWithZone(); + for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr) + { + if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr)) + { + if (summon->GetEntry() != NPC_SKARLOC_MOUNT) + { + summon->SetImmuneToAll(false); + summon->SetInCombatWithZone(); + } + } + } + }, 8s); } } @@ -161,25 +175,6 @@ public: void UpdateAI(uint32 diff) override { - events2.Update(diff); - switch (events2.ExecuteEvent()) - { - case EVENT_INITIAL_TALK: - Talk(SAY_ENTER); - break; - case EVENT_START_FIGHT: - me->SetImmuneToAll(false); - me->SetInCombatWithZone(); - for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr) - if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr)) - if (summon->GetEntry() != NPC_SKARLOC_MOUNT) - { - summon->SetImmuneToAll(false); - summon->SetInCombatWithZone(); - } - break; - } - if (!UpdateVictim()) return; From 3bd988d1954d42e33c3db1c4d9392d7b98781cd4 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 21:44:59 +0100 Subject: [PATCH 35/87] =?UTF-8?q?fix(Scripts/BlackMorass):=20Fixed=20amoun?= =?UTF-8?q?t=20of=20Medivh's=20Integrity=20shield=20t=E2=80=A6=20(#14948)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../instance_the_black_morass.cpp | 24 +++++++++++++++---- .../TheBlackMorass/the_black_morass.cpp | 20 ++++++++++++++-- 2 files changed, 38 insertions(+), 6 deletions(-) diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp index ae1e22d75..3221506c9 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp @@ -48,8 +48,8 @@ public: GuidSet encounterNPCs; uint32 encounters[MAX_ENCOUNTER]; ObjectGuid _medivhGUID; - uint8 _currentRift; - uint8 _shieldPercent; + uint8 _currentRift; + int8 _shieldPercent; void Initialize() override { @@ -144,7 +144,7 @@ public: } } - void SetData(uint32 type, uint32 /*data*/) override + void SetData(uint32 type, uint32 data) override { switch (type) { @@ -187,10 +187,19 @@ public: Events.RescheduleEvent(EVENT_NEXT_PORTAL, 3000); break; case DATA_DAMAGE_SHIELD: - --_shieldPercent; + { + _shieldPercent -= data; + if (_shieldPercent < 0) + { + _shieldPercent = 0; + } + DoUpdateWorldState(WORLD_STATE_BM_SHIELD, _shieldPercent); + if (!_shieldPercent) + { if (Creature* medivh = instance->GetCreature(_medivhGUID)) + { if (medivh->IsAlive()) { Unit::Kill(medivh, medivh); @@ -198,10 +207,17 @@ public: // Xinef: delete all spawns GuidSet eCopy = encounterNPCs; for (ObjectGuid const& guid : eCopy) + { if (Creature* creature = instance->GetCreature(guid)) + { creature->DespawnOrUnsummon(); + } + } } + } + } break; + } } } diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp index 0fec969f0..b1d88ca83 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp @@ -387,16 +387,32 @@ public: { PrepareAuraScript(spell_black_morass_corrupt_medivh_AuraScript); + bool Load() override + { + _ticks = 0; + return true; + } + void PeriodicTick(AuraEffect const* /*aurEff*/) { - if (InstanceScript* instance = GetUnitOwner()->GetInstanceScript()) - instance->SetData(DATA_DAMAGE_SHIELD, 1); + if (++_ticks >= 3) + { + _ticks = 0; + + if (InstanceScript* instance = GetUnitOwner()->GetInstanceScript()) + { + instance->SetData(DATA_DAMAGE_SHIELD, m_scriptSpellId == SPELL_CORRUPT_AEONUS ? 2 : 1); + } + } } void Register() override { OnEffectPeriodic += AuraEffectPeriodicFn(spell_black_morass_corrupt_medivh_AuraScript::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } + + private: + uint8 _ticks = 0; }; AuraScript* GetAuraScript() const override From f4dbb0443125570ba13debcbb895b4608a5710ad Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sat, 11 Feb 2023 21:45:36 +0100 Subject: [PATCH 36/87] fix(Scripts/BlackMorass): Fixed portal positions. (#14946) --- .../TheBlackMorass/instance_the_black_morass.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp index 3221506c9..086d08b93 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp @@ -25,10 +25,10 @@ const Position PortalLocation[4] = { - {-2041.06f, 7042.08f, 29.99f, 1.30f}, - {-1968.18f, 7042.11f, 21.93f, 2.12f}, - {-1885.82f, 7107.36f, 22.32f, 3.07f}, - {-1928.11f, 7175.95f, 22.11f, 3.44f} + { -2030.8318f, 7024.9443f, 23.071817f, 3.14159f }, + { -1961.7335f, 7029.5280f, 21.811401f, 2.12931f }, + { -1887.6950f, 7106.5570f, 22.049500f, 4.95673f }, + { -1930.9106f, 7183.5970f, 23.007639f, 3.59537f } }; class instance_the_black_morass : public InstanceMapScript From 8927d0cb646a82ff3c9dd94dcf585261f0692ecf Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Sat, 11 Feb 2023 21:46:07 +0100 Subject: [PATCH 37/87] fix(DB/Creature): Spawn Ancient Draenei Spirit (#14925) Co-authored-by: Skjalf <47818697+Nyeriah@users.noreply.github.com> --- .../rev_1675981332243959700.sql | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675981332243959700.sql diff --git a/data/sql/updates/pending_db_world/rev_1675981332243959700.sql b/data/sql/updates/pending_db_world/rev_1675981332243959700.sql new file mode 100644 index 000000000..5dcf8a79d --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675981332243959700.sql @@ -0,0 +1,45 @@ +-- + +UPDATE `creature_template` SET `unit_flags`=33587968 WHERE `entry` IN (19416); -- Ancient Draenei Spirit +DELETE FROM `creature` WHERE `guid` IN (83823,83824,83825,83826,83827,83828,83829,83830,83831,83832,83833,83834,83835,83836,83837,83838,83839,83840,83841,83842,83843,83844,83845,83846,83847,83848,83849,83850,83851,83852,83853,83854,83855,83856,83857,83858) AND `id1` = 19416; +INSERT INTO `creature` (`guid`, `id1`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`,`equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `VerifiedBuild`) VALUES +(83823, 19416, 530, 3519, 3688, 1, 1, 0, -3387.172, 5177.652, -95.4726, 1.396263, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3688 - Difficulty: 0) +(83824, 19416, 530, 3519, 3688, 1, 1, 0, -3330.136, 5182.805, -88.44417, 1.58825, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3688 - Difficulty: 0) +(83825, 19416, 530, 3519, 3688, 1, 1, 0, -3383.71, 5192.255, -97.12683, 3.822271, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3688 - Difficulty: 0) +(83826, 19416, 530, 3519, 3688, 1, 1, 0, -3330.147, 5185.821, -88.34676, 4.39823, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3688 - Difficulty: 0) +(83827, 19416, 530, 3519, 3688, 1, 1, 0, -3400.185, 5185.938, -88.72957, 0.01745329, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3688 - Difficulty: 0) +(83829, 19416, 530, 3519, 3893, 1, 1, 0, -3558.749, 4945.349, -8.938482, 3.141593, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83828, 19416, 530, 3519, 3893, 1, 1, 0, -3589.759, 4958.169, -16.07662, 5.8294, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83830, 19416, 530, 3519, 3893, 1, 1, 0, -3610.091, 4946.128, -22.55922, 6.021386, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83831, 19416, 530, 3519, 3893, 1, 1, 0, -3593.032, 4931.014, -18.51772, 0.06981317, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83832, 19416, 530, 3519, 3893, 1, 1, 0, -3561.48, 4948.509, -8.966965, 3.944444, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83833, 19416, 530, 3519, 3893, 1, 1, 0, -3565.491, 4949.006, -8.949272, 4.34587, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83834, 19416, 530, 3519, 3893, 1, 1, 0, -3569.862, 4949.046, -8.917868, 5.393067, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83835, 19416, 530, 3519, 3893, 1, 1, 0, -3610.145, 4928.859, -21.96672, 0.2443461, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83836, 19416, 530, 3519, 3893, 1, 1, 0, -3589.922, 4950.491, -16.01632, 6.021386, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83837, 19416, 530, 3519, 3893, 1, 1, 0, -3604.122, 4937.787, -22.62471, 6.003932, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83838, 19416, 530, 3519, 3893, 1, 1, 0, -3596.76, 4950.664, -21.2734, 6.195919, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83839, 19416, 530, 3519, 3893, 1, 1, 0, -3571.575, 4943.306, -8.917854, 0.03490658, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83840, 19416, 530, 3519, 3893, 1, 1, 0, -3603.546, 4962.408, -22.62576, 6.091199, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83841, 19416, 530, 3519, 3893, 1, 1, 0, -3610.495, 4936.802, -22.43668, 5.951573, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83842, 19416, 530, 3519, 3893, 1, 1, 0, -3592.681, 4962.177, -18.418, 5.916666, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83843, 19416, 530, 3519, 3893, 1, 1, 0, -3604.225, 4928.086, -22.33435, 6.178465, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83844, 19416, 530, 3519, 3893, 1, 1, 0, -3609.721, 4962.552, -22.62576, 5.916666, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83845, 19416, 530, 3519, 3893, 1, 1, 0, -3597.477, 4942.241, -21.6605, 0.05235988, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83846, 19416, 530, 3519, 3893, 1, 1, 0, -3564.036, 4936.497, -8.978624, 1.658063, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83847, 19416, 530, 3519, 3893, 1, 1, 0, -3596.669, 4934.441, -21.2282, 6.248279, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83848, 19416, 530, 3519, 3893, 1, 1, 0, -3604.072, 4946.475, -22.62576, 6.003932, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83849, 19416, 530, 3519, 3893, 1, 1, 0, -3590.313, 4942.292, -16.15607, 6.230825, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83850, 19416, 530, 3519, 3893, 1, 1, 0, -3593.291, 4954.31, -18.69635, 6.091199, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83851, 19416, 530, 3519, 3893, 1, 1, 0, -3609.907, 4954.746, -22.61663, 6.056293, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83852, 19416, 530, 3519, 3893, 1, 1, 0, -3569.752, 4938.038, -8.917878, 0.7504916, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83853, 19416, 530, 3519, 3893, 1, 1, 0, -3559.012, 4940.637, -8.940417, 2.548181, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83854, 19416, 530, 3519, 3893, 1, 1, 0, -3593.022, 4938.924, -18.31859, 6.230825, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83855, 19416, 530, 3519, 3893, 1, 1, 0, -3603.876, 4954.56, -22.62576, 6.003932, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83856, 19416, 530, 3519, 3893, 1, 1, 0, -3589.462, 4933.084, -15.72467, 6.248279, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83857, 19416, 530, 3519, 3893, 1, 1, 0, -3593.144, 4946.163, -18.38688, 6.056293, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545), -- 19416 (Area: 3893 - Difficulty: 0) +(83858, 19416, 530, 3519, 3893, 1, 1, 0, -3596.541, 4959.32, -21.31441, 6.056293, 120, 0, 0, 0, 0, 0, 0, 0, 0, 14545); -- 19416 (Area: 3893 - Difficulty: 0) + +DELETE FROM `creature_template_addon` WHERE `entry` IN (19416); +INSERT INTO `creature_template_addon` (`entry`, `bytes1`, `bytes2`, `auras`) VALUES +(19416, 0, 1, '32648'); From 580d78731f5aab7656ef30b703ce2d2fb4346739 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 20:48:27 +0000 Subject: [PATCH 38/87] chore(DB): import pending files Referenced commit(s): 8927d0cb646a82ff3c9dd94dcf585261f0692ecf --- .../rev_1675981332243959700.sql => db_world/2023_02_11_08.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675981332243959700.sql => db_world/2023_02_11_08.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1675981332243959700.sql b/data/sql/updates/db_world/2023_02_11_08.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1675981332243959700.sql rename to data/sql/updates/db_world/2023_02_11_08.sql index 5dcf8a79d..fc5a44c69 100644 --- a/data/sql/updates/pending_db_world/rev_1675981332243959700.sql +++ b/data/sql/updates/db_world/2023_02_11_08.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_07 -> 2023_02_11_08 -- UPDATE `creature_template` SET `unit_flags`=33587968 WHERE `entry` IN (19416); -- Ancient Draenei Spirit From 2e6c28c4d8a011e948e83c016f65d1497fca6c23 Mon Sep 17 00:00:00 2001 From: Pedro Antonio <37176834+Valdifer@users.noreply.github.com> Date: Sat, 11 Feb 2023 22:21:43 +0100 Subject: [PATCH 39/87] feat(Core/Pet): DK Petname generation locale (#14059) --- .../rev_1670175005015833100.sql | 125 ++++++++++++++++++ src/server/game/Entities/Player/Player.cpp | 2 +- src/server/game/Globals/ObjectMgr.cpp | 49 +++++++ src/server/game/Globals/ObjectMgr.h | 5 + src/server/game/World/World.cpp | 1 + 5 files changed, 181 insertions(+), 1 deletion(-) create mode 100644 data/sql/updates/pending_db_world/rev_1670175005015833100.sql diff --git a/data/sql/updates/pending_db_world/rev_1670175005015833100.sql b/data/sql/updates/pending_db_world/rev_1670175005015833100.sql new file mode 100644 index 000000000..a3326c77f --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1670175005015833100.sql @@ -0,0 +1,125 @@ +-- +/* +SQLyog Community v13.1.2 (64 bit) +MySQL - 5.7.37-log : Database - acore_world +********************************************************************* + +Table structure for table `pet_name_generation_locale` */ + +DROP TABLE IF EXISTS `pet_name_generation_locale`; +CREATE TABLE `pet_name_generation_locale` ( + `id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, + `locale` varchar(4) NOT NULL, + `word` tinytext NOT NULL, + `entry` mediumint(8) unsigned NOT NULL DEFAULT '0', + `half` tinyint(3) unsigned NOT NULL DEFAULT '0', + PRIMARY KEY (`ID`,`locale`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; + +INSERT INTO `pet_name_generation_locale` (`id`, `locale`, `word`, `entry`, `half`) VALUES (261, 'esES', 'piedras', 26125, 1), +(262, 'esES', 'rocas', 26125, 1), +(263, 'esES', 'ojos', 26125, 1), +(264, 'esES', 'tierra', 26125, 1), +(265, 'esES', 'sepulcros', 26125, 1), +(266, 'esES', 'murciélagos', 26125, 1), +(267, 'esES', 'ratas', 26125, 1), +(268, 'esES', 'cuerpos', 26125, 1), +(269, 'esES', 'tumbas', 26125, 1), +(270, 'esES', 'carroña', 26125, 1), +(271, 'esES', 'cráneos', 26125, 1), +(272, 'esES', 'huesos', 26125, 1), +(273, 'esES', 'criptas', 26125, 1), +(274, 'esES', 'costillas', 26125, 1), +(275, 'esES', 'cerebros', 26125, 1), +(276, 'esES', 'sarcófagos', 26125, 1), +(277, 'esES', 'podredumbre', 26125, 1), +(278, 'esES', 'gravilla', 26125, 1), +(279, 'esES', 'plaga', 26125, 1), +(280, 'esES', 'ataúdes', 26125, 1), +(281, 'esES', 'miembros', 26125, 1), +(282, 'esES', 'gusanos', 26125, 1), +(283, 'esES', 'suelos', 26125, 1), +(284, 'esES', 'espinas', 26125, 1), +(285, 'esES', 'guijarros', 26125, 1), +(286, 'esES', 'raíces', 26125, 1), +(287, 'esES', 'médulas', 26125, 1), +(288, 'esES', 'martillos', 26125, 1), +(289, 'esES', 'Devasta', 26125, 0), +(290, 'esES', 'Mastica', 26125, 0), +(291, 'esES', 'Tritura', 26125, 0), +(292, 'esES', 'Machaca', 26125, 0), +(293, 'esES', 'Salta', 26125, 0), +(294, 'esES', 'Afila', 26125, 0), +(295, 'esES', 'Acosa', 26125, 0), +(296, 'esES', 'Engulle', 26125, 0), +(297, 'esES', 'Come', 26125, 0), +(298, 'esES', 'Golpea', 26125, 0), +(299, 'esES', 'Masca', 26125, 0), +(300, 'esES', 'Destripa', 26125, 0), +(301, 'esES', 'Trocea', 26125, 0), +(302, 'esES', 'Roe', 26125, 0), +(303, 'esES', 'Desolla', 26125, 0), +(304, 'esES', 'Retumba', 26125, 0), +(305, 'esES', 'Muerde', 26125, 0), +(306, 'esES', 'Rompe', 26125, 0), +(307, 'esES', 'Guarda', 26125, 0), +(308, 'esES', 'Seca', 26125, 0), +(309, 'esES', 'Atraca', 26125, 0), +(310, 'esES', 'Roba', 26125, 0), +(311, 'esES', 'Captura', 26125, 0), +(312, 'esES', 'Bebe', 26125, 0), +(313, 'esES', 'Rebana', 26125, 0), +(261, 'esMX', 'piedras', 26125, 1), +(262, 'esMX', 'rocas', 26125, 1), +(263, 'esMX', 'ojos', 26125, 1), +(264, 'esMX', 'tierra', 26125, 1), +(265, 'esMX', 'sepulcros', 26125, 1), +(266, 'esMX', 'murciélagos', 26125, 1), +(267, 'esMX', 'ratas', 26125, 1), +(268, 'esMX', 'cuerpos', 26125, 1), +(269, 'esMX', 'tumbas', 26125, 1), +(270, 'esMX', 'carroña', 26125, 1), +(271, 'esMX', 'cráneos', 26125, 1), +(272, 'esMX', 'huesos', 26125, 1), +(273, 'esMX', 'criptas', 26125, 1), +(274, 'esMX', 'costillas', 26125, 1), +(275, 'esMX', 'cerebros', 26125, 1), +(276, 'esMX', 'sarcófagos', 26125, 1), +(277, 'esMX', 'podredumbre', 26125, 1), +(278, 'esMX', 'gravilla', 26125, 1), +(279, 'esMX', 'plaga', 26125, 1), +(280, 'esMX', 'ataúdes', 26125, 1), +(281, 'esMX', 'miembros', 26125, 1), +(282, 'esMX', 'gusanos', 26125, 1), +(283, 'esMX', 'suelos', 26125, 1), +(284, 'esMX', 'espinas', 26125, 1), +(285, 'esMX', 'guijarros', 26125, 1), +(286, 'esMX', 'raíces', 26125, 1), +(287, 'esMX', 'médulas', 26125, 1), +(288, 'esMX', 'martillos', 26125, 1), +(289, 'esMX', 'Devasta', 26125, 0), +(290, 'esMX', 'Mastica', 26125, 0), +(291, 'esMX', 'Tritura', 26125, 0), +(292, 'esMX', 'Machaca', 26125, 0), +(293, 'esMX', 'Salta', 26125, 0), +(294, 'esMX', 'Afila', 26125, 0), +(295, 'esMX', 'Acosa', 26125, 0), +(296, 'esMX', 'Engulle', 26125, 0), +(297, 'esMX', 'Come', 26125, 0), +(298, 'esMX', 'Golpea', 26125, 0), +(299, 'esMX', 'Masca', 26125, 0), +(300, 'esMX', 'Destripa', 26125, 0), +(301, 'esMX', 'Trocea', 26125, 0), +(302, 'esMX', 'Roe', 26125, 0), +(303, 'esMX', 'Desolla', 26125, 0), +(304, 'esMX', 'Retumba', 26125, 0), +(305, 'esMX', 'Muerde', 26125, 0), +(306, 'esMX', 'Rompe', 26125, 0), +(307, 'esMX', 'Guarda', 26125, 0), +(308, 'esMX', 'Seca', 26125, 0), +(309, 'esMX', 'Atraca', 26125, 0), +(310, 'esMX', 'Roba', 26125, 0), +(311, 'esMX', 'Captura', 26125, 0), +(312, 'esMX', 'Bebe', 26125, 0), +(313, 'esMX', 'Rebana', 26125, 0); + diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 01697f0ba..83e76ab76 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -8827,7 +8827,7 @@ Pet* Player::SummonPet(uint32 entry, float x, float y, float z, float ang, PetTy // Generate a new name for the newly summoned ghoul if (pet->IsPetGhoul()) { - std::string new_name = sObjectMgr->GeneratePetName(entry); + std::string new_name = sObjectMgr->GeneratePetNameLocale(entry, GetSession()->GetSessionDbLocaleIndex()); if (!new_name.empty()) pet->SetName(new_name); } diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index 58546192e..d71c4b1e8 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -448,6 +448,42 @@ void ObjectMgr::LoadGossipMenuItemsLocales() LOG_INFO("server.loading", ">> Loaded {} Gossip Menu Option Locale Strings in {} ms", (uint32)_gossipMenuItemsLocaleStore.size(), GetMSTimeDiffToNow(oldMSTime)); } +void ObjectMgr::LoadPetNamesLocales() +{ + uint32 oldMSTime = getMSTime(); + + // 0 1 2 3 + QueryResult result = WorldDatabase.Query("SELECT locale, word, entry, half FROM pet_name_generation_locale"); + + if (!result) + { + LOG_WARN("server.loading", ">> Loaded 0 pet name locales parts. DB table `pet_name_generation_locale` is empty!"); + LOG_INFO("server.loading", " "); + return; + } + + uint32 count = 0; + + do + { + Field* fields = result->Fetch(); + LocaleConstant locale = GetLocaleByName(fields[0].Get()); + std::string word = fields[1].Get(); + + uint32 entry = fields[2].Get(); + bool half = fields[3].Get(); + std::pair pairkey = std::make_pair(entry, locale); + if (half) + _petHalfLocaleName1[pairkey].push_back(word); + else + _petHalfLocaleName0[pairkey].push_back(word); + ++count; + } while (result->NextRow()); + + LOG_INFO("server.loading", ">> Loaded {} Pet Name Locales Parts in {} ms", count, GetMSTimeDiffToNow(oldMSTime)); + LOG_INFO("server.loading", " "); +} + void ObjectMgr::LoadPointOfInterestLocales() { uint32 oldMSTime = getMSTime(); @@ -7402,6 +7438,19 @@ void ObjectMgr::LoadPetNumber() LOG_INFO("server.loading", " "); } +std::string ObjectMgr::GeneratePetNameLocale(uint32 entry, LocaleConstant locale) +{ + std::vector& list0 = _petHalfLocaleName0[std::make_pair(entry, locale)]; + std::vector& list1 = _petHalfLocaleName1[std::make_pair(entry, locale)]; + + if (list0.empty() || list1.empty()) + { + return GeneratePetName(entry); + } + + return *(list0.begin() + urand(0, list0.size() - 1)) + *(list1.begin() + urand(0, list1.size() - 1)); +} + std::string ObjectMgr::GeneratePetName(uint32 entry) { std::vector& list0 = _petHalfName0[entry]; diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index 19ea6b2a5..0344f6726 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -1075,6 +1075,7 @@ public: void LoadPetLevelInfo(); void LoadExplorationBaseXP(); void LoadPetNames(); + void LoadPetNamesLocales(); void LoadPetNumber(); void LoadFishingBaseSkillLevel(); void ChangeFishingBaseSkillLevel(uint32 entry, int32 skill); @@ -1098,6 +1099,7 @@ public: void AddSpellToTrainer(uint32 entry, uint32 spell, uint32 spellCost, uint32 reqSkill, uint32 reqSkillValue, uint32 reqLevel, uint32 reqSpell); std::string GeneratePetName(uint32 entry); + std::string GeneratePetNameLocale(uint32 entry, LocaleConstant locale); uint32 GetBaseXP(uint8 level); [[nodiscard]] uint32 GetXPForLevel(uint8 level) const; @@ -1549,6 +1551,9 @@ private: typedef std::map> HalfNameContainer; HalfNameContainer _petHalfName0; HalfNameContainer _petHalfName1; + typedef std::map, std::vector> HalfNameContainerLocale; + HalfNameContainerLocale _petHalfLocaleName0; + HalfNameContainerLocale _petHalfLocaleName1; typedef std::unordered_map ItemSetNameContainer; ItemSetNameContainer _itemSetNameStore; diff --git a/src/server/game/World/World.cpp b/src/server/game/World/World.cpp index fba75e240..234b483de 100644 --- a/src/server/game/World/World.cpp +++ b/src/server/game/World/World.cpp @@ -1634,6 +1634,7 @@ void World::SetInitialWorldSettings() sObjectMgr->LoadPageTextLocales(); sObjectMgr->LoadGossipMenuItemsLocales(); sObjectMgr->LoadPointOfInterestLocales(); + sObjectMgr->LoadPetNamesLocales(); sObjectMgr->SetDBCLocaleIndex(GetDefaultDbcLocale()); // Get once for all the locale index of DBC language (console/broadcasts) LOG_INFO("server.loading", ">> Localization Strings loaded in {} ms", GetMSTimeDiffToNow(oldMSTime)); From 888e3ccac6d01482877d5036262fc9f3645d1ed2 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sat, 11 Feb 2023 21:24:12 +0000 Subject: [PATCH 40/87] chore(DB): import pending files Referenced commit(s): 2e6c28c4d8a011e948e83c016f65d1497fca6c23 --- .../rev_1670175005015833100.sql => db_world/2023_02_11_09.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1670175005015833100.sql => db_world/2023_02_11_09.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1670175005015833100.sql b/data/sql/updates/db_world/2023_02_11_09.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1670175005015833100.sql rename to data/sql/updates/db_world/2023_02_11_09.sql index a3326c77f..6b532dec2 100644 --- a/data/sql/updates/pending_db_world/rev_1670175005015833100.sql +++ b/data/sql/updates/db_world/2023_02_11_09.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_08 -> 2023_02_11_09 -- /* SQLyog Community v13.1.2 (64 bit) From b0decf9ce4c188f4cdd6c7f48905dd2fc4c66fa4 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 19:17:01 -0300 Subject: [PATCH 41/87] feat(Core/AI): Update the BossAI scheduler in the parent class (#14952) --- src/server/game/AI/ScriptedAI/ScriptedCreature.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp index e2cd312ee..a02fa01fb 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp @@ -648,6 +648,7 @@ void BossAI::UpdateAI(uint32 diff) } events.Update(diff); + scheduler.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) { From 18cf1761dcb9c5269a6c0ac120cbdddbbb0ee204 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 19:17:18 -0300 Subject: [PATCH 42/87] refactor(Scripts/TheBotanica): Modernize the Warp Splinter script (#14951) --- .../botanica/boss_warp_splinter.cpp | 98 ++++++------------- .../TempestKeep/botanica/the_botanica.h | 2 + 2 files changed, 33 insertions(+), 67 deletions(-) diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp index 4d406aa52..046c469aa 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp @@ -37,87 +37,51 @@ enum Spells SPELL_SUMMON_SAPLINGS_PERIODIC = 34741 }; -enum Misc +struct boss_warp_splinter : public BossAI { - EVENT_ARCANE_VOLLEY = 1, - EVENT_WAR_STOMP = 2, - EVENT_SUMMON_TREANT = 3 -}; + boss_warp_splinter(Creature* creature) : BossAI(creature, DATA_WARP_SPLINTER) { } -class boss_warp_splinter : public CreatureScript -{ -public: - boss_warp_splinter() : CreatureScript("boss_warp_splinter") { } - struct boss_warp_splinterAI : public BossAI + void EnterCombat(Unit* /*who*/) override { - boss_warp_splinterAI(Creature* creature) : BossAI(creature, DATA_WARP_SPLINTER) { } + _EnterCombat(); + Talk(SAY_AGGRO); - void Reset() override + scheduler.Schedule(8s, [this](TaskContext context) { - _Reset(); - } - - void EnterCombat(Unit* /*who*/) override + DoCastAOE(SPELL_ARCANE_VOLLEY); + context.Repeat(20s); + }).Schedule(15s, [this](TaskContext context) { - _EnterCombat(); - Talk(SAY_AGGRO); - - events.ScheduleEvent(EVENT_ARCANE_VOLLEY, 8000); - events.ScheduleEvent(EVENT_WAR_STOMP, 15000); - events.ScheduleEvent(EVENT_SUMMON_TREANT, 20000); - } - - void KilledUnit(Unit* victim) override + DoCastAOE(SPELL_WAR_STOMP); + context.Repeat(30s); + }).Schedule(20s, [this](TaskContext context) { - if (victim->GetTypeId() == TYPEID_PLAYER) - Talk(SAY_SLAY); - } - - void JustDied(Unit* /*killer*/) override - { - _JustDied(); - Talk(SAY_DEATH); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + Talk(SAY_SUMMON); + DoCastAOE(SPELL_SUMMON_SAPLINGS_PERIODIC, true); + for (uint8 i = 0; i < 6; ++i) { - case EVENT_ARCANE_VOLLEY: - me->CastSpell(me, SPELL_ARCANE_VOLLEY, false); - events.ScheduleEvent(EVENT_ARCANE_VOLLEY, 20000); - break; - case EVENT_WAR_STOMP: - me->CastSpell(me, SPELL_WAR_STOMP, false); - events.ScheduleEvent(EVENT_WAR_STOMP, 30000); - break; - case EVENT_SUMMON_TREANT: - Talk(SAY_SUMMON); - me->CastSpell(me, SPELL_SUMMON_SAPLINGS_PERIODIC, true); - for (uint8 i = 0; i < 6; ++i) - me->CastSpell(me, SPELL_SUMMON_SAPLINGS_SUMMON + i, true); - events.ScheduleEvent(EVENT_SUMMON_TREANT, 40000); - break; + DoCastAOE(SPELL_SUMMON_SAPLINGS_SUMMON + i, true); } + context.Repeat(40s); + }); + } - DoMeleeAttackIfReady(); - } - }; - - CreatureAI* GetAI(Creature* creature) const override + void KilledUnit(Unit* victim) override { - return GetTheBotanicaAI(creature); + if (victim->IsPlayer()) + { + Talk(SAY_SLAY); + } + } + + void JustDied(Unit* /*killer*/) override + { + _JustDied(); + Talk(SAY_DEATH); } }; void AddSC_boss_warp_splinter() { - new boss_warp_splinter(); + RegisterTheBotanicaCreatureAI(boss_warp_splinter); } diff --git a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h index ad6449eb7..083c83272 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h +++ b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h @@ -58,4 +58,6 @@ inline AI* GetTheBotanicaAI(T* obj) return GetInstanceAI(obj, TheBotanicaScriptName); } +#define RegisterTheBotanicaCreatureAI(ai_name) RegisterCreatureAIWithFactory(ai_name, GetTheBotanicaAI) + #endif From 66f4feb1da0593885d2a90081ab3be3fecd152e7 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 19:50:19 -0300 Subject: [PATCH 43/87] chore(DB/SQL): Correct file to comply with standards (#14953) --- data/sql/updates/db_world/2023_02_11_09.sql | 13 ++++++------- src/server/game/Globals/ObjectMgr.cpp | 6 +++++- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/data/sql/updates/db_world/2023_02_11_09.sql b/data/sql/updates/db_world/2023_02_11_09.sql index 6b532dec2..fa26c445d 100644 --- a/data/sql/updates/db_world/2023_02_11_09.sql +++ b/data/sql/updates/db_world/2023_02_11_09.sql @@ -9,13 +9,13 @@ Table structure for table `pet_name_generation_locale` */ DROP TABLE IF EXISTS `pet_name_generation_locale`; CREATE TABLE `pet_name_generation_locale` ( - `id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, - `locale` varchar(4) NOT NULL, - `word` tinytext NOT NULL, - `entry` mediumint(8) unsigned NOT NULL DEFAULT '0', - `half` tinyint(3) unsigned NOT NULL DEFAULT '0', + `ID` mediumint unsigned NOT NULL, + `Locale` varchar(4) NOT NULL, + `Word` tinytext NOT NULL, + `Entry` mediumint unsigned NOT NULL DEFAULT '0', + `Half` tinyint unsigned NOT NULL DEFAULT '0', PRIMARY KEY (`ID`,`locale`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT; +); INSERT INTO `pet_name_generation_locale` (`id`, `locale`, `word`, `entry`, `half`) VALUES (261, 'esES', 'piedras', 26125, 1), (262, 'esES', 'rocas', 26125, 1), @@ -123,4 +123,3 @@ INSERT INTO `pet_name_generation_locale` (`id`, `locale`, `word`, `entry`, `half (311, 'esMX', 'Captura', 26125, 0), (312, 'esMX', 'Bebe', 26125, 0), (313, 'esMX', 'Rebana', 26125, 0); - diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index d71c4b1e8..e05a041a2 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -453,7 +453,7 @@ void ObjectMgr::LoadPetNamesLocales() uint32 oldMSTime = getMSTime(); // 0 1 2 3 - QueryResult result = WorldDatabase.Query("SELECT locale, word, entry, half FROM pet_name_generation_locale"); + QueryResult result = WorldDatabase.Query("SELECT Locale, Word, Entry, Half FROM pet_name_generation_locale"); if (!result) { @@ -474,9 +474,13 @@ void ObjectMgr::LoadPetNamesLocales() bool half = fields[3].Get(); std::pair pairkey = std::make_pair(entry, locale); if (half) + { _petHalfLocaleName1[pairkey].push_back(word); + } else + { _petHalfLocaleName0[pairkey].push_back(word); + } ++count; } while (result->NextRow()); From 43cd34e72e8f76f1c2b2d5e13e87e1810d85c860 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 11 Feb 2023 21:40:44 -0300 Subject: [PATCH 44/87] refactor(Scripts/TheBotanica): Modernize High Botanist Freywinn script (#14954) --- .../botanica/boss_high_botanist_freywinn.cpp | 163 +++++++----------- 1 file changed, 63 insertions(+), 100 deletions(-) diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp index d046864c1..3af92dd8a 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp @@ -40,121 +40,84 @@ enum Spells SPELL_PLANT_RED = 34763 }; -enum Misc +enum Npcs { - NPC_FRAYER = 19953, - - EVENT_SUMMON_SEEDLING = 1, - EVENT_TREE_FORM = 2, - EVENT_CHECK_FRAYERS = 3, - EVENT_RESTORE_COMBAT = 4 + NPC_FRAYER = 19953 }; -class boss_high_botanist_freywinn : public CreatureScript +struct boss_high_botanist_freywinn : public BossAI { -public: - boss_high_botanist_freywinn() : CreatureScript("boss_high_botanist_freywinn") + boss_high_botanist_freywinn(Creature* creature) : BossAI(creature, DATA_HIGH_BOTANIST_FREYWINN) { } + + void EnterCombat(Unit* /*who*/) override { - } + _EnterCombat(); + Talk(SAY_AGGRO); - struct boss_high_botanist_freywinnAI : public BossAI - { - boss_high_botanist_freywinnAI(Creature* creature) : BossAI(creature, DATA_HIGH_BOTANIST_FREYWINN) { } - - void Reset() override + scheduler.Schedule(6s, [this](TaskContext context) { - _Reset(); - } - - void EnterCombat(Unit* /*who*/) override - { - _EnterCombat(); - Talk(SAY_AGGRO); - - events.ScheduleEvent(EVENT_SUMMON_SEEDLING, 6000); - events.ScheduleEvent(EVENT_TREE_FORM, 30000); - } - - void KilledUnit(Unit* victim) override - { - if (victim->GetTypeId() == TYPEID_PLAYER) - Talk(SAY_KILL); - } - - void JustDied(Unit* /*killer*/) override - { - Talk(SAY_DEATH); - _JustDied(); - } - - void SummonedCreatureDies(Creature* summon, Unit*) override - { - summons.Despawn(summon); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (!events.IsInPhase(1) && me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + if (roll_chance_i(20)) { - case EVENT_SUMMON_SEEDLING: - if (roll_chance_i(20)) - Talk(SAY_OOC_RANDOM); - me->CastSpell(me, RAND(SPELL_PLANT_WHITE, SPELL_PLANT_GREEN, SPELL_PLANT_BLUE, SPELL_PLANT_RED), false); - events.ScheduleEvent(EVENT_SUMMON_SEEDLING, 6000); - break; - case EVENT_TREE_FORM: - events.Reset(); - events.SetPhase(1); - events.ScheduleEvent(EVENT_CHECK_FRAYERS, 1000); - events.ScheduleEvent(EVENT_TREE_FORM, 75000); - events.ScheduleEvent(EVENT_RESTORE_COMBAT, 46000); - - Talk(SAY_TREE); - me->RemoveAllAuras(); - me->GetMotionMaster()->MoveIdle(); - me->GetMotionMaster()->Clear(false); - - me->CastSpell(me, SPELL_SUMMON_FRAYER, true); - me->CastSpell(me, SPELL_TRANQUILITY, true); - me->CastSpell(me, SPELL_TREE_FORM, true); - break; - case EVENT_RESTORE_COMBAT: - events.SetPhase(0); - events.ScheduleEvent(EVENT_SUMMON_SEEDLING, 6000); - me->GetMotionMaster()->MoveChase(me->GetVictim()); - break; - case EVENT_CHECK_FRAYERS: - if (!summons.HasEntry(NPC_FRAYER)) - { - me->InterruptNonMeleeSpells(true); - me->RemoveAllAuras(); - events.RescheduleEvent(EVENT_RESTORE_COMBAT, 0); - events.RescheduleEvent(EVENT_TREE_FORM, 30000); - break; - } - events.ScheduleEvent(EVENT_CHECK_FRAYERS, 500); - break; + Talk(SAY_OOC_RANDOM); } - if (!events.IsInPhase(1)) - DoMeleeAttackIfReady(); - } - }; + DoCastAOE(RAND(SPELL_PLANT_WHITE, SPELL_PLANT_GREEN, SPELL_PLANT_BLUE, SPELL_PLANT_RED)); + context.Repeat(); + }).Schedule(30s, [this](TaskContext context) + { + scheduler.CancelAll(); - CreatureAI* GetAI(Creature* creature) const override + Talk(SAY_TREE); + me->RemoveAllAuras(); + me->GetMotionMaster()->MoveIdle(); + me->GetMotionMaster()->Clear(false); + + DoCastSelf(SPELL_SUMMON_FRAYER, true); + DoCastSelf(SPELL_TRANQUILITY, true); + DoCastSelf(SPELL_TREE_FORM, true); + + scheduler.Schedule(45s, [this](TaskContext) + { + ResumeEncounter(); + }); + + context.Repeat(75s); + }); + } + + void ResumeEncounter() { - return GetTheBotanicaAI(creature); + me->GetMotionMaster()->MoveChase(me->GetVictim()); + me->RemoveAurasDueToSpell(SPELL_TREE_FORM); + me->InterruptNonMeleeSpells(false); + } + + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer()) + { + Talk(SAY_KILL); + } + } + + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_DEATH); + _JustDied(); + } + + void SummonedCreatureDies(Creature* summon, Unit*) override + { + summons.Despawn(summon); + + if (!summons.HasEntry(NPC_FRAYER)) + { + ResumeEncounter(); + } } }; void AddSC_boss_high_botanist_freywinn() { - new boss_high_botanist_freywinn(); + RegisterTheBotanicaCreatureAI(boss_high_botanist_freywinn); } From 68c38226ed0c8b96b7ec971f521013b87df5a237 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 00:31:23 -0300 Subject: [PATCH 45/87] =?UTF-8?q?fix(Core/Unit):=20Fix=20creatures=20not?= =?UTF-8?q?=20being=20able=20to=20cast=20spells=20during=20Ju=E2=80=A6=20(?= =?UTF-8?q?#14957)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/game/Entities/Unit/Unit.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 861679b7d..2929fb82c 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -17852,6 +17852,13 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp isRewardAllowed = creature->IsDamageEnoughForLootingAndReward(); if (!isRewardAllowed) creature->SetLootRecipient(nullptr); + + // Call creature just died function + if (CreatureAI* ai = creature->AI()) + { + ai->JustDied(killer); + sScriptMgr->OnUnitDeath(creature, killer); + } } // pussywizard: remade this if section (player is on the same map @@ -18074,13 +18081,6 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp if (killer && killer->GetTypeId() == TYPEID_UNIT && killer->IsAIEnabled) killer->ToCreature()->AI()->KilledUnit(victim); - // Call creature just died function - if (CreatureAI* ai = creature->AI()) - { - ai->JustDied(killer); - sScriptMgr->OnUnitDeath(creature, killer); - } - if (TempSummon* summon = creature->ToTempSummon()) { if (WorldObject* summoner = summon->GetSummoner()) From d29c523af1c1339de8293de896d3c036d42155fe Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 01:09:26 -0300 Subject: [PATCH 46/87] fix(DB/SAI): Script Sunseeker Netherbinder (#14958) --- .../rev_1676174163801356100.sql | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676174163801356100.sql diff --git a/data/sql/updates/pending_db_world/rev_1676174163801356100.sql b/data/sql/updates/pending_db_world/rev_1676174163801356100.sql new file mode 100644 index 000000000..af823096e --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676174163801356100.sql @@ -0,0 +1,18 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 20478; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 20478); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(20478, 0, 0, 0, 54, 0, 100, 0, 0, 0, 0, 0, 0, 11, 35259, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Arcane Servant - On Just Summoned - Cast \'Spotlight\''), +(20478, 0, 1, 0, 0, 0, 100, 0, 20000, 25000, 20000, 25000, 0, 11, 35255, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Arcane Servant - In Combat - Cast \'Arcane Volley\''), +(20478, 0, 2, 0, 54, 0, 100, 0, 0, 0, 0, 0, 0, 11, 22271, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Arcane Servant - On Just Summoned - Cast \'Arcane Explosion\''); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 20059); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(20059, 0, 0, 0, 0, 0, 100, 2, 15000, 30000, 15000, 30000, 0, 11, 35243, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - In Combat - Cast \'Starfire\' (Normal Dungeon)'), +(20059, 0, 1, 0, 0, 0, 100, 4, 15000, 30000, 15000, 30000, 0, 11, 38935, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - In Combat - Cast \'Starfire\' (Heroic Dungeon)'), +(20059, 0, 2, 0, 9, 0, 100, 2, 0, 8, 9000, 10000, 0, 11, 35261, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - Within 0-8 Range - Cast \'Arcane Nova\' (Normal Dungeon)'), +(20059, 0, 3, 0, 9, 0, 100, 4, 0, 8, 9000, 10000, 0, 11, 38936, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - Within 0-8 Range - Cast \'Arcane Nova\' (Heroic Dungeon)'), +(20059, 0, 4, 0, 0, 0, 100, 4, 5000, 5000, 10000, 10000, 0, 11, 17201, 0, 0, 0, 0, 0, 26, 30, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - In Combat - Cast \'Dispel Magic\' (Heroic Dungeon)'), +(20059, 0, 5, 0, 0, 0, 100, 0, 20000, 20000, 40000, 40000, 0, 11, 35251, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - In Combat - Cast \'Summon Arcane Golem\''), +(20059, 0, 6, 0, 0, 0, 100, 0, 20000, 20000, 40000, 40000, 0, 11, 35260, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Sunseeker Netherbinder - In Combat - Cast \'Summon Arcane Golem\''); From 1d414a35ba94306230a5b0157b73219817486975 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 04:11:43 +0000 Subject: [PATCH 47/87] chore(DB): import pending files Referenced commit(s): d29c523af1c1339de8293de896d3c036d42155fe --- .../rev_1676174163801356100.sql => db_world/2023_02_12_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1676174163801356100.sql => db_world/2023_02_12_00.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1676174163801356100.sql b/data/sql/updates/db_world/2023_02_12_00.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1676174163801356100.sql rename to data/sql/updates/db_world/2023_02_12_00.sql index af823096e..5da58c0ae 100644 --- a/data/sql/updates/pending_db_world/rev_1676174163801356100.sql +++ b/data/sql/updates/db_world/2023_02_12_00.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_11_09 -> 2023_02_12_00 -- UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 20478; From 5a9aeada1211776791064be7c675c08649253bbd Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Sun, 12 Feb 2023 10:51:42 +0100 Subject: [PATCH 48/87] feat(Core/DBC): Implement NamesProfanity and NamesReserved DBC (#14956) --- .../rev_1676164598799512000.sql | 16 +++ .../apps/worldserver/worldserver.conf.dist | 18 +++ src/server/game/DataStores/DBCStores.cpp | 5 + src/server/game/DataStores/DBCStores.h | 2 + src/server/game/Globals/ObjectMgr.cpp | 124 ++++++++++++++++++ src/server/game/Globals/ObjectMgr.h | 2 + src/server/game/Handlers/CharacterHandler.cpp | 27 ---- src/server/game/World/IWorld.h | 2 + src/server/game/World/World.cpp | 2 + src/server/shared/DataStores/DBCStructure.h | 14 ++ src/server/shared/DataStores/DBCfmt.h | 2 + 11 files changed, 187 insertions(+), 27 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1676164598799512000.sql diff --git a/data/sql/updates/pending_db_world/rev_1676164598799512000.sql b/data/sql/updates/pending_db_world/rev_1676164598799512000.sql new file mode 100644 index 000000000..93ad8fb58 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676164598799512000.sql @@ -0,0 +1,16 @@ +-- +DROP TABLE IF EXISTS `namesreserved_dbc`; +CREATE TABLE `namesreserved_dbc` ( + `ID` INT UNSIGNED NOT NULL, + `Pattern` TINYTEXT NOT NULL, + `LanguagueID` TINYINT NOT NULL, + PRIMARY KEY (`ID`) +); + +DROP TABLE IF EXISTS `namesprofanity_dbc`; +CREATE TABLE `namesprofanity_dbc` ( + `ID` INT UNSIGNED NOT NULL, + `Pattern` TINYTEXT NOT NULL, + `LanguagueID` TINYINT NOT NULL, + PRIMARY KEY (`ID`) +); diff --git a/src/server/apps/worldserver/worldserver.conf.dist b/src/server/apps/worldserver/worldserver.conf.dist index dc296e4ab..4ef0b35d3 100644 --- a/src/server/apps/worldserver/worldserver.conf.dist +++ b/src/server/apps/worldserver/worldserver.conf.dist @@ -626,6 +626,24 @@ RealmZone = 1 World.RealmAvailability = 1 +# +# StrictNames.Reserved +# Description: Use the Reserved Filter from DBC. +# Prevents Player, Pet & Charter names from containing reserved names. +# Default: 1 - Enabled +# 0 - Disabled + +StrictNames.Reserved = 1 + +# +# StrictNames.Profanity +# Description: Use the Profanity Filter from DBC. +# Prevents Player, Pet & Charter names from containing profanity. +# Default: 1 - Enabled +# 0 - Disabled + +StrictNames.Profanity = 1 + # # StrictPlayerNames # Description: Limit player name to language specific symbol set. Prevents character diff --git a/src/server/game/DataStores/DBCStores.cpp b/src/server/game/DataStores/DBCStores.cpp index ab07cbb40..400b294f8 100644 --- a/src/server/game/DataStores/DBCStores.cpp +++ b/src/server/game/DataStores/DBCStores.cpp @@ -121,6 +121,9 @@ MapDifficultyMap sMapDifficultyMap; DBCStorage sMovieStore(MovieEntryfmt); +DBCStorage sNamesReservedStore(NamesReservedfmt); +DBCStorage sNamesProfanityStore(NamesProfanityfmt); + DBCStorage sOverrideSpellDataStore(OverrideSpellDatafmt); DBCStorage sPowerDisplayStore(PowerDisplayfmt); @@ -330,6 +333,8 @@ void LoadDBCStores(const std::string& dataPath) LOAD_DBC(sMapStore, "Map.dbc", "map_dbc"); LOAD_DBC(sMapDifficultyStore, "MapDifficulty.dbc", "mapdifficulty_dbc"); LOAD_DBC(sMovieStore, "Movie.dbc", "movie_dbc"); + LOAD_DBC(sNamesReservedStore, "NamesReserved.dbc", "namesreserved_dbc"); + LOAD_DBC(sNamesProfanityStore, "NamesProfanity.dbc", "namesprofanity_dbc"); LOAD_DBC(sOverrideSpellDataStore, "OverrideSpellData.dbc", "overridespelldata_dbc"); LOAD_DBC(sPowerDisplayStore, "PowerDisplay.dbc", "powerdisplay_dbc"); LOAD_DBC(sPvPDifficultyStore, "PvpDifficulty.dbc", "pvpdifficulty_dbc"); diff --git a/src/server/game/DataStores/DBCStores.h b/src/server/game/DataStores/DBCStores.h index c9e70faee..07bf72a63 100644 --- a/src/server/game/DataStores/DBCStores.h +++ b/src/server/game/DataStores/DBCStores.h @@ -138,6 +138,8 @@ extern DBCStorage sMapStore; //extern DBCStorage sMapDifficultyStore; -- use GetMapDifficultyData insteed extern MapDifficultyMap sMapDifficultyMap; extern DBCStorage sMovieStore; +extern DBCStorage sNamesReservedStore; +extern DBCStorage sNamesProfanityStore; extern DBCStorage sOverrideSpellDataStore; extern DBCStorage sPowerDisplayStore; extern DBCStorage sQuestSortStore; diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index e05a041a2..a9fe13080 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -26,6 +26,7 @@ #include "Config.h" #include "Containers.h" #include "DatabaseEnv.h" +#include "DBCStructure.h" #include "DisableMgr.h" #include "GameObjectAIFactory.h" #include "GameEventMgr.h" @@ -53,6 +54,7 @@ #include "World.h" #include "StringConvert.h" #include "Tokenize.h" +#include ScriptMapMap sSpellScripts; ScriptMapMap sEventScripts; @@ -203,6 +205,62 @@ std::string ScriptInfo::GetDebugInfo() const return std::string(sz); } +/** + * @name ReservedNames + * @brief Checks NamesReserved.dbc for reserved names + * + * @param name Name to check for match in NamesReserved.dbc + * @return true/false + */ +bool ReservedNames(std::wstring& name) +{ + for (NamesReservedEntry const* reservedStore : sNamesReservedStore) + { + std::wstring PatternString; + + Utf8toWStr(reservedStore->Pattern, PatternString); + + boost::algorithm::replace_all(PatternString, "\\<", ""); + boost::algorithm::replace_all(PatternString, "\\>", ""); + + int stringCompare = name.compare(PatternString); + if (stringCompare == 0) + { + return true; + } + } + + return false; +}; + +/** + * @name ProfanityNames + * @brief Checks NamesProfanity.dbc for reserved names + * + * @param name Name to check for match in NamesProfanity.dbc + * @return true/false + */ +bool ProfanityNames(std::wstring& name) +{ + for (NamesProfanityEntry const* profanityStore : sNamesProfanityStore) + { + std::wstring PatternString; + + Utf8toWStr(profanityStore->Pattern, PatternString); + + boost::algorithm::replace_all(PatternString, "\\<", ""); + boost::algorithm::replace_all(PatternString, "\\>", ""); + + int stringCompare = name.compare(PatternString); + if (stringCompare == 0) + { + return true; + } + } + + return false; +} + bool normalizePlayerName(std::string& name) { if (name.empty()) @@ -8222,25 +8280,55 @@ bool isValidString(std::wstring wstr, uint32 strictMask, bool numericOrSpace, bo uint8 ObjectMgr::CheckPlayerName(std::string_view name, bool create) { std::wstring wname; + + // Check for invalid characters if (!Utf8toWStr(name, wname)) return CHAR_NAME_INVALID_CHARACTER; + // Check for too long name if (wname.size() > MAX_PLAYER_NAME) return CHAR_NAME_TOO_LONG; + // Check for too short name uint32 minName = sWorld->getIntConfig(CONFIG_MIN_PLAYER_NAME); if (wname.size() < minName) return CHAR_NAME_TOO_SHORT; + // Check for mixed languages uint32 strictMask = sWorld->getIntConfig(CONFIG_STRICT_PLAYER_NAMES); if (!isValidString(wname, strictMask, false, create)) return CHAR_NAME_MIXED_LANGUAGES; + // Check for three consecutive letters wstrToLower(wname); for (size_t i = 2; i < wname.size(); ++i) if (wname[i] == wname[i - 1] && wname[i] == wname[i - 2]) return CHAR_NAME_THREE_CONSECUTIVE; + // Check Reserved Name from Database + if (sObjectMgr->IsReservedName(name)) + { + return CHAR_NAME_RESERVED; + } + + // Check for Reserved Name from DBC + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_RESERVED)) + { + if (ReservedNames(wname)) + { + return CHAR_NAME_RESERVED; + } + } + + // Check for Profanity + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_PROFANITY)) + { + if (ProfanityNames(wname)) + { + return CHAR_NAME_PROFANE; + } + } + return CHAR_NAME_SUCCESS; } @@ -8257,6 +8345,24 @@ bool ObjectMgr::IsValidCharterName(std::string_view name) if (wname.size() < minName) return false; + // Check for Reserved Name from DBC + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_RESERVED)) + { + if (ReservedNames(wname)) + { + return false; + } + } + + // Check for Profanity + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_PROFANITY)) + { + if (ProfanityNames(wname)) + { + return false; + } + } + uint32 strictMask = sWorld->getIntConfig(CONFIG_STRICT_CHARTER_NAMES); return isValidString(wname, strictMask, true); @@ -8293,6 +8399,24 @@ PetNameInvalidReason ObjectMgr::CheckPetName(std::string_view name) if (!isValidString(wname, strictMask, false)) return PET_NAME_MIXED_LANGUAGES; + // Check for Reserved Name from DBC + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_RESERVED)) + { + if (ReservedNames(wname)) + { + return PET_NAME_RESERVED; + } + } + + // Check for Profanity + if (sWorld->getBoolConfig(CONFIG_STRICT_NAMES_PROFANITY)) + { + if (ProfanityNames(wname)) + { + return PET_NAME_PROFANE; + } + } + return PET_NAME_SUCCESS; } diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index 0344f6726..28b13f10c 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -691,6 +691,8 @@ SkillRangeType GetSkillRangeType(SkillRaceClassInfoEntry const* rcEntry); #define MAX_CHARTER_NAME 24 // max allowed by client name length #define MAX_CHANNEL_NAME 50 // pussywizard +bool ReservedNames(std::wstring& name); +bool ProfanityNames(std::wstring& name); bool normalizePlayerName(std::string& name); struct LanguageDesc diff --git a/src/server/game/Handlers/CharacterHandler.cpp b/src/server/game/Handlers/CharacterHandler.cpp index 623a0a517..55fd51650 100644 --- a/src/server/game/Handlers/CharacterHandler.cpp +++ b/src/server/game/Handlers/CharacterHandler.cpp @@ -356,12 +356,6 @@ void WorldSession::HandleCharCreateOpcode(WorldPacket& recvData) return; } - if (AccountMgr::IsPlayerAccount(GetSecurity()) && sObjectMgr->IsReservedName(createInfo->Name)) - { - SendCharCreate(CHAR_NAME_RESERVED); - return; - } - // speedup check for heroic class disabled case uint32 heroic_free_slots = sWorld->getIntConfig(CONFIG_HEROIC_CHARACTERS_PER_REALM); if (heroic_free_slots == 0 && AccountMgr::IsPlayerAccount(GetSecurity()) && createInfo->Class == CLASS_DEATH_KNIGHT) @@ -1351,13 +1345,6 @@ void WorldSession::HandleCharRenameOpcode(WorldPacket& recvData) return; } - // check name limitations - if (AccountMgr::IsPlayerAccount(GetSecurity()) && sObjectMgr->IsReservedName(renameInfo->Name)) - { - SendCharRename(CHAR_NAME_RESERVED, renameInfo.get()); - return; - } - // Ensure that the character belongs to the current account, that rename at login is enabled // and that there is no character with the desired new name CharacterDatabasePreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_FREE_NAME); @@ -1698,13 +1685,6 @@ void WorldSession::HandleCharCustomizeCallback(std::shared_ptrIsReservedName(customizeInfo->Name)) - { - SendCharCustomize(CHAR_NAME_RESERVED, customizeInfo.get()); - return; - } - // character with this name already exist if (ObjectGuid newguid = sCharacterCache->GetCharacterGuidByName(customizeInfo->Name)) { @@ -2083,13 +2063,6 @@ void WorldSession::HandleCharFactionOrRaceChangeCallback(std::shared_ptrIsReservedName(factionChangeInfo->Name)) - { - SendCharFactionChange(CHAR_NAME_RESERVED, factionChangeInfo.get()); - return; - } - // character with this name already exist if (ObjectGuid newguid = sCharacterCache->GetCharacterGuidByName(factionChangeInfo->Name)) { diff --git a/src/server/game/World/IWorld.h b/src/server/game/World/IWorld.h index 38d6a4c0b..cd7e2f369 100644 --- a/src/server/game/World/IWorld.h +++ b/src/server/game/World/IWorld.h @@ -179,6 +179,8 @@ enum WorldBoolConfigs CONFIG_OBJECT_SPARKLES, CONFIG_LOW_LEVEL_REGEN_BOOST, CONFIG_OBJECT_QUEST_MARKERS, + CONFIG_STRICT_NAMES_RESERVED, + CONFIG_STRICT_NAMES_PROFANITY, CONFIG_ALLOWS_RANK_MOD_FOR_PET_HEALTH, BOOL_CONFIG_VALUE_COUNT }; diff --git a/src/server/game/World/World.cpp b/src/server/game/World/World.cpp index 234b483de..568cf32a9 100644 --- a/src/server/game/World/World.cpp +++ b/src/server/game/World/World.cpp @@ -718,6 +718,8 @@ void World::LoadConfigSettings(bool reload) else _int_configs[CONFIG_REALM_ZONE] = sConfigMgr->GetOption("RealmZone", REALM_ZONE_DEVELOPMENT); + _bool_configs[CONFIG_STRICT_NAMES_RESERVED] = sConfigMgr->GetOption ("StrictNames.Reserved", true); + _bool_configs[CONFIG_STRICT_NAMES_PROFANITY] = sConfigMgr->GetOption ("StrictNames.Profanity", true); _int_configs[CONFIG_STRICT_PLAYER_NAMES] = sConfigMgr->GetOption ("StrictPlayerNames", 0); _int_configs[CONFIG_STRICT_CHARTER_NAMES] = sConfigMgr->GetOption ("StrictCharterNames", 0); _int_configs[CONFIG_STRICT_CHANNEL_NAMES] = sConfigMgr->GetOption ("StrictChannelNames", 0); diff --git a/src/server/shared/DataStores/DBCStructure.h b/src/server/shared/DataStores/DBCStructure.h index 38f0d6405..669a83e19 100644 --- a/src/server/shared/DataStores/DBCStructure.h +++ b/src/server/shared/DataStores/DBCStructure.h @@ -1377,6 +1377,20 @@ struct MovieEntry //uint32 unk2; // 2 always 100 }; +struct NamesReservedEntry +{ + //uint32 ID; // 0 + char const* Pattern; // 1 + //uint32 Language; // 2 +}; + +struct NamesProfanityEntry +{ + //uint32 ID; // 0 + char const* Pattern; // 1 + //uint32 Language; // 2 +}; + #define MAX_OVERRIDE_SPELL 10 struct OverrideSpellDataEntry diff --git a/src/server/shared/DataStores/DBCfmt.h b/src/server/shared/DataStores/DBCfmt.h index abd37d1e3..dc8fefb35 100644 --- a/src/server/shared/DataStores/DBCfmt.h +++ b/src/server/shared/DataStores/DBCfmt.h @@ -84,6 +84,8 @@ char constexpr MailTemplateEntryfmt[] = "nxxxxxxxxxxxxxxxxxssssssssssssssssx"; char constexpr MapEntryfmt[] = "nxiixssssssssssssssssxixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxixiffxiii"; char constexpr MapDifficultyEntryfmt[] = "diisxxxxxxxxxxxxxxxxiix"; char constexpr MovieEntryfmt[] = "nxx"; +char constexpr NamesReservedfmt[] = "xsx"; +char constexpr NamesProfanityfmt[] = "xsx"; char constexpr OverrideSpellDatafmt[] = "niiiiiiiiiix"; char constexpr PowerDisplayfmt[] = "nixxxx"; char constexpr QuestSortEntryfmt[] = "nxxxxxxxxxxxxxxxxx"; From 726bd6a8c129b3191b118705fc48f5821126ef18 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 09:54:01 +0000 Subject: [PATCH 49/87] chore(DB): import pending files Referenced commit(s): 5a9aeada1211776791064be7c675c08649253bbd --- .../rev_1676164598799512000.sql => db_world/2023_02_12_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1676164598799512000.sql => db_world/2023_02_12_01.sql} (90%) diff --git a/data/sql/updates/pending_db_world/rev_1676164598799512000.sql b/data/sql/updates/db_world/2023_02_12_01.sql similarity index 90% rename from data/sql/updates/pending_db_world/rev_1676164598799512000.sql rename to data/sql/updates/db_world/2023_02_12_01.sql index 93ad8fb58..e4fd56f2e 100644 --- a/data/sql/updates/pending_db_world/rev_1676164598799512000.sql +++ b/data/sql/updates/db_world/2023_02_12_01.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_00 -> 2023_02_12_01 -- DROP TABLE IF EXISTS `namesreserved_dbc`; CREATE TABLE `namesreserved_dbc` ( From 48ce9575973f639ff99463b7981965edf52760e0 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 12:27:25 +0100 Subject: [PATCH 50/87] fix(Scripts/BlackMorass): Adds should walk towards Medivh. (#14945) --- .../rev_1676119703739192300.sql | 2 + src/server/game/Movement/MotionMaster.cpp | 4 +- src/server/game/Movement/MotionMaster.h | 2 +- .../HomeMovementGenerator.cpp | 2 +- .../HomeMovementGenerator.h | 3 +- .../TheBlackMorass/the_black_morass.cpp | 562 +++++++++--------- .../TheBlackMorass/the_black_morass.h | 2 + 7 files changed, 290 insertions(+), 287 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1676119703739192300.sql diff --git a/data/sql/updates/pending_db_world/rev_1676119703739192300.sql b/data/sql/updates/pending_db_world/rev_1676119703739192300.sql new file mode 100644 index 000000000..8c3c75827 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676119703739192300.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `ScriptName`='npc_black_morass_summoned_add' WHERE `entry` IN (17835,21818,17892,18994,18995,21137,21136,21138,21139); diff --git a/src/server/game/Movement/MotionMaster.cpp b/src/server/game/Movement/MotionMaster.cpp index fe8075ddb..27daa3196 100644 --- a/src/server/game/Movement/MotionMaster.cpp +++ b/src/server/game/Movement/MotionMaster.cpp @@ -248,14 +248,14 @@ void MotionMaster::MoveRandom(float wanderDistance) } } -void MotionMaster::MoveTargetedHome() +void MotionMaster::MoveTargetedHome(bool walk /*= false*/) { Clear(false); if (_owner->GetTypeId() == TYPEID_UNIT && !_owner->ToCreature()->GetCharmerOrOwnerGUID()) { LOG_DEBUG("movement.motionmaster", "Creature ({}) targeted home", _owner->GetGUID().ToString()); - Mutate(new HomeMovementGenerator(), MOTION_SLOT_ACTIVE); + Mutate(new HomeMovementGenerator(walk), MOTION_SLOT_ACTIVE); } else if (_owner->GetTypeId() == TYPEID_UNIT && _owner->ToCreature()->GetCharmerOrOwnerGUID()) { diff --git a/src/server/game/Movement/MotionMaster.h b/src/server/game/Movement/MotionMaster.h index 73d8144c6..4693025de 100644 --- a/src/server/game/Movement/MotionMaster.h +++ b/src/server/game/Movement/MotionMaster.h @@ -197,7 +197,7 @@ public: } void MoveIdle(); - void MoveTargetedHome(); + void MoveTargetedHome(bool walk = false); void MoveRandom(float wanderDistance = 0.0f); void MoveFollow(Unit* target, float dist, float angle, MovementSlot slot = MOTION_SLOT_ACTIVE); void MoveChase(Unit* target, std::optional dist = {}, std::optional angle = {}); diff --git a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp index 818342744..ee8c9dfcc 100644 --- a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp @@ -65,7 +65,7 @@ void HomeMovementGenerator::_setTargetLocation(Creature* owner) owner->UpdateAllowedPositionZ(x, y, z); init.MoveTo(x, y, z, DisableMgr::IsPathfindingEnabled(owner->FindMap()), true); - init.SetWalk(false); + init.SetWalk(_walk); init.Launch(); arrived = false; diff --git a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h index 1b4395d36..82da2b0f2 100644 --- a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h @@ -29,7 +29,7 @@ template <> class HomeMovementGenerator : public MovementGeneratorMedium< Creature, HomeMovementGenerator > { public: - HomeMovementGenerator() : arrived(false), i_recalculateTravel(false) {} + HomeMovementGenerator(bool walk) : arrived(false), i_recalculateTravel(false), _walk(walk) {} ~HomeMovementGenerator() {} void DoInitialize(Creature*); @@ -43,5 +43,6 @@ private: void _setTargetLocation(Creature*); bool arrived : 1; bool i_recalculateTravel : 1; + bool _walk; }; #endif diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp index b1d88ca83..b3a27299b 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp @@ -17,6 +17,7 @@ #include "the_black_morass.h" #include "MoveSplineInit.h" +#include "SmartAI.h" #include "ScriptMgr.h" #include "ScriptedCreature.h" #include "ScriptedGossip.h" @@ -82,195 +83,194 @@ private: Creature& _owner; }; -class npc_medivh_bm : public CreatureScript +struct npc_medivh_bm : public ScriptedAI { -public: - npc_medivh_bm() : CreatureScript("npc_medivh_bm") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_medivh_bm(Creature* creature) : ScriptedAI(creature) { - return GetTheBlackMorassAI(creature); + _instance = creature->GetInstanceScript(); + + _groundArray.clear(); + _airArray.clear(); + + _groundArray.push_back(G3D::Vector3(creature->GetPositionX() + 8.0f, creature->GetPositionY(), creature->GetPositionZ())); + _airArray.push_back(G3D::Vector3(creature->GetPositionX(), creature->GetPositionY(), creature->GetPositionZ())); + + for (uint8 i = 0; i < 10; ++i) + { + _groundArray.push_back(G3D::Vector3(creature->GetPositionX() + 8.0f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + 8.0f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ())); + } + + for (uint8 i = 0; i < 40; ++i) + { + _airArray.push_back(G3D::Vector3(creature->GetPositionX() + i * 0.25f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + i * 0.25f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ() + i / 4.0f)); + } + + for (uint8 i = 40; i < 80; ++i) + { + _airArray.push_back(G3D::Vector3(creature->GetPositionX() + 10.0f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + 10.0f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ() + i / 4.0f)); + } } - struct npc_medivh_bmAI : public ScriptedAI + void Reset() override { - npc_medivh_bmAI(Creature* creature) : ScriptedAI(creature) + events.Reset(); + me->CastSpell(me, SPELL_MANA_SHIELD, true); + + if (_instance->GetData(TYPE_AEONUS) != DONE) { - instance = creature->GetInstanceScript(); + me->CastSpell(me, SPELL_MEDIVH_CHANNEL, false); + } + } - groundArray.clear(); - airArray.clear(); + void JustSummoned(Creature* summon) override + { + _instance->SetGuidData(DATA_SUMMONED_NPC, summon->GetGUID()); - groundArray.push_back(G3D::Vector3(creature->GetPositionX() + 8.0f, creature->GetPositionY(), creature->GetPositionZ())); - airArray.push_back(G3D::Vector3(creature->GetPositionX(), creature->GetPositionY(), creature->GetPositionZ())); - for (uint8 i = 0; i < 10; ++i) - groundArray.push_back(G3D::Vector3(creature->GetPositionX() + 8.0f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + 8.0f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ())); + if (summon->GetEntry() == NPC_DP_CRYSTAL_STALKER) + { + summon->DespawnOrUnsummon(25000); + summon->CastSpell(summon, RAND(SPELL_BANISH_PURPLE, SPELL_BANISH_GREEN), true); + summon->GetMotionMaster()->MoveSplinePath(&_airArray); + } + else if (summon->GetEntry() == NPC_DP_EMITTER_STALKER) + { + summon->CastSpell(summon, SPELL_BLACK_CRYSTAL, true); + Movement::MoveSplineInit init(summon); + init.MovebyPath(_groundArray); + init.SetCyclic(); + init.Launch(); + } + } - for (uint8 i = 0; i < 40; ++i) - airArray.push_back(G3D::Vector3(creature->GetPositionX() + i * 0.25f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + i * 0.25f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ() + i / 4.0f)); - for (uint8 i = 40; i < 80; ++i) - airArray.push_back(G3D::Vector3(creature->GetPositionX() + 10.0f * cos(2.0f * M_PI * i / 10.0f), creature->GetPositionY() + 10.0f * std::sin(2.0f * M_PI * i / 10.0f), creature->GetPositionZ() + i / 4.0f)); + void SummonedCreatureDespawn(Creature* summon) override + { + _instance->SetGuidData(DATA_DELETED_NPC, summon->GetGUID()); + } + + void MoveInLineOfSight(Unit* who) override + { + if (!events.Empty() || _instance->GetData(TYPE_AEONUS) == DONE) + { + return; } - InstanceScript* instance; - EventMap events; - Movement::PointsArray groundArray; - Movement::PointsArray airArray; + if (who->GetTypeId() == TYPEID_PLAYER && me->IsWithinDistInMap(who, 20.0f)) + { + Talk(SAY_ENTER); + _instance->SetData(DATA_MEDIVH, 1); - void Reset() override + me->CastSpell(me, SPELL_MEDIVH_CHANNEL, false); + + events.ScheduleEvent(EVENT_CHECK_HEALTH_75, 500); + events.ScheduleEvent(EVENT_CHECK_HEALTH_50, 500); + events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 500); + events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 2000); + events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 4000); + events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 6000); + events.ScheduleEvent(EVENT_SUMMON_FLYING_CRYSTAL, 8000); + } + } + + void AttackStart(Unit* ) override { } + + void DoAction(int32 param) override + { + if (param == ACTION_OUTRO) { events.Reset(); - me->CastSpell(me, SPELL_MANA_SHIELD, true); + events.ScheduleEvent(EVENT_OUTRO_1, 4000); + me->InterruptNonMeleeSpells(true); - if (instance && instance->GetData(TYPE_AEONUS) != DONE) - me->CastSpell(me, SPELL_MEDIVH_CHANNEL, false); + me->SummonGameObject(GO_DARK_PORTAL, -2086.0f, 7125.6215f, 30.5f, 6.148f, 0.0f, 0.0f, 0.0f, 0.0f, 0); } + } - void JustSummoned(Creature* summon) override + void JustDied(Unit* /*killer*/) override + { + me->SetRespawnTime(DAY); + events.Reset(); + Talk(SAY_DEATH); + } + + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (uint32 eventId = events.ExecuteEvent()) { - if (instance) - instance->SetGuidData(DATA_SUMMONED_NPC, summon->GetGUID()); - - if (summon->GetEntry() == NPC_DP_CRYSTAL_STALKER) - { - summon->DespawnOrUnsummon(25000); - summon->CastSpell(summon, RAND(SPELL_BANISH_PURPLE, SPELL_BANISH_GREEN), true); - summon->GetMotionMaster()->MoveSplinePath(&airArray); - } - else if (summon->GetEntry() == NPC_DP_EMITTER_STALKER) - { - summon->CastSpell(summon, SPELL_BLACK_CRYSTAL, true); - Movement::MoveSplineInit init(summon); - init.MovebyPath(groundArray); - init.SetCyclic(); - init.Launch(); - } - } - - void SummonedCreatureDespawn(Creature* summon) override - { - if (instance) - instance->SetGuidData(DATA_DELETED_NPC, summon->GetGUID()); - } - - void MoveInLineOfSight(Unit* who) override - { - if (!events.Empty() || (instance && instance->GetData(TYPE_AEONUS) == DONE)) - return; - - if (who->GetTypeId() == TYPEID_PLAYER && me->IsWithinDistInMap(who, 20.0f)) - { - Talk(SAY_ENTER); - if (instance) - instance->SetData(DATA_MEDIVH, 1); - - me->CastSpell(me, SPELL_MEDIVH_CHANNEL, false); - - events.ScheduleEvent(EVENT_CHECK_HEALTH_75, 500); - events.ScheduleEvent(EVENT_CHECK_HEALTH_50, 500); - events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 500); - events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 2000); - events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 4000); - events.ScheduleEvent(EVENT_SUMMON_CRYSTAL, 6000); - events.ScheduleEvent(EVENT_SUMMON_FLYING_CRYSTAL, 8000); - } - } - - void AttackStart(Unit* ) override { } - - void DoAction(int32 param) override - { - if (param == ACTION_OUTRO) - { - events.Reset(); - events.ScheduleEvent(EVENT_OUTRO_1, 4000); - me->InterruptNonMeleeSpells(true); - - me->SummonGameObject(GO_DARK_PORTAL, -2086.0f, 7125.6215f, 30.5f, 6.148f, 0.0f, 0.0f, 0.0f, 0.0f, 0); - } - } - - void JustDied(Unit* /*killer*/) override - { - me->SetRespawnTime(DAY); - events.Reset(); - Talk(SAY_DEATH); - } - - void UpdateAI(uint32 diff) override - { - events.Update(diff); - switch (uint32 eventId = events.ExecuteEvent()) - { - case EVENT_CHECK_HEALTH_25: - case EVENT_CHECK_HEALTH_50: - case EVENT_CHECK_HEALTH_75: - if (instance && instance->GetData(DATA_SHIELD_PERCENT) <= eventId * 25) - { - Talk(eventId + 1); - break; - } - events.ScheduleEvent(eventId, 500); - break; - case EVENT_SUMMON_CRYSTAL: - me->SummonCreature(NPC_DP_EMITTER_STALKER, me->GetPositionX() + 8.0f, me->GetPositionY(), me->GetPositionZ()); - break; - case EVENT_SUMMON_FLYING_CRYSTAL: - me->CastSpell(me, SPELL_PORTAL_CRYSTALS, true); - events.ScheduleEvent(EVENT_SUMMON_FLYING_CRYSTAL, 1000); - break; - case EVENT_OUTRO_1: - me->SetFacingTo(6.21f); - Talk(SAY_WIN); - events.ScheduleEvent(EVENT_OUTRO_2, 17000); - break; - case EVENT_OUTRO_2: - me->SetFacingTo(3.07f); - events.ScheduleEvent(EVENT_OUTRO_3, 2000); - break; - case EVENT_OUTRO_3: - SummonOrcs(-2046.158f, -3.0f, 37000, 30000, true); - events.ScheduleEvent(EVENT_OUTRO_4, 2000); - break; - case EVENT_OUTRO_4: - SummonOrcs(-2055.97f, -2.0f, 33000, 28000, false); - events.ScheduleEvent(EVENT_OUTRO_5, 2000); - break; - case EVENT_OUTRO_5: - SummonOrcs(-2064.0f, -1.5f, 29000, 26000, false); - events.ScheduleEvent(EVENT_OUTRO_6, 2000); - break; - case EVENT_OUTRO_6: - SummonOrcs(-2074.35f, -0.1f, 26000, 24000, false); - events.ScheduleEvent(EVENT_OUTRO_7, 7000); - break; - case EVENT_OUTRO_7: - Talk(SAY_ORCS_ENTER); - events.ScheduleEvent(EVENT_OUTRO_8, 7000); - break; - case EVENT_OUTRO_8: - if (Creature* cr = me->FindNearestCreature(NPC_SHADOW_COUNCIL_ENFORCER, 20.0f)) - { - cr->SetFacingTo(3.07f); - cr->AI()->Talk(SAY_ORCS_ANSWER); - } - break; - } - } - - void SummonOrcs(float x, float y, uint32 duration, uint32 homeTime, bool first) - { - for (uint8 i = 0; i < 6; ++i) - { - if (Creature* cr = me->SummonCreature(NPC_SHADOW_COUNCIL_ENFORCER, -2091.731f, 7133.083f - 3.0f * i, 34.589f, 0.0f)) + case EVENT_CHECK_HEALTH_25: + case EVENT_CHECK_HEALTH_50: + case EVENT_CHECK_HEALTH_75: + if (_instance->GetData(DATA_SHIELD_PERCENT) <= eventId * 25) { - cr->GetMotionMaster()->MovePoint(0, (first && i == 3) ? x + 2.0f : x, cr->GetPositionY() + y, cr->GetMapHeight(x, cr->GetPositionY() + y, cr->GetPositionZ(), true)); - cr->m_Events.AddEvent(new NpcRunToHome(*cr), cr->m_Events.CalculateTime(homeTime + urand(0, 2000))); - cr->DespawnOrUnsummon(duration + urand(0, 2000)); + Talk(eventId + 1); + break; } + events.ScheduleEvent(eventId, 500); + break; + case EVENT_SUMMON_CRYSTAL: + me->SummonCreature(NPC_DP_EMITTER_STALKER, me->GetPositionX() + 8.0f, me->GetPositionY(), me->GetPositionZ()); + break; + case EVENT_SUMMON_FLYING_CRYSTAL: + me->CastSpell(me, SPELL_PORTAL_CRYSTALS, true); + events.ScheduleEvent(EVENT_SUMMON_FLYING_CRYSTAL, 1000); + break; + case EVENT_OUTRO_1: + me->SetFacingTo(6.21f); + Talk(SAY_WIN); + events.ScheduleEvent(EVENT_OUTRO_2, 17000); + break; + case EVENT_OUTRO_2: + me->SetFacingTo(3.07f); + events.ScheduleEvent(EVENT_OUTRO_3, 2000); + break; + case EVENT_OUTRO_3: + SummonOrcs(-2046.158f, -3.0f, 37000, 30000, true); + events.ScheduleEvent(EVENT_OUTRO_4, 2000); + break; + case EVENT_OUTRO_4: + SummonOrcs(-2055.97f, -2.0f, 33000, 28000, false); + events.ScheduleEvent(EVENT_OUTRO_5, 2000); + break; + case EVENT_OUTRO_5: + SummonOrcs(-2064.0f, -1.5f, 29000, 26000, false); + events.ScheduleEvent(EVENT_OUTRO_6, 2000); + break; + case EVENT_OUTRO_6: + SummonOrcs(-2074.35f, -0.1f, 26000, 24000, false); + events.ScheduleEvent(EVENT_OUTRO_7, 7000); + break; + case EVENT_OUTRO_7: + Talk(SAY_ORCS_ENTER); + events.ScheduleEvent(EVENT_OUTRO_8, 7000); + break; + case EVENT_OUTRO_8: + if (Creature* cr = me->FindNearestCreature(NPC_SHADOW_COUNCIL_ENFORCER, 20.0f)) + { + cr->SetFacingTo(3.07f); + cr->AI()->Talk(SAY_ORCS_ANSWER); + } + break; + } + } + + void SummonOrcs(float x, float y, uint32 duration, uint32 homeTime, bool first) + { + for (uint8 i = 0; i < 6; ++i) + { + if (Creature* cr = me->SummonCreature(NPC_SHADOW_COUNCIL_ENFORCER, -2091.731f, 7133.083f - 3.0f * i, 34.589f, 0.0f)) + { + cr->GetMotionMaster()->MovePoint(0, (first && i == 3) ? x + 2.0f : x, cr->GetPositionY() + y, cr->GetMapHeight(x, cr->GetPositionY() + y, cr->GetPositionZ(), true)); + cr->m_Events.AddEvent(new NpcRunToHome(*cr), cr->m_Events.CalculateTime(homeTime + urand(0, 2000))); + cr->DespawnOrUnsummon(duration + urand(0, 2000)); } } - }; + } + +private: + InstanceScript* _instance; + EventMap _events; + Movement::PointsArray _groundArray; + Movement::PointsArray _airArray; }; enum timeRift @@ -279,151 +279,149 @@ enum timeRift EVENT_CHECK_DEATH = 2 }; -class npc_time_rift : public CreatureScript +struct npc_time_rift : public NullCreatureAI { -public: - npc_time_rift() : CreatureScript("npc_time_rift") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_time_rift(Creature* creature) : NullCreatureAI(creature) { - return GetTheBlackMorassAI(creature); + _instance = creature->GetInstanceScript(); } - struct npc_time_riftAI : public NullCreatureAI + void Reset() override { - npc_time_riftAI(Creature* creature) : NullCreatureAI(creature) + if (_instance->GetData(DATA_RIFT_NUMBER) >= 18) { - instance = creature->GetInstanceScript(); + me->DespawnOrUnsummon(30000); + return; } - EventMap events; - InstanceScript* instance; - ObjectGuid riftKeeperGUID; + events.ScheduleEvent(EVENT_SUMMON_AT_RIFT, 16000); + events.ScheduleEvent(EVENT_CHECK_DEATH, 8000); + } - void Reset() override - { - if (instance && instance->GetData(DATA_RIFT_NUMBER) >= 18) + void SetGUID(ObjectGuid guid, int32) override + { + _riftKeeperGUID = guid; + } + + void DoSummonAtRift(uint32 entry) + { + Position pos = me->GetNearPosition(10.0f, 2 * M_PI * rand_norm()); + + if (Creature* summon = me->SummonCreature(entry, pos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 150000)) + if (_instance) { - me->DespawnOrUnsummon(30000); - return; - } - - events.ScheduleEvent(EVENT_SUMMON_AT_RIFT, 16000); - events.ScheduleEvent(EVENT_CHECK_DEATH, 8000); - } - - void SetGUID(ObjectGuid guid, int32) override - { - riftKeeperGUID = guid; - } - - void DoSummonAtRift(uint32 entry) - { - Position pos = me->GetNearPosition(10.0f, 2 * M_PI * rand_norm()); - - if (Creature* summon = me->SummonCreature(entry, pos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 150000)) - if (instance) + if (Unit* medivh = ObjectAccessor::GetUnit(*me, _instance->GetGuidData(DATA_MEDIVH))) { - if (Unit* medivh = ObjectAccessor::GetUnit(*me, instance->GetGuidData(DATA_MEDIVH))) + float o = medivh->GetAngle(summon) + frand(-1.0f, 1.0f); + summon->SetHomePosition(medivh->GetPositionX() + 14.0f * cos(o), medivh->GetPositionY() + 14.0f * std::sin(o), medivh->GetPositionZ(), summon->GetAngle(medivh)); + summon->GetMotionMaster()->MoveTargetedHome(true); + summon->SetReactState(REACT_DEFENSIVE); + } + } + } + + void DoSelectSummon() + { + uint32 entry = RAND(NPC_INFINITE_ASSASIN, NPC_INFINITE_WHELP, NPC_INFINITE_CRONOMANCER, NPC_INFINITE_EXECUTIONER, NPC_INFINITE_VANQUISHER); + if (entry == NPC_INFINITE_WHELP) + { + DoSummonAtRift(entry); + DoSummonAtRift(entry); + DoSummonAtRift(entry); + } + else + { + DoSummonAtRift(entry); + } + } + + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (events.ExecuteEvent()) + { + case EVENT_SUMMON_AT_RIFT: + DoSelectSummon(); + events.ScheduleEvent(EVENT_SUMMON_AT_RIFT, 15000); + break; + case EVENT_CHECK_DEATH: + if (!me->HasUnitState(UNIT_STATE_CASTING)) + { + Creature* riftKeeper = ObjectAccessor::GetCreature(*me, _riftKeeperGUID); + if (!riftKeeper || !riftKeeper->IsAlive()) { - float o = medivh->GetAngle(summon) + frand(-1.0f, 1.0f); - summon->SetHomePosition(medivh->GetPositionX() + 14.0f * cos(o), medivh->GetPositionY() + 14.0f * std::sin(o), medivh->GetPositionZ(), summon->GetAngle(medivh)); - summon->GetMotionMaster()->MoveTargetedHome(); - summon->SetReactState(REACT_DEFENSIVE); + _instance->SetData(DATA_RIFT_KILLED, 1); + + me->DespawnOrUnsummon(0); + break; + } + else + { + me->CastSpell(riftKeeper, SPELL_RIFT_CHANNEL, false); } } + events.ScheduleEvent(EVENT_CHECK_DEATH, 500); + break; } + } - void DoSelectSummon() - { - uint32 entry = RAND(NPC_INFINITE_ASSASIN, NPC_INFINITE_WHELP, NPC_INFINITE_CRONOMANCER, NPC_INFINITE_EXECUTIONER, NPC_INFINITE_VANQUISHER); - if (entry == NPC_INFINITE_WHELP) - { - DoSummonAtRift(entry); - DoSummonAtRift(entry); - DoSummonAtRift(entry); - } - else - DoSummonAtRift(entry); - } - - void UpdateAI(uint32 diff) override - { - events.Update(diff); - switch (events.ExecuteEvent()) - { - case EVENT_SUMMON_AT_RIFT: - DoSelectSummon(); - events.ScheduleEvent(EVENT_SUMMON_AT_RIFT, 15000); - break; - case EVENT_CHECK_DEATH: - if (!me->HasUnitState(UNIT_STATE_CASTING)) - { - Creature* riftKeeper = ObjectAccessor::GetCreature(*me, riftKeeperGUID); - if (!riftKeeper || !riftKeeper->IsAlive()) - { - if (instance) - instance->SetData(DATA_RIFT_KILLED, 1); - - me->DespawnOrUnsummon(0); - break; - } - else - me->CastSpell(riftKeeper, SPELL_RIFT_CHANNEL, false); - } - events.ScheduleEvent(EVENT_CHECK_DEATH, 500); - break; - } - } - }; +private: + EventMap _events; + InstanceScript* _instance; + ObjectGuid _riftKeeperGUID; }; -class spell_black_morass_corrupt_medivh : public SpellScriptLoader +struct npc_black_morass_summoned_add : public SmartAI { -public: - spell_black_morass_corrupt_medivh() : SpellScriptLoader("spell_black_morass_corrupt_medivh") { } - - class spell_black_morass_corrupt_medivh_AuraScript : public AuraScript + npc_black_morass_summoned_add(Creature* creature) : SmartAI(creature) { - PrepareAuraScript(spell_black_morass_corrupt_medivh_AuraScript); + } - bool Load() override + void EnterEvadeMode(EvadeReason why) override + { + SmartAI::EnterEvadeMode(why); + + me->GetMotionMaster()->MoveTargetedHome(true); + } +}; + +class spell_black_morass_corrupt_medivh : public AuraScript +{ + PrepareAuraScript(spell_black_morass_corrupt_medivh); + + bool Load() override + { + _ticks = 0; + return true; + } + + void PeriodicTick(AuraEffect const* /*aurEff*/) + { + if (++_ticks >= 3) { _ticks = 0; - return true; - } - void PeriodicTick(AuraEffect const* /*aurEff*/) - { - if (++_ticks >= 3) + if (InstanceScript* instance = GetUnitOwner()->GetInstanceScript()) { - _ticks = 0; - - if (InstanceScript* instance = GetUnitOwner()->GetInstanceScript()) - { - instance->SetData(DATA_DAMAGE_SHIELD, m_scriptSpellId == SPELL_CORRUPT_AEONUS ? 2 : 1); - } + instance->SetData(DATA_DAMAGE_SHIELD, m_scriptSpellId == SPELL_CORRUPT_AEONUS ? 2 : 1); } } - - void Register() override - { - OnEffectPeriodic += AuraEffectPeriodicFn(spell_black_morass_corrupt_medivh_AuraScript::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); - } - - private: - uint8 _ticks = 0; - }; - - AuraScript* GetAuraScript() const override - { - return new spell_black_morass_corrupt_medivh_AuraScript(); } + + void Register() override + { + OnEffectPeriodic += AuraEffectPeriodicFn(spell_black_morass_corrupt_medivh::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); + } + +private: + uint8 _ticks = 0; }; void AddSC_the_black_morass() { - new npc_medivh_bm(); - new npc_time_rift(); - new spell_black_morass_corrupt_medivh(); + RegisterTheBlackMorassCreatureAI(npc_medivh_bm); + RegisterTheBlackMorassCreatureAI(npc_time_rift); + RegisterTheBlackMorassCreatureAI(npc_black_morass_summoned_add); + + RegisterSpellScript(spell_black_morass_corrupt_medivh); } diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h index 2666034bc..73874f7c0 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h @@ -94,4 +94,6 @@ inline AI* GetTheBlackMorassAI(T* obj) return GetInstanceAI(obj, TheBlackMorassScriptName); } +#define RegisterTheBlackMorassCreatureAI(ai_name) RegisterCreatureAIWithFactory(ai_name, GetTheBlackMorassAI) + #endif From 1e17eaae0bedc5e03a6b7c5c3792f5c04742b71d Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 08:28:18 -0300 Subject: [PATCH 51/87] fix(Core/SAI): Set minions in combat with their master's victim (#14959) --- src/server/game/AI/SmartScripts/SmartAI.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp index 05d311de6..942041d08 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.cpp +++ b/src/server/game/AI/SmartScripts/SmartAI.cpp @@ -811,6 +811,20 @@ void SmartAI::JustSummoned(Creature* creature) { GetScript()->ProcessEventsFor(SMART_EVENT_SUMMONED_UNIT, creature); GetScript()->AddCreatureSummon(creature->GetGUID()); + + if (me->IsEngaged() && !creature->IsInEvadeMode()) + { + if (Unit* victim = me->GetVictim()) + { + creature->SetInCombatWith(victim); + victim->SetInCombatWith(creature); + + if (creature->CanHaveThreatList()) + { + creature->AddThreat(victim, 0.0f); + } + } + } } void SmartAI::SummonedCreatureDies(Creature* summon, Unit* /*killer*/) From 2595e0c26c5549c72ca98eff59f9c1ded3c26ae5 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 12:28:51 +0100 Subject: [PATCH 52/87] fix(DB/SAI): "Someone Else's Hard Work Pays Off" - fixed ending scene. (#14962) --- data/sql/updates/pending_db_world/rev_1676193535182619400.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676193535182619400.sql diff --git a/data/sql/updates/pending_db_world/rev_1676193535182619400.sql b/data/sql/updates/pending_db_world/rev_1676193535182619400.sql new file mode 100644 index 000000000..12a59157e --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676193535182619400.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `smart_scripts` WHERE `entryorguid`=19671 AND `source_type`=0 AND `id`=19; +INSERT INTO `smart_scripts` VALUES +(19671,0,19,0,54,0,100,0,0,0,0,0,0,211,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,'Cryo-Engineer Sha\'heen - On Just Summoned - Disallow reset phase'); From e76711b6d39210be08ca2ff272bf17198fea12ca Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 11:31:25 +0000 Subject: [PATCH 53/87] chore(DB): import pending files Referenced commit(s): 2595e0c26c5549c72ca98eff59f9c1ded3c26ae5 --- .../rev_1676119703739192300.sql => db_world/2023_02_12_02.sql} | 1 + .../rev_1676193535182619400.sql => db_world/2023_02_12_03.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1676119703739192300.sql => db_world/2023_02_12_02.sql} (77%) rename data/sql/updates/{pending_db_world/rev_1676193535182619400.sql => db_world/2023_02_12_03.sql} (85%) diff --git a/data/sql/updates/pending_db_world/rev_1676119703739192300.sql b/data/sql/updates/db_world/2023_02_12_02.sql similarity index 77% rename from data/sql/updates/pending_db_world/rev_1676119703739192300.sql rename to data/sql/updates/db_world/2023_02_12_02.sql index 8c3c75827..4d41973b5 100644 --- a/data/sql/updates/pending_db_world/rev_1676119703739192300.sql +++ b/data/sql/updates/db_world/2023_02_12_02.sql @@ -1,2 +1,3 @@ +-- DB update 2023_02_12_01 -> 2023_02_12_02 -- UPDATE `creature_template` SET `ScriptName`='npc_black_morass_summoned_add' WHERE `entry` IN (17835,21818,17892,18994,18995,21137,21136,21138,21139); diff --git a/data/sql/updates/pending_db_world/rev_1676193535182619400.sql b/data/sql/updates/db_world/2023_02_12_03.sql similarity index 85% rename from data/sql/updates/pending_db_world/rev_1676193535182619400.sql rename to data/sql/updates/db_world/2023_02_12_03.sql index 12a59157e..e6833da17 100644 --- a/data/sql/updates/pending_db_world/rev_1676193535182619400.sql +++ b/data/sql/updates/db_world/2023_02_12_03.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_02 -> 2023_02_12_03 -- DELETE FROM `smart_scripts` WHERE `entryorguid`=19671 AND `source_type`=0 AND `id`=19; INSERT INTO `smart_scripts` VALUES From e37e6327f046037299e77ea42cc1e837bf5f7da2 Mon Sep 17 00:00:00 2001 From: Maelthyr <100411212+Maelthyrr@users.noreply.github.com> Date: Sun, 12 Feb 2023 14:05:13 +0100 Subject: [PATCH 54/87] refactor(Core/GameObject): Split GameObject for Dynamic Crea/Go (#14889) Co-authored-by: Maelthyrr --- .../game/Entities/GameObject/GameObject.h | 711 +---------------- .../game/Entities/GameObject/GameObjectData.h | 716 ++++++++++++++++++ 2 files changed, 726 insertions(+), 701 deletions(-) create mode 100644 src/server/game/Entities/GameObject/GameObjectData.h diff --git a/src/server/game/Entities/GameObject/GameObject.h b/src/server/game/Entities/GameObject/GameObject.h index 609041a72..61962e75d 100644 --- a/src/server/game/Entities/GameObject/GameObject.h +++ b/src/server/game/Entities/GameObject/GameObject.h @@ -24,6 +24,7 @@ #include "LootMgr.h" #include "Object.h" #include "SharedDefines.h" +#include "GameObjectData.h" #include "Unit.h" #include @@ -31,661 +32,21 @@ class GameObjectAI; class Transport; class StaticTransport; class MotionTransport; +class OPvPCapturePoint; +class Unit; +class GameObjectModel; + +struct TransportAnimation; typedef void(*goEventFlag)(Player*, GameObject*, Battleground*); -#define MAX_GAMEOBJECT_QUEST_ITEMS 6 - -// from `gameobject_template` -struct GameObjectTemplate -{ - uint32 entry; - uint32 type; - uint32 displayId; - std::string name; - std::string IconName; - std::string castBarCaption; - std::string unk1; - float size; - union // different GO types have different data field - { - //0 GAMEOBJECT_TYPE_DOOR - struct - { - uint32 startOpen; //0 used client side to determine GO_ACTIVATED means open/closed - uint32 lockId; //1 -> Lock.dbc - uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 - uint32 noDamageImmune; //3 break opening whenever you recieve damage? - uint32 openTextID; //4 can be used to replace castBarCaption? - uint32 closeTextID; //5 - uint32 ignoredByPathing; //6 - } door; - //1 GAMEOBJECT_TYPE_BUTTON - struct - { - uint32 startOpen; //0 - uint32 lockId; //1 -> Lock.dbc - uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 - uint32 linkedTrap; //3 - uint32 noDamageImmune; //4 isBattlegroundObject - uint32 large; //5 - uint32 openTextID; //6 can be used to replace castBarCaption? - uint32 closeTextID; //7 - uint32 losOK; //8 - } button; - //2 GAMEOBJECT_TYPE_QUESTGIVER - struct - { - uint32 lockId; //0 -> Lock.dbc - uint32 questList; //1 - uint32 pageMaterial; //2 - uint32 gossipID; //3 - uint32 customAnim; //4 - uint32 noDamageImmune; //5 - uint32 openTextID; //6 can be used to replace castBarCaption? - uint32 losOK; //7 - uint32 allowMounted; //8 - uint32 large; //9 - } questgiver; - //3 GAMEOBJECT_TYPE_CHEST - struct - { - uint32 lockId; //0 -> Lock.dbc - uint32 lootId; //1 - uint32 chestRestockTime; //2 - uint32 consumable; //3 - uint32 minSuccessOpens; //4 Deprecated, pre 3.0 was used for mining nodes but since WotLK all mining nodes are usable once and grant all loot with a single use - uint32 maxSuccessOpens; //5 Deprecated, pre 3.0 was used for mining nodes but since WotLK all mining nodes are usable once and grant all loot with a single use - uint32 eventId; //6 lootedEvent - uint32 linkedTrapId; //7 - uint32 questId; //8 not used currently but store quest required for GO activation for player - uint32 level; //9 - uint32 losOK; //10 - uint32 leaveLoot; //11 - uint32 notInCombat; //12 - uint32 logLoot; //13 - uint32 openTextID; //14 can be used to replace castBarCaption? - uint32 groupLootRules; //15 - uint32 floatingTooltip; //16 - } chest; - //4 GAMEOBJECT_TYPE_BINDER - empty - //5 GAMEOBJECT_TYPE_GENERIC - struct - { - uint32 floatingTooltip; //0 - uint32 highlight; //1 - uint32 serverOnly; //2 - uint32 large; //3 - uint32 floatOnWater; //4 - int32 questID; //5 - } _generic; - //6 GAMEOBJECT_TYPE_TRAP - struct - { - uint32 lockId; //0 -> Lock.dbc - uint32 level; //1 - uint32 diameter; //2 diameter for trap activation - uint32 spellId; //3 - uint32 type; //4 0 trap with no despawn after cast. 1 trap despawns after cast. 2 bomb casts on spawn. - uint32 cooldown; //5 time in secs - int32 autoCloseTime; //6 - uint32 startDelay; //7 - uint32 serverOnly; //8 - uint32 stealthed; //9 - uint32 large; //10 - uint32 invisible; //11 - uint32 openTextID; //12 can be used to replace castBarCaption? - uint32 closeTextID; //13 - uint32 ignoreTotems; //14 - } trap; - //7 GAMEOBJECT_TYPE_CHAIR - struct - { - uint32 slots; //0 - uint32 height; //1 - uint32 onlyCreatorUse; //2 - uint32 triggeredEvent; //3 - } chair; - //8 GAMEOBJECT_TYPE_SPELL_FOCUS - struct - { - uint32 focusId; //0 - uint32 dist; //1 - uint32 linkedTrapId; //2 - uint32 serverOnly; //3 - uint32 questID; //4 - uint32 large; //5 - uint32 floatingTooltip; //6 - } spellFocus; - //9 GAMEOBJECT_TYPE_TEXT - struct - { - uint32 pageID; //0 - uint32 language; //1 - uint32 pageMaterial; //2 - uint32 allowMounted; //3 - } text; - //10 GAMEOBJECT_TYPE_GOOBER - struct - { - uint32 lockId; //0 -> Lock.dbc - int32 questId; //1 - uint32 eventId; //2 - uint32 autoCloseTime; //3 - uint32 customAnim; //4 - uint32 consumable; //5 - uint32 cooldown; //6 - uint32 pageId; //7 - uint32 language; //8 - uint32 pageMaterial; //9 - uint32 spellId; //10 - uint32 noDamageImmune; //11 - uint32 linkedTrapId; //12 - uint32 large; //13 - uint32 openTextID; //14 can be used to replace castBarCaption? - uint32 closeTextID; //15 - uint32 losOK; //16 isBattlegroundObject - uint32 allowMounted; //17 - uint32 floatingTooltip; //18 - uint32 gossipID; //19 - uint32 WorldStateSetsState; //20 - } goober; - //11 GAMEOBJECT_TYPE_TRANSPORT - struct - { - uint32 pauseAtTime; //0 - uint32 startOpen; //1 - uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 - uint32 pause1EventID; //3 - uint32 pause2EventID; //4 - } transport; - //12 GAMEOBJECT_TYPE_AREADAMAGE - struct - { - uint32 lockId; //0 - uint32 radius; //1 - uint32 damageMin; //2 - uint32 damageMax; //3 - uint32 damageSchool; //4 - uint32 autoCloseTime; //5 secs till autoclose = autoCloseTime / 0x10000 - uint32 openTextID; //6 - uint32 closeTextID; //7 - } areadamage; - //13 GAMEOBJECT_TYPE_CAMERA - struct - { - uint32 lockId; //0 -> Lock.dbc - uint32 cinematicId; //1 - uint32 eventID; //2 - uint32 openTextID; //3 can be used to replace castBarCaption? - } camera; - //14 GAMEOBJECT_TYPE_MAPOBJECT - empty - //15 GAMEOBJECT_TYPE_MO_TRANSPORT - struct - { - uint32 taxiPathId; //0 - uint32 moveSpeed; //1 - uint32 accelRate; //2 - uint32 startEventID; //3 - uint32 stopEventID; //4 - uint32 transportPhysics; //5 - uint32 mapID; //6 - uint32 worldState1; //7 - uint32 canBeStopped; //8 - } moTransport; - //16 GAMEOBJECT_TYPE_DUELFLAG - empty - //17 GAMEOBJECT_TYPE_FISHINGNODE - empty - //18 GAMEOBJECT_TYPE_SUMMONING_RITUAL - struct - { - uint32 reqParticipants; //0 - uint32 spellId; //1 - uint32 animSpell; //2 - uint32 ritualPersistent; //3 - uint32 casterTargetSpell; //4 - uint32 casterTargetSpellTargets; //5 - uint32 castersGrouped; //6 - uint32 ritualNoTargetCheck; //7 - } summoningRitual; - //19 GAMEOBJECT_TYPE_MAILBOX - empty - //20 GAMEOBJECT_TYPE_DONOTUSE - empty - //21 GAMEOBJECT_TYPE_GUARDPOST - struct - { - uint32 creatureID; //0 - uint32 charges; //1 - } guardpost; - //22 GAMEOBJECT_TYPE_SPELLCASTER - struct - { - uint32 spellId; //0 - uint32 charges; //1 - uint32 partyOnly; //2 - uint32 allowMounted; //3 - uint32 large; //4 - } spellcaster; - //23 GAMEOBJECT_TYPE_MEETINGSTONE - struct - { - uint32 minLevel; //0 - uint32 maxLevel; //1 - uint32 areaID; //2 - } meetingstone; - //24 GAMEOBJECT_TYPE_FLAGSTAND - struct - { - uint32 lockId; //0 - uint32 pickupSpell; //1 - uint32 radius; //2 - uint32 returnAura; //3 - uint32 returnSpell; //4 - uint32 noDamageImmune; //5 - uint32 openTextID; //6 - uint32 losOK; //7 - } flagstand; - //25 GAMEOBJECT_TYPE_FISHINGHOLE - struct - { - uint32 radius; //0 how close bobber must land for sending loot - uint32 lootId; //1 - uint32 minSuccessOpens; //2 - uint32 maxSuccessOpens; //3 - uint32 lockId; //4 -> Lock.dbc; possibly 1628 for all? - } fishinghole; - //26 GAMEOBJECT_TYPE_FLAGDROP - struct - { - uint32 lockId; //0 - uint32 eventID; //1 - uint32 pickupSpell; //2 - uint32 noDamageImmune; //3 - uint32 openTextID; //4 - } flagdrop; - //27 GAMEOBJECT_TYPE_MINI_GAME - struct - { - uint32 gameType; //0 - } miniGame; - //29 GAMEOBJECT_TYPE_CAPTURE_POINT - struct - { - uint32 radius; //0 - uint32 spell; //1 - uint32 worldState1; //2 - uint32 worldstate2; //3 - uint32 winEventID1; //4 - uint32 winEventID2; //5 - uint32 contestedEventID1; //6 - uint32 contestedEventID2; //7 - uint32 progressEventID1; //8 - uint32 progressEventID2; //9 - uint32 neutralEventID1; //10 - uint32 neutralEventID2; //11 - uint32 neutralPercent; //12 - uint32 worldstate3; //13 - uint32 minSuperiority; //14 - uint32 maxSuperiority; //15 - uint32 minTime; //16 - uint32 maxTime; //17 - uint32 large; //18 - uint32 highlight; //19 - uint32 startingValue; //20 - uint32 unidirectional; //21 - } capturePoint; - //30 GAMEOBJECT_TYPE_AURA_GENERATOR - struct - { - uint32 startOpen; //0 - uint32 radius; //1 - uint32 auraID1; //2 - uint32 conditionID1; //3 - uint32 auraID2; //4 - uint32 conditionID2; //5 - uint32 serverOnly; //6 - } auraGenerator; - //31 GAMEOBJECT_TYPE_DUNGEON_DIFFICULTY - struct - { - uint32 mapID; //0 - uint32 difficulty; //1 - } dungeonDifficulty; - //32 GAMEOBJECT_TYPE_BARBER_CHAIR - struct - { - uint32 chairheight; //0 - uint32 heightOffset; //1 - } barberChair; - //33 GAMEOBJECT_TYPE_DESTRUCTIBLE_BUILDING - struct - { - uint32 intactNumHits; //0 - uint32 creditProxyCreature; //1 - uint32 state1Name; //2 - uint32 intactEvent; //3 - uint32 damagedDisplayId; //4 - uint32 damagedNumHits; //5 - uint32 empty3; //6 - uint32 empty4; //7 - uint32 empty5; //8 - uint32 damagedEvent; //9 - uint32 destroyedDisplayId; //10 - uint32 empty7; //11 - uint32 empty8; //12 - uint32 empty9; //13 - uint32 destroyedEvent; //14 - uint32 empty10; //15 - uint32 debuildingTimeSecs; //16 - uint32 empty11; //17 - uint32 destructibleData; //18 - uint32 rebuildingEvent; //19 - uint32 empty12; //20 - uint32 empty13; //21 - uint32 damageEvent; //22 - uint32 empty14; //23 - } building; - //34 GAMEOBJECT_TYPE_GUILDBANK - empty - //35 GAMEOBJECT_TYPE_TRAPDOOR - struct - { - uint32 whenToPause; // 0 - uint32 startOpen; // 1 - uint32 autoClose; // 2 - } trapDoor; - - // not use for specific field access (only for output with loop by all filed), also this determinate max union size - struct - { - uint32 data[MAX_GAMEOBJECT_DATA]; - } raw; - }; - - std::string AIName; - uint32 ScriptId; - bool IsForQuests; // pussywizard - - // helpers - [[nodiscard]] bool IsDespawnAtAction() const - { - switch (type) - { - case GAMEOBJECT_TYPE_CHEST: - return chest.consumable; - case GAMEOBJECT_TYPE_GOOBER: - return goober.consumable; - default: - return false; - } - } - - [[nodiscard]] bool IsUsableMounted() const - { - switch (type) - { - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.allowMounted; - case GAMEOBJECT_TYPE_TEXT: - return text.allowMounted; - case GAMEOBJECT_TYPE_GOOBER: - return goober.allowMounted; - case GAMEOBJECT_TYPE_SPELLCASTER: - return spellcaster.allowMounted; - default: - return false; - } - } - - [[nodiscard]] uint32 GetLockId() const - { - switch (type) - { - case GAMEOBJECT_TYPE_DOOR: - return door.lockId; - case GAMEOBJECT_TYPE_BUTTON: - return button.lockId; - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.lockId; - case GAMEOBJECT_TYPE_CHEST: - return chest.lockId; - case GAMEOBJECT_TYPE_TRAP: - return trap.lockId; - case GAMEOBJECT_TYPE_GOOBER: - return goober.lockId; - case GAMEOBJECT_TYPE_AREADAMAGE: - return areadamage.lockId; - case GAMEOBJECT_TYPE_CAMERA: - return camera.lockId; - case GAMEOBJECT_TYPE_FLAGSTAND: - return flagstand.lockId; - case GAMEOBJECT_TYPE_FISHINGHOLE: - return fishinghole.lockId; - case GAMEOBJECT_TYPE_FLAGDROP: - return flagdrop.lockId; - default: - return 0; - } - } - - [[nodiscard]] bool GetDespawnPossibility() const // despawn at targeting of cast? - { - switch (type) - { - case GAMEOBJECT_TYPE_DOOR: - return door.noDamageImmune; - case GAMEOBJECT_TYPE_BUTTON: - return button.noDamageImmune; - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.noDamageImmune; - case GAMEOBJECT_TYPE_GOOBER: - return goober.noDamageImmune; - case GAMEOBJECT_TYPE_FLAGSTAND: - return flagstand.noDamageImmune; - case GAMEOBJECT_TYPE_FLAGDROP: - return flagdrop.noDamageImmune; - default: - return true; - } - } - - [[nodiscard]] uint32 GetCharges() const // despawn at uses amount - { - switch (type) - { - //case GAMEOBJECT_TYPE_TRAP: return trap.charges; - case GAMEOBJECT_TYPE_GUARDPOST: - return guardpost.charges; - case GAMEOBJECT_TYPE_SPELLCASTER: - return spellcaster.charges; - default: - return 0; - } - } - - [[nodiscard]] uint32 GetLinkedGameObjectEntry() const - { - switch (type) - { - case GAMEOBJECT_TYPE_BUTTON: - return button.linkedTrap; - case GAMEOBJECT_TYPE_CHEST: - return chest.linkedTrapId; - case GAMEOBJECT_TYPE_SPELL_FOCUS: - return spellFocus.linkedTrapId; - case GAMEOBJECT_TYPE_GOOBER: - return goober.linkedTrapId; - default: - return 0; - } - } - - [[nodiscard]] uint32 GetAutoCloseTime() const - { - uint32 autoCloseTime = 0; - switch (type) - { - case GAMEOBJECT_TYPE_DOOR: - autoCloseTime = door.autoCloseTime; - break; - case GAMEOBJECT_TYPE_BUTTON: - autoCloseTime = button.autoCloseTime; - break; - case GAMEOBJECT_TYPE_TRAP: - autoCloseTime = trap.autoCloseTime; - break; - case GAMEOBJECT_TYPE_GOOBER: - autoCloseTime = goober.autoCloseTime; - break; - case GAMEOBJECT_TYPE_TRANSPORT: - autoCloseTime = transport.autoCloseTime; - break; - case GAMEOBJECT_TYPE_AREADAMAGE: - autoCloseTime = areadamage.autoCloseTime; - break; - default: - break; - } - return autoCloseTime /* xinef: changed to milliseconds/ IN_MILLISECONDS*/; // prior to 3.0.3, conversion was / 0x10000; - } - - [[nodiscard]] uint32 GetLootId() const - { - switch (type) - { - case GAMEOBJECT_TYPE_CHEST: - return chest.lootId; - case GAMEOBJECT_TYPE_FISHINGHOLE: - return fishinghole.lootId; - default: - return 0; - } - } - - [[nodiscard]] uint32 GetGossipMenuId() const - { - switch (type) - { - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.gossipID; - case GAMEOBJECT_TYPE_GOOBER: - return goober.gossipID; - default: - return 0; - } - } - - [[nodiscard]] uint32 GetEventScriptId() const - { - switch (type) - { - case GAMEOBJECT_TYPE_GOOBER: - return goober.eventId; - case GAMEOBJECT_TYPE_CHEST: - return chest.eventId; - case GAMEOBJECT_TYPE_CAMERA: - return camera.eventID; - default: - return 0; - } - } - - [[nodiscard]] uint32 GetCooldown() const // Cooldown preventing goober and traps to cast spell - { - switch (type) - { - case GAMEOBJECT_TYPE_TRAP: - return trap.cooldown; - case GAMEOBJECT_TYPE_GOOBER: - return goober.cooldown; - default: - return 0; - } - } - - [[nodiscard]] bool IsLargeGameObject() const - { - switch (type) - { - case GAMEOBJECT_TYPE_BUTTON: - return button.large != 0; - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.large != 0; - case GAMEOBJECT_TYPE_GENERIC: - return _generic.large != 0; - case GAMEOBJECT_TYPE_TRAP: - return trap.large != 0; - case GAMEOBJECT_TYPE_SPELL_FOCUS: - return spellFocus.large != 0; - case GAMEOBJECT_TYPE_GOOBER: - return goober.large != 0; - case GAMEOBJECT_TYPE_SPELLCASTER: - return spellcaster.large != 0; - case GAMEOBJECT_TYPE_CAPTURE_POINT: - return capturePoint.large != 0; - default: - return false; - } - } - - [[nodiscard]] bool IsInfiniteGameObject() const - { - switch (type) - { - case GAMEOBJECT_TYPE_DOOR: - return true; - case GAMEOBJECT_TYPE_FLAGSTAND: - return true; - case GAMEOBJECT_TYPE_FLAGDROP: - return true; - case GAMEOBJECT_TYPE_DUNGEON_DIFFICULTY: - return true; - case GAMEOBJECT_TYPE_TRAPDOOR: - return true; - default: - return false; - } - } - - [[nodiscard]] bool IsGameObjectForQuests() const - { - return IsForQuests; - } - - [[nodiscard]] bool IsIgnoringLOSChecks() const - { - switch (type) - { - case GAMEOBJECT_TYPE_BUTTON: - return button.losOK == 0; - case GAMEOBJECT_TYPE_QUESTGIVER: - return questgiver.losOK == 0; - case GAMEOBJECT_TYPE_CHEST: - return chest.losOK == 0; - case GAMEOBJECT_TYPE_GOOBER: - return goober.losOK == 0; - case GAMEOBJECT_TYPE_FLAGSTAND: - return flagstand.losOK == 0; - default: - return false; - } - } -}; - -// From `gameobject_template_addon` -struct GameObjectTemplateAddon -{ - uint32 entry; - uint32 faction; - uint32 flags; - uint32 mingold; - uint32 maxgold; - std::array artKits = {}; -}; - // Benchmarked: Faster than std::map (insert/find) typedef std::unordered_map GameObjectTemplateContainer; typedef std::unordered_map GameObjectTemplateAddonContainer; -class OPvPCapturePoint; -struct TransportAnimation; +typedef std::unordered_map GameObjectAddonContainer; +typedef std::vector GameObjectQuestItemList; +typedef std::unordered_map GameObjectQuestItemMap; union GameObjectValue { @@ -713,31 +74,6 @@ union GameObjectValue } Building; }; -struct GameObjectLocale -{ - std::vector Name; - std::vector CastBarCaption; -}; - -// `gameobject_addon` table -struct GameObjectAddon -{ - InvisibilityType invisibilityType; - uint32 InvisibilityValue; -}; - -typedef std::unordered_map GameObjectAddonContainer; - -// client side GO show states -enum GOState -{ - GO_STATE_ACTIVE = 0, // show in world as used and not reset (closed door open) - GO_STATE_READY = 1, // show in world as ready (closed door close) - GO_STATE_ACTIVE_ALTERNATIVE = 2 // show in world as used in alt way and not reset (closed door open by cannon fire) -}; - -#define MAX_GO_STATE 3 - enum class GameObjectActions : uint32 { // Name from client executable // Comments @@ -767,45 +103,18 @@ enum class GameObjectActions : uint32 SetTapList, // Set Tap List }; -// from `gameobject` -struct GameObjectData -{ - explicit GameObjectData() = default; - uint32 id{0}; // entry in gamobject_template - uint16 mapid{0}; - uint32 phaseMask{0}; - float posX{0.0f}; - float posY{0.0f}; - float posZ{0.0f}; - float orientation{0.0f}; - G3D::Quat rotation; - int32 spawntimesecs{0}; - uint32 ScriptId; - uint32 animprogress{0}; - GOState go_state{GO_STATE_ACTIVE}; - uint8 spawnMask{0}; - uint8 artKit{0}; - bool dbData{true}; -}; - -typedef std::vector GameObjectQuestItemList; -typedef std::unordered_map GameObjectQuestItemMap; - // For containers: [GO_NOT_READY]->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED->GO_READY -> ... // For bobber: GO_NOT_READY ->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED-> // For door(closed):[GO_NOT_READY]->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED->GO_READY(close) -> ... // For door(open): [GO_NOT_READY]->GO_READY (open) ->GO_ACTIVATED (close)->GO_JUST_DEACTIVATED->GO_READY(open) -> ... enum LootState { - GO_NOT_READY = 0, + GO_NOT_READY, GO_READY, // can be ready but despawned, and then not possible activate until spawn GO_ACTIVATED, GO_JUST_DEACTIVATED }; -class Unit; -class GameObjectModel; - // 5 sec for bobber catch #define FISHING_BOBBER_READY_TIME 5 diff --git a/src/server/game/Entities/GameObject/GameObjectData.h b/src/server/game/Entities/GameObject/GameObjectData.h new file mode 100644 index 000000000..65566447b --- /dev/null +++ b/src/server/game/Entities/GameObject/GameObjectData.h @@ -0,0 +1,716 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#ifndef GAMEOBJECTDATA_H +#define GAMEOBJECTDATA_H + +#include "Common.h" +#include "SharedDefines.h" +#include "WorldPacket.h" +#include +#include + +#define MAX_GAMEOBJECT_QUEST_ITEMS 6 +#define MAX_GO_STATE 3 + + // from `gameobject_template` +struct GameObjectTemplate +{ + uint32 entry; + uint32 type; + uint32 displayId; + std::string name; + std::string IconName; + std::string castBarCaption; + std::string unk1; + float size; + union // different GO types have different data field + { + //0 GAMEOBJECT_TYPE_DOOR + struct + { + uint32 startOpen; //0 used client side to determine GO_ACTIVATED means open/closed + uint32 lockId; //1 -> Lock.dbc + uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 + uint32 noDamageImmune; //3 break opening whenever you recieve damage? + uint32 openTextID; //4 can be used to replace castBarCaption? + uint32 closeTextID; //5 + uint32 ignoredByPathing; //6 + } door; + //1 GAMEOBJECT_TYPE_BUTTON + struct + { + uint32 startOpen; //0 + uint32 lockId; //1 -> Lock.dbc + uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 + uint32 linkedTrap; //3 + uint32 noDamageImmune; //4 isBattlegroundObject + uint32 large; //5 + uint32 openTextID; //6 can be used to replace castBarCaption? + uint32 closeTextID; //7 + uint32 losOK; //8 + } button; + //2 GAMEOBJECT_TYPE_QUESTGIVER + struct + { + uint32 lockId; //0 -> Lock.dbc + uint32 questList; //1 + uint32 pageMaterial; //2 + uint32 gossipID; //3 + uint32 customAnim; //4 + uint32 noDamageImmune; //5 + uint32 openTextID; //6 can be used to replace castBarCaption? + uint32 losOK; //7 + uint32 allowMounted; //8 + uint32 large; //9 + } questgiver; + //3 GAMEOBJECT_TYPE_CHEST + struct + { + uint32 lockId; //0 -> Lock.dbc + uint32 lootId; //1 + uint32 chestRestockTime; //2 + uint32 consumable; //3 + uint32 minSuccessOpens; //4 Deprecated, pre 3.0 was used for mining nodes but since WotLK all mining nodes are usable once and grant all loot with a single use + uint32 maxSuccessOpens; //5 Deprecated, pre 3.0 was used for mining nodes but since WotLK all mining nodes are usable once and grant all loot with a single use + uint32 eventId; //6 lootedEvent + uint32 linkedTrapId; //7 + uint32 questId; //8 not used currently but store quest required for GO activation for player + uint32 level; //9 + uint32 losOK; //10 + uint32 leaveLoot; //11 + uint32 notInCombat; //12 + uint32 logLoot; //13 + uint32 openTextID; //14 can be used to replace castBarCaption? + uint32 groupLootRules; //15 + uint32 floatingTooltip; //16 + } chest; + //4 GAMEOBJECT_TYPE_BINDER - empty + //5 GAMEOBJECT_TYPE_GENERIC + struct + { + uint32 floatingTooltip; //0 + uint32 highlight; //1 + uint32 serverOnly; //2 + uint32 large; //3 + uint32 floatOnWater; //4 + int32 questID; //5 + } _generic; + //6 GAMEOBJECT_TYPE_TRAP + struct + { + uint32 lockId; //0 -> Lock.dbc + uint32 level; //1 + uint32 diameter; //2 diameter for trap activation + uint32 spellId; //3 + uint32 type; //4 0 trap with no despawn after cast. 1 trap despawns after cast. 2 bomb casts on spawn. + uint32 cooldown; //5 time in secs + int32 autoCloseTime; //6 + uint32 startDelay; //7 + uint32 serverOnly; //8 + uint32 stealthed; //9 + uint32 large; //10 + uint32 invisible; //11 + uint32 openTextID; //12 can be used to replace castBarCaption? + uint32 closeTextID; //13 + uint32 ignoreTotems; //14 + } trap; + //7 GAMEOBJECT_TYPE_CHAIR + struct + { + uint32 slots; //0 + uint32 height; //1 + uint32 onlyCreatorUse; //2 + uint32 triggeredEvent; //3 + } chair; + //8 GAMEOBJECT_TYPE_SPELL_FOCUS + struct + { + uint32 focusId; //0 + uint32 dist; //1 + uint32 linkedTrapId; //2 + uint32 serverOnly; //3 + uint32 questID; //4 + uint32 large; //5 + uint32 floatingTooltip; //6 + } spellFocus; + //9 GAMEOBJECT_TYPE_TEXT + struct + { + uint32 pageID; //0 + uint32 language; //1 + uint32 pageMaterial; //2 + uint32 allowMounted; //3 + } text; + //10 GAMEOBJECT_TYPE_GOOBER + struct + { + uint32 lockId; //0 -> Lock.dbc + int32 questId; //1 + uint32 eventId; //2 + uint32 autoCloseTime; //3 + uint32 customAnim; //4 + uint32 consumable; //5 + uint32 cooldown; //6 + uint32 pageId; //7 + uint32 language; //8 + uint32 pageMaterial; //9 + uint32 spellId; //10 + uint32 noDamageImmune; //11 + uint32 linkedTrapId; //12 + uint32 large; //13 + uint32 openTextID; //14 can be used to replace castBarCaption? + uint32 closeTextID; //15 + uint32 losOK; //16 isBattlegroundObject + uint32 allowMounted; //17 + uint32 floatingTooltip; //18 + uint32 gossipID; //19 + uint32 WorldStateSetsState; //20 + } goober; + //11 GAMEOBJECT_TYPE_TRANSPORT + struct + { + uint32 pauseAtTime; //0 + uint32 startOpen; //1 + uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / 0x10000 + uint32 pause1EventID; //3 + uint32 pause2EventID; //4 + } transport; + //12 GAMEOBJECT_TYPE_AREADAMAGE + struct + { + uint32 lockId; //0 + uint32 radius; //1 + uint32 damageMin; //2 + uint32 damageMax; //3 + uint32 damageSchool; //4 + uint32 autoCloseTime; //5 secs till autoclose = autoCloseTime / 0x10000 + uint32 openTextID; //6 + uint32 closeTextID; //7 + } areadamage; + //13 GAMEOBJECT_TYPE_CAMERA + struct + { + uint32 lockId; //0 -> Lock.dbc + uint32 cinematicId; //1 + uint32 eventID; //2 + uint32 openTextID; //3 can be used to replace castBarCaption? + } camera; + //14 GAMEOBJECT_TYPE_MAPOBJECT - empty + //15 GAMEOBJECT_TYPE_MO_TRANSPORT + struct + { + uint32 taxiPathId; //0 + uint32 moveSpeed; //1 + uint32 accelRate; //2 + uint32 startEventID; //3 + uint32 stopEventID; //4 + uint32 transportPhysics; //5 + uint32 mapID; //6 + uint32 worldState1; //7 + uint32 canBeStopped; //8 + } moTransport; + //16 GAMEOBJECT_TYPE_DUELFLAG - empty + //17 GAMEOBJECT_TYPE_FISHINGNODE - empty + //18 GAMEOBJECT_TYPE_SUMMONING_RITUAL + struct + { + uint32 reqParticipants; //0 + uint32 spellId; //1 + uint32 animSpell; //2 + uint32 ritualPersistent; //3 + uint32 casterTargetSpell; //4 + uint32 casterTargetSpellTargets; //5 + uint32 castersGrouped; //6 + uint32 ritualNoTargetCheck; //7 + } summoningRitual; + //19 GAMEOBJECT_TYPE_MAILBOX - empty + //20 GAMEOBJECT_TYPE_DONOTUSE - empty + //21 GAMEOBJECT_TYPE_GUARDPOST + struct + { + uint32 creatureID; //0 + uint32 charges; //1 + } guardpost; + //22 GAMEOBJECT_TYPE_SPELLCASTER + struct + { + uint32 spellId; //0 + uint32 charges; //1 + uint32 partyOnly; //2 + uint32 allowMounted; //3 + uint32 large; //4 + } spellcaster; + //23 GAMEOBJECT_TYPE_MEETINGSTONE + struct + { + uint32 minLevel; //0 + uint32 maxLevel; //1 + uint32 areaID; //2 + } meetingstone; + //24 GAMEOBJECT_TYPE_FLAGSTAND + struct + { + uint32 lockId; //0 + uint32 pickupSpell; //1 + uint32 radius; //2 + uint32 returnAura; //3 + uint32 returnSpell; //4 + uint32 noDamageImmune; //5 + uint32 openTextID; //6 + uint32 losOK; //7 + } flagstand; + //25 GAMEOBJECT_TYPE_FISHINGHOLE + struct + { + uint32 radius; //0 how close bobber must land for sending loot + uint32 lootId; //1 + uint32 minSuccessOpens; //2 + uint32 maxSuccessOpens; //3 + uint32 lockId; //4 -> Lock.dbc; possibly 1628 for all? + } fishinghole; + //26 GAMEOBJECT_TYPE_FLAGDROP + struct + { + uint32 lockId; //0 + uint32 eventID; //1 + uint32 pickupSpell; //2 + uint32 noDamageImmune; //3 + uint32 openTextID; //4 + } flagdrop; + //27 GAMEOBJECT_TYPE_MINI_GAME + struct + { + uint32 gameType; //0 + } miniGame; + //29 GAMEOBJECT_TYPE_CAPTURE_POINT + struct + { + uint32 radius; //0 + uint32 spell; //1 + uint32 worldState1; //2 + uint32 worldstate2; //3 + uint32 winEventID1; //4 + uint32 winEventID2; //5 + uint32 contestedEventID1; //6 + uint32 contestedEventID2; //7 + uint32 progressEventID1; //8 + uint32 progressEventID2; //9 + uint32 neutralEventID1; //10 + uint32 neutralEventID2; //11 + uint32 neutralPercent; //12 + uint32 worldstate3; //13 + uint32 minSuperiority; //14 + uint32 maxSuperiority; //15 + uint32 minTime; //16 + uint32 maxTime; //17 + uint32 large; //18 + uint32 highlight; //19 + uint32 startingValue; //20 + uint32 unidirectional; //21 + } capturePoint; + //30 GAMEOBJECT_TYPE_AURA_GENERATOR + struct + { + uint32 startOpen; //0 + uint32 radius; //1 + uint32 auraID1; //2 + uint32 conditionID1; //3 + uint32 auraID2; //4 + uint32 conditionID2; //5 + uint32 serverOnly; //6 + } auraGenerator; + //31 GAMEOBJECT_TYPE_DUNGEON_DIFFICULTY + struct + { + uint32 mapID; //0 + uint32 difficulty; //1 + } dungeonDifficulty; + //32 GAMEOBJECT_TYPE_BARBER_CHAIR + struct + { + uint32 chairheight; //0 + uint32 heightOffset; //1 + } barberChair; + //33 GAMEOBJECT_TYPE_DESTRUCTIBLE_BUILDING + struct + { + uint32 intactNumHits; //0 + uint32 creditProxyCreature; //1 + uint32 state1Name; //2 + uint32 intactEvent; //3 + uint32 damagedDisplayId; //4 + uint32 damagedNumHits; //5 + uint32 empty3; //6 + uint32 empty4; //7 + uint32 empty5; //8 + uint32 damagedEvent; //9 + uint32 destroyedDisplayId; //10 + uint32 empty7; //11 + uint32 empty8; //12 + uint32 empty9; //13 + uint32 destroyedEvent; //14 + uint32 empty10; //15 + uint32 debuildingTimeSecs; //16 + uint32 empty11; //17 + uint32 destructibleData; //18 + uint32 rebuildingEvent; //19 + uint32 empty12; //20 + uint32 empty13; //21 + uint32 damageEvent; //22 + uint32 empty14; //23 + } building; + //34 GAMEOBJECT_TYPE_GUILDBANK - empty + //35 GAMEOBJECT_TYPE_TRAPDOOR + struct + { + uint32 whenToPause; // 0 + uint32 startOpen; // 1 + uint32 autoClose; // 2 + } trapDoor; + + // not use for specific field access (only for output with loop by all filed), also this determinate max union size + struct + { + uint32 data[MAX_GAMEOBJECT_DATA]; + } raw; + }; + + std::string AIName; + uint32 ScriptId; + bool IsForQuests; // pussywizard + + // helpers + [[nodiscard]] bool IsDespawnAtAction() const + { + switch (type) + { + case GAMEOBJECT_TYPE_CHEST: + return chest.consumable; + case GAMEOBJECT_TYPE_GOOBER: + return goober.consumable; + default: + return false; + } + } + + [[nodiscard]] bool IsUsableMounted() const + { + switch (type) + { + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.allowMounted; + case GAMEOBJECT_TYPE_TEXT: + return text.allowMounted; + case GAMEOBJECT_TYPE_GOOBER: + return goober.allowMounted; + case GAMEOBJECT_TYPE_SPELLCASTER: + return spellcaster.allowMounted; + default: + return false; + } + } + + [[nodiscard]] uint32 GetLockId() const + { + switch (type) + { + case GAMEOBJECT_TYPE_DOOR: + return door.lockId; + case GAMEOBJECT_TYPE_BUTTON: + return button.lockId; + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.lockId; + case GAMEOBJECT_TYPE_CHEST: + return chest.lockId; + case GAMEOBJECT_TYPE_TRAP: + return trap.lockId; + case GAMEOBJECT_TYPE_GOOBER: + return goober.lockId; + case GAMEOBJECT_TYPE_AREADAMAGE: + return areadamage.lockId; + case GAMEOBJECT_TYPE_CAMERA: + return camera.lockId; + case GAMEOBJECT_TYPE_FLAGSTAND: + return flagstand.lockId; + case GAMEOBJECT_TYPE_FISHINGHOLE: + return fishinghole.lockId; + case GAMEOBJECT_TYPE_FLAGDROP: + return flagdrop.lockId; + default: + return 0; + } + } + + [[nodiscard]] bool GetDespawnPossibility() const // despawn at targeting of cast? + { + switch (type) + { + case GAMEOBJECT_TYPE_DOOR: + return door.noDamageImmune; + case GAMEOBJECT_TYPE_BUTTON: + return button.noDamageImmune; + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.noDamageImmune; + case GAMEOBJECT_TYPE_GOOBER: + return goober.noDamageImmune; + case GAMEOBJECT_TYPE_FLAGSTAND: + return flagstand.noDamageImmune; + case GAMEOBJECT_TYPE_FLAGDROP: + return flagdrop.noDamageImmune; + default: + return true; + } + } + + [[nodiscard]] uint32 GetCharges() const // despawn at uses amount + { + switch (type) + { + //case GAMEOBJECT_TYPE_TRAP: return trap.charges; + case GAMEOBJECT_TYPE_GUARDPOST: + return guardpost.charges; + case GAMEOBJECT_TYPE_SPELLCASTER: + return spellcaster.charges; + default: + return 0; + } + } + + [[nodiscard]] uint32 GetLinkedGameObjectEntry() const + { + switch (type) + { + case GAMEOBJECT_TYPE_BUTTON: + return button.linkedTrap; + case GAMEOBJECT_TYPE_CHEST: + return chest.linkedTrapId; + case GAMEOBJECT_TYPE_SPELL_FOCUS: + return spellFocus.linkedTrapId; + case GAMEOBJECT_TYPE_GOOBER: + return goober.linkedTrapId; + default: + return 0; + } + } + + [[nodiscard]] uint32 GetAutoCloseTime() const + { + uint32 autoCloseTime = 0; + switch (type) + { + case GAMEOBJECT_TYPE_DOOR: + autoCloseTime = door.autoCloseTime; + break; + case GAMEOBJECT_TYPE_BUTTON: + autoCloseTime = button.autoCloseTime; + break; + case GAMEOBJECT_TYPE_TRAP: + autoCloseTime = trap.autoCloseTime; + break; + case GAMEOBJECT_TYPE_GOOBER: + autoCloseTime = goober.autoCloseTime; + break; + case GAMEOBJECT_TYPE_TRANSPORT: + autoCloseTime = transport.autoCloseTime; + break; + case GAMEOBJECT_TYPE_AREADAMAGE: + autoCloseTime = areadamage.autoCloseTime; + break; + default: + break; + } + return autoCloseTime /* xinef: changed to milliseconds/ IN_MILLISECONDS*/; // prior to 3.0.3, conversion was / 0x10000; + } + + [[nodiscard]] uint32 GetLootId() const + { + switch (type) + { + case GAMEOBJECT_TYPE_CHEST: + return chest.lootId; + case GAMEOBJECT_TYPE_FISHINGHOLE: + return fishinghole.lootId; + default: + return 0; + } + } + + [[nodiscard]] uint32 GetGossipMenuId() const + { + switch (type) + { + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.gossipID; + case GAMEOBJECT_TYPE_GOOBER: + return goober.gossipID; + default: + return 0; + } + } + + [[nodiscard]] uint32 GetEventScriptId() const + { + switch (type) + { + case GAMEOBJECT_TYPE_GOOBER: + return goober.eventId; + case GAMEOBJECT_TYPE_CHEST: + return chest.eventId; + case GAMEOBJECT_TYPE_CAMERA: + return camera.eventID; + default: + return 0; + } + } + + [[nodiscard]] uint32 GetCooldown() const // Cooldown preventing goober and traps to cast spell + { + switch (type) + { + case GAMEOBJECT_TYPE_TRAP: + return trap.cooldown; + case GAMEOBJECT_TYPE_GOOBER: + return goober.cooldown; + default: + return 0; + } + } + + [[nodiscard]] bool IsLargeGameObject() const + { + switch (type) + { + case GAMEOBJECT_TYPE_BUTTON: + return button.large != 0; + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.large != 0; + case GAMEOBJECT_TYPE_GENERIC: + return _generic.large != 0; + case GAMEOBJECT_TYPE_TRAP: + return trap.large != 0; + case GAMEOBJECT_TYPE_SPELL_FOCUS: + return spellFocus.large != 0; + case GAMEOBJECT_TYPE_GOOBER: + return goober.large != 0; + case GAMEOBJECT_TYPE_SPELLCASTER: + return spellcaster.large != 0; + case GAMEOBJECT_TYPE_CAPTURE_POINT: + return capturePoint.large != 0; + default: + return false; + } + } + + [[nodiscard]] bool IsInfiniteGameObject() const + { + switch (type) + { + case GAMEOBJECT_TYPE_DOOR: + return true; + case GAMEOBJECT_TYPE_FLAGSTAND: + return true; + case GAMEOBJECT_TYPE_FLAGDROP: + return true; + case GAMEOBJECT_TYPE_DUNGEON_DIFFICULTY: + return true; + case GAMEOBJECT_TYPE_TRAPDOOR: + return true; + default: + return false; + } + } + + [[nodiscard]] bool IsGameObjectForQuests() const + { + return IsForQuests; + } + + [[nodiscard]] bool IsIgnoringLOSChecks() const + { + switch (type) + { + case GAMEOBJECT_TYPE_BUTTON: + return button.losOK == 0; + case GAMEOBJECT_TYPE_QUESTGIVER: + return questgiver.losOK == 0; + case GAMEOBJECT_TYPE_CHEST: + return chest.losOK == 0; + case GAMEOBJECT_TYPE_GOOBER: + return goober.losOK == 0; + case GAMEOBJECT_TYPE_FLAGSTAND: + return flagstand.losOK == 0; + default: + return false; + } + } +}; + +// From `gameobject_template_addon` +struct GameObjectTemplateAddon +{ + uint32 entry; + uint32 faction; + uint32 flags; + uint32 mingold; + uint32 maxgold; + std::array artKits = {}; +}; + +struct GameObjectLocale +{ + std::vector Name; + std::vector CastBarCaption; +}; + +// `gameobject_addon` table +struct GameObjectAddon +{ + InvisibilityType invisibilityType; + uint32 InvisibilityValue; +}; + +// client side GO show states +enum GOState +{ + GO_STATE_ACTIVE = 0, // show in world as used and not reset (closed door open) + GO_STATE_READY = 1, // show in world as ready (closed door close) + GO_STATE_ACTIVE_ALTERNATIVE = 2 // show in world as used in alt way and not reset (closed door open by cannon fire) +}; + +// from `gameobject` +struct GameObjectData +{ + explicit GameObjectData() = default; + uint32 id{ 0 }; // entry in gamobject_template + uint16 mapid{ 0 }; + uint32 phaseMask{ 0 }; + float posX{ 0.0f }; + float posY{ 0.0f }; + float posZ{ 0.0f }; + float orientation{ 0.0f }; + G3D::Quat rotation; + int32 spawntimesecs{ 0 }; + uint32 ScriptId; + uint32 animprogress{ 0 }; + GOState go_state{ GO_STATE_ACTIVE }; + uint8 spawnMask{ 0 }; + uint8 artKit{ 0 }; + bool dbData{ true }; +}; + +#endif // GameObjectData_h__ From f039836a2fd7f615c51a1a2efe896181ae56c103 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Sun, 12 Feb 2023 14:05:34 +0100 Subject: [PATCH 55/87] chore(Core/Misc): Change all TODO to doxygen comment (#14966) --- src/common/Logging/Log.cpp | 2 +- src/common/Metric/Metric.cpp | 2 +- src/common/Metric/Metric.h | 2 +- src/common/Utilities/StringConvert.h | 2 +- src/common/Utilities/advstd.h | 2 +- src/server/database/Database/QueryResult.cpp | 2 +- src/server/game/AI/CoreAI/CombatAI.cpp | 2 +- src/server/game/AI/CoreAI/UnitAI.h | 2 +- .../game/AI/SmartScripts/SmartScriptMgr.h | 14 ++++---- .../game/Achievements/AchievementMgr.cpp | 2 +- src/server/game/Battlefield/Battlefield.cpp | 4 +-- .../game/Battlefield/Zones/BattlefieldWG.cpp | 8 ++--- .../game/Battlefield/Zones/BattlefieldWG.h | 2 +- src/server/game/Battlegrounds/ArenaTeam.cpp | 2 +- .../game/Battlegrounds/Battleground.cpp | 2 +- src/server/game/Battlegrounds/Battleground.h | 2 +- .../Battlegrounds/Zones/BattlegroundAV.cpp | 2 +- src/server/game/DungeonFinding/LFGScripts.cpp | 2 +- .../game/Entities/Creature/Creature.cpp | 6 ++-- src/server/game/Entities/Creature/Creature.h | 2 +- .../game/Entities/Creature/CreatureData.h | 4 +-- .../Entities/Creature/TemporarySummon.cpp | 2 +- .../game/Entities/GameObject/GameObject.cpp | 2 +- src/server/game/Entities/Object/Object.cpp | 4 +-- src/server/game/Entities/Pet/Pet.cpp | 2 +- src/server/game/Entities/Player/Player.cpp | 16 +++++----- .../game/Entities/Player/PlayerStorage.cpp | 4 +-- .../game/Entities/Player/PlayerUpdates.cpp | 6 ++-- src/server/game/Entities/Unit/Unit.cpp | 32 +++++++++---------- src/server/game/Entities/Unit/Unit.h | 4 +-- src/server/game/Events/GameEventMgr.cpp | 2 +- src/server/game/Guilds/Guild.h | 2 +- src/server/game/Handlers/CalendarHandler.cpp | 2 +- src/server/game/Handlers/MiscHandler.cpp | 2 +- src/server/game/Handlers/PetHandler.cpp | 2 +- src/server/game/Handlers/PetitionsHandler.cpp | 2 +- src/server/game/Handlers/SpellHandler.cpp | 6 ++-- src/server/game/Loot/LootMgr.cpp | 4 +-- src/server/game/Maps/MapMgr.cpp | 4 +-- .../PointMovementGenerator.cpp | 2 +- .../game/Movement/Spline/MoveSpline.cpp | 2 +- src/server/game/Scripting/MapScripts.cpp | 2 +- .../ScriptDefines/BattlegroundScript.cpp | 2 +- src/server/game/Server/WorldSession.cpp | 4 +-- src/server/game/Server/WorldSocket.cpp | 2 +- .../game/Spells/Auras/SpellAuraEffects.cpp | 12 +++---- src/server/game/Spells/Auras/SpellAuras.cpp | 16 +++++----- src/server/game/Spells/Spell.cpp | 30 ++++++++--------- src/server/game/Spells/SpellEffects.cpp | 26 +++++++-------- src/server/game/Spells/SpellInfo.cpp | 4 +-- src/server/game/Spells/SpellMgr.cpp | 4 +-- src/server/game/Spells/SpellMgr.h | 2 +- src/server/game/Tickets/TicketMgr.h | 2 +- src/server/game/Warden/WardenWin.cpp | 2 +- src/server/scripts/Commands/cs_item.cpp | 2 +- src/server/scripts/Commands/cs_misc.cpp | 2 +- .../BlackwingLair/instance_blackwing_lair.cpp | 2 +- .../instance_scarlet_monastery.cpp | 2 +- src/server/scripts/Events/hallows_end.cpp | 2 +- .../instance_old_hillsbrad.cpp | 2 +- .../AzjolNerub/AzjolNerub/boss_hadronox.cpp | 2 +- .../AzjolNerub/ahnkahet/boss_elder_nadox.cpp | 2 +- .../ahnkahet/boss_prince_taldaram.cpp | 4 +-- .../ObsidianSanctum/boss_sartharion.cpp | 2 +- .../FrozenHalls/PitOfSaron/pit_of_saron.cpp | 6 ++-- .../boss_deathbringer_saurfang.cpp | 2 +- src/server/scripts/OutdoorPvP/OutdoorPvPNA.h | 2 +- src/server/scripts/OutdoorPvP/OutdoorPvPZM.h | 2 +- .../Outland/zone_blades_edge_mountains.cpp | 2 +- src/server/scripts/Pet/pet_dk.cpp | 2 +- src/server/scripts/Spells/spell_dk.cpp | 2 +- src/server/scripts/Spells/spell_generic.cpp | 2 +- src/server/scripts/Spells/spell_hunter.cpp | 4 +-- src/server/scripts/Spells/spell_mage.cpp | 4 +-- .../scripts/World/areatrigger_scripts.cpp | 2 +- src/server/scripts/World/npcs_special.cpp | 2 +- src/server/shared/DataStores/DBCEnums.h | 12 +++---- src/server/shared/DataStores/DBCStructure.h | 12 +++---- .../game/Miscellaneous/FormulasTest.cpp | 2 +- src/tools/mmaps_generator/MapBuilder.cpp | 4 +-- src/tools/mmaps_generator/MapBuilder.h | 2 +- src/tools/vmap4_extractor/dbcfile.h | 2 +- .../vmap4_extractor/gameobject_extract.cpp | 2 +- src/tools/vmap4_extractor/wmo.cpp | 2 +- 84 files changed, 185 insertions(+), 185 deletions(-) diff --git a/src/common/Logging/Log.cpp b/src/common/Logging/Log.cpp index cb58d80dd..386ccbbe3 100644 --- a/src/common/Logging/Log.cpp +++ b/src/common/Logging/Log.cpp @@ -339,7 +339,7 @@ void Log::Close() bool Log::ShouldLog(std::string const& type, LogLevel level) const { - // TODO: Use cache to store "Type.sub1.sub2": "Type" equivalence, should + /// @todo: Use cache to store "Type.sub1.sub2": "Type" equivalence, should // Speed up in cases where requesting "Type.sub1.sub2" but only configured // Logger "Type" diff --git a/src/common/Metric/Metric.cpp b/src/common/Metric/Metric.cpp index 01a2511f5..908ffc676 100644 --- a/src/common/Metric/Metric.cpp +++ b/src/common/Metric/Metric.cpp @@ -322,7 +322,7 @@ std::string Metric::FormatInfluxDBValue(float value) std::string Metric::FormatInfluxDBTagValue(std::string const& value) { - // ToDo: should handle '=' and ',' characters too + /// @todo: should handle '=' and ',' characters too return boost::replace_all_copy(value, " ", "\\ "); } diff --git a/src/common/Metric/Metric.h b/src/common/Metric/Metric.h index e629a5b31..ed841a1e9 100644 --- a/src/common/Metric/Metric.h +++ b/src/common/Metric/Metric.h @@ -95,7 +95,7 @@ private: static std::string FormatInfluxDBTagValue(std::string const& value); - // ToDo: should format TagKey and FieldKey too in the same way as TagValue + /// @todo: should format TagKey and FieldKey too in the same way as TagValue public: Metric(); diff --git a/src/common/Utilities/StringConvert.h b/src/common/Utilities/StringConvert.h index 33c830281..bd02cf3ea 100644 --- a/src/common/Utilities/StringConvert.h +++ b/src/common/Utilities/StringConvert.h @@ -194,7 +194,7 @@ namespace Acore::Impl::StringConvertImpl } }; #else - // @todo replace this once libc++ supports double args to from_chars + /// @todo replace this once libc++ supports double args to from_chars template struct For>> { diff --git a/src/common/Utilities/advstd.h b/src/common/Utilities/advstd.h index 3b33dbaec..09485ff4b 100644 --- a/src/common/Utilities/advstd.h +++ b/src/common/Utilities/advstd.h @@ -25,7 +25,7 @@ namespace advstd { // This workaround for std::remove_cvref_t, std::type_identify is needed for GCC 8... - // TODO: remove when we drop GCC 8 support. https://en.cppreference.com/w/cpp/compiler_support/20 + /// @todo: remove when we drop GCC 8 support. https://en.cppreference.com/w/cpp/compiler_support/20 // C++20 advstd::remove_cvref_t template using remove_cvref_t = std::remove_cv_t>; diff --git a/src/server/database/Database/QueryResult.cpp b/src/server/database/Database/QueryResult.cpp index 06005a34d..0e8d3c8c1 100644 --- a/src/server/database/Database/QueryResult.cpp +++ b/src/server/database/Database/QueryResult.cpp @@ -349,7 +349,7 @@ PreparedResultSet::PreparedResultSet(MySQLStmt* stmt, MySQLResult* result, uint6 // when mysql_stmt_fetch returned MYSQL_DATA_TRUNCATED // we cannot blindly null-terminate the data either as it may be retrieved as binary blob and not specifically a string // in this case using Field::GetCString will result in garbage - // TODO: remove Field::GetCString and use std::string_view in C++17 + /// @todo: remove Field::GetCString and use std::string_view in C++17 if (fetched_length < buffer_length) *((char*)buffer + fetched_length) = '\0'; break; diff --git a/src/server/game/AI/CoreAI/CombatAI.cpp b/src/server/game/AI/CoreAI/CombatAI.cpp index c038d5b98..c1c5a7d19 100644 --- a/src/server/game/AI/CoreAI/CombatAI.cpp +++ b/src/server/game/AI/CoreAI/CombatAI.cpp @@ -228,7 +228,7 @@ TurretAI::TurretAI(Creature* c) : CreatureAI(c) bool TurretAI::CanAIAttack(Unit const* /*who*/) const { - // TODO: use one function to replace it + /// @todo: use one function to replace it if (!me->IsWithinCombatRange(me->GetVictim(), me->m_CombatDistance) || (m_minRange && me->IsWithinCombatRange(me->GetVictim(), m_minRange))) return false; diff --git a/src/server/game/AI/CoreAI/UnitAI.h b/src/server/game/AI/CoreAI/UnitAI.h index 0d9cc7c66..5d6903cb5 100644 --- a/src/server/game/AI/CoreAI/UnitAI.h +++ b/src/server/game/AI/CoreAI/UnitAI.h @@ -93,7 +93,7 @@ struct DefaultTargetSelector : public Acore::unary_function }; // Target selector for spell casts checking range, auras and attributes -// TODO: Add more checks from Spell::CheckCast +/// @todo: Add more checks from Spell::CheckCast struct SpellTargetSelector : public Acore::unary_function { public: diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h index 8e670c191..0fc4c2c97 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h @@ -641,22 +641,22 @@ enum SMART_ACTION SMART_ACTION_SET_CORPSE_DELAY = 116, // timer SMART_ACTION_DISABLE_EVADE = 117, // 0/1 (1 = disabled, 0 = enabled) SMART_ACTION_GO_SET_GO_STATE = 118, // state - SMART_ACTION_SET_CAN_FLY = 119, // TODO: NOT SUPPORTED YET - SMART_ACTION_REMOVE_AURAS_BY_TYPE = 120, // TODO: NOT SUPPORTED YET + SMART_ACTION_SET_CAN_FLY = 119, /// @todo: NOT SUPPORTED YET + SMART_ACTION_REMOVE_AURAS_BY_TYPE = 120, /// @todo: NOT SUPPORTED YET SMART_ACTION_SET_SIGHT_DIST = 121, // sightDistance SMART_ACTION_FLEE = 122, // fleeTime SMART_ACTION_ADD_THREAT = 123, // +threat, -threat SMART_ACTION_LOAD_EQUIPMENT = 124, // id SMART_ACTION_TRIGGER_RANDOM_TIMED_EVENT = 125, // id min range, id max range SMART_ACTION_REMOVE_ALL_GAMEOBJECTS = 126, - SMART_ACTION_REMOVE_MOVEMENT = 127, // TODO: NOT SUPPORTED YET + SMART_ACTION_REMOVE_MOVEMENT = 127, /// @todo: NOT SUPPORTED YET SMART_ACTION_PLAY_ANIMKIT = 128, // don't use on 3.3.5a SMART_ACTION_SCENE_PLAY = 129, // don't use on 3.3.5a SMART_ACTION_SCENE_CANCEL = 130, // don't use on 3.3.5a - SMART_ACTION_SPAWN_SPAWNGROUP = 131, // TODO: NOT SUPPORTED YET - SMART_ACTION_DESPAWN_SPAWNGROUP = 132, // TODO: NOT SUPPORTED YET - SMART_ACTION_RESPAWN_BY_SPAWNID = 133, // TODO: NOT SUPPORTED YET - // SMART_ACTION_INVOKER_CAST = 134, // TODO: solve name conflicts + SMART_ACTION_SPAWN_SPAWNGROUP = 131, /// @todo: NOT SUPPORTED YET + SMART_ACTION_DESPAWN_SPAWNGROUP = 132, /// @todo: NOT SUPPORTED YET + SMART_ACTION_RESPAWN_BY_SPAWNID = 133, /// @todo: NOT SUPPORTED YET + // SMART_ACTION_INVOKER_CAST = 134, /// @todo: solve name conflicts SMART_ACTION_PLAY_CINEMATIC = 135, // entry, cinematic SMART_ACTION_SET_MOVEMENT_SPEED = 136, // movementType, speedInteger, speedFraction diff --git a/src/server/game/Achievements/AchievementMgr.cpp b/src/server/game/Achievements/AchievementMgr.cpp index 640002d1d..3c3061058 100644 --- a/src/server/game/Achievements/AchievementMgr.cpp +++ b/src/server/game/Achievements/AchievementMgr.cpp @@ -2341,7 +2341,7 @@ void AchievementMgr::BuildAllDataPacket(WorldPacket* data) const *data << uint32(iter->first); data->appendPackGUID(iter->second.counter); *data << GetPlayer()->GetPackGUID(); - *data << uint32(0); // TODO: This should be 1 if it is a failed timed criteria + *data << uint32(0); /// @todo: This should be 1 if it is a failed timed criteria data->AppendPackedTime(iter->second.date); *data << uint32(now - iter->second.date); *data << uint32(now - iter->second.date); diff --git a/src/server/game/Battlefield/Battlefield.cpp b/src/server/game/Battlefield/Battlefield.cpp index 042e7bf08..fe6544a23 100644 --- a/src/server/game/Battlefield/Battlefield.cpp +++ b/src/server/game/Battlefield/Battlefield.cpp @@ -87,7 +87,7 @@ void Battlefield::HandlePlayerEnterZone(Player* player, uint32 /*zone*/) InvitePlayerToWar(player); else // No more vacant places { - // TODO: Send a packet to announce it to player + /// @todo: Send a packet to announce it to player m_PlayersWillBeKick[player->GetTeamId()][player->GetGUID()] = GameTime::GetGameTime().count() + (player->IsGameMaster() ? 30 * MINUTE : 10); InvitePlayerToQueue(player); } @@ -273,7 +273,7 @@ void Battlefield::InvitePlayerToWar(Player* player) if (!player) return; - // TODO : needed ? + /// @todo : needed ? if (player->IsInFlight()) return; diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp index fdce52068..51a4fec74 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp @@ -15,9 +15,9 @@ * with this program. If not, see . */ -// TODO: Implement proper support for vehicle+player teleportation -// TODO: Use spell victory/defeat in wg instead of RewardMarkOfHonor() && RewardHonor -// TODO: Add proper implement of achievement +/// @todo: Implement proper support for vehicle+player teleportation +/// @todo: Use spell victory/defeat in wg instead of RewardMarkOfHonor() && RewardHonor +/// @todo: Add proper implement of achievement #include "BattlefieldWG.h" #include "GameTime.h" @@ -864,7 +864,7 @@ void BattlefieldWG::OnPlayerJoinWar(Player* player) void BattlefieldWG::OnPlayerLeaveWar(Player* player) { - // Remove all aura from WG // TODO: false we can go out of this zone on retail and keep Rank buff, remove on end of WG + // Remove all aura from WG /// @todo: false we can go out of this zone on retail and keep Rank buff, remove on end of WG if (!player->GetSession()->PlayerLogout()) { if (player->GetVehicle()) // Remove vehicle of player if he go out. diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.h b/src/server/game/Battlefield/Zones/BattlefieldWG.h index 96fca9624..f603d2a35 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.h +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.h @@ -532,7 +532,7 @@ enum WintergraspWorldstates WORLDSTATE_ALLIANCE_KEEP_DEFENDED = 4025, }; -// TODO: Handle this with creature_text ? +/// @todo: Handle this with creature_text ? enum eWGText { BATTLEFIELD_WG_TEXT_START = 28, diff --git a/src/server/game/Battlegrounds/ArenaTeam.cpp b/src/server/game/Battlegrounds/ArenaTeam.cpp index 15d0e9418..2d326dcd0 100644 --- a/src/server/game/Battlegrounds/ArenaTeam.cpp +++ b/src/server/game/Battlegrounds/ArenaTeam.cpp @@ -751,7 +751,7 @@ int32 ArenaTeam::GetRatingMod(uint32 ownRating, uint32 opponentRating, bool won // Calculate the rating modification float mod; - // TODO: Replace this hack with using the confidence factor (limiting the factor to 2.0f) + /// @todo: Replace this hack with using the confidence factor (limiting the factor to 2.0f) if (won) { if (ownRating < 1300) diff --git a/src/server/game/Battlegrounds/Battleground.cpp b/src/server/game/Battlegrounds/Battleground.cpp index 2ed25b07f..3723778ea 100644 --- a/src/server/game/Battlegrounds/Battleground.cpp +++ b/src/server/game/Battlegrounds/Battleground.cpp @@ -1599,7 +1599,7 @@ bool Battleground::AddSpiritGuide(uint32 type, float x, float y, float z, float creature->setDeathState(DEAD); creature->SetGuidValue(UNIT_FIELD_CHANNEL_OBJECT, creature->GetGUID()); // aura - // TODO: Fix display here + /// @todo: Fix display here // creature->SetVisibleAura(0, SPELL_SPIRIT_HEAL_CHANNEL); // casting visual effect creature->SetUInt32Value(UNIT_CHANNEL_SPELL, SPELL_SPIRIT_HEAL_CHANNEL); diff --git a/src/server/game/Battlegrounds/Battleground.h b/src/server/game/Battlegrounds/Battleground.h index b91332b3b..0b7aab9d9 100644 --- a/src/server/game/Battlegrounds/Battleground.h +++ b/src/server/game/Battlegrounds/Battleground.h @@ -525,7 +525,7 @@ public: void HandleTriggerBuff(GameObject* gameObject); void SetHoliday(bool is_holiday); - // TODO: make this protected: + /// @todo: make this protected: typedef GuidVector BGObjects; typedef GuidVector BGCreatures; BGObjects BgObjects; diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp index 7c5f1db93..114b7d3c9 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp @@ -326,7 +326,7 @@ Creature* BattlegroundAV::AddAVCreature(uint16 cinfoid, uint16 type) if (!creature) return nullptr; if (creature->GetEntry() == BG_AV_CreatureInfo[AV_NPC_A_CAPTAIN] || creature->GetEntry() == BG_AV_CreatureInfo[AV_NPC_H_CAPTAIN]) - creature->SetRespawnDelay(RESPAWN_ONE_DAY); // TODO: look if this can be done by database + also add this for the wingcommanders + creature->SetRespawnDelay(RESPAWN_ONE_DAY); /// @todo: look if this can be done by database + also add this for the wingcommanders if ((isStatic && cinfoid >= 10 && cinfoid <= 14) || (!isStatic && ((cinfoid >= AV_NPC_A_GRAVEDEFENSE0 && cinfoid <= AV_NPC_A_GRAVEDEFENSE3) || (cinfoid >= AV_NPC_H_GRAVEDEFENSE0 && cinfoid <= AV_NPC_H_GRAVEDEFENSE3)))) diff --git a/src/server/game/DungeonFinding/LFGScripts.cpp b/src/server/game/DungeonFinding/LFGScripts.cpp index 151623140..02b907d67 100644 --- a/src/server/game/DungeonFinding/LFGScripts.cpp +++ b/src/server/game/DungeonFinding/LFGScripts.cpp @@ -80,7 +80,7 @@ namespace lfg sLFGMgr->InitializeLockedDungeons(player, group); sLFGMgr->SetTeam(player->GetGUID(), player->GetTeamId()); - // TODO - Restore LfgPlayerData and send proper status to player if it was in a group + /// @todo - Restore LfgPlayerData and send proper status to player if it was in a group } void LFGPlayerScript::OnBindToInstance(Player* player, Difficulty difficulty, uint32 mapId, bool /*permanent*/) diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp index cc2fc741e..987191e96 100644 --- a/src/server/game/Entities/Creature/Creature.cpp +++ b/src/server/game/Entities/Creature/Creature.cpp @@ -50,7 +50,7 @@ #include "World.h" #include "WorldPacket.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -547,7 +547,7 @@ bool Creature::UpdateEntry(uint32 Entry, const CreatureData* data, bool changele SetMeleeDamageSchool(SpellSchools(cInfo->dmgschool)); CreatureBaseStats const* stats = sObjectMgr->GetCreatureBaseStats(GetLevel(), cInfo->unit_class); - float armor = (float)stats->GenerateArmor(cInfo); // TODO: Why is this treated as uint32 when it's a float? + float armor = (float)stats->GenerateArmor(cInfo); /// @todo: Why is this treated as uint32 when it's a float? SetModifierValue(UNIT_MOD_ARMOR, BASE_VALUE, armor); SetModifierValue(UNIT_MOD_RESISTANCE_HOLY, BASE_VALUE, float(cInfo->resistance[SPELL_SCHOOL_HOLY])); SetModifierValue(UNIT_MOD_RESISTANCE_FIRE, BASE_VALUE, float(cInfo->resistance[SPELL_SCHOOL_FIRE])); @@ -1521,7 +1521,7 @@ void Creature::SelectLevel(bool changelevel) SetMaxPower(POWER_MANA, mana); //MAX Mana SetPower(POWER_MANA, mana); - // TODO: set UNIT_FIELD_POWER*, for some creature class case (energy, etc) + /// @todo: set UNIT_FIELD_POWER*, for some creature class case (energy, etc) SetModifierValue(UNIT_MOD_HEALTH, BASE_VALUE, (float)health); SetModifierValue(UNIT_MOD_MANA, BASE_VALUE, (float)mana); diff --git a/src/server/game/Entities/Creature/Creature.h b/src/server/game/Entities/Creature/Creature.h index 83c93fa34..ef2033317 100644 --- a/src/server/game/Entities/Creature/Creature.h +++ b/src/server/game/Entities/Creature/Creature.h @@ -91,7 +91,7 @@ public: [[nodiscard]] bool HasReactState(ReactStates state) const { return (m_reactState == state); } void InitializeReactState(); - ///// TODO RENAME THIS!!!!! + ///// @todo RENAME THIS!!!!! bool isCanInteractWithBattleMaster(Player* player, bool msg) const; bool isCanTrainingAndResetTalentsOf(Player* player) const; [[nodiscard]] bool IsValidTrainerForPlayer(Player* player, uint32* npcFlags = nullptr) const; diff --git a/src/server/game/Entities/Creature/CreatureData.h b/src/server/game/Entities/Creature/CreatureData.h index eaff79bce..fd4d3432b 100644 --- a/src/server/game/Entities/Creature/CreatureData.h +++ b/src/server/game/Entities/Creature/CreatureData.h @@ -42,7 +42,7 @@ constexpr Milliseconds PET_FOCUS_REGEN_INTERVAL = 4s; enum class VisibilityDistanceType : uint8; -// TODO: Implement missing flags from TC in places that custom flags from xinef&pussywizzard use flag values. +/// @todo: Implement missing flags from TC in places that custom flags from xinef&pussywizzard use flag values. // EnumUtils: DESCRIBE THIS enum CreatureFlagsExtra : uint32 { @@ -57,7 +57,7 @@ enum CreatureFlagsExtra : uint32 CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, // creature is immune to taunt auras and 'attack me' effects CREATURE_FLAG_EXTRA_NO_MOVE_FLAGS_UPDATE = 0x00000200, // creature won't update movement flags CREATURE_FLAG_EXTRA_GHOST_VISIBILITY = 0x00000400, // creature will only be visible to dead players - CREATURE_FLAG_EXTRA_UNUSED_12 = 0x00000800, // TODO: Implement CREATURE_FLAG_EXTRA_USE_OFFHAND_ATTACK (creature will use offhand attacks) + CREATURE_FLAG_EXTRA_UNUSED_12 = 0x00000800, /// @todo: Implement CREATURE_FLAG_EXTRA_USE_OFFHAND_ATTACK (creature will use offhand attacks) CREATURE_FLAG_EXTRA_NO_SELL_VENDOR = 0x00001000, // players can't sell items to this vendor CREATURE_FLAG_EXTRA_IGNORE_COMBAT = 0x00002000, CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, // custom flag for world event creatures (left room for merging) diff --git a/src/server/game/Entities/Creature/TemporarySummon.cpp b/src/server/game/Entities/Creature/TemporarySummon.cpp index 42c6e66aa..9236f8520 100644 --- a/src/server/game/Entities/Creature/TemporarySummon.cpp +++ b/src/server/game/Entities/Creature/TemporarySummon.cpp @@ -499,7 +499,7 @@ void Puppet::Update(uint32 time) if (!IsAlive()) { UnSummon(); - // TODO: why long distance .die does not remove it + /// @todo: why long distance .die does not remove it } } } diff --git a/src/server/game/Entities/GameObject/GameObject.cpp b/src/server/game/Entities/GameObject/GameObject.cpp index de62a0cc2..7431b5050 100644 --- a/src/server/game/Entities/GameObject/GameObject.cpp +++ b/src/server/game/Entities/GameObject/GameObject.cpp @@ -2299,7 +2299,7 @@ void GameObject::ModifyHealth(int32 change, Unit* attackerOrHealer /*= nullptr*/ Player* player = attackerOrHealer->GetCharmerOrOwnerPlayerOrPlayerItself(); // dealing damage, send packet - // TODO: is there any packet for healing? + /// @todo: is there any packet for healing? if (player) { WorldPacket data(SMSG_DESTRUCTIBLE_BUILDING_DAMAGE, 8 + 8 + 8 + 4 + 4); diff --git a/src/server/game/Entities/Object/Object.cpp b/src/server/game/Entities/Object/Object.cpp index 2f1e6bc27..7d8f75a61 100644 --- a/src/server/game/Entities/Object/Object.cpp +++ b/src/server/game/Entities/Object/Object.cpp @@ -52,7 +52,7 @@ #include "Tokenize.h" #include "StringConvert.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -2889,7 +2889,7 @@ void WorldObject::DestroyForNearbyPlayers() if (!player->HaveAtClient(this)) continue; - if (isType(TYPEMASK_UNIT) && ((Unit*)this)->GetCharmerGUID() == player->GetGUID()) // TODO: this is for puppet + if (isType(TYPEMASK_UNIT) && ((Unit*)this)->GetCharmerGUID() == player->GetGUID()) /// @todo: this is for puppet continue; DestroyForPlayer(player); diff --git a/src/server/game/Entities/Pet/Pet.cpp b/src/server/game/Entities/Pet/Pet.cpp index 7c9b35048..bc095df32 100644 --- a/src/server/game/Entities/Pet/Pet.cpp +++ b/src/server/game/Entities/Pet/Pet.cpp @@ -1005,7 +1005,7 @@ bool Pet::CreateBaseAtTamed(CreatureTemplate const* cinfo, Map* map, uint32 phas return true; } -// TODO: Move stat mods code to pet passive auras +/// @todo: Move stat mods code to pet passive auras bool Guardian::InitStatsForLevel(uint8 petlevel) { CreatureTemplate const* cinfo = GetCreatureTemplate(); diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 83e76ab76..96e82f1e1 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -89,7 +89,7 @@ #include "Tokenize.h" #include "StringConvert.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -470,7 +470,7 @@ void Player::CleanupsBeforeDelete(bool finalCleanup) bool Player::Create(ObjectGuid::LowType guidlow, CharacterCreateInfo* createInfo) { // FIXME: outfitId not used in player creating - // TODO: need more checks against packet modifications + /// @todo: need more checks against packet modifications // should check that skin, face, hair* are valid via DBC per race/class // also do it in Player::BuildEnumData, Player::LoadFromDB @@ -853,7 +853,7 @@ void Player::HandleDrowning(uint32 time_diff) { m_MirrorTimer[BREATH_TIMER] += 1 * IN_MILLISECONDS; // Calculate and deal damage - // TODO: Check this formula + /// @todo: Check this formula uint32 damage = GetMaxHealth() / 5 + urand(0, GetLevel() - 1); EnvironmentalDamage(DAMAGE_DROWNING, damage); } @@ -922,7 +922,7 @@ void Player::HandleDrowning(uint32 time_diff) { m_MirrorTimer[FIRE_TIMER] += 1 * IN_MILLISECONDS; // Calculate and deal damage - // TODO: Check this formula + /// @todo: Check this formula uint32 damage = urand(600, 700); if (m_MirrorTimerFlags & UNDERWATER_INLAVA) EnvironmentalDamage(DAMAGE_LAVA, damage); @@ -1837,7 +1837,7 @@ void Player::Regenerate(Powers power) uint32 curValue = GetPower(power); - // TODO: possible use of miscvalueb instead of amount + /// @todo: possible use of miscvalueb instead of amount if (HasAuraTypeWithMiscvalue(SPELL_AURA_PREVENT_REGENERATE_POWER, power + 1)) return; @@ -3184,7 +3184,7 @@ bool Player::_addSpell(uint32 spellId, uint8 addSpecMask, bool temporary, bool l continue; } - // @todo confirm if rogues start wth lockpicking skill at level 1 but only recieve the spell to use it at level 16 + /// @todo confirm if rogues start wth lockpicking skill at level 1 but only recieve the spell to use it at level 16 // Added for runeforging, it is confirmed via sniff that this happens when death knights learn the spell, not on character creation. if ((_spell_idx->second->AcquireMethod == SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN && !HasSkill(pSkill->id)) || ((pSkill->id == SKILL_LOCKPICKING || pSkill->id == SKILL_RUNEFORGING) && _spell_idx->second->TrivialSkillLineRankHigh == 0)) { @@ -5055,7 +5055,7 @@ void Player::GetDodgeFromAgility(float& diminishing, float& nondiminishing) if (!dodgeRatio || pclass > MAX_CLASSES) return; - // TODO: research if talents/effects that increase total agility by x% should increase non-diminishing part + /// @todo: research if talents/effects that increase total agility by x% should increase non-diminishing part float base_agility = GetCreateStat(STAT_AGILITY) * m_auraModifiersGroup[UNIT_MOD_STAT_START + static_cast(STAT_AGILITY)][BASE_PCT]; float bonus_agility = GetStat(STAT_AGILITY) - base_agility; @@ -12921,7 +12921,7 @@ PartyResult Player::CanUninviteFromGroup(ObjectGuid targetPlayerGUID) const if (grp->isRollLootActive()) return ERR_PARTY_LFG_BOOT_LOOT_ROLLS; - // TODO: Should also be sent when anyone has recently left combat, with an aprox ~5 seconds timer. + /// @todo: Should also be sent when anyone has recently left combat, with an aprox ~5 seconds timer. for (GroupReference const* itr = grp->GetFirstMember(); itr != nullptr; itr = itr->next()) if (itr->GetSource() && itr->GetSource()->IsInMap(this) && itr->GetSource()->IsInCombat()) return ERR_PARTY_LFG_BOOT_IN_COMBAT; diff --git a/src/server/game/Entities/Player/PlayerStorage.cpp b/src/server/game/Entities/Player/PlayerStorage.cpp index 6371c56a7..9d55b21e4 100644 --- a/src/server/game/Entities/Player/PlayerStorage.cpp +++ b/src/server/game/Entities/Player/PlayerStorage.cpp @@ -76,7 +76,7 @@ #include "Tokenize.h" #include "StringConvert.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -2271,7 +2271,7 @@ InventoryResult Player::CanUseItem(Item* pItem, bool not_loading) const // Armor that is binded to account can "morph" from plate to mail, etc. if skill is not learned yet. if (pProto->Quality == ITEM_QUALITY_HEIRLOOM && pProto->Class == ITEM_CLASS_ARMOR && !HasSkill(itemSkill)) { - // TODO: when you right-click already equipped item it throws EQUIP_ERR_NO_REQUIRED_PROFICIENCY. + /// @todo: when you right-click already equipped item it throws EQUIP_ERR_NO_REQUIRED_PROFICIENCY. // In fact it's a visual bug, everything works properly... I need sniffs of operations with // binded to account items from off server. diff --git a/src/server/game/Entities/Player/PlayerUpdates.cpp b/src/server/game/Entities/Player/PlayerUpdates.cpp index c6661c13b..9a7e09f80 100644 --- a/src/server/game/Entities/Player/PlayerUpdates.cpp +++ b/src/server/game/Entities/Player/PlayerUpdates.cpp @@ -38,7 +38,7 @@ #include "WeatherMgr.h" #include "WorldStatePackets.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -164,7 +164,7 @@ void Player::Update(uint32 p_time) if (Unit* victim = GetVictim()) { // default combat reach 10 - // TODO add weapon, skill check + /// @todo add weapon, skill check if (isAttackReady(BASE_ATTACK)) { @@ -1407,7 +1407,7 @@ void Player::UpdatePvPState() void Player::UpdateFFAPvPState(bool reset /*= true*/) { - // TODO: should we always synchronize UNIT_FIELD_BYTES_2, 1 of controller + /// @todo: should we always synchronize UNIT_FIELD_BYTES_2, 1 of controller // and controlled? no, we shouldn't, those are checked for affecting player // by client if (!pvpInfo.IsInNoPvPArea && !IsGameMaster() && diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 2929fb82c..4af0aa5c4 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -1174,7 +1174,7 @@ SpellCastResult Unit::CastSpell(SpellCastTargets const& targets, SpellInfo const return SPELL_FAILED_SPELL_UNAVAILABLE; } - // TODO: this is a workaround - not needed anymore, but required for some scripts :( + /// @todo: this is a workaround - not needed anymore, but required for some scripts :( if (!originalCaster && triggeredByAura) { originalCaster = triggeredByAura->GetCasterGUID(); @@ -1457,7 +1457,7 @@ void Unit::DealSpellDamage(SpellNonMeleeDamage* damageInfo, bool durabilityLoss, Unit::DealDamage(this, victim, damageInfo->damage, &cleanDamage, SPELL_DIRECT_DAMAGE, SpellSchoolMask(damageInfo->schoolMask), spellProto, durabilityLoss, false, spell); } -// TODO for melee need create structure as in +// @todo for melee need create structure as in void Unit::CalculateMeleeDamage(Unit* victim, CalcDamageInfo* damageInfo, WeaponAttackType attackType, const bool sittingVictim) { damageInfo->attacker = this; @@ -1951,7 +1951,7 @@ void Unit::DealMeleeDamage(CalcDamageInfo* damageInfo, bool durabilityLoss) Unit::DealDamageMods(this, damage, &absorb); - // TODO: Move this to a packet handler + /// @todo: Move this to a packet handler WorldPacket data(SMSG_SPELLDAMAGESHIELD, (8 + 8 + 4 + 4 + 4 + 4)); data << victim->GetGUID(); data << GetGUID(); @@ -3428,7 +3428,7 @@ SpellMissInfo Unit::SpellHitResult(Unit* victim, SpellInfo const* spell, bool Ca return SPELL_MISS_IMMUNE; // All positive spells can`t miss - // TODO: client not show miss log for this spells - so need find info for this in dbc and use it! + /// @todo: client not show miss log for this spells - so need find info for this in dbc and use it! if ((spell->IsPositive() || spell->HasEffect(SPELL_EFFECT_DISPEL)) && (!IsHostileTo(victim))) // prevent from affecting enemy by "positive" spell return SPELL_MISS_NONE; @@ -3496,7 +3496,7 @@ SpellMissInfo Unit::SpellHitResult(Unit* victim, Spell const* spell, bool CanRef } // All positive spells can`t miss - // TODO: client not show miss log for this spells - so need find info for this in dbc and use it! + /// @todo: client not show miss log for this spells - so need find info for this in dbc and use it! if ((spellInfo->IsPositive() || spellInfo->HasEffect(SPELL_EFFECT_DISPEL)) && (!IsHostileTo(victim))) // prevent from affecting enemy by "positive" spell { @@ -6615,7 +6615,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere target = this; if (roll_chance_i(10)) - ToPlayer()->Say("This is Madness!", LANG_UNIVERSAL); // TODO: It should be moved to database, shouldn't it? + ToPlayer()->Say("This is Madness!", LANG_UNIVERSAL); /// @todo: It should be moved to database, shouldn't it? break; } // Sunwell Exalted Caster Neck (??? neck) @@ -7527,7 +7527,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere triggered_spell_id = isWrathSpell ? 48518 : 48517; break; } - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. } case SPELLFAMILY_ROGUE: { @@ -8378,7 +8378,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere // Mark of Blood if (dummySpell->Id == 49005) { - // TODO: need more info (cooldowns/PPM) + /// @todo: need more info (cooldowns/PPM) triggered_spell_id = 61607; break; } @@ -9454,7 +9454,7 @@ bool Unit::HandleProcTriggerSpell(Unit* victim, uint32 damage, AuraEffect* trigg target = this; trigger_spell_id = 22588; - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. } // Bonus Healing (Crystal Spire of Karabor mace) case 40971: @@ -10843,7 +10843,7 @@ void Unit::SetCharm(Unit* charm, bool apply) LOG_FATAL("entities.unit", "Player {} is trying to charm unit {}, but it already has a charmed unit {}", GetName(), charm->GetEntry(), GetCharmGUID().ToString()); charm->m_ControlledByPlayer = true; - // TODO: maybe we can use this flag to check if controlled by player + /// @todo: maybe we can use this flag to check if controlled by player charm->SetUnitFlag(UNIT_FLAG_PLAYER_CONTROLLED); } else @@ -12150,7 +12150,7 @@ float Unit::SpellTakenCritChance(Unit const* caster, SpellInfo const* spellProto { return 100.0f; } - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_DAMAGE_CLASS_RANGED: { // flat aura mods @@ -12211,7 +12211,7 @@ uint32 Unit::SpellCriticalDamageBonus(Unit const* caster, SpellInfo const* spell { case SPELL_DAMAGE_CLASS_MELEE: // for melee based spells is 100% case SPELL_DAMAGE_CLASS_RANGED: - // TODO: write here full calculation for melee/ranged spells + /// @todo: write here full calculation for melee/ranged spells crit_bonus += damage; break; default: @@ -12249,7 +12249,7 @@ uint32 Unit::SpellCriticalHealingBonus(Unit const* caster, SpellInfo const* spel { case SPELL_DAMAGE_CLASS_MELEE: // for melee based spells is 100% case SPELL_DAMAGE_CLASS_RANGED: - // TODO: write here full calculation for melee/ranged spells + /// @todo: write here full calculation for melee/ranged spells crit_bonus = damage; break; default: @@ -14867,7 +14867,7 @@ void Unit::ModSpellCastTime(SpellInfo const* spellInfo, int32& castTime, Spell* // called from caster if (Player* modOwner = GetSpellModOwner()) - // TODO:(MadAgos) Eventually check and delete the bool argument + /// @todo:(MadAgos) Eventually check and delete the bool argument modOwner->ApplySpellMod(spellInfo->Id, SPELLMOD_CASTING_TIME, castTime, spell, bool(modOwner != this && !IsPet())); switch (spellInfo->DmgClass) @@ -18101,7 +18101,7 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp { Map* instanceMap = creature->GetMap(); //Player* creditedPlayer = GetCharmerOrOwnerPlayerOrPlayerItself(); - // TODO: do instance binding anyway if the charmer/owner is offline + /// @todo: do instance binding anyway if the charmer/owner is offline if (instanceMap->IsDungeon() && player) if (instanceMap->IsRaidOrHeroicDungeon()) @@ -18540,7 +18540,7 @@ bool Unit::SetCharmedBy(Unit* charmer, CharmType type, AuraApplication const* au AttackStop(); // Xinef: dont reset threat and combat, put them on offline list, moved down after faction changes - // CombatStop(); // TODO: CombatStop(true) may cause crash (interrupt spells) + // CombatStop(); /// @todo: CombatStop(true) may cause crash (interrupt spells) // DeleteThreatList(); Player* playerCharmer = charmer->ToPlayer(); diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index ba35c7c30..6fa06c994 100644 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -581,7 +581,7 @@ enum MovementFlags MOVEMENTFLAG_FALLING_SLOW = 0x20000000, // active rogue safe fall spell (passive) MOVEMENTFLAG_HOVER = 0x40000000, // hover, cannot jump - // TODO: Check if PITCH_UP and PITCH_DOWN really belong here.. + /// @todo: Check if PITCH_UP and PITCH_DOWN really belong here.. MOVEMENTFLAG_MASK_MOVING = MOVEMENTFLAG_FORWARD | MOVEMENTFLAG_BACKWARD | MOVEMENTFLAG_STRAFE_LEFT | MOVEMENTFLAG_STRAFE_RIGHT | MOVEMENTFLAG_PITCH_UP | MOVEMENTFLAG_PITCH_DOWN | MOVEMENTFLAG_FALLING | MOVEMENTFLAG_FALLING_FAR | MOVEMENTFLAG_ASCENDING | MOVEMENTFLAG_DESCENDING | @@ -900,7 +900,7 @@ struct CalcDamageInfo uint32 procVictim; uint32 procEx; uint32 cleanDamage; // Used only for rage calculation - MeleeHitOutcome hitOutCome; // TODO: remove this field (need use TargetState) + MeleeHitOutcome hitOutCome; /// @todo: remove this field (need use TargetState) }; // Spell damage info structure based on structure sending in SMSG_SPELLNONMELEEDAMAGELOG opcode diff --git a/src/server/game/Events/GameEventMgr.cpp b/src/server/game/Events/GameEventMgr.cpp index d9d5879e7..21e40c9e1 100644 --- a/src/server/game/Events/GameEventMgr.cpp +++ b/src/server/game/Events/GameEventMgr.cpp @@ -826,7 +826,7 @@ void GameEventMgr::LoadFromDB() Field* fields = result->Fetch(); uint32 questId = fields[0].Get(); - uint32 eventEntry = fields[1].Get(); // TODO: Change to uint8 + uint32 eventEntry = fields[1].Get(); /// @todo: Change to uint8 Quest* questTemplate = const_cast(sObjectMgr->GetQuestTemplate(questId)); diff --git a/src/server/game/Guilds/Guild.h b/src/server/game/Guilds/Guild.h index 2c6591f69..a4d873235 100644 --- a/src/server/game/Guilds/Guild.h +++ b/src/server/game/Guilds/Guild.h @@ -161,7 +161,7 @@ enum GuildEvents GE_RANK_DELETED = 11, GE_SIGNED_ON = 12, GE_SIGNED_OFF = 13, - GE_GUILDBANKBAGSLOTS_CHANGED = 14, /// TODO: Sent when items are moved in gbank - all players with bank open will send tab query + GE_GUILDBANKBAGSLOTS_CHANGED = 14, /// @todo: Sent when items are moved in gbank - all players with bank open will send tab query GE_BANK_TAB_PURCHASED = 15, GE_BANK_TAB_UPDATED = 16, GE_BANK_MONEY_SET = 17, diff --git a/src/server/game/Handlers/CalendarHandler.cpp b/src/server/game/Handlers/CalendarHandler.cpp index 5130565f6..9f72af9c0 100644 --- a/src/server/game/Handlers/CalendarHandler.cpp +++ b/src/server/game/Handlers/CalendarHandler.cpp @@ -152,7 +152,7 @@ void WorldSession::HandleCalendarGetCalendar(WorldPacket& /*recvData*/) data << uint32(boundCounter); data.append(dataBuffer); - // TODO: Fix this, how we do know how many and what holidays to send? + /// @todo: Fix this, how we do know how many and what holidays to send? data << uint32(sGameEventMgr->modifiedHolidays.size()); for (uint32 entry : sGameEventMgr->modifiedHolidays) { diff --git a/src/server/game/Handlers/MiscHandler.cpp b/src/server/game/Handlers/MiscHandler.cpp index 8005cbe38..d78818a47 100644 --- a/src/server/game/Handlers/MiscHandler.cpp +++ b/src/server/game/Handlers/MiscHandler.cpp @@ -431,7 +431,7 @@ void WorldSession::HandleLogoutRequestOpcode(WorldPackets::Character::LogoutRequ bool preventAfkLogout = sWorld->getIntConfig(CONFIG_AFK_PREVENT_LOGOUT) == 2 && GetPlayer()->isAFK(); - /// TODO: Possibly add RBAC permission to log out in combat + /// @todo: Possibly add RBAC permission to log out in combat bool canLogoutInCombat = GetPlayer()->HasPlayerFlag(PLAYER_FLAGS_RESTING); uint32 reason = 0; diff --git a/src/server/game/Handlers/PetHandler.cpp b/src/server/game/Handlers/PetHandler.cpp index 6d9b1c1af..ca040451d 100644 --- a/src/server/game/Handlers/PetHandler.cpp +++ b/src/server/game/Handlers/PetHandler.cpp @@ -321,7 +321,7 @@ void WorldSession::HandlePetActionHelper(Unit* pet, ObjectGuid guid1, uint32 spe if (pet->ToPet()) pet->ToPet()->ClearCastWhenWillAvailable(); pet->ClearInPetCombat(); - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case REACT_DEFENSIVE: //recovery case REACT_AGGRESSIVE: //activete diff --git a/src/server/game/Handlers/PetitionsHandler.cpp b/src/server/game/Handlers/PetitionsHandler.cpp index 3734aeaf8..e8cc33152 100644 --- a/src/server/game/Handlers/PetitionsHandler.cpp +++ b/src/server/game/Handlers/PetitionsHandler.cpp @@ -91,7 +91,7 @@ void WorldSession::HandlePetitionBuyOpcode(WorldPacket& recvData) } else { - // TODO: find correct opcode + /// @todo: find correct opcode if (_player->GetLevel() < sWorld->getIntConfig(CONFIG_MAX_PLAYER_LEVEL)) { SendArenaTeamCommandResult(ERR_ARENA_TEAM_CREATE_S, "", _player->GetName(), ERR_ARENA_TEAM_TARGET_TOO_LOW_S); diff --git a/src/server/game/Handlers/SpellHandler.cpp b/src/server/game/Handlers/SpellHandler.cpp index 247fded70..c8947b7f1 100644 --- a/src/server/game/Handlers/SpellHandler.cpp +++ b/src/server/game/Handlers/SpellHandler.cpp @@ -58,7 +58,7 @@ void WorldSession::HandleClientCastFlags(WorldPacket& recvPacket, uint8 castFlag void WorldSession::HandleUseItemOpcode(WorldPacket& recvPacket) { - // TODO: add targets.read() check + /// @todo: add targets.read() check Player* pUser = _player; // ignore for remote control state @@ -384,7 +384,7 @@ void WorldSession::HandleCastSpellOpcode(WorldPacket& recvPacket) } } - // TODO: Preparation for #23204 + /// @todo: Preparation for #23204 // allow casting of spells triggered by clientside periodic trigger auras /* if (caster->HasAuraTypeWithTriggerSpell(SPELL_AURA_PERIODIC_TRIGGER_SPELL_FROM_CLIENT, spellId)) @@ -651,7 +651,7 @@ void WorldSession::HandleSpellClick(WorldPacket& recvData) if (!unit) return; - // TODO: Unit::SetCharmedBy: 28782 is not in world but 0 is trying to charm it! -> crash + /// @todo: Unit::SetCharmedBy: 28782 is not in world but 0 is trying to charm it! -> crash if (!unit->IsInWorld()) return; diff --git a/src/server/game/Loot/LootMgr.cpp b/src/server/game/Loot/LootMgr.cpp index e78bd0cc3..7316843fa 100644 --- a/src/server/game/Loot/LootMgr.cpp +++ b/src/server/game/Loot/LootMgr.cpp @@ -1457,7 +1457,7 @@ float LootTemplate::LootGroup::TotalChance() const void LootTemplate::LootGroup::Verify(LootStore const& lootstore, uint32 id, uint8 group_id) const { float chance = RawTotalChance(); - if (chance > 101.0f) // TODO: replace with 100% when DBs will be ready + if (chance > 101.0f) /// @todo: replace with 100% when DBs will be ready { LOG_ERROR("sql.sql", "Table '{}' entry {} group {} has total chance > 100% ({})", lootstore.GetName(), id, group_id, chance); } @@ -1807,7 +1807,7 @@ void LootTemplate::Verify(LootStore const& lootstore, uint32 id) const if (Groups[i]) Groups[i]->Verify(lootstore, id, i + 1); - // TODO: References validity checks + /// @todo: References validity checks } void LootTemplate::CheckLootRefs(LootTemplateMap const& store, LootIdSet* ref_set) const diff --git a/src/server/game/Maps/MapMgr.cpp b/src/server/game/Maps/MapMgr.cpp index b3ade9b5a..a1f866eac 100644 --- a/src/server/game/Maps/MapMgr.cpp +++ b/src/server/game/Maps/MapMgr.cpp @@ -167,7 +167,7 @@ Map::EnterState MapMgr::PlayerCannotEnter(uint32 mapid, Player* player, bool log if ((!group || !group->isRaidGroup()) && !sWorld->getBoolConfig(CONFIG_INSTANCE_IGNORE_RAID)) { // probably there must be special opcode, because client has this string constant in GlobalStrings.lua - // TODO: this is not a good place to send the message + /// @todo: this is not a good place to send the message player->GetSession()->SendAreaTriggerMessage(player->GetSession()->GetAcoreString(LANG_INSTANCE_RAID_GROUP_ONLY), mapName); LOG_DEBUG("maps", "MAP: Player '{}' must be in a raid group to enter instance '{}'", player->GetName(), mapName); return Map::CANNOT_ENTER_NOT_IN_RAID; @@ -320,7 +320,7 @@ bool MapMgr::IsValidMAP(uint32 mapid, bool startUp) return mEntry && (!mEntry->IsDungeon() || sObjectMgr->GetInstanceTemplate(mapid)); } - // TODO: add check for battleground template + /// @todo: add check for battleground template } void MapMgr::UnloadAll() diff --git a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp index 5e06523fa..b3b43a572 100644 --- a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp @@ -32,7 +32,7 @@ void PointMovementGenerator::DoInitialize(T* unit) if (unit->HasUnitState(UNIT_STATE_NOT_MOVE) || unit->IsMovementPreventedByCasting()) { // the next line is to ensure that a new spline is created in DoUpdate() once the unit is no longer rooted/stunned - // todo: rename this flag to something more appropriate since it is set to true even without speed change now. + /// @todo: rename this flag to something more appropriate since it is set to true even without speed change now. i_recalculateSpeed = true; return; } diff --git a/src/server/game/Movement/Spline/MoveSpline.cpp b/src/server/game/Movement/Spline/MoveSpline.cpp index 27fb52288..3d3be3769 100644 --- a/src/server/game/Movement/Spline/MoveSpline.cpp +++ b/src/server/game/Movement/Spline/MoveSpline.cpp @@ -147,7 +147,7 @@ namespace Movement spline.initLengths(init); } - // TODO: what to do in such cases? problem is in input data (all points are at same coords) + /// @todo: what to do in such cases? problem is in input data (all points are at same coords) if (spline.length() < minimal_duration) { spline.set_length(spline.last(), spline.isCyclic() ? 1000 : 1); diff --git a/src/server/game/Scripting/MapScripts.cpp b/src/server/game/Scripting/MapScripts.cpp index d8c96b85b..1874dabef 100644 --- a/src/server/game/Scripting/MapScripts.cpp +++ b/src/server/game/Scripting/MapScripts.cpp @@ -664,7 +664,7 @@ void Map::ScriptsProcess() case SCRIPT_COMMAND_CAST_SPELL: { - // TODO: Allow gameobjects to be targets and casters + /// @todo: Allow gameobjects to be targets and casters if (!source && !target) { LOG_ERROR("maps.script", "{} source and target objects are nullptr.", step.script->GetDebugInfo()); diff --git a/src/server/game/Scripting/ScriptDefines/BattlegroundScript.cpp b/src/server/game/Scripting/ScriptDefines/BattlegroundScript.cpp index f746906de..272b62f0a 100644 --- a/src/server/game/Scripting/ScriptDefines/BattlegroundScript.cpp +++ b/src/server/game/Scripting/ScriptDefines/BattlegroundScript.cpp @@ -19,7 +19,7 @@ Battleground* ScriptMgr::CreateBattleground(BattlegroundTypeId /*typeId*/) { - // TODO: Implement script-side battlegrounds. + /// @todo: Implement script-side battlegrounds. ABORT(); return nullptr; } diff --git a/src/server/game/Server/WorldSession.cpp b/src/server/game/Server/WorldSession.cpp index 551239007..2d9fd18bd 100644 --- a/src/server/game/Server/WorldSession.cpp +++ b/src/server/game/Server/WorldSession.cpp @@ -1175,7 +1175,7 @@ void WorldSession::ReadAddonsInfo(ByteBuffer& data) LOG_DEBUG("network", "ADDON: {} (0x{:x}) was not known, saving...", addon.Name, addon.CRC); } - // TODO: Find out when to not use CRC/pubkey, and other possible states. + /// @todo: Find out when to not use CRC/pubkey, and other possible states. m_addonsList.push_back(addon); } @@ -1230,7 +1230,7 @@ void WorldSession::SendAddonsInfo() data.append(addonPublicKey, sizeof(addonPublicKey)); } - data << uint32(0); // TODO: Find out the meaning of this. + data << uint32(0); /// @todo: Find out the meaning of this. } uint8 unk3 = 0; // 0 is sent here diff --git a/src/server/game/Server/WorldSocket.cpp b/src/server/game/Server/WorldSocket.cpp index 964fb40e4..57a8b54e0 100644 --- a/src/server/game/Server/WorldSocket.cpp +++ b/src/server/game/Server/WorldSocket.cpp @@ -351,7 +351,7 @@ WorldSocket::ReadDataHandlerResult WorldSocket::ReadDataHandler() LOG_ERROR("network", "WorldSocket::ReadDataHandler(): client {} sent malformed CMSG_AUTH_SESSION", GetRemoteIpAddress().to_string()); return ReadDataHandlerResult::Error; } - case CMSG_KEEP_ALIVE: // todo: handle this packet in the same way of CMSG_TIME_SYNC_RESP + case CMSG_KEEP_ALIVE: /// @todo: handle this packet in the same way of CMSG_TIME_SYNC_RESP sessionGuard.lock(); LogOpcodeText(opcode, sessionGuard); if (_worldSession) diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.cpp b/src/server/game/Spells/Auras/SpellAuraEffects.cpp index 48fb3ef30..799bf9e55 100644 --- a/src/server/game/Spells/Auras/SpellAuraEffects.cpp +++ b/src/server/game/Spells/Auras/SpellAuraEffects.cpp @@ -39,7 +39,7 @@ #include "Vehicle.h" #include "WorldPacket.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -595,7 +595,7 @@ void AuraEffect::CalculatePeriodic(Unit* caster, bool create, bool load) // 3 spells have no amplitude set if (!m_amplitude) m_amplitude = 1 * IN_MILLISECONDS; - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_AURA_PERIODIC_DAMAGE: case SPELL_AURA_PERIODIC_HEAL: case SPELL_AURA_OBS_MOD_HEALTH: @@ -1190,7 +1190,7 @@ void AuraEffect::CleanupTriggeredSpells(Unit* target) return; // needed for spell 43680, maybe others - // TODO: is there a spell flag, which can solve this in a more sophisticated way? + /// @todo: is there a spell flag, which can solve this in a more sophisticated way? if (m_spellInfo->Effects[GetEffIndex()].ApplyAuraName == SPELL_AURA_PERIODIC_TRIGGER_SPELL && uint32(m_spellInfo->GetDuration()) == m_spellInfo->Effects[GetEffIndex()].Amplitude) return; @@ -3128,7 +3128,7 @@ void AuraEffect::HandlePreventFleeing(AuraApplication const* aurApp, uint8 mode, // Since patch 3.0.2 this mechanic no longer affects fear effects. It will ONLY prevent humanoids from fleeing due to low health. if (target->GetTypeId() == TYPEID_PLAYER || !apply || target->HasAuraType(SPELL_AURA_MOD_FEAR)) return; - /// TODO: find a way to cancel fleeing for assistance. + /// @todo: find a way to cancel fleeing for assistance. /// Currently this will only stop creatures fleeing due to low health that could not find nearby allies to flee towards. target->SetControlled(false, UNIT_STATE_FLEEING); } @@ -3864,7 +3864,7 @@ void AuraEffect::HandleAuraModSchoolImmunity(AuraApplication const* aurApp, uint && GetSpellInfo()->HasAttribute(SPELL_ATTR2_FAIL_ON_ALL_TARGETS_IMMUNE)) target->RemoveAurasWithInterruptFlags(AURA_INTERRUPT_FLAG_IMMUNE_OR_LOST_SELECTION); - // TODO: optimalize this cycle - use RemoveAurasWithInterruptFlags call or something else + /// @todo: optimalize this cycle - use RemoveAurasWithInterruptFlags call or something else if ((apply) && GetSpellInfo()->HasAttribute(SPELL_ATTR1_IMMUNITY_PURGES_EFFECT) && GetSpellInfo()->IsPositive()) //Only positive immunity removes auras @@ -6024,7 +6024,7 @@ void AuraEffect::HandlePeriodicTriggerSpellAuraTick(Unit* target, Unit* caster) triggerSpellId = 30571; break; // Doom - // TODO: effect trigger spell may be independant on spell targets, and executed in spell finish phase + /// @todo: effect trigger spell may be independant on spell targets, and executed in spell finish phase // so instakill will be naturally done before trigger spell case 31347: { diff --git a/src/server/game/Spells/Auras/SpellAuras.cpp b/src/server/game/Spells/Auras/SpellAuras.cpp index 9afd67389..6a8bc2109 100644 --- a/src/server/game/Spells/Auras/SpellAuras.cpp +++ b/src/server/game/Spells/Auras/SpellAuras.cpp @@ -35,7 +35,7 @@ #include "Vehicle.h" #include "WorldPacket.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -520,7 +520,7 @@ void Aura::_UnapplyForTarget(Unit* target, Unit* caster, AuraApplication* auraAp ApplicationMap::iterator itr = m_applications.find(target->GetGUID()); - // TODO: Figure out why this happens + /// @todo: Figure out why this happens if (itr == m_applications.end()) { LOG_ERROR("spells.aura", "Aura::_UnapplyForTarget, target:{}, caster:{}, spell:{} was not found in owners application map!", @@ -1396,7 +1396,7 @@ void Aura::HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, b if (caster->HasAura(56370)) SetDuration(0); } - // Todo: This should be moved to similar function in spell::hit + /// @todo: This should be moved to similar function in spell::hit else if (GetSpellInfo()->SpellFamilyFlags[0] & 0x01000000) { // Polymorph Sound - Sheep && Penguin @@ -1695,7 +1695,7 @@ void Aura::HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, b case SPELLFAMILY_WARRIOR: if (!caster) break; - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELLFAMILY_WARLOCK: if (!caster) break; @@ -2243,7 +2243,7 @@ bool Aura::IsProcTriggeredOnEvent(AuraApplication* aurApp, ProcEventInfo& eventI if (IsProcOnCooldown()) return false; - // TODO: + /// @todo: // something about triggered spells triggering, and add extra attack effect // do checks against db data @@ -2261,14 +2261,14 @@ bool Aura::IsProcTriggeredOnEvent(AuraApplication* aurApp, ProcEventInfo& eventI if (!check) return false; - // TODO: + /// @todo: // do allow additional requirements for procs // this is needed because this is the last moment in which you can prevent aura charge drop on proc // and possibly a way to prevent default checks (if there're going to be any) // Check if current equipment meets aura requirements // do that only for passive spells - // TODO: this needs to be unified for all kinds of auras + /// @todo: this needs to be unified for all kinds of auras Unit* target = aurApp->GetTarget(); if (IsPassive() && target->GetTypeId() == TYPEID_PLAYER && GetSpellInfo()->EquippedItemClass != -1) { @@ -2847,7 +2847,7 @@ void UnitAura::FillTargetMap(std::map& targets, Unit* caster) } case SPELL_EFFECT_APPLY_AREA_AURA_PET: targetList.push_back(GetUnitOwner()); - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_EFFECT_APPLY_AREA_AURA_OWNER: { if (Unit* owner = GetUnitOwner()->GetCharmerOrOwner()) diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp index 54a700170..e22e99eb6 100644 --- a/src/server/game/Spells/Spell.cpp +++ b/src/server/game/Spells/Spell.cpp @@ -1890,7 +1890,7 @@ void Spell::SelectImplicitTrajTargets(SpellEffIndex effIndex, SpellImplicitTarge continue; const float size = std::max((*itr)->GetObjectSize() * 0.7f, 1.0f); // 1/sqrt(3) - // TODO: all calculation should be based on src instead of m_caster + /// @todo: all calculation should be based on src instead of m_caster const float objDist2d = std::fabs(m_targets.GetSrcPos()->GetExactDist2d(*itr) * cos(m_targets.GetSrcPos()->GetRelativeAngle(*itr))); const float dz = std::fabs((*itr)->GetPositionZ() - m_targets.GetSrcPos()->m_positionZ); @@ -2011,7 +2011,7 @@ void Spell::SelectImplicitTrajTargets(SpellEffIndex effIndex, SpellImplicitTarge void Spell::SelectEffectTypeImplicitTargets(uint8 effIndex) { // special case for SPELL_EFFECT_SUMMON_RAF_FRIEND and SPELL_EFFECT_SUMMON_PLAYER - // TODO: this is a workaround - target shouldn't be stored in target map for those spells + /// @todo: this is a workaround - target shouldn't be stored in target map for those spells switch (m_spellInfo->Effects[effIndex].Effect) { case SPELL_EFFECT_SUMMON_RAF_FRIEND: @@ -2054,7 +2054,7 @@ void Spell::SelectEffectTypeImplicitTargets(uint8 effIndex) { if (Corpse* corpseTarget = m_targets.GetCorpseTarget()) { - // TODO: this is a workaround - corpses should be added to spell target map too, but we can't do that so we add owner instead + /// @todo: this is a workaround - corpses should be added to spell target map too, but we can't do that so we add owner instead if (Player* owner = ObjectAccessor::FindPlayer(corpseTarget->GetOwnerGUID())) target = owner; } @@ -2442,7 +2442,7 @@ void Spell::AddUnitTarget(Unit* target, uint32 effectMask, bool checkIfValid /*= if (m_spellInfo->Speed > 0.0f && m_caster != target) { // calculate spell incoming interval - // TODO: this is a hack + /// @todo: this is a hack float dist = m_caster->GetDistance(target->GetPositionX(), target->GetPositionY(), target->GetPositionZ()); if (dist < 5.0f) @@ -2472,7 +2472,7 @@ void Spell::AddUnitTarget(Unit* target, uint32 effectMask, bool checkIfValid /*= m_spellFlags |= SPELL_FLAG_REFLECTED; // HACK: workaround check for succubus seduction case - // TODO: seduction should be casted only on humanoids (not demons) + /// @todo: seduction should be casted only on humanoids (not demons) if (m_caster->IsPet()) { CreatureTemplate const* ci = sObjectMgr->GetCreatureTemplate(m_caster->GetEntry()); @@ -2702,7 +2702,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo* target) { m_needComboPoints = false; // Restore spell mods for a miss/dodge/parry Cold Blood - // TODO: check how broad this rule should be + /// @todo: check how broad this rule should be if (m_caster->GetTypeId() == TYPEID_PLAYER && (missInfo == SPELL_MISS_MISS || missInfo == SPELL_MISS_DODGE || missInfo == SPELL_MISS_PARRY)) m_caster->ToPlayer()->RestoreSpellMods(this, 14177); } @@ -3051,7 +3051,7 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit* unit, uint32 effectMask, bool scaleA else if (m_caster->IsFriendlyTo(unit)) { // for delayed spells ignore negative spells (after duel end) for friendly targets - // TODO: this cause soul transfer bugged + /// @todo: this cause soul transfer bugged if(!IsTriggered() && m_spellInfo->Speed > 0.0f && unit->GetTypeId() == TYPEID_PLAYER && !m_spellInfo->IsPositive()) return SPELL_MISS_EVADE; @@ -3238,7 +3238,7 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit* unit, uint32 effectMask, bool scaleA void Spell::DoTriggersOnSpellHit(Unit* unit, uint8 effMask) { // Apply additional spell effects to target - // TODO: move this code to scripts + /// @todo: move this code to scripts if (m_preCastSpell) { // Paladin immunity shields @@ -3297,7 +3297,7 @@ void Spell::DoTriggersOnSpellHit(Unit* unit, uint8 effMask) } // trigger linked auras remove/apply - // TODO: remove/cleanup this, as this table is not documented and people are doing stupid things with it + /// @todo: remove/cleanup this, as this table is not documented and people are doing stupid things with it if (std::vector const* spellTriggered = sSpellMgr->GetSpellLinked(m_spellInfo->Id + SPELL_LINK_HIT)) { for (std::vector::const_iterator i = spellTriggered->begin(); i != spellTriggered->end(); ++i) @@ -3709,7 +3709,7 @@ void Spell::cancel(bool bySelf) if (m_caster->ToPlayer()->NeedSendSpectatorData()) ArenaSpectator::SendCommand_Spell(m_caster->FindMap(), m_caster->GetGUID(), "SPE", m_spellInfo->Id, bySelf ? 99998 : 99999); } - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_STATE_DELAYED: SendInterrupted(0); // xinef: fixes bugged gcd reset in some cases @@ -5992,7 +5992,7 @@ SpellCastResult Spell::CheckCast(bool strict) } // Triggered spells also have range check - // TODO: determine if there is some flag to enable/disable the check + /// @todo: determine if there is some flag to enable/disable the check castResult = CheckRange(strict); if (castResult != SPELL_CAST_OK) return castResult; @@ -7416,7 +7416,7 @@ SpellCastResult Spell::CheckItems() return SPELL_FAILED_DONT_REPORT; } } - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC: { Item* targetItem = m_targets.GetItemTarget(); @@ -7917,7 +7917,7 @@ bool Spell::CheckEffectTarget(Unit const* target, uint32 eff) const return true; } - // todo: below shouldn't be here, but it's temporary + /// @todo: below shouldn't be here, but it's temporary //Check targets for LOS visibility (except spells without range limitations) switch (m_spellInfo->Effects[eff].Effect) { @@ -8709,7 +8709,7 @@ bool Spell::CanExecuteTriggersOnHit(uint8 effMask, SpellInfo const* triggeredByA void Spell::PrepareTriggersExecutedOnHit() { - // todo: move this to scripts + /// @todo: move this to scripts if (m_spellInfo->SpellFamilyName) { SpellInfo const* excludeCasterSpellInfo = sSpellMgr->GetSpellInfo(m_spellInfo->ExcludeCasterAuraSpell); @@ -8720,7 +8720,7 @@ void Spell::PrepareTriggersExecutedOnHit() m_preCastSpell = m_spellInfo->ExcludeTargetAuraSpell; } - // todo: move this to scripts + /// @todo: move this to scripts switch (m_spellInfo->SpellFamilyName) { case SPELLFAMILY_PALADIN: diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 49f6cd7ca..bf518f291 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -63,7 +63,7 @@ #include "World.h" #include "WorldPacket.h" - // TODO: this import is not necessary for compilation and marked as unused by the IDE + /// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -586,7 +586,7 @@ void Spell::EffectSchoolDMG(SpellEffIndex effIndex) } } - // TODO: should this be put on taken but not done? + /// @todo: should this be put on taken but not done? if (found) damage += m_spellInfo->Effects[EFFECT_1].CalcValue(); @@ -797,7 +797,7 @@ void Spell::EffectTriggerSpell(SpellEffIndex effIndex) uint32 triggered_spell_id = m_spellInfo->Effects[effIndex].TriggerSpell; - // todo: move those to spell scripts + /// @todo: move those to spell scripts if (m_spellInfo->Effects[effIndex].Effect == SPELL_EFFECT_TRIGGER_SPELL && effectHandleMode == SPELL_EFFECT_HANDLE_LAUNCH_TARGET) { @@ -1422,7 +1422,7 @@ void Spell::EffectSendEvent(SpellEffIndex effIndex) // some spells have no target entries in dbc and they use focus target if (focusObject) target = focusObject; - // TODO: there should be a possibility to pass dest target to event script + /// @todo: there should be a possibility to pass dest target to event script } LOG_DEBUG("spells.aura", "Spell ScriptStart {} for spellid {} in EffectSendEvent ", m_spellInfo->Effects[effIndex].MiscValue, m_spellInfo->Id); @@ -1827,7 +1827,7 @@ void Spell::EffectCreateItem2(SpellEffIndex effIndex) else player->AutoStoreLoot(m_spellInfo->Id, LootTemplates_Spell); // create some random items } - // TODO: ExecuteLogEffectCreateItem(i, m_spellInfo->Effects[i].ItemType); + /// @todo: ExecuteLogEffectCreateItem(i, m_spellInfo->Effects[i].ItemType); } void Spell::EffectCreateRandomItem(SpellEffIndex /*effIndex*/) @@ -1846,7 +1846,7 @@ void Spell::EffectCreateRandomItem(SpellEffIndex /*effIndex*/) // create some random items player->AutoStoreLoot(m_spellInfo->Id, LootTemplates_Spell); - // TODO: ExecuteLogEffectCreateItem(i, m_spellInfo->Effects[i].ItemType); + /// @todo: ExecuteLogEffectCreateItem(i, m_spellInfo->Effects[i].ItemType); } void Spell::EffectPersistentAA(SpellEffIndex effIndex) @@ -2107,7 +2107,7 @@ void Spell::EffectOpenLock(SpellEffIndex effIndex) if (gameObjTarget) { GameObjectTemplate const* goInfo = gameObjTarget->GetGOInfo(); - // Arathi Basin banner opening. // TODO: Verify correctness of this check + // Arathi Basin banner opening. /// @todo: Verify correctness of this check if ((goInfo->type == GAMEOBJECT_TYPE_BUTTON && goInfo->button.noDamageImmune) || (goInfo->type == GAMEOBJECT_TYPE_GOOBER && goInfo->goober.losOK)) { @@ -2139,7 +2139,7 @@ void Spell::EffectOpenLock(SpellEffIndex effIndex) } return; } - // TODO: Add script for spell 41920 - Filling, becouse server it freze when use this spell + /// @todo: Add script for spell 41920 - Filling, becouse server it freze when use this spell // handle outdoor pvp object opening, return true if go was registered for handling // these objects must have been spawned by outdoorpvp! else if (gameObjTarget->GetGOInfo()->type == GAMEOBJECT_TYPE_GOOBER && sOutdoorPvPMgr->HandleOpenGo(player, gameObjTarget)) @@ -2687,7 +2687,7 @@ void Spell::EffectDualWield(SpellEffIndex /*effIndex*/) void Spell::EffectPull(SpellEffIndex effIndex) { - // TODO: create a proper pull towards distract spell center for distract + /// @todo: create a proper pull towards distract spell center for distract EffectNULL(effIndex); } @@ -3712,7 +3712,7 @@ void Spell::EffectInterruptCast(SpellEffIndex effIndex) if (!unitTarget || !unitTarget->IsAlive()) return; - // TODO: not all spells that used this effect apply cooldown at school spells + /// @todo: not all spells that used this effect apply cooldown at school spells // also exist case: apply cooldown to interrupted cast only and to all spells // there is no CURRENT_AUTOREPEAT_SPELL spells that can be interrupted for (uint32 i = CURRENT_FIRST_NON_MELEE_SPELL; i < CURRENT_AUTOREPEAT_SPELL; ++i) @@ -3794,7 +3794,7 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex) if (effectHandleMode != SPELL_EFFECT_HANDLE_HIT_TARGET) return; - // TODO: we must implement hunter pet summon at login there (spell 6962) + /// @todo: we must implement hunter pet summon at login there (spell 6962) switch (m_spellInfo->SpellFamilyName) { @@ -4554,7 +4554,7 @@ void Spell::EffectFeedPet(SpellEffIndex effIndex) uint32 count = 1; player->DestroyItemCount(foodItem, count, true); - // TODO: fix crash when a spell has two effects, both pointed at the same item target + /// @todo: fix crash when a spell has two effects, both pointed at the same item target m_caster->CastCustomSpell(pet, m_spellInfo->Effects[effIndex].TriggerSpell, &benefit, nullptr, nullptr, true); } @@ -5248,7 +5248,7 @@ void Spell::EffectResurrectPet(SpellEffIndex /*effIndex*/) return; } - // TODO: Better to fail Hunter's "Revive Pet" at cast instead of here when casting ends + /// @todo: Better to fail Hunter's "Revive Pet" at cast instead of here when casting ends if (pet->IsAlive()) { return; diff --git a/src/server/game/Spells/SpellInfo.cpp b/src/server/game/Spells/SpellInfo.cpp index a6845e5f3..89629a44c 100644 --- a/src/server/game/Spells/SpellInfo.cpp +++ b/src/server/game/Spells/SpellInfo.cpp @@ -1460,7 +1460,7 @@ SpellCastResult SpellInfo::CheckShapeshift(uint32 form) const // Check if stance disables cast of not-stance spells // Example: cannot cast any other spells in zombie or ghoul form - // TODO: Find a way to disable use of these spells clientside + /// @todo: Find a way to disable use of these spells clientside if (shapeInfo && shapeInfo->flags1 & 0x400) { if (!(stanceMask & Stances)) @@ -2283,7 +2283,7 @@ SpellSpecificType SpellInfo::LoadSpellSpecific() const /// @workaround For non-stacking tracking spells (We need generic solution) if (Id == 30645) // Gas Cloud Tracking return SPELL_SPECIFIC_NORMAL; - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case SPELL_AURA_TRACK_RESOURCES: case SPELL_AURA_TRACK_STEALTHED: return SPELL_SPECIFIC_TRACKER; diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index 26d5a407f..3729e7bfa 100644 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -2179,7 +2179,7 @@ void SpellMgr::LoadEnchantCustomAttr() if (!spellInfo) continue; - // TODO: find a better check + /// @todo: find a better check // Xinef: commented second part, fixes warlock enchants like firestone, spellstone if (!spellInfo->HasAttribute(SPELL_ATTR2_ENCHANT_OWN_ITEM_ONLY)/* || !spellInfo->HasAttribute(SPELL_ATTR0_NOT_SHAPESHIFTED)*/) continue; @@ -3029,7 +3029,7 @@ void SpellMgr::LoadSpellInfoCustomAttributes() spellInfo->Effects[j].ApplyAuraName == SPELL_AURA_PERIODIC_HEALTH_FUNNEL || spellInfo->Effects[j].ApplyAuraName == SPELL_AURA_PERIODIC_DUMMY) continue; - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. default: if (spellInfo->Effects[j].CalcValue() || ((spellInfo->Effects[j].Effect == SPELL_EFFECT_INTERRUPT_CAST || spellInfo->HasAttribute(SPELL_ATTR0_CU_DONT_BREAK_STEALTH)) && !spellInfo->HasAttribute(SPELL_ATTR0_NO_IMMUNITIES))) if (spellInfo->Id != 69649 && spellInfo->Id != 71056 && spellInfo->Id != 71057 && spellInfo->Id != 71058 && spellInfo->Id != 73061 && spellInfo->Id != 73062 && spellInfo->Id != 73063 && spellInfo->Id != 73064) // Sindragosa Frost Breath diff --git a/src/server/game/Spells/SpellMgr.h b/src/server/game/Spells/SpellMgr.h index aa548a4d5..4c18ceecf 100644 --- a/src/server/game/Spells/SpellMgr.h +++ b/src/server/game/Spells/SpellMgr.h @@ -85,7 +85,7 @@ enum SpellFamilyFlag SPELLFAMILYFLAG_DK_DEATH_STRIKE = 0x00000010, SPELLFAMILYFLAG_DK_DEATH_COIL = 0x00002000, - // TODO: Figure out a more accurate name for the following familyflag(s) + /// @todo: Figure out a more accurate name for the following familyflag(s) SPELLFAMILYFLAG_SHAMAN_TOTEM_EFFECTS = 0x04000000, // Seems to be linked to most totems and some totem effects }; diff --git a/src/server/game/Tickets/TicketMgr.h b/src/server/game/Tickets/TicketMgr.h index 6d6957e74..0ed8de16a 100644 --- a/src/server/game/Tickets/TicketMgr.h +++ b/src/server/game/Tickets/TicketMgr.h @@ -172,7 +172,7 @@ private: bool _completed; GMTicketEscalationStatus _escalatedStatus; bool _viewed; - bool _needResponse; // TODO: find out the use of this, and then store it in DB + bool _needResponse; /// @todo: find out the use of this, and then store it in DB bool _needMoreHelp; std::string _response; std::string _chatLog; // No need to store in db, will be refreshed every session client side diff --git a/src/server/game/Warden/WardenWin.cpp b/src/server/game/Warden/WardenWin.cpp index 604192c55..3aea6b795 100644 --- a/src/server/game/Warden/WardenWin.cpp +++ b/src/server/game/Warden/WardenWin.cpp @@ -477,7 +477,7 @@ void WardenWin::HandleData(ByteBuffer& buff) { uint8 result; buff >> result; - // TODO: test it. + /// @todo: test it. if (result == 0x00) { LOG_DEBUG("warden", "TIMING CHECK FAIL result 0x00"); diff --git a/src/server/scripts/Commands/cs_item.cpp b/src/server/scripts/Commands/cs_item.cpp index d3edb1133..0fad10d33 100644 --- a/src/server/scripts/Commands/cs_item.cpp +++ b/src/server/scripts/Commands/cs_item.cpp @@ -159,7 +159,7 @@ public: return true; } - // TODO - move item to other slot + /// @todo - move item to other slot static bool HandleItemMoveCommand(ChatHandler* handler, uint8 srcSlot, uint8 dstSlot) { if (srcSlot == dstSlot) diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index 915f161f3..9944653ca 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -44,7 +44,7 @@ #include "Tokenize.h" #include "WeatherMgr.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +/// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp index fabb6a882..7a4ba7113 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp @@ -229,7 +229,7 @@ public: for (ObjectGuid const& guid : EggList) { // Eggs should be destroyed instead - // @todo: after dynamic spawns + /// @todo: after dynamic spawns if (GameObject* egg = instance->GetGameObject(guid)) { egg->SetPhaseMask(2, true); diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp index b66fe012c..2b90f373e 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp @@ -777,7 +777,7 @@ public: return true; case 16: SendGossipMenuFor(player, 100116, creature->GetGUID()); - // todo: we need to play these 3 emote in sequence, we play only the last one right now. + /// @todo: we need to play these 3 emote in sequence, we play only the last one right now. creature->HandleEmoteCommand(274); creature->HandleEmoteCommand(1); creature->HandleEmoteCommand(397); diff --git a/src/server/scripts/Events/hallows_end.cpp b/src/server/scripts/Events/hallows_end.cpp index d534bc5cf..52a140c07 100644 --- a/src/server/scripts/Events/hallows_end.cpp +++ b/src/server/scripts/Events/hallows_end.cpp @@ -28,7 +28,7 @@ #include "SpellScript.h" #include "TaskScheduler.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp index 7eaf5c633..fc741ea92 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp @@ -251,7 +251,7 @@ public: { drake->AI()->Talk(0); } - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. } case EVENT_THRALL_REPOSITION: { diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp index a7133a2fd..4435715c6 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp @@ -200,7 +200,7 @@ public: break; case EVENT_HADRONOX_MOVE4: me->CastSpell(me, SPELL_WEB_FRONT_DOORS, true); - [[fallthrough]]; // TODO: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. + [[fallthrough]]; /// @todo: Not sure whether the fallthrough was a mistake (forgetting a break) or intended. This should be double-checked. case EVENT_HADRONOX_MOVE1: case EVENT_HADRONOX_MOVE2: case EVENT_HADRONOX_MOVE3: diff --git a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_elder_nadox.cpp b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_elder_nadox.cpp index 8f27998cf..388d9e454 100644 --- a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_elder_nadox.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_elder_nadox.cpp @@ -346,7 +346,7 @@ class spell_ahn_kahet_swarmer_aura : public SpellScript } else if (_targetCount) { - // TODO: move spell id to enum + /// @todo: move spell id to enum caster->CastCustomSpell(SPELL_SWARM, SPELLVALUE_AURA_STACK, _targetCount, caster, true); if (Aura *aur = caster->GetAura(SPELL_SWARM)) { diff --git a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_prince_taldaram.cpp b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_prince_taldaram.cpp index ecd605097..bfb1907ad 100644 --- a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_prince_taldaram.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/boss_prince_taldaram.cpp @@ -131,7 +131,7 @@ struct npc_taldaram_flamesphere : public NullCreatureAI DoCastSelf(SPELL_FLAME_SPHERE_SPAWN_EFFECT); DoCastSelf(SPELL_FLAME_SPHERE_VISUAL); - // TODO: replace with DespawnOrUnsummon + /// @todo: replace with DespawnOrUnsummon uiDespawnTimer = 13000; } @@ -490,7 +490,7 @@ private: } }; -// TODO: Turn into new script type when Gossips have been updated +// @todo: Turn into new script type when Gossips have been updated class go_prince_taldaram_sphere : public GameObjectScript { public: diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp index ec1c23b89..209471d74 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp @@ -1305,7 +1305,7 @@ public: if (Creature* acolyte = me->SummonCreature((isCalledBySartharion ? NPC_ACOLYTE_OF_SHADRON : NPC_DISCIPLE_OF_SHADRON), me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation())) { - // TODO: inpect JustSummoned + /// @todo: inpect JustSummoned summons.Summon(acolyte); acolyte->SetPhaseMask(16, true); } diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp index 1977fef62..8889b14a5 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp @@ -141,7 +141,7 @@ public: n2->GetMotionMaster()->MovePoint(1, NecrolytePos2); n2->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_READY1H); } - // TODO This spell check is invalid + /// @todo This spell check is invalid // if (SPELL_NECROLYTE_CHANNELING) // { n1->RemoveAura(SPELL_NECROLYTE_CHANNELING); @@ -410,7 +410,7 @@ public: { isInvincible = true; - // TODO This spell check is invalid + /// @todo This spell check is invalid // if (SPELL_NECROLYTE_CHANNELING) me->CastSpell(me, SPELL_NECROLYTE_CHANNELING, false); @@ -434,7 +434,7 @@ public: void EnterCombat(Unit* /*who*/) override { - // TODO This spell check is invalid + /// @todo This spell check is invalid // if (SPELL_NECROLYTE_CHANNELING) me->RemoveAura(SPELL_NECROLYTE_CHANNELING); events.Reset(); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp index 032ca2ff9..5792b4f48 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp @@ -63,7 +63,7 @@ enum ScriptTexts SAY_INTRO_ALLIANCE_1 = 0, SAY_INTRO_ALLIANCE_4 = 1, SAY_INTRO_ALLIANCE_5 = 2, - SAY_OUTRO_ALLIANCE_1 = 3, // TODO ALLIANCE OUTRO + SAY_OUTRO_ALLIANCE_1 = 3, /// @todo ALLIANCE OUTRO SAY_OUTRO_ALLIANCE_2 = 4, SAY_OUTRO_ALLIANCE_3 = 5, SAY_OUTRO_ALLIANCE_4 = 6, diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h index 0491867a1..61e1e6c82 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h @@ -20,7 +20,7 @@ #include "OutdoorPvP.h" -// TODO: "sometimes" set to neutral +// @todo: "sometimes" set to neutral enum OutdoorPvPNASpells { diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h index 6f78824f4..73f987b4d 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h @@ -259,5 +259,5 @@ private: uint32 m_HordeTowersControlled; }; -// todo: flag carrier death/leave/mount/activitychange should give back the gossip options +// @todo: flag carrier death/leave/mount/activitychange should give back the gossip options #endif diff --git a/src/server/scripts/Outland/zone_blades_edge_mountains.cpp b/src/server/scripts/Outland/zone_blades_edge_mountains.cpp index 84b495ff8..98e96bdce 100644 --- a/src/server/scripts/Outland/zone_blades_edge_mountains.cpp +++ b/src/server/scripts/Outland/zone_blades_edge_mountains.cpp @@ -39,7 +39,7 @@ EndContentData */ #include "SpellInfo.h" #include "SpellScript.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/scripts/Pet/pet_dk.cpp b/src/server/scripts/Pet/pet_dk.cpp index a47484d71..c5a34ffa5 100644 --- a/src/server/scripts/Pet/pet_dk.cpp +++ b/src/server/scripts/Pet/pet_dk.cpp @@ -30,7 +30,7 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index 36e32aca6..a0f3939e9 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -861,7 +861,7 @@ class spell_dk_anti_magic_shell_raid : public AuraScript void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/) { - // TODO: this should absorb limited amount of damage, but no info on calculation formula + /// @todo: this should absorb limited amount of damage, but no info on calculation formula amount = -1; } diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp index 04e116289..13c1df6dd 100644 --- a/src/server/scripts/Spells/spell_generic.cpp +++ b/src/server/scripts/Spells/spell_generic.cpp @@ -43,7 +43,7 @@ #include "Vehicle.h" #include -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/scripts/Spells/spell_hunter.cpp b/src/server/scripts/Spells/spell_hunter.cpp index 361785e6e..1d95d5b24 100644 --- a/src/server/scripts/Spells/spell_hunter.cpp +++ b/src/server/scripts/Spells/spell_hunter.cpp @@ -31,7 +31,7 @@ #include "SpellMgr.h" #include "SpellScript.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 @@ -463,7 +463,7 @@ class spell_hun_chimera_shot : public SpellScript // Amount of one aura tick basePoint = int32(CalculatePct(unitTarget->GetMaxPower(POWER_MANA), aurEff->GetAmount())); - int32 casterBasePoint = aurEff->GetAmount() * unitTarget->GetMaxPower(POWER_MANA) / 50; // TODO: Caster uses unitTarget? + int32 casterBasePoint = aurEff->GetAmount() * unitTarget->GetMaxPower(POWER_MANA) / 50; /// @todo: Caster uses unitTarget? if (basePoint > casterBasePoint) basePoint = casterBasePoint; ApplyPct(basePoint, TickCount * 60); diff --git a/src/server/scripts/Spells/spell_mage.cpp b/src/server/scripts/Spells/spell_mage.cpp index 04356827a..88c57a623 100644 --- a/src/server/scripts/Spells/spell_mage.cpp +++ b/src/server/scripts/Spells/spell_mage.cpp @@ -591,7 +591,7 @@ class spell_mage_ice_barrier_aura : public spell_mage_incanters_absorbtion_base_ { PrepareAuraScript(spell_mage_ice_barrier_aura); - // TODO: Rework + /// @todo: Rework static int32 CalculateSpellAmount(Unit* caster, int32 amount, SpellInfo const* spellInfo, const AuraEffect* aurEff) { // +80.68% from sp bonus @@ -627,7 +627,7 @@ class spell_mage_ice_barrier : public SpellScript { PrepareSpellScript(spell_mage_ice_barrier); - // TODO: Rework + /// @todo: Rework static int32 CalculateSpellAmount(Unit* caster, int32 amount, SpellInfo const* spellInfo, const AuraEffect* aurEff) { // +80.68% from sp bonus diff --git a/src/server/scripts/World/areatrigger_scripts.cpp b/src/server/scripts/World/areatrigger_scripts.cpp index 3de188d33..9b8fdf62e 100644 --- a/src/server/scripts/World/areatrigger_scripts.cpp +++ b/src/server/scripts/World/areatrigger_scripts.cpp @@ -329,7 +329,7 @@ public: enum SentryPoint { - SPELL_TELEPORT_VISUAL = 799, // TODO Find the correct spell + SPELL_TELEPORT_VISUAL = 799, /// @todo Find the correct spell QUEST_MISSING_DIPLO_PT14 = 1265, NPC_TERVOSH = 4967 }; diff --git a/src/server/scripts/World/npcs_special.cpp b/src/server/scripts/World/npcs_special.cpp index 1a4016690..c64f8d4ce 100644 --- a/src/server/scripts/World/npcs_special.cpp +++ b/src/server/scripts/World/npcs_special.cpp @@ -56,7 +56,7 @@ EndContentData */ #include "WaypointMgr.h" #include "World.h" -// TODO: this import is not necessary for compilation and marked as unused by the IDE +// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue // there is probably some underlying problem with imports which should properly addressed // see: https://github.com/azerothcore/azerothcore-wotlk/issues/9766 diff --git a/src/server/shared/DataStores/DBCEnums.h b/src/server/shared/DataStores/DBCEnums.h index a974d040d..c9ea4a632 100644 --- a/src/server/shared/DataStores/DBCEnums.h +++ b/src/server/shared/DataStores/DBCEnums.h @@ -154,7 +154,7 @@ enum AchievementCriteriaTypes ACHIEVEMENT_CRITERIA_TYPE_LEARN_SPELL = 34, ACHIEVEMENT_CRITERIA_TYPE_HONORABLE_KILL = 35, ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM = 36, - ACHIEVEMENT_CRITERIA_TYPE_WIN_RATED_ARENA = 37, // TODO: the archievements 1162 and 1163 requires a special rating which can't be found in the dbc + ACHIEVEMENT_CRITERIA_TYPE_WIN_RATED_ARENA = 37, /// @todo: the archievements 1162 and 1163 requires a special rating which can't be found in the dbc ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_TEAM_RATING = 38, ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_PERSONAL_RATING = 39, ACHIEVEMENT_CRITERIA_TYPE_LEARN_SKILL_LEVEL = 40, @@ -167,13 +167,13 @@ enum AchievementCriteriaTypes ACHIEVEMENT_CRITERIA_TYPE_GAIN_EXALTED_REPUTATION = 47, ACHIEVEMENT_CRITERIA_TYPE_VISIT_BARBER_SHOP = 48, // note: rewarded as soon as the player payed, not at taking place at the seat ACHIEVEMENT_CRITERIA_TYPE_EQUIP_EPIC_ITEM = 49, - ACHIEVEMENT_CRITERIA_TYPE_ROLL_NEED_ON_LOOT = 50, // TODO: itemlevel is mentioned in text but not present in dbc + ACHIEVEMENT_CRITERIA_TYPE_ROLL_NEED_ON_LOOT = 50, /// @todo: itemlevel is mentioned in text but not present in dbc ACHIEVEMENT_CRITERIA_TYPE_ROLL_GREED_ON_LOOT = 51, ACHIEVEMENT_CRITERIA_TYPE_HK_CLASS = 52, ACHIEVEMENT_CRITERIA_TYPE_HK_RACE = 53, ACHIEVEMENT_CRITERIA_TYPE_DO_EMOTE = 54, ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE = 55, - ACHIEVEMENT_CRITERIA_TYPE_GET_KILLING_BLOWS = 56, // TODO: in some cases map not present, and in some cases need do without die + ACHIEVEMENT_CRITERIA_TYPE_GET_KILLING_BLOWS = 56, /// @todo: in some cases map not present, and in some cases need do without die ACHIEVEMENT_CRITERIA_TYPE_EQUIP_ITEM = 57, ACHIEVEMENT_CRITERIA_TYPE_MONEY_FROM_VENDORS = 59, ACHIEVEMENT_CRITERIA_TYPE_GOLD_SPENT_FOR_TALENTS = 60, @@ -187,11 +187,11 @@ enum AchievementCriteriaTypes ACHIEVEMENT_CRITERIA_TYPE_BE_SPELL_TARGET2 = 69, ACHIEVEMENT_CRITERIA_TYPE_SPECIAL_PVP_KILL = 70, ACHIEVEMENT_CRITERIA_TYPE_FISH_IN_GAMEOBJECT = 72, - ACHIEVEMENT_CRITERIA_TYPE_ON_LOGIN = 74, // TODO: title id is not mentioned in dbc + ACHIEVEMENT_CRITERIA_TYPE_ON_LOGIN = 74, /// @todo: title id is not mentioned in dbc ACHIEVEMENT_CRITERIA_TYPE_LEARN_SKILLLINE_SPELLS = 75, ACHIEVEMENT_CRITERIA_TYPE_WIN_DUEL = 76, ACHIEVEMENT_CRITERIA_TYPE_LOSE_DUEL = 77, - ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE = 78, // TODO: creature type (demon, undead etc.) is not stored in dbc + ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE = 78, /// @todo: creature type (demon, undead etc.) is not stored in dbc ACHIEVEMENT_CRITERIA_TYPE_GOLD_EARNED_BY_AUCTIONS = 80, ACHIEVEMENT_CRITERIA_TYPE_CREATE_AUCTION = 82, ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_AUCTION_BID = 83, @@ -220,7 +220,7 @@ enum AchievementCriteriaTypes ACHIEVEMENT_CRITERIA_TYPE_QUEST_ABANDONED = 107, ACHIEVEMENT_CRITERIA_TYPE_FLIGHT_PATHS_TAKEN = 108, ACHIEVEMENT_CRITERIA_TYPE_LOOT_TYPE = 109, - ACHIEVEMENT_CRITERIA_TYPE_CAST_SPELL2 = 110, // TODO: target entry is missing + ACHIEVEMENT_CRITERIA_TYPE_CAST_SPELL2 = 110, /// @todo: target entry is missing ACHIEVEMENT_CRITERIA_TYPE_LEARN_SKILL_LINE = 112, ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL = 113, ACHIEVEMENT_CRITERIA_TYPE_ACCEPTED_SUMMONINGS = 114, diff --git a/src/server/shared/DataStores/DBCStructure.h b/src/server/shared/DataStores/DBCStructure.h index 669a83e19..025284204 100644 --- a/src/server/shared/DataStores/DBCStructure.h +++ b/src/server/shared/DataStores/DBCStructure.h @@ -74,7 +74,7 @@ struct AchievementCriteriaEntry union { // ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE = 0 - // TODO: also used for player deaths.. + /// @todo: also used for player deaths.. struct { uint32 creatureID; // 3 @@ -286,14 +286,14 @@ struct AchievementCriteriaEntry // ACHIEVEMENT_CRITERIA_TYPE_EXPLORE_AREA = 43 struct { - // TODO: This rank is _NOT_ the index from AreaTable.dbc + /// @todo: This rank is _NOT_ the index from AreaTable.dbc uint32 areaReference; // 3 } explore_area; // ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK = 44 struct { - // TODO: This rank is _NOT_ the index from CharTitles.dbc + /// @todo: This rank is _NOT_ the index from CharTitles.dbc uint32 rank; // 3 } own_rank; @@ -326,7 +326,7 @@ struct AchievementCriteriaEntry } visit_barber; // ACHIEVEMENT_CRITERIA_TYPE_EQUIP_EPIC_ITEM = 49 - // TODO: where is the required itemlevel stored? + /// @todo: where is the required itemlevel stored? struct { uint32 itemSlot; // 3 @@ -361,7 +361,7 @@ struct AchievementCriteriaEntry } hk_race; // ACHIEVEMENT_CRITERIA_TYPE_DO_EMOTE = 54 - // TODO: where is the information about the target stored? + /// @todo: where is the information about the target stored? struct { uint32 emoteID; // 3 enum TextEmotes @@ -412,7 +412,7 @@ struct AchievementCriteriaEntry } use_gameobject; // ACHIEVEMENT_CRITERIA_TYPE_SPECIAL_PVP_KILL = 70 - // TODO: are those special criteria stored in the dbc or do we have to add another sql table? + /// @todo: are those special criteria stored in the dbc or do we have to add another sql table? struct { uint32 unused; // 3 diff --git a/src/test/server/game/Miscellaneous/FormulasTest.cpp b/src/test/server/game/Miscellaneous/FormulasTest.cpp index e420cb18d..3f773b3d8 100644 --- a/src/test/server/game/Miscellaneous/FormulasTest.cpp +++ b/src/test/server/game/Miscellaneous/FormulasTest.cpp @@ -103,6 +103,6 @@ TEST(FormulasTest, Gain) { auto worldMock = new WorldMock(); sWorld.reset((worldMock)); - // TODO: create mocks of Player and Creature + /// @todo: create mocks of Player and Creature // Gain(nullptr, nullptr); } diff --git a/src/tools/mmaps_generator/MapBuilder.cpp b/src/tools/mmaps_generator/MapBuilder.cpp index c2e846396..d991a4d26 100644 --- a/src/tools/mmaps_generator/MapBuilder.cpp +++ b/src/tools/mmaps_generator/MapBuilder.cpp @@ -384,7 +384,7 @@ namespace MMAP return; } - // ToDo: delete the old tile as the user clearly wants to rebuild it + /// @todo: delete the old tile as the user clearly wants to rebuild it TileBuilder tileBuilder = TileBuilder(this, m_skipLiquid, m_bigBaseUnit, m_debugOutput); tileBuilder.buildTile(mapID, tileX, tileY, navMesh); @@ -763,7 +763,7 @@ namespace MMAP delete[] tiles; // set polygons as walkable - // TODO: special flags for DYNAMIC polygons, ie surfaces that can be turned on and off + /// @todo: special flags for DYNAMIC polygons, ie surfaces that can be turned on and off for (int i = 0; i < iv.polyMesh->npolys; ++i) if (iv.polyMesh->areas[i] & RC_WALKABLE_AREA) iv.polyMesh->flags[i] = iv.polyMesh->areas[i]; diff --git a/src/tools/mmaps_generator/MapBuilder.h b/src/tools/mmaps_generator/MapBuilder.h index b4882557e..464b12d19 100644 --- a/src/tools/mmaps_generator/MapBuilder.h +++ b/src/tools/mmaps_generator/MapBuilder.h @@ -104,7 +104,7 @@ namespace MMAP dtNavMeshParams m_navMeshParams; }; - // ToDo: move this to its own file. For now it will stay here to keep the changes to a minimum, especially in the cpp file + /// @todo: move this to its own file. For now it will stay here to keep the changes to a minimum, especially in the cpp file class MapBuilder; class TileBuilder { diff --git a/src/tools/vmap4_extractor/dbcfile.h b/src/tools/vmap4_extractor/dbcfile.h index 5b7d5d882..593a85b96 100644 --- a/src/tools/vmap4_extractor/dbcfile.h +++ b/src/tools/vmap4_extractor/dbcfile.h @@ -31,7 +31,7 @@ public: // Open database. It must be openened before it can be used. bool open(); - // TODO: Add a close function? + /// @todo: Add a close function? // Database exceptions class Exception diff --git a/src/tools/vmap4_extractor/gameobject_extract.cpp b/src/tools/vmap4_extractor/gameobject_extract.cpp index 398376078..0bcc9c2da 100644 --- a/src/tools/vmap4_extractor/gameobject_extract.cpp +++ b/src/tools/vmap4_extractor/gameobject_extract.cpp @@ -107,7 +107,7 @@ void ExtractGameobjectModels() } else if (!strcmp(ch_ext, ".mdl")) { - // TODO: extract .mdl files, if needed + /// @todo: extract .mdl files, if needed continue; } else //if (!strcmp(ch_ext, ".mdx") || !strcmp(ch_ext, ".m2")) diff --git a/src/tools/vmap4_extractor/wmo.cpp b/src/tools/vmap4_extractor/wmo.cpp index e208ff2fa..0f303d0a4 100644 --- a/src/tools/vmap4_extractor/wmo.cpp +++ b/src/tools/vmap4_extractor/wmo.cpp @@ -472,7 +472,7 @@ int WMOGroup::ConvertToVMAPGroupWmo(FILE* output, bool preciseVectorData) // only need height values, the other values are unknown anyway for (uint32 i = 0; i < LiquEx_size / sizeof(WMOLiquidVert); ++i) fwrite(&LiquEx[i].height, sizeof(float), 1, output); - // todo: compress to bit field + /// @todo: compress to bit field fwrite(LiquBytes, 1, hlq->xtiles * hlq->ytiles, output); } } From c3c10aa160ba4edf0aca0374b2ee42cb9db6f39d Mon Sep 17 00:00:00 2001 From: Gultask <100873791+Gultask@users.noreply.github.com> Date: Sun, 12 Feb 2023 10:06:17 -0300 Subject: [PATCH 56/87] fix(DB/SAI): Add OOC lines to Tempest-Forge Peacekeeper (#14975) --- .../updates/pending_db_world/rev_1676204879733696800.sql | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676204879733696800.sql diff --git a/data/sql/updates/pending_db_world/rev_1676204879733696800.sql b/data/sql/updates/pending_db_world/rev_1676204879733696800.sql new file mode 100644 index 000000000..5950fcbe0 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676204879733696800.sql @@ -0,0 +1,9 @@ +-- +DELETE FROM `creature_text` WHERE `CreatureID`=18405; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES +(18405, 0, 0, 'Protect the Botanica at all costs!', 14, 100, 0, 16784, 'Tempest-Forge Peacekeeper'), +(18405, 0, 1, 'Any intruders must be eliminated!', 14, 100, 0, 16785, 'Tempest-Forge Peacekeeper'); + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = -147039) AND (`source_type` = 0) AND (`id` IN (1003)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-147039, 0, 1003, 0, 1, 0, 100, 0, 450000, 600000, 450000, 600000, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Tempest-Forge Peacekeeper - Out of Combat - Say Line 0'); From 7e07a31f2663c9a7de6c95aff2e85d45d4aa2aaa Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 13:10:24 +0000 Subject: [PATCH 57/87] chore(DB): import pending files Referenced commit(s): c3c10aa160ba4edf0aca0374b2ee42cb9db6f39d --- .../rev_1676204879733696800.sql => db_world/2023_02_12_04.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1676204879733696800.sql => db_world/2023_02_12_04.sql} (96%) diff --git a/data/sql/updates/pending_db_world/rev_1676204879733696800.sql b/data/sql/updates/db_world/2023_02_12_04.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1676204879733696800.sql rename to data/sql/updates/db_world/2023_02_12_04.sql index 5950fcbe0..b3d225094 100644 --- a/data/sql/updates/pending_db_world/rev_1676204879733696800.sql +++ b/data/sql/updates/db_world/2023_02_12_04.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_03 -> 2023_02_12_04 -- DELETE FROM `creature_text` WHERE `CreatureID`=18405; INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Probability`, `Emote`, `BroadcastTextId`, `comment`) VALUES From 3d9a55996d9b42c676db924254e608fc3f2e5cc8 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 14:14:15 +0100 Subject: [PATCH 58/87] fix(Scripts/GruulsLair): Fixed Ground Slam. (#14780) Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com> --- .../rev_1674905348348106300.sql | 8 + .../scripts/Outland/GruulsLair/boss_gruul.cpp | 415 ++++++++++-------- 2 files changed, 230 insertions(+), 193 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1674905348348106300.sql diff --git a/data/sql/updates/pending_db_world/rev_1674905348348106300.sql b/data/sql/updates/pending_db_world/rev_1674905348348106300.sql new file mode 100644 index 000000000..3269953f1 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1674905348348106300.sql @@ -0,0 +1,8 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id`=33496; +INSERT INTO `spell_script_names` VALUES +(33496,'spell_tractor_beam_creator'); + +UPDATE `spell_dbc` SET `Effect_1`=28, `EffectMiscValueB_1`=64 WHERE `ID` IN (33495,33514,33515,33516,33517,33518,33519,33520); + +UPDATE `creature_template` SET `ScriptName`='npc_invisible_tractor_beam_source' WHERE `entry`=19198; diff --git a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp index f9c387a64..9458e8bde 100644 --- a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp +++ b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp @@ -19,6 +19,7 @@ #include "ScriptedCreature.h" #include "SpellScript.h" #include "gruuls_lair.h" +#include "PassiveAI.h" enum Yells { @@ -33,15 +34,28 @@ enum Yells enum Spells { - SPELL_GROWTH = 36300, - SPELL_CAVE_IN = 36240, - SPELL_GROUND_SLAM = 33525, - SPELL_REVERBERATION = 36297, - SPELL_HURTFUL_STRIKE = 33813, - SPELL_SHATTER = 33654, + SPELL_GROWTH = 36300, + SPELL_CAVE_IN = 36240, + SPELL_GROUND_SLAM = 33525, + SPELL_REVERBERATION = 36297, + SPELL_HURTFUL_STRIKE = 33813, + SPELL_SHATTER = 33654, + SPELL_LOOK_AROUND = 33965, - SPELL_SHATTER_EFFECT = 33671, - SPELL_STONED = 33652, + // Ground Slam spells + SPELL_SUMMON_TRACTOR_BEAM_CREATOR = 33496, + SPELL_TRACTOR_BEAM_PULL = 33497, + SPELL_SUMMON_TRACTOR_BEAM_1 = 33495, + SPELL_SUMMON_TRACTOR_BEAM_2 = 33514, + SPELL_SUMMON_TRACTOR_BEAM_3 = 33515, + SPELL_SUMMON_TRACTOR_BEAM_4 = 33516, + SPELL_SUMMON_TRACTOR_BEAM_5 = 33517, + SPELL_SUMMON_TRACTOR_BEAM_6 = 33518, + SPELL_SUMMON_TRACTOR_BEAM_7 = 33519, + SPELL_SUMMON_TRACTOR_BEAM_8 = 33520, + + SPELL_SHATTER_EFFECT = 33671, + SPELL_STONED = 33652, }; enum Events @@ -55,241 +69,256 @@ enum Events EVENT_RECENTLY_SPOKEN = 7 }; -class boss_gruul : public CreatureScript +struct boss_gruul : public BossAI { -public: - boss_gruul() : CreatureScript("boss_gruul") { } + boss_gruul(Creature* creature) : BossAI(creature, DATA_GRUUL) { } - struct boss_gruulAI : public BossAI + void Reset() override { - boss_gruulAI(Creature* creature) : BossAI(creature, DATA_GRUUL) { } + _Reset(); + _caveInTimer = 29000; + } - void Reset() override - { - _Reset(); - _caveInTimer = 29000; - } - - void EnterCombat(Unit* /*who*/) override - { - _EnterCombat(); - Talk(SAY_AGGRO); - - events.ScheduleEvent(EVENT_GROWTH, 30000); - events.ScheduleEvent(EVENT_CAVE_IN, _caveInTimer); - events.ScheduleEvent(EVENT_REVERBERATION, 20000); - events.ScheduleEvent(EVENT_HURTFUL_STRIKE, 10000); - events.ScheduleEvent(EVENT_GROUND_SLAM, 35000); - } - - void KilledUnit(Unit* /*who*/) override - { - if (events.GetNextEventTime(EVENT_RECENTLY_SPOKEN) == 0) - { - events.ScheduleEvent(EVENT_RECENTLY_SPOKEN, 5000); - Talk(SAY_SLAY); - } - } - - void JustDied(Unit* /*killer*/) override - { - _JustDied(); - Talk(SAY_DEATH); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_GROWTH: - Talk(EMOTE_GROW); - DoCast(me, SPELL_GROWTH); - events.ScheduleEvent(EVENT_GROWTH, 30000); - break; - case EVENT_CAVE_IN: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - me->CastSpell(target, SPELL_CAVE_IN, false); - if (_caveInTimer >= 4000) - _caveInTimer -= 1500; - events.ScheduleEvent(EVENT_CAVE_IN, _caveInTimer); - break; - case EVENT_REVERBERATION: - me->CastSpell(me, SPELL_REVERBERATION, false); - events.ScheduleEvent(EVENT_REVERBERATION, 22000); - break; - case EVENT_HURTFUL_STRIKE: - if (Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 5.0f)) - { - me->CastSpell(target, SPELL_HURTFUL_STRIKE, false); - } - else - { - me->CastSpell(me->GetVictim(), SPELL_HURTFUL_STRIKE, false); - } - events.ScheduleEvent(EVENT_HURTFUL_STRIKE, 15000); - break; - case EVENT_GROUND_SLAM: - Talk(SAY_SLAM); - me->CastSpell(me, SPELL_GROUND_SLAM, false); - events.DelayEvents(8001); - events.ScheduleEvent(EVENT_GROUND_SLAM, 60000); - events.ScheduleEvent(EVENT_SHATTER, 8000); - me->SetControlled(true, UNIT_STATE_ROOT); - break; - case EVENT_SHATTER: - Talk(SAY_SHATTER); - me->SetControlled(false, UNIT_STATE_ROOT); - me->CastSpell(me, SPELL_SHATTER, false); - break; - } - - if (!me->HasUnitState(UNIT_STATE_ROOT)) - { - DoMeleeAttackIfReady(); - } - } - - private: - uint32 _caveInTimer; - }; - - CreatureAI* GetAI(Creature* creature) const override + void EnterCombat(Unit* /*who*/) override { - return GetGruulsLairAI(creature); + _EnterCombat(); + Talk(SAY_AGGRO); + + events.ScheduleEvent(EVENT_GROWTH, 30000); + events.ScheduleEvent(EVENT_CAVE_IN, _caveInTimer); + events.ScheduleEvent(EVENT_REVERBERATION, 20000); + events.ScheduleEvent(EVENT_HURTFUL_STRIKE, 10000); + events.ScheduleEvent(EVENT_GROUND_SLAM, 35000); + } + + void KilledUnit(Unit* /*who*/) override + { + if (events.GetNextEventTime(EVENT_RECENTLY_SPOKEN) == 0) + { + events.ScheduleEvent(EVENT_RECENTLY_SPOKEN, 5000); + Talk(SAY_SLAY); + } + } + + void JustDied(Unit* /*killer*/) override + { + _JustDied(); + Talk(SAY_DEATH); + } + + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; + + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + + switch (events.ExecuteEvent()) + { + case EVENT_GROWTH: + Talk(EMOTE_GROW); + DoCast(me, SPELL_GROWTH); + events.ScheduleEvent(EVENT_GROWTH, 30000); + break; + case EVENT_CAVE_IN: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) + me->CastSpell(target, SPELL_CAVE_IN, false); + if (_caveInTimer >= 4000) + _caveInTimer -= 1500; + events.ScheduleEvent(EVENT_CAVE_IN, _caveInTimer); + break; + case EVENT_REVERBERATION: + me->CastSpell(me, SPELL_REVERBERATION, false); + events.ScheduleEvent(EVENT_REVERBERATION, 22000); + break; + case EVENT_HURTFUL_STRIKE: + if (Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 5.0f)) + { + me->CastSpell(target, SPELL_HURTFUL_STRIKE, false); + } + else + { + me->CastSpell(me->GetVictim(), SPELL_HURTFUL_STRIKE, false); + } + events.ScheduleEvent(EVENT_HURTFUL_STRIKE, 15000); + break; + case EVENT_GROUND_SLAM: + Talk(SAY_SLAM); + me->CastSpell(me, SPELL_GROUND_SLAM, false); + events.DelayEvents(8001); + events.ScheduleEvent(EVENT_GROUND_SLAM, 60000); + events.ScheduleEvent(EVENT_SHATTER, 8000); + break; + case EVENT_SHATTER: + Talk(SAY_SHATTER); + me->RemoveAurasDueToSpell(SPELL_LOOK_AROUND); + me->CastSpell(me, SPELL_SHATTER, false); + break; + } + + if (!me->HasUnitState(UNIT_STATE_ROOT)) + { + DoMeleeAttackIfReady(); + } + } + +private: + uint32 _caveInTimer; +}; + +struct npc_invisible_tractor_beam_source : public NullCreatureAI +{ + npc_invisible_tractor_beam_source(Creature* creature) : NullCreatureAI(creature) { } + + void IsSummonedBy(WorldObject* summoner) override + { + if (Unit* summonerUnit = summoner->ToUnit()) + { + DoCast(summonerUnit, SPELL_TRACTOR_BEAM_PULL, true); + } } }; -class spell_gruul_ground_slam : public SpellScriptLoader +class spell_gruul_ground_slam : public SpellScript { -public: - spell_gruul_ground_slam() : SpellScriptLoader("spell_gruul_ground_slam") { } + PrepareSpellScript(spell_gruul_ground_slam); - class spell_gruul_ground_slam_SpellScript : public SpellScript + bool Validate(SpellInfo const* /*spellInfo*/) override { - PrepareSpellScript(spell_gruul_ground_slam_SpellScript); + return ValidateSpellInfo({ SPELL_SUMMON_TRACTOR_BEAM_CREATOR }); + } - void HandleScriptEffect(SpellEffIndex /*effIndex*/) - { - if (Unit* target = GetHitUnit()) - target->KnockbackFrom(GetCaster()->GetPositionX(), GetCaster()->GetPositionY(), 15.0f, 15.0f); - } - - void Register() override - { - OnEffectHitTarget += SpellEffectFn(spell_gruul_ground_slam_SpellScript::HandleScriptEffect, EFFECT_1, SPELL_EFFECT_SCRIPT_EFFECT); - } - }; - - SpellScript* GetSpellScript() const override + void ApplyStun() { - return new spell_gruul_ground_slam_SpellScript(); + if (Unit* caster = GetCaster()) + { + caster->CastSpell(caster, SPELL_LOOK_AROUND, true); + } + } + + void HandleScriptEffect(SpellEffIndex /*effIndex*/) + { + if (Unit* target = GetHitUnit()) + { + target->CastSpell(target, SPELL_SUMMON_TRACTOR_BEAM_CREATOR, true); + } + } + + void Register() override + { + AfterCast += SpellCastFn(spell_gruul_ground_slam::ApplyStun); + OnEffectHitTarget += SpellEffectFn(spell_gruul_ground_slam::HandleScriptEffect, EFFECT_1, SPELL_EFFECT_SCRIPT_EFFECT); } }; -class spell_gruul_ground_slam_trigger : public SpellScriptLoader +class spell_tractor_beam_creator : public SpellScript { -public: - spell_gruul_ground_slam_trigger() : SpellScriptLoader("spell_gruul_ground_slam_trigger") { } + PrepareSpellScript(spell_tractor_beam_creator); - class spell_gruul_ground_slam_trigger_AuraScript : public AuraScript + void HandleScriptEffect(SpellEffIndex /*effIndex*/) { - PrepareAuraScript(spell_gruul_ground_slam_trigger_AuraScript); - - void OnApply(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/) + if (Unit* caster = GetCaster()) { - if (GetUnitOwner()->GetAuraCount(GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell) == 5) - GetUnitOwner()->CastSpell(GetUnitOwner(), SPELL_STONED, true); + std::vector tractorBeamSummons = { SPELL_SUMMON_TRACTOR_BEAM_1, SPELL_SUMMON_TRACTOR_BEAM_2, SPELL_SUMMON_TRACTOR_BEAM_3, SPELL_SUMMON_TRACTOR_BEAM_4, + SPELL_SUMMON_TRACTOR_BEAM_5, SPELL_SUMMON_TRACTOR_BEAM_6, SPELL_SUMMON_TRACTOR_BEAM_7, SPELL_SUMMON_TRACTOR_BEAM_8 }; + uint32 randomTractorSpellID = Acore::Containers::SelectRandomContainerElement(tractorBeamSummons); + caster->CastSpell(caster, randomTractorSpellID, true); } + } - void Register() override - { - AfterEffectRemove += AuraEffectRemoveFn(spell_gruul_ground_slam_trigger_AuraScript::OnApply, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL, AURA_EFFECT_HANDLE_REAL); - } - }; - - AuraScript* GetAuraScript() const override + void Register() override { - return new spell_gruul_ground_slam_trigger_AuraScript(); + OnEffectHitTarget += SpellEffectFn(spell_tractor_beam_creator::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); } }; -class spell_gruul_shatter : public SpellScriptLoader +class spell_gruul_ground_slam_trigger : public AuraScript { -public: - spell_gruul_shatter() : SpellScriptLoader("spell_gruul_shatter") { } + PrepareAuraScript(spell_gruul_ground_slam_trigger); - class spell_gruul_shatter_SpellScript : public SpellScript + bool Validate(SpellInfo const* /*spellInfo*/) override { - PrepareSpellScript(spell_gruul_shatter_SpellScript); + return ValidateSpellInfo({ SPELL_STONED }); + } - void HandleScriptEffect(SpellEffIndex /*effIndex*/) - { - if (Unit* target = GetHitUnit()) - { - target->RemoveAurasDueToSpell(SPELL_STONED); - target->CastSpell((Unit*)nullptr, SPELL_SHATTER_EFFECT, true); - } - } - - void Register() override - { - OnEffectHitTarget += SpellEffectFn(spell_gruul_shatter_SpellScript::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); - } - }; - - SpellScript* GetSpellScript() const override + void OnApply(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/) { - return new spell_gruul_shatter_SpellScript(); + if (GetUnitOwner()->GetAuraCount(GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell) == 5) + { + GetUnitOwner()->CastSpell(GetUnitOwner(), SPELL_STONED, true); + } + } + + void Register() override + { + AfterEffectRemove += AuraEffectRemoveFn(spell_gruul_ground_slam_trigger::OnApply, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL, AURA_EFFECT_HANDLE_REAL); } }; -class spell_gruul_shatter_effect : public SpellScriptLoader +class spell_gruul_shatter : public SpellScript { -public: - spell_gruul_shatter_effect() : SpellScriptLoader("spell_gruul_shatter_effect") { } + PrepareSpellScript(spell_gruul_shatter); - class spell_gruul_shatter_effect_SpellScript : public SpellScript + bool Validate(SpellInfo const* /*spellInfo*/) override { - PrepareSpellScript(spell_gruul_shatter_effect_SpellScript); + return ValidateSpellInfo({ SPELL_SHATTER_EFFECT }); + } - void CalculateDamage() + void HandleScriptEffect(SpellEffIndex /*effIndex*/) + { + if (Unit* target = GetHitUnit()) { - if (!GetHitUnit()) - return; + target->RemoveAurasDueToSpell(SPELL_STONED); + target->CastSpell((Unit*)nullptr, SPELL_SHATTER_EFFECT, true); + } + } - float radius = GetSpellInfo()->Effects[EFFECT_0].CalcRadius(GetCaster()); - if (!radius) - return; + void Register() override + { + OnEffectHitTarget += SpellEffectFn(spell_gruul_shatter::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); + } +}; - float distance = GetCaster()->GetDistance2d(GetHitUnit()); - if (distance > 1.0f) - SetHitDamage(int32(GetHitDamage() * ((radius - distance) / radius))); +class spell_gruul_shatter_effect : public SpellScript +{ + PrepareSpellScript(spell_gruul_shatter_effect); + + void CalculateDamage() + { + if (!GetHitUnit()) + { + return; } - void Register() override + float radius = GetSpellInfo()->Effects[EFFECT_0].CalcRadius(GetCaster()); + if (!radius) { - OnHit += SpellHitFn(spell_gruul_shatter_effect_SpellScript::CalculateDamage); + return; } - }; - SpellScript* GetSpellScript() const override + float distance = GetCaster()->GetDistance2d(GetHitUnit()); + if (distance > 1.0f) + { + SetHitDamage(int32(GetHitDamage() * ((radius - distance) / radius))); + } + } + + void Register() override { - return new spell_gruul_shatter_effect_SpellScript(); + OnHit += SpellHitFn(spell_gruul_shatter_effect::CalculateDamage); } }; void AddSC_boss_gruul() { - new boss_gruul(); - new spell_gruul_ground_slam(); - new spell_gruul_ground_slam_trigger(); - new spell_gruul_shatter(); - new spell_gruul_shatter_effect(); + RegisterGruulsLairAI(boss_gruul); + RegisterGruulsLairAI(npc_invisible_tractor_beam_source); + + RegisterSpellScript(spell_gruul_ground_slam); + RegisterSpellScript(spell_tractor_beam_creator); + RegisterSpellScript(spell_gruul_ground_slam_trigger); + RegisterSpellScript(spell_gruul_shatter); + RegisterSpellScript(spell_gruul_shatter_effect); } From d47e02a415ef237a07aff43a9c393301a2bc10cd Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 13:16:49 +0000 Subject: [PATCH 59/87] chore(DB): import pending files Referenced commit(s): 3d9a55996d9b42c676db924254e608fc3f2e5cc8 --- .../rev_1674905348348106300.sql => db_world/2023_02_12_05.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1674905348348106300.sql => db_world/2023_02_12_05.sql} (89%) diff --git a/data/sql/updates/pending_db_world/rev_1674905348348106300.sql b/data/sql/updates/db_world/2023_02_12_05.sql similarity index 89% rename from data/sql/updates/pending_db_world/rev_1674905348348106300.sql rename to data/sql/updates/db_world/2023_02_12_05.sql index 3269953f1..25e6ac2bf 100644 --- a/data/sql/updates/pending_db_world/rev_1674905348348106300.sql +++ b/data/sql/updates/db_world/2023_02_12_05.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_04 -> 2023_02_12_05 -- DELETE FROM `spell_script_names` WHERE `spell_id`=33496; INSERT INTO `spell_script_names` VALUES From 8d76c296b419354355dfc1b75cf64b67c693bee2 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 16:04:28 +0100 Subject: [PATCH 60/87] =?UTF-8?q?fix(DB/SAI):=20Shattered=20Hand=20Sharpsh?= =?UTF-8?q?ooter=20uses=20Viper=20Sting=20=E2=80=A6=20(#14976)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- data/sql/updates/pending_db_world/rev_1676207172928034700.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676207172928034700.sql diff --git a/data/sql/updates/pending_db_world/rev_1676207172928034700.sql b/data/sql/updates/pending_db_world/rev_1676207172928034700.sql new file mode 100644 index 000000000..ecf0fed47 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676207172928034700.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `event_flags`=4 WHERE `entryorguid`=16704 AND `source_type`=0 AND `id`=4; From 44dba5a8ec95edf791feb3587cd7f63997fb75e4 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 16:04:51 +0100 Subject: [PATCH 61/87] fix(DB/SAI): Shattered Hand Assassin. (#14965) --- .../pending_db_world/rev_1676199530062182300.sql | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676199530062182300.sql diff --git a/data/sql/updates/pending_db_world/rev_1676199530062182300.sql b/data/sql/updates/pending_db_world/rev_1676199530062182300.sql new file mode 100644 index 000000000..9b0644cc1 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676199530062182300.sql @@ -0,0 +1,14 @@ +-- +DELETE FROM `smart_scripts` WHERE `entryorguid`=17695 AND `source_type`=0; +INSERT INTO `smart_scripts` VALUES +(17695,0,0,0,63,0,100,0,0,0,0,0,0,11,30991,0,0,0,0,0,1,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Create - Cast Stealth'), +(17695,0,1,0,21,0,100,0,0,0,0,0,0,11,30991,0,0,0,0,0,1,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Reached Home - Cast Stealth'), +(17695,0,2,0,11,0,100,0,0,0,0,0,0,8,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Reset - Set react defensive'), +(17695,0,3,0,4,0,100,0,0,0,0,0,0,8,2,0,0,0,0,0,1,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Aggro - Set react agressive'), +(17695,0,4,0,67,0,100,0,4500,6500,0,0,0,11,30992,0,0,0,0,0,2,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Target Behind - Cast Backstab'), +(17695,0,5,0,0,0,100,0,8000,11000,22000,25000,0,11,36974,0,0,0,0,0,2,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - In Combat - Cast Wound Poison'), +(17695,0,6,0,0,0,100,0,2000,4500,12000,20000,0,11,30981,0,0,0,0,0,2,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - In Combat - Cast Crippling Poison'), +(17695,0,7,0,10,0,100,0,0,15,12000,15000,1,11,30980,0,0,0,0,0,7,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Target Close - Cast Sap'), +(17695,0,8,0,10,0,100,0,0,8,4000,8000,0,11,30986,0,0,0,0,0,7,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Target Close - Cast Cheap Shot'), +(17695,0,9,0,9,0,100,0,0,8,4000,8000,0,11,30986,0,0,0,0,0,7,0,0,0,0,0,0,0,0,'Shattered Hand Assassin - On Target Close - Cast Cheap Shot'), +(17695,0,10,0,6,0,100,512,0,0,0,0,0,45,5,5,0,0,0,0,11,16700,20,1,0,0,0,0,0,'Shattered Hand Assassin - On Death - Set Data'); From 5cc73e1963fa0da495ee84ed151664c485fe134d Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 15:07:10 +0000 Subject: [PATCH 62/87] chore(DB): import pending files Referenced commit(s): 44dba5a8ec95edf791feb3587cd7f63997fb75e4 --- .../rev_1676199530062182300.sql => db_world/2023_02_12_06.sql} | 1 + .../rev_1676207172928034700.sql => db_world/2023_02_12_07.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1676199530062182300.sql => db_world/2023_02_12_06.sql} (97%) rename data/sql/updates/{pending_db_world/rev_1676207172928034700.sql => db_world/2023_02_12_07.sql} (70%) diff --git a/data/sql/updates/pending_db_world/rev_1676199530062182300.sql b/data/sql/updates/db_world/2023_02_12_06.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1676199530062182300.sql rename to data/sql/updates/db_world/2023_02_12_06.sql index 9b0644cc1..bb735f01e 100644 --- a/data/sql/updates/pending_db_world/rev_1676199530062182300.sql +++ b/data/sql/updates/db_world/2023_02_12_06.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_05 -> 2023_02_12_06 -- DELETE FROM `smart_scripts` WHERE `entryorguid`=17695 AND `source_type`=0; INSERT INTO `smart_scripts` VALUES diff --git a/data/sql/updates/pending_db_world/rev_1676207172928034700.sql b/data/sql/updates/db_world/2023_02_12_07.sql similarity index 70% rename from data/sql/updates/pending_db_world/rev_1676207172928034700.sql rename to data/sql/updates/db_world/2023_02_12_07.sql index ecf0fed47..60da84e7c 100644 --- a/data/sql/updates/pending_db_world/rev_1676207172928034700.sql +++ b/data/sql/updates/db_world/2023_02_12_07.sql @@ -1,2 +1,3 @@ +-- DB update 2023_02_12_06 -> 2023_02_12_07 -- UPDATE `smart_scripts` SET `event_flags`=4 WHERE `entryorguid`=16704 AND `source_type`=0 AND `id`=4; From 0dbb8c814c4ab2fbed2f604ee97c4bf6bc93d116 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 15:53:48 -0300 Subject: [PATCH 63/87] refactor(Core/InstanceScript): refactored load and save methods (#14977) Co-authored-by: joschiwald <736792+joschiwald@users.noreply.github.com> --- src/server/game/Instances/InstanceScript.cpp | 84 +++++++++++++-- src/server/game/Instances/InstanceScript.h | 20 ++-- .../BlackrockDepths/blackrock_depths.h | 2 + .../instance_blackrock_depths.cpp | 5 +- .../BlackrockSpire/blackrock_spire.h | 2 + .../instance_blackrock_spire.cpp | 45 +------- .../BlackwingLair/instance_blackwing_lair.cpp | 49 ++------- .../MoltenCore/instance_molten_core.cpp | 54 +--------- .../MoltenCore/molten_core.h | 2 + .../EasternKingdoms/Deadmines/deadmines.h | 1 + .../Deadmines/instance_deadmines.cpp | 1 + .../EasternKingdoms/Gnomeregan/gnomeregan.h | 2 + .../Gnomeregan/instance_gnomeregan.cpp | 25 +---- .../Karazhan/instance_karazhan.cpp | 1 + .../instance_magisters_terrace.cpp | 41 ++----- .../MagistersTerrace/magisters_terrace.h | 1 + .../instance_scarlet_monastery.cpp | 5 +- .../ScarletMonastery/scarletmonastery.h | 2 + .../Scholomance/instance_scholomance.cpp | 25 +---- .../instance_shadowfang_keep.cpp | 31 ++---- .../ShadowfangKeep/shadowfang_keep.h | 1 + .../Stratholme/instance_stratholme.cpp | 48 ++++----- .../EasternKingdoms/Stratholme/stratholme.h | 1 + .../SunkenTemple/instance_sunken_temple.cpp | 36 +++---- .../SunkenTemple/sunken_temple.h | 2 + .../instance_sunwell_plateau.cpp | 44 +------- .../SunwellPlateau/sunwell_plateau.h | 2 + .../Uldaman/instance_uldaman.cpp | 30 ++---- .../scripts/EasternKingdoms/Uldaman/uldaman.h | 2 + .../ZulAman/instance_zulaman.cpp | 1 + .../scripts/EasternKingdoms/ZulAman/zulaman.h | 1 + .../ZulGurub/instance_zulgurub.cpp | 43 +------- .../EasternKingdoms/ZulGurub/zulgurub.h | 2 + .../BlackfathomDeeps/blackfathom_deeps.h | 2 + .../instance_blackfathom_deeps.cpp | 35 +++--- .../CavernsOfTime/BattleForMountHyjal/hyjal.h | 2 + .../BattleForMountHyjal/instance_hyjal.cpp | 47 ++++---- .../culling_of_stratholme.h | 1 + .../instance_culling_of_stratholme.cpp | 1 + .../instance_old_hillsbrad.cpp | 38 ++----- .../EscapeFromDurnholdeKeep/old_hillsbrad.h | 2 + .../instance_the_black_morass.cpp | 39 ++----- .../TheBlackMorass/the_black_morass.h | 2 + .../scripts/Kalimdor/DireMaul/dire_maul.h | 2 + .../Kalimdor/DireMaul/instance_dire_maul.cpp | 32 +++--- .../Kalimdor/Maraudon/instance_maraudon.cpp | 25 +---- .../scripts/Kalimdor/Maraudon/maraudon.h | 2 + .../OnyxiasLair/instance_onyxias_lair.cpp | 45 +------- .../Kalimdor/OnyxiasLair/onyxias_lair.h | 2 + .../RazorfenDowns/instance_razorfen_downs.cpp | 23 ++-- .../Kalimdor/RazorfenDowns/razorfen_downs.h | 2 + .../instance_ruins_of_ahnqiraj.cpp | 44 +------- .../RuinsOfAhnQiraj/ruins_of_ahnqiraj.h | 1 + .../instance_temple_of_ahnqiraj.cpp | 1 + .../TempleOfAhnQiraj/temple_of_ahnqiraj.h | 1 + .../instance_wailing_caverns.cpp | 32 +++--- .../Kalimdor/WailingCaverns/wailing_caverns.h | 2 + .../Kalimdor/ZulFarrak/instance_zulfarrak.cpp | 23 ++-- .../scripts/Kalimdor/ZulFarrak/zulfarrak.h | 2 + .../AzjolNerub/AzjolNerub/azjol_nerub.h | 2 + .../AzjolNerub/instance_azjol_nerub.cpp | 34 +----- .../Northrend/AzjolNerub/ahnkahet/ahnkahet.h | 1 + .../AzjolNerub/ahnkahet/instance_ahnkahet.cpp | 63 ++--------- .../instance_obsidian_sanctum.cpp | 43 +------- .../ObsidianSanctum/obsidian_sanctum.h | 2 + .../RubySanctum/instance_ruby_sanctum.cpp | 59 ++-------- .../RubySanctum/ruby_sanctum.h | 2 + .../instance_trial_of_the_champion.cpp | 6 +- .../trial_of_the_champion.h | 2 + .../instance_trial_of_the_crusader.cpp | 66 +++++------- .../trial_of_the_crusader.h | 2 + .../DraktharonKeep/drak_tharon_keep.h | 2 + .../instance_drak_tharon_keep.cpp | 29 +---- .../FrozenHalls/ForgeOfSouls/forge_of_souls.h | 2 + .../ForgeOfSouls/instance_forge_of_souls.cpp | 42 ++------ .../HallsOfReflection/halls_of_reflection.h | 2 + .../instance_halls_of_reflection.cpp | 42 ++------ .../PitOfSaron/instance_pit_of_saron.cpp | 53 +++------ .../FrozenHalls/PitOfSaron/pit_of_saron.h | 2 + .../scripts/Northrend/Gundrak/gundrak.h | 2 + .../Northrend/Gundrak/instance_gundrak.cpp | 29 +---- .../IcecrownCitadel/icecrown_citadel.h | 2 + .../instance_icecrown_citadel.cpp | 102 ++++++++---------- .../Naxxramas/instance_naxxramas.cpp | 50 +-------- .../scripts/Northrend/Naxxramas/naxxramas.h | 2 + .../Nexus/EyeOfEternity/eye_of_eternity.h | 1 + .../instance_eye_of_eternity.cpp | 58 +++------- .../Northrend/Nexus/Nexus/instance_nexus.cpp | 29 +---- .../scripts/Northrend/Nexus/Nexus/nexus.h | 2 + .../Nexus/Oculus/instance_oculus.cpp | 46 +++----- .../scripts/Northrend/Nexus/Oculus/oculus.h | 2 + .../HallsOfLightning/halls_of_lightning.h | 2 + .../instance_halls_of_lightning.cpp | 51 ++------- .../Ulduar/HallsOfStone/halls_of_stone.h | 2 + .../HallsOfStone/instance_halls_of_stone.cpp | 45 +++----- .../Ulduar/Ulduar/instance_ulduar.cpp | 92 ++++++---------- .../scripts/Northrend/Ulduar/Ulduar/ulduar.h | 2 + .../UtgardeKeep/instance_utgarde_keep.cpp | 46 ++------ .../instance_utgarde_pinnacle.cpp | 44 ++------ .../UtgardePinnacle/utgarde_pinnacle.h | 2 + .../instance_vault_of_archavon.cpp | 45 ++------ .../VaultOfArchavon/vault_of_archavon.h | 2 + .../VioletHold/instance_violet_hold.cpp | 58 +++------- .../Northrend/VioletHold/violet_hold.h | 2 + .../instance_auchenai_crypts.cpp | 5 +- .../ManaTombs/instance_mana_tombs.cpp | 5 +- .../Outland/BlackTemple/black_temple.h | 2 + .../BlackTemple/instance_black_temple.cpp | 44 +------- .../SerpentShrine/instance_serpent_shrine.cpp | 44 +------- .../SerpentShrine/serpent_shrine.h | 2 + .../SlavePens/instance_the_slave_pens.cpp | 3 +- .../scripts/Outland/GruulsLair/gruuls_lair.h | 2 + .../GruulsLair/instance_gruuls_lair.cpp | 44 +------- .../HellfireRamparts/hellfire_ramparts.h | 1 + .../instance_hellfire_ramparts.cpp | 31 +----- .../instance_magtheridons_lair.cpp | 44 +------- .../MagtheridonsLair/magtheridons_lair.h | 2 + .../instance_shattered_halls.cpp | 43 +------- .../TempestKeep/Eye/instance_the_eye.cpp | 54 +--------- .../scripts/Outland/TempestKeep/Eye/the_eye.h | 2 + .../Mechanar/instance_mechanar.cpp | 58 ++-------- .../Outland/TempestKeep/Mechanar/mechanar.h | 2 + .../Outland/TempestKeep/arcatraz/arcatraz.h | 2 + .../arcatraz/instance_arcatraz.cpp | 44 +------- .../botanica/instance_the_botanica.cpp | 52 +-------- .../TempestKeep/botanica/the_botanica.h | 2 + 126 files changed, 677 insertions(+), 2004 deletions(-) diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index 2d6735753..daba9b609 100644 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -134,6 +134,17 @@ void InstanceScript::LoadBossBoundaries(const BossBoundaryData& data) bosses[entry.bossId].boundary.push_back(entry.boundary); } +void InstanceScript::SetHeaders(std::string const& dataHeaders) +{ + for (char header : dataHeaders) + { + if (isalpha(header)) + { + headers.push_back(header); + } + } +} + void InstanceScript::LoadMinionData(const MinionData* data) { while (data->entry) @@ -340,30 +351,89 @@ bool InstanceScript::SetBossState(uint32 id, EncounterState state) return false; } -void InstanceScript::LoadBossState(const char* data) +void InstanceScript::Load(const char* data) { if (!data) + { + OUT_LOAD_INST_DATA_FAIL; return; + } + + OUT_LOAD_INST_DATA(data); std::istringstream loadStream(data); - uint32 buff; + + if (ReadSaveDataHeaders(loadStream)) + { + ReadSaveDataBossStates(loadStream); + ReadSaveDataMore(loadStream); + } + else + OUT_LOAD_INST_DATA_FAIL; + + OUT_LOAD_INST_DATA_COMPLETE; +} + +bool InstanceScript::ReadSaveDataHeaders(std::istringstream& data) +{ + for (char header : headers) + { + char buff; + data >> buff; + + if (header != buff) + return false; + } + + return true; +} + +void InstanceScript::ReadSaveDataBossStates(std::istringstream& data) +{ uint32 bossId = 0; for (std::vector::iterator i = bosses.begin(); i != bosses.end(); ++i, ++bossId) { - loadStream >> buff; + uint32 buff; + data >> buff; + if (buff == IN_PROGRESS || buff == FAIL || buff == SPECIAL) + buff = NOT_STARTED; + if (buff < TO_BE_DECIDED) - SetBossState(bossId, (EncounterState)buff); + SetBossState(bossId, EncounterState(buff)); } } -std::string InstanceScript::GetBossSaveData() +std::string InstanceScript::GetSaveData() { + OUT_SAVE_INST_DATA; + std::ostringstream saveStream; - for (std::vector::iterator i = bosses.begin(); i != bosses.end(); ++i) - saveStream << (uint32)i->state << ' '; + + WriteSaveDataHeaders(saveStream); + WriteSaveDataBossStates(saveStream); + WriteSaveDataMore(saveStream); + + OUT_SAVE_INST_DATA_COMPLETE; + return saveStream.str(); } +void InstanceScript::WriteSaveDataHeaders(std::ostringstream& data) +{ + for (char header : headers) + { + data << header << ' '; + } +} + +void InstanceScript::WriteSaveDataBossStates(std::ostringstream& data) +{ + for (BossInfo const& bossInfo : bosses) + { + data << uint32(bossInfo.state) << ' '; + } +} + void InstanceScript::DoUseDoorOrButton(ObjectGuid uiGuid, uint32 uiWithRestoreTime, bool bUseAlternativeState) { if (!uiGuid) diff --git a/src/server/game/Instances/InstanceScript.h b/src/server/game/Instances/InstanceScript.h index f294bf2a3..92c98110d 100644 --- a/src/server/game/Instances/InstanceScript.h +++ b/src/server/game/Instances/InstanceScript.h @@ -148,14 +148,14 @@ public: //On creation, NOT load. virtual void Initialize() {} - //On load - virtual void Load(char const* data) { LoadBossState(data); } + // On load + virtual void Load(char const* data); //Called when creature is Looted virtual void CreatureLooted(Creature* /*creature*/, LootType) {} - //When save is needed, this function generates the data - virtual std::string GetSaveData() { return GetBossSaveData(); } + // When save is needed, this function generates the data + virtual std::string GetSaveData(); void SaveToDB(); @@ -255,6 +255,7 @@ public: // Allows to perform particular actions virtual void DoAction(int32 /*action*/) {} protected: + void SetHeaders(std::string const& dataHeaders); void SetBossNumber(uint32 number) { bosses.resize(number); } void LoadBossBoundaries(BossBoundaryData const& data); void LoadDoorData(DoorData const* data); @@ -271,11 +272,18 @@ protected: void UpdateDoorState(GameObject* door); void UpdateMinionState(Creature* minion, EncounterState state); - void LoadBossState(char const* data); - std::string GetBossSaveData(); + // Instance Load and Save + bool ReadSaveDataHeaders(std::istringstream& data); + void ReadSaveDataBossStates(std::istringstream& data); + virtual void ReadSaveDataMore(std::istringstream& /*data*/) { } + void WriteSaveDataHeaders(std::ostringstream& data); + void WriteSaveDataBossStates(std::ostringstream& data); + virtual void WriteSaveDataMore(std::ostringstream& /*data*/) { } + private: static void LoadObjectData(ObjectData const* creatureData, ObjectInfoMap& objectInfo); + std::vector headers; std::vector bosses; DoorInfoMap doors; MinionInfoMap minions; diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h index 67fe9be83..0ba8145c3 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h @@ -19,6 +19,8 @@ #define DEF_BRD_H #include "CreatureAIImpl.h" + +#define DataHeader "BRD" #define BRDScriptName "instance_blackrock_depths" enum FactionIds diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp index 4470a091b..6d706d99a 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp @@ -107,7 +107,10 @@ public: struct instance_blackrock_depths_InstanceMapScript : public InstanceScript { - instance_blackrock_depths_InstanceMapScript(Map* map) : InstanceScript(map) { } + instance_blackrock_depths_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + } uint32 encounter[MAX_ENCOUNTER]; std::string str_data; diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h index 0d5060e9c..fa9446d06 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h @@ -22,6 +22,8 @@ uint32 const EncounterCount = 23; +#define DataHeader "BRS" + #define BRSScriptName "instance_blackrock_spire" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp index 701cf4e49..eb6ef3ddb 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp @@ -85,6 +85,7 @@ public: instance_blackrock_spireMapScript(InstanceMap* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(EncounterCount); LoadMinionData(minionData); LoadDoorData(doorData); @@ -672,50 +673,6 @@ public: } } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B S " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* strIn) override - { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'B' && dataHead2 == 'S') - { - for (uint8 i = 0; i < EncounterCount; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: EventMap Events; ObjectGuid HighlordOmokk; diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp index 7a4ba7113..4aec41e16 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp @@ -78,7 +78,7 @@ public: { instance_blackwing_lair_InstanceMapScript(Map* map) : InstanceScript(map) { - //SetHeaders(DataHeader); + SetHeaders(DataHeader); SetBossNumber(EncounterCount); LoadDoorData(doorData); LoadObjectData(creatureData, objectData); @@ -432,52 +432,15 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B W L " << GetBossSaveData() << NefarianLeftTunnel << ' ' << NefarianRightTunnel; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> NefarianLeftTunnel; + data >> NefarianRightTunnel; } - void Load(char const* data) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!data) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(data); - - char dataHead1, dataHead2, dataHead3; - - std::istringstream loadStream(data); - loadStream >> dataHead1 >> dataHead2 >> dataHead3; - - if (dataHead1 == 'B' && dataHead2 == 'W' && dataHead3 == 'L') - { - for (uint32 i = 0; i < EncounterCount; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState == FAIL || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - - loadStream >> NefarianLeftTunnel; - loadStream >> NefarianRightTunnel; - } - else - { - OUT_LOAD_INST_DATA_FAIL; - } - - OUT_LOAD_INST_DATA_COMPLETE; + data << NefarianLeftTunnel << ' ' << NefarianRightTunnel; } protected: diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp index 6465de471..f97f3661a 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp @@ -62,6 +62,7 @@ public: { instance_molten_core_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); LoadMinionData(minionData); } @@ -404,59 +405,6 @@ public: return true; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "M C " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* data) override - { - if (!data) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(data); - - char dataHead1, dataHead2; - - std::istringstream loadStream(data); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'M' && dataHead2 == 'C') - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > TO_BE_DECIDED) - { - tmpState = NOT_STARTED; - } - - SetBossState(i, static_cast(tmpState)); - } - - if (CheckMajordomoExecutus()) - { - SummonMajordomoExecutus(); - } - } - else - { - OUT_LOAD_INST_DATA_FAIL; - } - - OUT_LOAD_INST_DATA_COMPLETE; - } - private: std::unordered_map _circlesGUIDs; std::unordered_map _runesGUIDs; diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h index 807cc6c72..aad474bef 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "Object.h" +#define DataHeader "MC" + constexpr auto MCScriptName = "instance_molten_core"; constexpr uint32 MAX_ENCOUNTER = 10; diff --git a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h index 3694c5993..6ff733ad8 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h +++ b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h @@ -20,6 +20,7 @@ #include "CreatureAIImpl.h" +#define DataHeader "DM" #define DeadminesScriptName "instance_deadmines" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp b/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp index 430ea08db..0d92d33a6 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp +++ b/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp @@ -28,6 +28,7 @@ public: { instance_deadmines_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); } void Initialize() override diff --git a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h index 02d916f58..375f759e6 100644 --- a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h +++ b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "GNO" + #define GnomereganScriptName "instance_gnomeregan" template diff --git a/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp b/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp index 26767b10a..a67da8176 100644 --- a/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp +++ b/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp @@ -36,6 +36,7 @@ public: { instance_gnomeregan_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); } void OnCreatureCreate(Creature* creature) override @@ -77,30 +78,14 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "D E " << _encounters[0]; - return saveStream.str(); + data >> _encounters[TYPE_GRUBBIS]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'D' && dataHead2 == 'E') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[TYPE_GRUBBIS]; } private: diff --git a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp index 2d116dc85..e6d6115e7 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp @@ -46,6 +46,7 @@ public: { instance_karazhan_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(EncounterCount); // 1 - OZ, 2 - HOOD, 3 - RAJ, this never gets altered. diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp index 26e547c90..7f812f34c 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp @@ -26,7 +26,10 @@ public: struct instance_magisters_terrace_InstanceMapScript : public InstanceScript { - instance_magisters_terrace_InstanceMapScript(Map* map) : InstanceScript(map) { } + instance_magisters_terrace_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + } uint32 Encounter[MAX_ENCOUNTER]; @@ -150,39 +153,17 @@ public: } } - std::string GetSaveData() override + // @todo: Use BossStates. This is for code compatibility + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << Encounter[0] << ' ' << Encounter[1] << ' ' << Encounter[2] << ' ' << Encounter[3]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> Encounter[1]; + data >> Encounter[2]; + data >> Encounter[3]; } - void Load(const char* str) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - std::istringstream loadStream(str); - - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetData(i, tmpState); - } - - OUT_LOAD_INST_DATA_COMPLETE; + data << Encounter[0] << ' ' << Encounter[1] << ' ' << Encounter[2] << ' ' << Encounter[3]; } ObjectGuid GetGuidData(uint32 identifier) const override diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h index 0aac2e80e..20bb86b22 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h @@ -23,6 +23,7 @@ #include "Player.h" #include "SpellScript.h" +#define DataHeader "MT" #define MTScriptName "instance_magisters_terrace" enum MTData diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp index 2b90f373e..e3a9318b0 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp @@ -66,7 +66,10 @@ public: struct instance_scarlet_monastery_InstanceMapScript : public InstanceScript { - instance_scarlet_monastery_InstanceMapScript(Map* map) : InstanceScript(map) {} + instance_scarlet_monastery_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + } void OnPlayerEnter(Player* player) override { diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarletmonastery.h b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarletmonastery.h index 286d8f8dc..92db65f7a 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarletmonastery.h +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarletmonastery.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "SM" + #define ScarletMonasteryScriptName "instance_scarlet_monastery" template diff --git a/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp b/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp index 873c49852..c8dd58d23 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp @@ -211,30 +211,15 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "S O " << _kirtonosState << ' ' << _miniBosses; - return saveStream.str(); + data >> _kirtonosState; + data >> _miniBosses; } - void Load(const char* str) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!str) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'S' && dataHead2 == 'O') - { - loadStream >> _kirtonosState; - loadStream >> _miniBosses; - - if (_kirtonosState == IN_PROGRESS) - _kirtonosState = NOT_STARTED; - } + data << _kirtonosState << ' ' << _miniBosses; } protected: diff --git a/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp b/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp index d667691f8..0e4b6ce5e 100644 --- a/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp +++ b/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp @@ -37,7 +37,10 @@ public: struct instance_shadowfang_keep_InstanceMapScript : public InstanceScript { - instance_shadowfang_keep_InstanceMapScript(Map* map) : InstanceScript(map) { } + instance_shadowfang_keep_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + } void Initialize() override { @@ -112,30 +115,16 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "S K " << _encounters[0] << ' ' << _encounters[1] << ' ' << _encounters[2]; - return saveStream.str(); + data >> _encounters[0]; + data >> _encounters[1]; + data >> _encounters[2]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'S' && dataHead2 == 'K') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[0] << ' ' << _encounters[1] << ' ' << _encounters[2]; } private: diff --git a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h index fada11a7a..9d8a9428b 100644 --- a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h +++ b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h @@ -22,6 +22,7 @@ #include "SpellScript.h" #include "CreatureAIImpl.h" +#define DataHeader "SK" #define ShadowfangKeepScriptName "instance_shadowfang_keep" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp b/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp index a6b6d8c72..2de15bdf7 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp @@ -60,6 +60,7 @@ public: { instance_stratholme_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); } void Initialize() override @@ -344,37 +345,36 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "S T " << _baronRunProgress << ' ' << _baronRunTime << ' ' << _zigguratState1 << ' ' << _zigguratState2 << ' ' << _zigguratState3 << ' ' << _slaughterProgress << ' ' << _postboxesOpened; - return saveStream.str(); - } + data >> _baronRunProgress; + data >> _baronRunTime; + data >> _zigguratState1; + data >> _zigguratState2; + data >> _zigguratState3; + data >> _slaughterProgress; + data >> _postboxesOpened; - void Load(const char* in) override - { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'S' && dataHead2 == 'T') + if (_baronRunTime) { - loadStream >> _baronRunProgress; - loadStream >> _baronRunTime; - loadStream >> _zigguratState1; - loadStream >> _zigguratState2; - loadStream >> _zigguratState3; - loadStream >> _slaughterProgress; - loadStream >> _postboxesOpened; + events.ScheduleEvent(EVENT_BARON_TIME, 60000); } - if (_baronRunTime > 0) - events.ScheduleEvent(EVENT_BARON_TIME, 60000); - if (_slaughterProgress > 0 && _slaughterProgress < 4) + { events.ScheduleEvent(EVENT_FORCE_SLAUGHTER_EVENT, 5000); + } + } + + void WriteSaveDataMore(std::ostringstream& data) override + { + data << _baronRunProgress << ' ' + << _baronRunTime << ' ' + << _zigguratState1 << ' ' + << _zigguratState2 << ' ' + << _zigguratState3 << ' ' + << _slaughterProgress << ' ' + << _postboxesOpened; } uint32 GetData(uint32 type) const override diff --git a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h index 16e7fc766..33ea5114e 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h +++ b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h @@ -20,6 +20,7 @@ #include "SpellAuras.h" +#define DataHeader "STR" #define StratholmeScriptName "instance_stratholme" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp b/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp index 3032794d8..dec10234d 100644 --- a/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp +++ b/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp @@ -33,6 +33,7 @@ public: { instance_sunken_temple_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); } void Initialize() override @@ -168,33 +169,22 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "T A " << _encounters[0] << ' ' << _encounters[1] << ' ' << _encounters[2] << ' ' << _statuePhase << ' ' << _defendersKilled; - return saveStream.str(); + data >> _encounters[0]; + data >> _encounters[1]; + data >> _encounters[2]; + data >> _statuePhase; + data >> _defendersKilled; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'T' && dataHead2 == 'A') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - - loadStream >> _statuePhase; - loadStream >> _defendersKilled; - } + data << _encounters[0] << ' ' + << _encounters[1] << ' ' + << _encounters[2] << ' ' + << _statuePhase << ' ' + << _defendersKilled; } private: diff --git a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h index d94c1eee8..a30d47443 100644 --- a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h +++ b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h @@ -18,6 +18,8 @@ #ifndef DEF_SUNKEN_TEMPLE_H #define DEF_SUNKEN_TEMPLE_H +#define DataHeader "STR" + enum DataTypes { DATA_STATUES = 10, diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp index 36f6ad57a..39e4c9f8b 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp @@ -40,6 +40,7 @@ public: { instance_sunwell_plateau_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); } @@ -233,49 +234,6 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "S P " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'S' && dataHead2 == 'P') - { - for (uint32 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: ObjectGuid KalecgosDragonGUID; ObjectGuid SathrovarrGUID; diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h index 4aee9c649..1eb558cb6 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h @@ -24,6 +24,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "SWP" + #define SWPScriptName "instance_sunwell_plateau" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp b/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp index aec0b170e..f1a69a4ef 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp +++ b/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp @@ -43,6 +43,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&_encounters, 0, sizeof(_encounters)); } @@ -101,31 +102,18 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "U D " << _encounters[DATA_IRONAYA_DOORS] << ' ' << _encounters[DATA_STONE_KEEPERS] << ' ' << _encounters[DATA_ARCHAEDAS]; - return saveStream.str(); + data >> _encounters[DATA_IRONAYA_DOORS]; + data >> _encounters[DATA_STONE_KEEPERS]; + data >> _encounters[DATA_ARCHAEDAS]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'U' && dataHead2 == 'D') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[DATA_IRONAYA_DOORS] << ' ' + << _encounters[DATA_STONE_KEEPERS] << ' ' + << _encounters[DATA_ARCHAEDAS]; } void OnCreatureCreate(Creature* creature) override diff --git a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h index a76f0b6a7..13196f6ff 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h +++ b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h @@ -18,6 +18,8 @@ #ifndef DEF_ULDAMAN_H #define DEF_ULDAMAN_H +#define DataHeader "UD" + enum DataTypes { DATA_IRONAYA_DOORS = 0, diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index c54148ddf..e6934009f 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -91,6 +91,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); QuestTimer = 0; diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h index 6c19fdbda..d8a5fdd1c 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h @@ -20,6 +20,7 @@ #include "CreatureAIImpl.h" +#define DataHeader "ZA" #define ZulAmanScriptName "instance_zulaman" enum DataTypes diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp index 2e1af2680..25395d4df 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp @@ -50,6 +50,7 @@ public: { instance_zulgurub_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(EncounterCount); LoadDoorData(doorData); LoadObjectData(creatureData, nullptr); @@ -170,48 +171,6 @@ public: return true; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "Z G " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'Z' && dataHead2 == 'G') - { - for (uint32 i = 0; i < EncounterCount; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } private: // If all High Priest bosses were killed. Ohgan is added too. // Jindo is needed for healfunction. diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h b/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h index 7c88c3fa0..1db3e27a1 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h +++ b/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h @@ -22,6 +22,8 @@ uint32 const EncounterCount = 13; +#define DataHeader "ZG" + #define ZGScriptName "instance_zulgurub" enum DataTypes diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h index c30314752..5fef90f4b 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h @@ -18,6 +18,8 @@ #ifndef BFD_H_ #define BFD_H_ +#define DataHeader "BFD" + enum Data { TYPE_GELIHAST = 0, diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp index 24332165b..c1207cb3a 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp @@ -35,6 +35,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&_encounters, 0, sizeof(_encounters)); _requiredDeaths = 0; } @@ -111,30 +112,24 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "B L " << _encounters[0] << ' ' << _encounters[1] << ' ' << _encounters[2] << ' ' << _encounters[3] << ' ' << _encounters[4] << ' ' << _encounters[5]; - return saveStream.str(); + data >> _encounters[0]; + data >> _encounters[1]; + data >> _encounters[2]; + data >> _encounters[3]; + data >> _encounters[4]; + data >> _encounters[5]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'B' && dataHead2 == 'L') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[0] << ' ' + << _encounters[1] << ' ' + << _encounters[2] << ' ' + << _encounters[3] << ' ' + << _encounters[4] << ' ' + << _encounters[5]; } bool IsFireEventDone() diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h index 13210662c..76987a6c9 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "GridNotifiers.h" +#define DataHeader "HY" + #define HyjalScriptName "instance_hyjal" uint32 const EncounterCount = 5; diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp index fe5ef1f43..0c4dab7ab 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp @@ -55,6 +55,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); m_uiAncientGemGUID.clear(); @@ -257,18 +258,7 @@ public: if (data == DONE) { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' - << m_auiEncounter[3] << ' ' << m_auiEncounter[4] - << ' ' << allianceRetreat << ' ' << hordeRetreat - << ' ' << RaidDamage; - - str_data = saveStream.str(); - SaveToDB(); - OUT_SAVE_INST_DATA_COMPLETE; } } @@ -298,31 +288,32 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - return str_data; + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> m_auiEncounter[3]; + data >> m_auiEncounter[4]; + data >> allianceRetreat; + data >> hordeRetreat; + data >> RaidDamage; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - std::istringstream loadStream(in); - loadStream >> m_auiEncounter[0] >> m_auiEncounter[1] >> m_auiEncounter[2] >> m_auiEncounter[3] >> m_auiEncounter[4] >> allianceRetreat >> hordeRetreat >> RaidDamage; - for (uint8 i = 0; i < EncounterCount; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) // Do not load an encounter as IN_PROGRESS - reset it instead. - m_auiEncounter[i] = NOT_STARTED; - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << m_auiEncounter[3] << ' ' + << m_auiEncounter[4]<< ' ' + << allianceRetreat << ' ' + << hordeRetreat << ' ' + << RaidDamage; } protected: uint32 m_auiEncounter[EncounterCount]; - std::string str_data; GuidList m_uiAncientGemGUID; ObjectGuid RageWinterchill; ObjectGuid Anetheron; diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h index 8e0e0407f..28d7a36dd 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h @@ -20,6 +20,7 @@ #include "CreatureAIImpl.h" +#define DataHeader "CS" #define CullingOfStratholmeScriptName "instance_culling_of_stratholme" enum Data diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp index f0fd316cb..55166324f 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp @@ -38,6 +38,7 @@ public: instance_culling_of_stratholme_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { // Instance + SetHeaders(DataHeader); _crateCount = 0; _showCrateTimer = 0; _guardianTimer = 0; diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp index fc741ea92..d11b888a9 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp @@ -53,6 +53,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); _encounterProgress = 0; _barrelCount = 0; _attemptsCount = 0; @@ -298,42 +299,15 @@ public: instance->LoadGrid(thrallPositions[i].GetPositionX(), thrallPositions[i].GetPositionY()); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "O H " << _encounterProgress << ' ' << _attemptsCount; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> _encounterProgress; + data >> _attemptsCount; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1; - - if (dataHead1 == 'O' && dataHead2 == 'H') - { - _encounterProgress = data0; - _attemptsCount = data1; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << _encounterProgress << ' ' << _attemptsCount; } private: diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h index 39e4ee9be..e7b96c383 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "OH" + #define OldHillsbradScriptName "instance_old_hillsbrad" enum DataIds diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp index 086d08b93..876dc4a7d 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp @@ -53,6 +53,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&encounters, 0, sizeof(encounters)); _currentRift = 0; _shieldPercent = 100; @@ -327,40 +328,18 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B M " << encounters[0] << ' ' << encounters[1] << ' ' << encounters[2]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> encounters[0]; + data >> encounters[1]; + data >> encounters[2]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'B' && dataHead2 == 'M') - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - loadStream >> encounters[i]; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << encounters[0] << ' ' + << encounters[1] << ' ' + << encounters[2] << ' '; } protected: diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h index 73874f7c0..eb6aabd17 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h @@ -22,6 +22,8 @@ #include "PassiveAI.h" #include "SpellScript.h" +#define DataHeader "TBM" + #define TheBlackMorassScriptName "instance_the_black_morass" enum DataTypes diff --git a/src/server/scripts/Kalimdor/DireMaul/dire_maul.h b/src/server/scripts/Kalimdor/DireMaul/dire_maul.h index a1c60c8b5..ef958c22b 100644 --- a/src/server/scripts/Kalimdor/DireMaul/dire_maul.h +++ b/src/server/scripts/Kalimdor/DireMaul/dire_maul.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "DML" + constexpr auto DMScriptName = "instance_dire_maul"; enum DataTypes diff --git a/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp b/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp index 1e33528f9..ab34bc3ff 100644 --- a/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp +++ b/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp @@ -30,6 +30,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); _eastWingProgress = 0; _westWingProgress = 0; _pylonsState = 0; @@ -144,29 +145,22 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "D M " << _eastWingProgress << ' ' << _westWingProgress << ' ' << _pylonsState << ' ' << _northWingProgress << ' ' << _northWingBosses; - return saveStream.str(); + data >> _eastWingProgress; + data >> _westWingProgress; + data >> _pylonsState; + data >> _northWingProgress; + data >> _northWingBosses; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'D' && dataHead2 == 'M') - { - loadStream >> _eastWingProgress; - loadStream >> _westWingProgress; - loadStream >> _pylonsState; - loadStream >> _northWingProgress; - loadStream >> _northWingBosses; - } + data << _eastWingProgress << ' ' + << _westWingProgress << ' ' + << _pylonsState << ' ' + << _northWingProgress << ' ' + << _northWingBosses; } private: diff --git a/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp b/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp index 969854c99..3d8bffce2 100644 --- a/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp @@ -32,6 +32,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&_encounters, 0, sizeof(_encounters)); } @@ -59,30 +60,14 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "M A " << _encounters[0]; - return saveStream.str(); + data >> _encounters[0]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'M' && dataHead2 == 'A') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[0]; } private: diff --git a/src/server/scripts/Kalimdor/Maraudon/maraudon.h b/src/server/scripts/Kalimdor/Maraudon/maraudon.h index 68aff349b..c9fb5c4ac 100644 --- a/src/server/scripts/Kalimdor/Maraudon/maraudon.h +++ b/src/server/scripts/Kalimdor/Maraudon/maraudon.h @@ -18,6 +18,8 @@ #ifndef DEF_MARAUDON_H #define DEF_MARAUDON_H +#define DataHeader "MA" + enum DataTypes { TYPE_NOXXION = 0, diff --git a/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp b/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp index 25af7297d..2410d352c 100644 --- a/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp +++ b/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp @@ -44,6 +44,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); ManyWhelpsCounter = 0; bDeepBreath = true; @@ -93,50 +94,6 @@ public: } } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - std::ostringstream saveStream; - saveStream << "O L " << GetBossSaveData(); - str_data = saveStream.str(); - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; - } - - void Load(const char* in) override - { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint16 data0; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0; - - if (dataHead1 == 'O' && dataHead2 == 'L') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState == FAIL || tmpState > SPECIAL) - { - tmpState = NOT_STARTED; - } - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* /*source*/, Unit const* /*target*/, uint32 /*miscvalue1*/) override { switch(criteria_id) diff --git a/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h b/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h index 7d78bc694..1b987076d 100644 --- a/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h +++ b/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "OL" + #define OnyxiasLairScriptName "instance_onyxias_lair" enum eInstanceData diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp index a22751437..04e8f6ab9 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp @@ -33,6 +33,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); _gongPhase = 0; _firesState = 0; } @@ -70,27 +71,15 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "R D " << _gongPhase << ' ' << _firesState; - return saveStream.str(); + data >> _gongPhase; + data >> _firesState; } - void Load(const char* str) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!str) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'R' && dataHead2 == 'D') - { - loadStream >> _gongPhase; - loadStream >> _firesState; - } + data << _gongPhase << ' ' << _firesState; } private: diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h index 61a9da0b2..259c26d43 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h +++ b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "PassiveAI.h" +#define DataHeader "RFD" + #define RazorfenDownsScriptName "instance_razorfen_downs" enum CreatureIds diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp index fc897bc6a..a1f7e531c 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp @@ -72,6 +72,7 @@ public: { instance_ruins_of_ahnqiraj_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(NUM_ENCOUNTER); LoadObjectData(creatureData, nullptr); _rajaxWaveCounter = 0; @@ -244,49 +245,6 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "R A" << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* data) override - { - if (!data) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(data); - - char dataHead1, dataHead2; - - std::istringstream loadStream(data); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'R' && dataHead2 == 'A') - { - for (uint8 i = 0; i < NUM_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > TO_BE_DECIDED) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - void CallNextRajaxxLeader(bool announce = false) { ++_rajaxWaveCounter; diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h index 91024c36b..3261b5f6a 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h @@ -20,6 +20,7 @@ #include "CreatureAIImpl.h" +#define DataHeader "RA" #define RuinsOfAhnQirajScriptName "instance_ruins_of_ahnqiraj" enum DataTypes diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp index 749a11e43..f18981d13 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp @@ -60,6 +60,7 @@ public: { instance_temple_of_ahnqiraj_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_BOSS_NUMBER); LoadObjectData(creatureData, nullptr); LoadDoorData(doorData); diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h index 2527a960b..916b996cf 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h @@ -20,6 +20,7 @@ #include "CreatureAIImpl.h" +#define DataHeader "AQT" #define TempleOfAhnQirajScriptName "instance_temple_of_ahnqiraj" enum DataTypes diff --git a/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp b/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp index e5d31327d..d9ea29f03 100644 --- a/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp +++ b/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp @@ -91,30 +91,22 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "W C " << _encounters[0] << ' ' << _encounters[1] << ' ' << _encounters[2] << ' ' << _encounters[3] << ' ' << _encounters[4]; - return saveStream.str(); + data >> _encounters[0]; + data >> _encounters[1]; + data >> _encounters[2]; + data >> _encounters[3]; + data >> _encounters[4]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'W' && dataHead2 == 'C') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - loadStream >> _encounters[i]; - if (_encounters[i] == IN_PROGRESS) - _encounters[i] = NOT_STARTED; - } - } + data << _encounters[0] << ' ' + << _encounters[1] << ' ' + << _encounters[2] << ' ' + << _encounters[3] << ' ' + << _encounters[4] << ' '; } private: diff --git a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h index 9683dee87..239e1eea7 100644 --- a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h +++ b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h @@ -18,6 +18,8 @@ #ifndef DEF_WAILING_CAVERNS_H #define DEF_WAILING_CAVERNS_H +#define DataHeader "WC" + #include "CreatureAI.h" enum DataTypes diff --git a/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp b/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp index 877922a82..e7d4f6100 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp +++ b/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp @@ -133,6 +133,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); GahzrillaSummoned = NOT_STARTED; PyramidPhase = 0; @@ -440,27 +441,15 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "Z F " << PyramidPhase << ' ' << GahzrillaSummoned; - return saveStream.str(); + data >> PyramidPhase; + data >> GahzrillaSummoned; } - void Load(const char* str) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!str) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'Z' && dataHead2 == 'F') - { - loadStream >> PyramidPhase; - loadStream >> GahzrillaSummoned; - } + data << PyramidPhase << ' ' << GahzrillaSummoned; } }; }; diff --git a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.h b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.h index bd7ff856e..3202de53e 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.h +++ b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.h @@ -22,6 +22,8 @@ #include "CreatureAIImpl.h" #include "SpellScript.h" +#define DataHeader "ZF" + #define ZFScriptName "instance_zulfarrak" enum ZulFarrakCreatures diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h index 266175f16..2f6c474a3 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h @@ -23,6 +23,8 @@ #include "SpellAuras.h" #include "SpellScript.h" +#define DataHeader "AN" + #define AzjolNerubScriptName "instance_azjol_nerub" enum ANData diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp index 55fa7d7c5..551dbca7f 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp @@ -51,6 +51,7 @@ public: { instance_azjol_nerub_InstanceScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadBossBoundaries(boundaries); LoadDoorData(doorData); @@ -102,39 +103,6 @@ public: break; } } - - bool SetBossState(uint32 id, EncounterState state) override - { - return InstanceScript::SetBossState(id, state); - } - - std::string GetSaveData() override - { - std::ostringstream saveStream; - saveStream << "A N " << GetBossSaveData(); - return saveStream.str(); - } - - void Load(const char* in) override - { - if( !in ) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'A' && dataHead2 == 'N') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/ahnkahet.h b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/ahnkahet.h index 438ab4647..e384d0291 100644 --- a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/ahnkahet.h +++ b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/ahnkahet.h @@ -18,6 +18,7 @@ #ifndef DEF_AHNKAHET_H #define DEF_AHNKAHET_H +#define DataHeader "AK" #define AhnKahetScriptName "instance_ahnkahet" constexpr uint32 MAX_ENCOUNTER = 5; enum AhnkahetData diff --git a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/instance_ahnkahet.cpp b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/instance_ahnkahet.cpp index f26e66845..c7d284979 100644 --- a/src/server/scripts/Northrend/AzjolNerub/ahnkahet/instance_ahnkahet.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/ahnkahet/instance_ahnkahet.cpp @@ -31,6 +31,7 @@ public: { instance_ahnkahet_InstanceScript(Map* pMap) : InstanceScript(pMap), canSaveBossStates(false) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); teldaramSpheres.fill(NOT_STARTED); } @@ -172,62 +173,18 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - // Encounter states - saveStream << "A K " << GetBossSaveData(); - - // Extra data - saveStream << teldaramSpheres[0] << ' ' << teldaramSpheres[1]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* in) override - { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'A' && dataHead2 == 'K') - { - // Encounter states - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - { - tmpState = NOT_STARTED; - } - - SetBossState(i, EncounterState(tmpState)); - } - - // Extra data - loadStream >> teldaramSpheres[0] >> teldaramSpheres[1]; - } - else - { - OUT_LOAD_INST_DATA_FAIL; - return; - } + data >> teldaramSpheres[0]; + data >> teldaramSpheres[1]; canSaveBossStates = true; - OUT_LOAD_INST_DATA_COMPLETE; + } + + void WriteSaveDataMore(std::ostringstream& data) override + { + data << teldaramSpheres[0] << ' ' + << teldaramSpheres[1]; } private: diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp index dcd0ee6a3..401179a6a 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp @@ -41,6 +41,7 @@ public: { instance_obsidian_sanctum_InstanceMapScript(Map* pMap) : InstanceScript(pMap), portalCount(0) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadBossBoundaries(boundaries); } @@ -204,48 +205,6 @@ public: } } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "O S " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* strIn) override - { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'O' && dataHead2 == 'S') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 temp; - loadStream >> temp; - if (temp == IN_PROGRESS) - temp = NOT_STARTED; - - SetBossState(i, static_cast(temp)); - } - } - - OUT_LOAD_INST_DATA_COMPLETE; - } - private: ObjectGuid m_uiSartharionGUID; ObjectGuid m_uiTenebronGUID; diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h index 3142d5934..665d8a417 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "OS" + #define ObsidianSanctumScriptName "instance_obsidian_sanctum" enum Data : uint32 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp index 43b161bbf..126c0caa2 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp @@ -51,6 +51,7 @@ public: { instance_ruby_sanctum_InstanceMapScript(InstanceMap* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadBossBoundaries(boundaries); LoadDoorData(doorData); @@ -183,6 +184,13 @@ public: switch (type) { + case DATA_HALION_INTRO_DONE: + if (state != DONE) + { + SetBossState(DATA_HALION_INTRO1, NOT_STARTED); + SetBossState(DATA_HALION_INTRO2, NOT_STARTED); + } + break; case DATA_SAVIANA_RAGEFIRE: case DATA_BALTHARUS_THE_WARBORN: if (GetBossState(DATA_BALTHARUS_THE_WARBORN) == DONE && GetBossState(DATA_SAVIANA_RAGEFIRE) == DONE) @@ -208,17 +216,6 @@ public: return true; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "R S " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - void FillInitialWorldStates(WorldPacket& data) override { data << uint32(WORLDSTATE_CORPOREALITY_MATERIAL) << uint32(50); @@ -226,46 +223,6 @@ public: data << uint32(WORLDSTATE_CORPOREALITY_TOGGLE) << uint32(0); } - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'R' && dataHead2 == 'S') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - - SetBossState(i, EncounterState(tmpState)); - } - - // Xinef: additional check - if (GetBossState(DATA_HALION_INTRO_DONE) != DONE) - { - SetBossState(DATA_HALION_INTRO1, NOT_STARTED); - SetBossState(DATA_HALION_INTRO2, NOT_STARTED); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: ObjectGuid BaltharusTheWarbornGUID; ObjectGuid XerestraszaGUID; diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h index 7d8809d42..6e6f59b76 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h @@ -27,6 +27,8 @@ #include "Player.h" #include "SpellScript.h" +#define DataHeader "RS" + #define RubySanctumScriptName "instance_ruby_sanctum" enum DataTypes diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp index 792e1a15c..8e54fb614 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp @@ -39,7 +39,11 @@ public: struct instance_trial_of_the_champion_InstanceMapScript : public InstanceScript { - instance_trial_of_the_champion_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { Initialize(); } + instance_trial_of_the_champion_InstanceMapScript(Map* pMap) : InstanceScript(pMap) + { + SetHeaders(DataHeader); + Initialize(); + } bool CLEANED; TeamId TeamIdInInstance; diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h index 5636b1eaf..8d41e0f7e 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h @@ -21,6 +21,8 @@ #include "CombatAI.h" #include "CreatureAIImpl.h" +#define DataHeader "TC" + #define TrialOfTheChampionScriptName "instance_trial_of_the_champion" enum eData diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp index 3058e6810..70dda3ebf 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp @@ -32,7 +32,11 @@ public: struct instance_trial_of_the_crusader_InstanceMapScript : public InstanceScript { - instance_trial_of_the_crusader_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { Initialize(); } + instance_trial_of_the_crusader_InstanceMapScript(Map* pMap) : InstanceScript(pMap) + { + SetHeaders(DataHeader); + Initialize(); + } bool CLEANED; uint32 EncounterStatus; @@ -1589,54 +1593,32 @@ public: events.RescheduleEvent(EVENT_CHECK_PLAYERS, CLEANUP_CHECK_INTERVAL); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - std::ostringstream saveStream; - saveStream << "T C " << InstanceProgress; - if( instance->IsHeroic() ) - saveStream << ' ' << AttemptsLeft << ' ' << (bDedicatedInsanity ? (uint32)1 : (uint32)0) << ' ' << (bNooneDied ? (uint32)1 : (uint32)0); - str_data = saveStream.str(); - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; + data >> InstanceProgress; + + if (instance->IsHeroic()) + { + data >> AttemptsLeft; + uint32 temp = 0; + data >> temp; + bDedicatedInsanity = !!temp; + data >> temp; + bNooneDied = !!temp; + } } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - EncounterStatus = NOT_STARTED; - CLEANED = false; - events.Reset(); - events.RescheduleEvent(EVENT_CHECK_PLAYERS, 0); + data << InstanceProgress; - if( !in ) + if (instance->IsHeroic()) { - OUT_LOAD_INST_DATA_FAIL; - return; + data << ' ' + << AttemptsLeft << ' ' + << (bDedicatedInsanity ? 1 : 0) << ' ' + << (bNooneDied ? 1 : 0); } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint16 data0; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0; - - if( dataHead1 == 'T' && dataHead2 == 'C' ) - { - InstanceProgress = data0; - if( instance->IsHeroic() ) - { - uint32 data1 = 0, data2 = 0, data3 = 0; - loadStream >> data1 >> data2 >> data3; - AttemptsLeft = data1; - bDedicatedInsanity = !!data2; - bNooneDied = !!data3; - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; } bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* /*source*/, Unit const* /*target*/, uint32 /*miscvalue1*/) override diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.h b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.h index 1acb10e7c..320f316e2 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.h +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.h @@ -22,6 +22,8 @@ #include "GridNotifiers.h" #include "SpellAuraEffects.h" +#define DataHeader "TCR" + #define TrialOfTheCrusaderScriptName "instance_trial_of_the_crusader" enum DataTypes diff --git a/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h b/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h index d7abf5be2..43a52b2ec 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h +++ b/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h @@ -22,6 +22,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "DTK" + #define DraktharonKeepScriptName "instance_drak_tharon_keep" enum Data diff --git a/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp b/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp index 83e212d20..0956ff233 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp @@ -37,6 +37,7 @@ public: { instance_drak_tharon_keep_InstanceScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); } @@ -66,34 +67,6 @@ public: break; } } - - std::string GetSaveData() override - { - std::ostringstream saveStream; - saveStream << "D K " << GetBossSaveData(); - return saveStream.str(); - } - - void Load(const char* in) override - { - if( !in ) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'D' && dataHead2 == 'K') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h index 353d4c398..b8b94e438 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "GridNotifiers.h" +#define DataHeader "FOS" + #define ForgeOfSoulsScriptName "instance_forge_of_souls" enum Data diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp index 7a65bde9f..8d7a416f2 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp @@ -40,6 +40,7 @@ public: { instance_forge_of_souls_InstanceScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); LoadBossBoundaries(boundaries); } @@ -200,46 +201,15 @@ public: return false; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "F S " << m_auiEncounter[0] << ' ' << m_auiEncounter[1]; - str_data = saveStream.str(); - - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1; - - if (dataHead1 == 'F' && dataHead2 == 'S') - { - m_auiEncounter[0] = data0; - m_auiEncounter[1] = data1; - - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - } - else OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' << m_auiEncounter[1]; } }; }; diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h index 93fd62c60..9c1d584a3 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h @@ -28,6 +28,8 @@ #include "SpellAuras.h" #include "SpellScript.h" +#define DataHeader "HOR" + #define HallsOfReflectionScriptName "instance_halls_of_reflection" enum Data diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp index 4b3be91d4..41660c3bc 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp @@ -126,7 +126,10 @@ public: struct instance_halls_of_reflection_InstanceMapScript : public InstanceScript { - instance_halls_of_reflection_InstanceMapScript(Map* pMap) : InstanceScript(pMap) {}; + instance_halls_of_reflection_InstanceMapScript(Map* pMap) : InstanceScript(pMap) + { + SetHeaders(DataHeader); + }; uint32 EncounterMask; TeamId TeamIdInInstance; @@ -705,42 +708,15 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "H R " << EncounterMask; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> EncounterMask; + BatteredHiltStatus = (EncounterMask & (1 << DATA_BATTERED_HILT)) ? BHSF_FINISHED : BHSF_NONE; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0; - - if (dataHead1 == 'H' && dataHead2 == 'R') - { - EncounterMask = data0; - BatteredHiltStatus = (EncounterMask & (1 << DATA_BATTERED_HILT)) ? BHSF_FINISHED : BHSF_NONE; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << EncounterMask; } void OnUnitDeath(Unit* unit) override diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp index 9a26bcfe9..fe28bcc4f 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp @@ -27,7 +27,10 @@ public: struct instance_pit_of_saron_InstanceScript : public InstanceScript { - instance_pit_of_saron_InstanceScript(Map* map) : InstanceScript(map) {} + instance_pit_of_saron_InstanceScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + } uint32 m_auiEncounter[MAX_ENCOUNTER]; TeamId teamIdInInstance; @@ -378,48 +381,20 @@ public: return false; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "P S " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << InstanceProgress; - str_data = saveStream.str(); - - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> InstanceProgress; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1, data2, data3; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3; - - if (dataHead1 == 'P' && dataHead2 == 'S') - { - m_auiEncounter[0] = data0; - m_auiEncounter[1] = data1; - m_auiEncounter[2] = data2; - InstanceProgress = data3; - - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - } - else OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << InstanceProgress; } }; diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h index 193d89de7..64f752a24 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h @@ -21,6 +21,8 @@ #include "Chat.h" #include "CreatureAIImpl.h" +#define DataHeader "POS" + #define PitOfSaronScriptName "instance_pit_of_saron" enum DataTypes diff --git a/src/server/scripts/Northrend/Gundrak/gundrak.h b/src/server/scripts/Northrend/Gundrak/gundrak.h index 90b8932a7..ec6da02e0 100644 --- a/src/server/scripts/Northrend/Gundrak/gundrak.h +++ b/src/server/scripts/Northrend/Gundrak/gundrak.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "SpellScript.h" +#define DataHeader "GD" + #define GundrakScriptName "instance_gundrak" enum Data diff --git a/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp b/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp index 73587356b..3859e54aa 100644 --- a/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp +++ b/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp @@ -43,6 +43,7 @@ public: { instance_gundrak_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); } ObjectGuid _sladRanAltarGUID; @@ -197,34 +198,6 @@ public: return true; } - std::string GetSaveData() override - { - std::ostringstream saveStream; - saveStream << "G D " << GetBossSaveData(); - return saveStream.str(); - } - - void Load(const char* in) override - { - if (!in) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - if (dataHead1 == 'G' && dataHead2 == 'D') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - } - void Update(uint32 diff) override { if (!_activateTimer) diff --git a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h index 3e3212f17..73eac4e21 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h +++ b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h @@ -32,6 +32,8 @@ #include "SpellMgr.h" #include "SpellScript.h" +#define DataHeader "IC" + #define ICCScriptName "instance_icecrown_citadel" uint32 const WeeklyNPCs = 9; diff --git a/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp index 829e12173..5415a43b8 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp @@ -197,6 +197,7 @@ public: LichKingRandomWhisperTimer = 120 * IN_MILLISECONDS; DarkwhisperElevatorTimer = 3000; + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadBossBoundaries(boundaries); LoadDoorData(doorData); @@ -1576,73 +1577,54 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; + data >> HeroicAttempts; - std::ostringstream saveStream; - saveStream << "I C " << GetBossSaveData() << HeroicAttempts << ' ' - << ColdflameJetsState << ' ' << BloodQuickeningState << ' ' << BloodQuickeningMinutes << ' ' << WeeklyQuestId10 << ' ' << PutricideEventProgress << ' ' - << uint32(LichKingHeroicAvailable ? 1 : 0) << ' ' << BloodPrinceTrashCount << ' ' << uint32(IsBuffAvailable ? 1 : 0); + uint32 temp = 0; + data >> temp; - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* str) override - { - if (!str) + if (temp == IN_PROGRESS) { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'I' && dataHead2 == 'C') - { - for (uint32 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState == FAIL || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - - loadStream >> HeroicAttempts; - - uint32 temp = 0; - loadStream >> temp; - ColdflameJetsState = temp ? DONE : NOT_STARTED; - - loadStream >> BloodQuickeningState; - loadStream >> BloodQuickeningMinutes; - if (BloodQuickeningState == IN_PROGRESS) - { - Events.ScheduleEvent(EVENT_UPDATE_EXECUTION_TIME, 60000); - DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 1); - DoUpdateWorldState(WORLDSTATE_EXECUTION_TIME, BloodQuickeningMinutes); - } - - loadStream >> WeeklyQuestId10; - loadStream >> PutricideEventProgress; - PutricideEventProgress &= ~PUTRICIDE_EVENT_FLAG_TRAP_INPROGRESS; - loadStream >> temp; - LichKingHeroicAvailable = !!temp; - loadStream >> BloodPrinceTrashCount; - loadStream >> temp; - SetData(DATA_BUFF_AVAILABLE, !!temp); + ColdflameJetsState = NOT_STARTED; } else - OUT_LOAD_INST_DATA_FAIL; + { + ColdflameJetsState = temp ? DONE : NOT_STARTED; + } - OUT_LOAD_INST_DATA_COMPLETE; + data >> temp; + data >> BloodQuickeningState; + data >> BloodQuickeningMinutes; + + if (BloodQuickeningState == IN_PROGRESS) + { + Events.ScheduleEvent(EVENT_UPDATE_EXECUTION_TIME, 60000); + DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 1); + DoUpdateWorldState(WORLDSTATE_EXECUTION_TIME, BloodQuickeningMinutes); + } + + data >> WeeklyQuestId10; + data >> PutricideEventProgress; + PutricideEventProgress &= ~PUTRICIDE_EVENT_FLAG_TRAP_INPROGRESS; + data >> temp; + LichKingHeroicAvailable = !!temp; + data >> BloodPrinceTrashCount; + data >> temp; + SetData(DATA_BUFF_AVAILABLE, !!temp); + } + + void WriteSaveDataMore(std::ostringstream& data) override + { + data << HeroicAttempts << ' ' + << ColdflameJetsState << ' ' + << BloodQuickeningState << ' ' + << BloodQuickeningMinutes << ' ' + << WeeklyQuestId10 << ' ' + << PutricideEventProgress << ' ' + << uint32(LichKingHeroicAvailable ? 1 : 0) << ' ' + << BloodPrinceTrashCount << ' ' + << uint32(IsBuffAvailable ? 1 : 0); } void Update(uint32 diff) override diff --git a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp index fa67832af..638c294c4 100644 --- a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp +++ b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp @@ -64,6 +64,7 @@ public: { explicit instance_naxxramas_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); for (auto& i : HeiganEruption) i.clear(); @@ -1119,55 +1120,14 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "N X X " << GetBossSaveData() << ' ' << immortalAchievement; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> immortalAchievement; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2, dataHead3; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> dataHead3; - - if (dataHead1 == 'N' && dataHead2 == 'X' && dataHead3 == 'X') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS) - { - tmpState = NOT_STARTED; - } - if (i == BOSS_HORSEMAN && tmpState == DONE) - { - _horsemanLoadDoneState = true; - } - SetBossState(i, EncounterState(tmpState)); - } - loadStream >> immortalAchievement; - - OUT_LOAD_INST_DATA_COMPLETE; - } - else - { - OUT_LOAD_INST_DATA_FAIL; - } + data << immortalAchievement; } }; }; diff --git a/src/server/scripts/Northrend/Naxxramas/naxxramas.h b/src/server/scripts/Northrend/Naxxramas/naxxramas.h index ed4425b0d..dcbeb811f 100644 --- a/src/server/scripts/Northrend/Naxxramas/naxxramas.h +++ b/src/server/scripts/Northrend/Naxxramas/naxxramas.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "SpellScript.h" +#define DataHeader "NAX" + #define NaxxramasScriptName "instance_naxxramas" enum Encouters diff --git a/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h b/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h index c9ac5e54e..b61b1d7cb 100644 --- a/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h +++ b/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h @@ -21,6 +21,7 @@ #include "Chat.h" #include "CreatureAIImpl.h" +#define DataHeader "EOE" #define EyeOfEternityScriptName "instance_eye_of_eternity" enum Objects diff --git a/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp b/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp index ed593811c..07023e5cc 100644 --- a/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp +++ b/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp @@ -208,51 +208,27 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - std::ostringstream saveStream; - saveStream << "E E " << EncounterStatus; - str_data = saveStream.str(); - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; + data >> EncounterStatus; + + switch (EncounterStatus) + { + case IN_PROGRESS: + EncounterStatus = NOT_STARTED; + break; + case DONE: + // destroy platform, hide iris + ProcessEvent(nullptr, 20158); + if (GameObject* go = instance->GetGameObject(GO_IrisGUID)) + go->SetPhaseMask(2, true); + break; + } } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if( !in ) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0; - - if( dataHead1 == 'E' && dataHead2 == 'E' ) - { - EncounterStatus = data0; - switch(EncounterStatus) - { - case IN_PROGRESS: - EncounterStatus = NOT_STARTED; - break; - case DONE: - // destroy platform, hide iris - ProcessEvent(nullptr, 20158); - if (GameObject* go = instance->GetGameObject(GO_IrisGUID)) - go->SetPhaseMask(2, true); - break; - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << EncounterStatus; } bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* source, Unit const* /*target*/, uint32 /*miscvalue1*/) override diff --git a/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp b/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp index 8b355d0ef..0f022848f 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp @@ -43,6 +43,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); } @@ -151,34 +152,6 @@ public: (*i)->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); return true; } - - std::string GetSaveData() override - { - std::ostringstream saveStream; - saveStream << "N E X " << GetBossSaveData(); - return saveStream.str(); - } - - void Load(const char* in) override - { - if( !in ) - return; - - char dataHead1, dataHead2, dataHead3; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> dataHead3; - if (dataHead1 == 'N' && dataHead2 == 'E' && dataHead3 == 'X') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - } }; }; diff --git a/src/server/scripts/Northrend/Nexus/Nexus/nexus.h b/src/server/scripts/Northrend/Nexus/Nexus/nexus.h index 2b80fbf74..6186b7a71 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/nexus.h +++ b/src/server/scripts/Northrend/Nexus/Nexus/nexus.h @@ -26,6 +26,8 @@ #include "SpellAuras.h" #include "SpellScript.h" +#define DataHeader "NEX" + #define NexusScriptName "instance_nexus" enum eTypes diff --git a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp index 3c6ad2e2c..3c10df6e5 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp @@ -52,6 +52,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); CentrifugeCount = 0; bAmberVoid = false; bEmeraldVoid = false; @@ -238,43 +239,22 @@ public: return ObjectGuid::Empty; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "T O " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << m_auiEncounter[3] << ' ' << CentrifugeCount; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> m_auiEncounter[3]; + data >> CentrifugeCount; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if( !in ) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2; - - if( dataHead1 == 'T' && dataHead2 == 'O' ) - { - loadStream >> m_auiEncounter[0] >> m_auiEncounter[1] >> m_auiEncounter[2] >> m_auiEncounter[3] >> CentrifugeCount; - - for( uint8 i = 0; i < MAX_ENCOUNTER; ++i ) - if( m_auiEncounter[i] == IN_PROGRESS ) - m_auiEncounter[i] = NOT_STARTED; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << m_auiEncounter[3] << ' ' + << CentrifugeCount; } bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* source, Unit const* /*target*/, uint32 /*miscvalue1*/) override diff --git a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h index 5570d424f..69e5fd5c3 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h +++ b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h @@ -23,6 +23,8 @@ #include "SpellAuras.h" #include "SpellScript.h" +#define DataHeader "OC" + #define OculusScriptName "instance_oculus" Position const VerdisaPOS = { 949.056f, 1032.97f, 359.967f, 1.035795f }; diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h index 4bf633f9b..dac581309 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "HOL" + #define HallsOfLightningScriptName "instance_halls_of_lightning" enum HoLEvents diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp index b79fe2e03..aefa0995a 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp @@ -51,6 +51,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); volkhanAchievement = false; @@ -172,50 +173,20 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "H L " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' - << m_auiEncounter[2] << ' ' << m_auiEncounter[3] << ' ' << m_auiEncounter[4]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> m_auiEncounter[3]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1, data2, data3, data4; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3 >> data4; - - if (dataHead1 == 'H' && dataHead2 == 'L') - { - m_auiEncounter[0] = data0; - m_auiEncounter[1] = data1; - m_auiEncounter[2] = data2; - m_auiEncounter[3] = data3; - m_auiEncounter[4] = data4; - - for (uint8 i = 0; i < TYPE_LOKEN_INTRO; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - - OUT_LOAD_INST_DATA_COMPLETE; - } - else - OUT_LOAD_INST_DATA_FAIL; + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << m_auiEncounter[3] << ' '; } uint32 GetData(uint32 uiType) const override diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h index cd1dc614d..f027fa014 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "HOS" + #define HallsOfStoneScriptName "instance_halls_of_stone" enum Encounter diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp index 9af56f3b2..96f24a0f4 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp @@ -56,6 +56,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&Encounter, 0, sizeof(Encounter)); brannAchievement = false; @@ -242,42 +243,22 @@ public: SaveToDB(); } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "H O S " << Encounter[0] << ' ' << Encounter[1] << ' ' << Encounter[2] << ' ' << Encounter[3] << ' ' << Encounter[4]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> Encounter[0]; + data >> Encounter[1]; + data >> Encounter[2]; + data >> Encounter[3]; + data >> Encounter[4]; } - void Load(const char* strIn) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2, dataHead3; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2 >> dataHead3; - - if (dataHead1 == 'H' && dataHead2 == 'O' && dataHead3 == 'S') - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - { - loadStream >> Encounter[i]; - if( Encounter[i] == IN_PROGRESS ) - Encounter[i] = NOT_STARTED; - } - } - OUT_LOAD_INST_DATA_COMPLETE; + data << Encounter[0] << ' ' + << Encounter[1] << ' ' + << Encounter[2] << ' ' + << Encounter[3] << ' ' + << Encounter[4] << ' '; } }; }; diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp index 39054e7bf..f9acc923d 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp @@ -40,6 +40,7 @@ public: instance_ulduar_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { Initialize(); + SetHeaders(DataHeader); // 0: 10 man difficulty // 1: 25 man difficulty m_difficulty = (pMap->Is25ManRaid() ? 0 : 1); @@ -1056,69 +1057,46 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[3]; + data >> m_auiEncounter[4]; + data >> m_auiEncounter[5]; + data >> m_auiEncounter[6]; + data >> m_auiEncounter[7]; + data >> m_auiEncounter[8]; + data >> m_auiEncounter[9]; + data >> m_auiEncounter[10]; + data >> m_auiEncounter[11]; + data >> m_auiEncounter[12]; + data >> m_auiEncounter[13]; + data >> m_auiEncounter[14]; + data >> m_conspeedatoryAttempt; + data >> m_unbrokenAchievement; + data >> m_algalonTimer; - std::ostringstream saveStream; - saveStream << "U U " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << m_auiEncounter[3] << ' ' - << m_auiEncounter[4] << ' ' << m_auiEncounter[5] << ' ' << m_auiEncounter[6] << ' ' << m_auiEncounter[7] << ' ' - << m_auiEncounter[8] << ' ' << m_auiEncounter[9] << ' ' << m_auiEncounter[10] << ' ' << m_auiEncounter[11] << ' ' - << m_auiEncounter[12] << ' ' << m_auiEncounter[13] << ' ' << m_auiEncounter[14] << ' ' << m_conspeedatoryAttempt << ' ' - << m_unbrokenAchievement << ' ' << m_algalonTimer << ' ' << C_of_Ulduar_MASK << ' ' << m_mageBarrier; + if (m_algalonTimer == TIMER_ALGALON_SUMMONED) + m_algalonTimer = TIMER_ALGALON_TO_SUMMON; - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + if (m_algalonTimer && m_algalonTimer <= 60 && GetData(TYPE_ALGALON) != DONE) + { + DoUpdateWorldState(WORLD_STATE_ALGALON_TIMER_ENABLED, 1); + DoUpdateWorldState(WORLD_STATE_ALGALON_DESPAWN_TIMER, m_algalonTimer); + } + + data >> C_of_Ulduar_MASK; + data >> m_mageBarrier; } - void Load(const char* strIn) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'U' && dataHead2 == 'U') - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - { - loadStream >> m_auiEncounter[i]; - - if (m_auiEncounter[i] == IN_PROGRESS && i != TYPE_WATCHERS) - m_auiEncounter[i] = NOT_STARTED; - } - - // Achievements - loadStream >> m_conspeedatoryAttempt; - loadStream >> m_unbrokenAchievement; - - // Algalon - loadStream >> m_algalonTimer; - if (m_algalonTimer == TIMER_ALGALON_SUMMONED) - m_algalonTimer = TIMER_ALGALON_TO_SUMMON; - - if (m_algalonTimer && m_algalonTimer <= 60 && GetData(TYPE_ALGALON) != DONE) - { - DoUpdateWorldState(WORLD_STATE_ALGALON_TIMER_ENABLED, 1); - DoUpdateWorldState(WORLD_STATE_ALGALON_DESPAWN_TIMER, m_algalonTimer); - } - - // achievement Conqueror/Champion of Ulduar - loadStream >> C_of_Ulduar_MASK; - - //Base Camp - Mage Barrier status - loadStream >> m_mageBarrier; - } - - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << m_auiEncounter[3] << ' ' + << m_auiEncounter[4] << ' ' << m_auiEncounter[5] << ' ' << m_auiEncounter[6] << ' ' << m_auiEncounter[7] << ' ' + << m_auiEncounter[8] << ' ' << m_auiEncounter[9] << ' ' << m_auiEncounter[10] << ' ' << m_auiEncounter[11] << ' ' + << m_auiEncounter[12] << ' ' << m_auiEncounter[13] << ' ' << m_auiEncounter[14] << ' ' << m_conspeedatoryAttempt << ' ' + << m_unbrokenAchievement << ' ' << m_algalonTimer << ' ' << C_of_Ulduar_MASK << ' ' << m_mageBarrier; } void Update(uint32 diff) override diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h b/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h index d42daffc3..186bcde78 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h @@ -24,6 +24,8 @@ #include "GridNotifiers.h" #include "GridNotifiersImpl.h" +#define DataHeader "UU" + #define UlduarScriptName "instance_ulduar" enum UlduarEncounters diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp index a90be6c4f..e034b7ef1 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp @@ -318,49 +318,17 @@ public: return 0; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "U K " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << ForgeEventMask; - - str_data = saveStream.str(); - - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> ForgeEventMask; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1, data2, data3; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3; - - if (dataHead1 == 'U' && dataHead2 == 'K') - { - m_auiEncounter[0] = data0; - m_auiEncounter[1] = data1; - m_auiEncounter[2] = data2; - ForgeEventMask = data3; - - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - } - else OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << ForgeEventMask; } bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* /*source*/, Unit const* /*target*/, uint32 /*miscvalue1*/) override diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp index df43f7ff8..40101acd6 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp @@ -57,6 +57,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); SkadiHits = 0; SkadiInRange = 0; @@ -192,43 +193,20 @@ public: OUT_SAVE_INST_DATA_COMPLETE; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - std::ostringstream saveStream; - saveStream << "U P " << Encounters[0] << ' ' << Encounters[1] << ' ' << Encounters[2] << ' ' << Encounters[3]; - return saveStream.str(); + data >> Encounters[0]; + data >> Encounters[1]; + data >> Encounters[2]; + data >> Encounters[3]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint16 data0, data1, data2, data3; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3; - - if (dataHead1 == 'U' && dataHead2 == 'P') - { - Encounters[0] = data0; - Encounters[1] = data1; - Encounters[2] = data2; - Encounters[3] = data3; - - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - if (Encounters[i] == IN_PROGRESS) - Encounters[i] = NOT_STARTED; - } - else OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << Encounters[0] << ' ' + << Encounters[1] << ' ' + << Encounters[2] << ' ' + << Encounters[3]; } uint32 GetData(uint32 type) const override diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h index d39a95dc1..ce37fa561 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "Opcodes.h" +#define DataHeader "UP" + #define UtgardePinnacleScriptName "instance_utgarde_pinnacle" enum Data diff --git a/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp index 8937a3a61..b3980021b 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp @@ -44,6 +44,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); ArchavonDeath = 0; @@ -230,44 +231,20 @@ public: return false; } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "V O A " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << m_auiEncounter[3]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> m_auiEncounter[3]; } - void Load(const char* in) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2, dataHead3; - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> dataHead3; - - if (dataHead1 == 'V' && dataHead2 == 'O' && dataHead3 == 'A') - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - { - loadStream >> m_auiEncounter[i]; - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - } - - OUT_LOAD_INST_DATA_COMPLETE; - } - else - OUT_LOAD_INST_DATA_FAIL; + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << m_auiEncounter[3]; } private: diff --git a/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h b/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h index bc0646be1..a8e8a047c 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h +++ b/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h @@ -20,6 +20,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "VA" + #define VaultOfArchavonScriptName "instance_vault_of_archavon" enum Creatures diff --git a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp index 644718725..6df100c1f 100644 --- a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp +++ b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp @@ -84,6 +84,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); CLEANED = false; EncounterStatus = NOT_STARTED; @@ -637,57 +638,26 @@ public: return false; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "V H " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << uiFirstBoss << ' ' << uiSecondBoss; - str_data = saveStream.str(); - - OUT_SAVE_INST_DATA_COMPLETE; - return str_data; - } - - void Load(const char* in) override + void ReadSaveDataMore(std::istringstream& data) override { EncounterStatus = NOT_STARTED; CLEANED = false; events.Reset(); events.RescheduleEvent(EVENT_CHECK_PLAYERS, 0); - if (!in) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } + data >> m_auiEncounter[0]; + data >> m_auiEncounter[1]; + data >> m_auiEncounter[2]; + data >> uiFirstBoss; + } - OUT_LOAD_INST_DATA(in); - - char dataHead1, dataHead2; - uint32 data0, data1, data2, data3, data4; - - std::istringstream loadStream(in); - loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3 >> data4; - - if (dataHead1 == 'V' && dataHead2 == 'H') - { - m_auiEncounter[0] = data0; - m_auiEncounter[1] = data1; - m_auiEncounter[2] = data2; - uiFirstBoss = data3; - uiSecondBoss = data4; - - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - m_auiEncounter[i] = NOT_STARTED; - - if (m_auiEncounter[MAX_ENCOUNTER - 1] == DONE) - EncounterStatus = DONE; - } - else OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + void WriteSaveDataMore(std::ostringstream& data) override + { + data << m_auiEncounter[0] << ' ' + << m_auiEncounter[1] << ' ' + << m_auiEncounter[2] << ' ' + << uiFirstBoss << ' ' + << uiSecondBoss << ' '; } }; }; diff --git a/src/server/scripts/Northrend/VioletHold/violet_hold.h b/src/server/scripts/Northrend/VioletHold/violet_hold.h index 85be8d76e..84d3baa14 100644 --- a/src/server/scripts/Northrend/VioletHold/violet_hold.h +++ b/src/server/scripts/Northrend/VioletHold/violet_hold.h @@ -22,6 +22,8 @@ #include "CreatureAIImpl.h" +#define DataHeader "VIO" + #define VioletHoldScriptName "instance_violet_hold" enum Creatures diff --git a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp index f599201bb..3294874d9 100644 --- a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp +++ b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp @@ -29,12 +29,9 @@ public: { instance_auchenai_crypts_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(EncounterCount); } - - void Load(char const* data) override { LoadBossState(data); } - - std::string GetSaveData() override { return DataHeader + GetBossSaveData(); } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp b/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp index 55377d766..3407aacf8 100644 --- a/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp +++ b/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp @@ -29,12 +29,9 @@ public: { instance_mana_tombs_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(EncounterCount); } - - void Load(char const* data) override { LoadBossState(data); } - - std::string GetSaveData() override { return DataHeader + GetBossSaveData(); } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Outland/BlackTemple/black_temple.h b/src/server/scripts/Outland/BlackTemple/black_temple.h index cc5898335..bcff3b3a0 100644 --- a/src/server/scripts/Outland/BlackTemple/black_temple.h +++ b/src/server/scripts/Outland/BlackTemple/black_temple.h @@ -26,6 +26,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "BT" + #define BlackTempleScriptName "instance_black_temple" enum DataTypes diff --git a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp index 1b76c37f6..13b27e4df 100644 --- a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp +++ b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp @@ -64,6 +64,7 @@ public: { instance_black_temple_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); LoadBossBoundaries(boundaries); @@ -229,49 +230,6 @@ public: return true; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B T " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'B' && dataHead2 == 'T') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: ObjectGuid ShadeOfAkamaGUID; ObjectGuid AkamaShadeGUID; diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp index fb76249ca..d22cd4c47 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp @@ -42,6 +42,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); @@ -173,49 +174,6 @@ public: return 0; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "S C " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'S' && dataHead2 == 'C') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - private: ObjectGuid LadyVashjGUID; ObjectGuid ShieldGeneratorGUID[4]; diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h index 1bc1ee14d..ad3b54f5f 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h @@ -25,6 +25,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "SS" + #define SerpentShrineScriptName "instance_serpent_shrine" enum DataTypes diff --git a/src/server/scripts/Outland/CoilfangReservoir/SlavePens/instance_the_slave_pens.cpp b/src/server/scripts/Outland/CoilfangReservoir/SlavePens/instance_the_slave_pens.cpp index c95b5ffe7..f48474783 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SlavePens/instance_the_slave_pens.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SlavePens/instance_the_slave_pens.cpp @@ -37,11 +37,10 @@ public: { instance_the_slave_pens_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); counter = DATA_FLAMECALLER_000; } - void Load(char const* /*data*/) override { LoadBossState(DataHeader); } - void OnCreatureCreate(Creature* creature) override { switch (creature->GetEntry()) diff --git a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h index aa8247b4f..91244e4af 100644 --- a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h +++ b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h @@ -22,6 +22,8 @@ #include "CreatureAIImpl.h" #include "SpellAuraEffects.h" +#define DataHeader "GL" + #define GruulsLairScriptName "instance_gruuls_lair" enum DataTypes diff --git a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp index 94d0b57be..5fbfadbcb 100644 --- a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp +++ b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp @@ -44,6 +44,7 @@ public: { instance_gruuls_lair_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); LoadDoorData(doorData); LoadMinionData(minionData); @@ -127,49 +128,6 @@ public: return 0; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "G L " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'G' && dataHead2 == 'L') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: uint32 _addsKilled; ObjectGuid _maulgarGUID; diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h index 834fb1e8d..35c71f723 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h @@ -21,6 +21,7 @@ #include "CreatureAIImpl.h" #include "SpellScript.h" +#define DataHeader "HR" #define HellfireRampartsScriptName "instance_hellfire_ramparts" enum DataTypes diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp index b20442cca..07bdac483 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp @@ -30,6 +30,7 @@ public: void Initialize() override { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); } @@ -55,36 +56,6 @@ public: return true; } - std::string GetSaveData() override - { - std::ostringstream saveStream; - saveStream << "H R " << GetBossSaveData(); - return saveStream.str(); - } - - void Load(const char* strIn) override - { - if (!strIn) - return; - - char dataHead1, dataHead2; - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'H' && dataHead2 == 'R') - { - for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - - SetBossState(i, EncounterState(tmpState)); - } - } - } - protected: ObjectGuid felIronChestGUID; }; diff --git a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp index 779f25b84..454479e9c 100644 --- a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp @@ -44,6 +44,7 @@ public: { instance_magtheridons_lair_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); LoadDoorData(doorData); LoadMinionData(minionData); @@ -179,49 +180,6 @@ public: } } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "M L " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'M' && dataHead2 == 'L') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - private: ObjectGuid _magtheridonGUID; GuidSet _wardersSet; diff --git a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h index 3eef4674f..9f38598fc 100644 --- a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h +++ b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h @@ -21,6 +21,8 @@ #include "CreatureAIImpl.h" #include "SpellScript.h" +#define DataHeader "ML" + #define MagtheridonsLairScriptName "instance_magtheridons_lair" enum DataTypes diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp index f15a02cb0..161393275 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp @@ -186,49 +186,14 @@ public: } } - std::string GetSaveData() override + void ReadSaveDataMore(std::istringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "S H " << GetBossSaveData() << ' ' << RescueTimer; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); + data >> RescueTimer; } - void Load(const char* strIn) override + void WriteSaveDataMore(std::ostringstream& data) override { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'S' && dataHead2 == 'H') - { - for (uint8 i = 0; i < ENCOUNTER_COUNT; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - - loadStream >> RescueTimer; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << RescueTimer; } protected: diff --git a/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp b/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp index 49c9ec9fb..ff9c4f096 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp @@ -26,7 +26,11 @@ public: struct instance_the_eye_InstanceMapScript : public InstanceScript { - instance_the_eye_InstanceMapScript(Map* map) : InstanceScript(map) {} + instance_the_eye_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + SetBossNumber(MAX_ENCOUNTER); + } ObjectGuid ThaladredTheDarkenerGUID; ObjectGuid LordSanguinarGUID; @@ -38,11 +42,6 @@ public: ObjectGuid KaelStateRightGUID; ObjectGuid KaelStateLeftGUID; - void Initialize() override - { - SetBossNumber(MAX_ENCOUNTER); - } - void OnCreatureCreate(Creature* creature) override { switch (creature->GetEntry()) @@ -110,49 +109,6 @@ public: return ObjectGuid::Empty; } - - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "E Y " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'E' && dataHead2 == 'Y') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h index 9e359fb9e..e7f2b0625 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h +++ b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h @@ -24,6 +24,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "TE" + #define TheEyeScriptName "instance_the_eye" enum EyeData diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp index b1a01653e..a13c4d32e 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp @@ -36,6 +36,7 @@ public: { instance_mechanar_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); LoadDoorData(doorData); @@ -192,60 +193,19 @@ public: } } - bool SetBossState(uint32 type, EncounterState state) override + void ReadSaveDataMore(std::istringstream& data) override { - if (!InstanceScript::SetBossState(type, state)) - return false; + data >> _passageEncounter; - return true; + if (_passageEncounter == ENCOUNTER_PASSAGE_DONE) + { + _passageEncounter = ENCOUNTER_PASSAGE_PHASE6; + } } - std::string GetSaveData() override + void WriteSaveDataMore(std::ostringstream& data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - // Xinef: no space needed - saveStream << "M E " << GetBossSaveData() << _passageEncounter; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(const char* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'M' && dataHead2 == 'E') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - - loadStream >> _passageEncounter; - if (_passageEncounter == ENCOUNTER_PASSAGE_DONE) - _passageEncounter = ENCOUNTER_PASSAGE_PHASE6; - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; + data << _passageEncounter; } private: diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h b/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h index 361383f3c..bcd8fae64 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h @@ -24,6 +24,8 @@ #include "SpellAuraEffects.h" #include "SpellScript.h" +#define DataHeader "MR" + #define MechanarScriptName "instance_mechanar" enum DataTypes diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h index e8fbe7c83..9625baee4 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h @@ -23,6 +23,8 @@ #include "Player.h" #include "SpellScript.h" +#define DataHeader "AZ" + #define ArcatrazScriptName "instance_arcatraz" enum DataTypes diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp index b92cd7bfd..45492b0e5 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp @@ -35,6 +35,7 @@ public: { instance_arcatraz_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUTER); LoadDoorData(doorData); } @@ -154,49 +155,6 @@ public: return true; } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "A Z " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'A' && dataHead2 == 'Z') - { - for (uint32 i = 0; i < MAX_ENCOUTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } - protected: ObjectGuid DalliahGUID; ObjectGuid SoccothratesGUID; diff --git a/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp index bacbe7cfd..c7a1f4d76 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp @@ -29,59 +29,9 @@ public: { instance_the_botanica_InstanceMapScript(Map* map) : InstanceScript(map) { + SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); } - - bool SetBossState(uint32 type, EncounterState state) override - { - if (!InstanceScript::SetBossState(type, state)) - return false; - - return true; - } - - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B O " << GetBossSaveData(); - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - - void Load(char const* str) override - { - if (!str) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(str); - - char dataHead1, dataHead2; - - std::istringstream loadStream(str); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'B' && dataHead2 == 'O') - { - for (uint32 i = 0; i < MAX_ENCOUNTER; ++i) - { - uint32 tmpState; - loadStream >> tmpState; - if (tmpState == IN_PROGRESS || tmpState > SPECIAL) - tmpState = NOT_STARTED; - SetBossState(i, EncounterState(tmpState)); - } - } - else - OUT_LOAD_INST_DATA_FAIL; - - OUT_LOAD_INST_DATA_COMPLETE; - } }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h index 083c83272..44d4e44a8 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h +++ b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h @@ -23,6 +23,8 @@ #define TheBotanicaScriptName "instance_the_botanica" +#define DataHeader "BC" + enum DataTypes { DATA_COMMANDER_SARANNIS = 0, From 1251939d42c1a39b11014dcdbde400275011bbc6 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 21:27:39 +0100 Subject: [PATCH 64/87] fix(DB/SAI): Fixed "Trapping the Light Fantastic" quest. (#14963) --- data/sql/updates/pending_db_world/rev_1676194422036481300.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676194422036481300.sql diff --git a/data/sql/updates/pending_db_world/rev_1676194422036481300.sql b/data/sql/updates/pending_db_world/rev_1676194422036481300.sql new file mode 100644 index 000000000..87cabdeb9 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676194422036481300.sql @@ -0,0 +1,4 @@ +-- +UPDATE `smart_scripts` SET `target_type`=19, `target_param1`=20635, `target_param2`=20 WHERE `entryorguid`=21926 AND `source_type`=0 AND `id`=2; +UPDATE `smart_scripts` SET `target_type`=19, `target_param1`=20771, `target_param2`=20 WHERE `entryorguid`=21926 AND `source_type`=0 AND `id`=3; +UPDATE `smart_scripts` SET `target_type`=23 WHERE `entryorguid`=21926 AND `source_type`=0 AND `id`=4; From 98d158ba909a4bb20bf8b043e31f9885335addb2 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 21:27:46 +0100 Subject: [PATCH 65/87] =?UTF-8?q?fix(DB/ShatteredHalls):=20Spawned=20Hellf?= =?UTF-8?q?ire=20Training=20Dummies=20in=20Shattere=E2=80=A6=20(#14964)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pending_db_world/rev_1676195324837213600.sql | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676195324837213600.sql diff --git a/data/sql/updates/pending_db_world/rev_1676195324837213600.sql b/data/sql/updates/pending_db_world/rev_1676195324837213600.sql new file mode 100644 index 000000000..0b53995ab --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676195324837213600.sql @@ -0,0 +1,10 @@ +-- +SET @CGUID := 2000102; +DELETE FROM `creature` WHERE `id1`=17578; +INSERT INTO `creature` (`guid`, `id1`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`) VALUES +(@CGUID,17578,540,3714,0,3,1,0,512.174,205.351,2.00779,0.698132,7200,0,0,0,0,0,0,0,0,'',14545), +(@CGUID+1,17578,540,3714,0,3,1,0,512.93,186.96,2.00013,0.767945,7200,0,0,0,0,0,0,0,0,'',14545), +(@CGUID+2,17578,540,3714,0,3,1,0,525.067,176.656,2.01602,2.35619,7200,0,0,0,0,0,0,0,0,'',14545), +(@CGUID+3,17578,540,3714,0,3,1,0,508.17,131.228,2.01886,1.22173,7200,0,0,0,0,0,0,0,0,'',14545), +(@CGUID+4,17578,540,3714,0,3,1,0,512.597,119.766,1.99459,0.663225,7200,0,0,0,0,0,0,0,0,'',14545), +(@CGUID+5,17578,540,3714,0,3,1,0,523.467,119.278,1.94614,2.04204,7200,0,0,0,0,0,0,0,0,'',14545); From f6b7d2b8a6f22a1764546c71a8323b1db86fcdc6 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Sun, 12 Feb 2023 21:27:53 +0100 Subject: [PATCH 66/87] fix(DB/Creature): Implement & Script Wildhammer Gryphon Rider (#14924) Co-authored-by: Gultask <100873791+Gultask@users.noreply.github.com> --- .../rev_1675980877375293800.sql | 118 ++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675980877375293800.sql diff --git a/data/sql/updates/pending_db_world/rev_1675980877375293800.sql b/data/sql/updates/pending_db_world/rev_1675980877375293800.sql new file mode 100644 index 000000000..216a31fe7 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675980877375293800.sql @@ -0,0 +1,118 @@ +-- + +DELETE FROM `creature` WHERE `guid` IN (125922, 125927, 125930, 125931, 125932, 126052, 1158) AND `id1`=19382; -- Wildhammer Gryphon Rider +INSERT INTO `creature` (`guid`, `id1`, `map`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `npcflag`, `MovementType`) VALUES +(125922, 19382, 530, 1, 1, 0, -4051.94, 2241.56, 162.544, 0.216896, 300, 0, 0, 6986, 0, 0, 2), +(125927, 19382, 530, 1, 1, 0, -3899.48, 2238.93, 153.799, 6.19141, 300, 0, 0, 6986, 0, 0, 2), +(125930, 19382, 530, 1, 1, 0, -3949.48, 2304.36, 171.654, 6.06812, 300, 0, 0, 6986, 0, 0, 2), +(125931, 19382, 530, 1, 1, 0, -3897.92, 2224.14, 151.055, 0.100661, 300, 0, 0, 6986, 0, 0, 2), +(125932, 19382, 530, 1, 1, 0, -3999.39, 2088.57, 154.241, 4.72118, 300, 0, 0, 6986, 0, 0, 2), +(126052, 19382, 530, 1, 1, 0, -4076.25, 2220.12, 152.366, 5.04713, 300, 0, 0, 6986, 0, 0, 2), +(1158, 19382, 530, 1, 1, 0, -4108.75, 2120.99, 165.498, 5.35342, 300, 0, 0, 6986, 0, 0, 2); + +DELETE FROM `creature_addon` WHERE `guid` IN (125922, 125927, 125930, 125931, 125932, 126052, 126091, 1158); +INSERT INTO `creature_addon` (`guid`, `path_id`) VALUES +(125922,1259220), +(125927,1259270), +(125930,1259300), +(125931,1259310), +(125932,1259320), +(126052,1260520), +(1158,11580); + +DELETE FROM `waypoint_data` WHERE `id` IN (1259220, 1259270, 1259300, 1259310, 1259320, 1260520, 11580); +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`action`,`move_type`,`action_chance`,`wpguid`) VALUES +(1259220, 1, -4051.94, 2241.56, 162.544, 0.216896, 0, 0, 2, 100,0), +(1259220, 2, -3997.56, 2253.14, 158.921, 5.91104, 0, 0, 2, 100,0), +(1259220, 3, -3925.54, 2219.22, 155.111, 5.63615, 0, 0, 2, 100,0), +(1259220, 4, -3854.31, 2156.6, 134.7, 5.20418, 0, 0, 2, 100,0), +(1259220, 5, -3818.04, 2075.42, 128.011, 3.66089, 0, 0, 2, 100,0), +(1259220, 6, -3834.16, 2048.48, 128.009, 3.46848, 0, 0, 2, 100,0), +(1259220, 7, -3880.47, 2038.16, 123.718, 3.00902, 0, 0, 2, 100,0), +(1259220, 8, -3925.97, 2044.73, 123.344, 3.0208, 0, 0, 2, 100,0), +(1259220, 9, -3974.4, 2054.21, 134.021, 2.71449, 0, 0, 2, 100,0), +(1259220, 10, -4013.86, 2083.46, 146.103, 2.18435, 0, 0, 2, 100,0), +(1259220, 11, -4031.3, 2131.46, 154.554, 1.89375, 0, 0, 2, 100,0), +(1259220, 12, -4054.6, 2206.02, 161.32, 1.71704, 0, 0, 2, 100,0), +(1259270, 1, -3899.48, 2238.93, 153.799, 6.19534, 0, 0, 2, 100,0), +(1259270, 2, -3857.09, 2225.5, 139.343, 4.98584, 0, 0, 2, 100,0), +(1259270, 3, -3849.71, 2185.97, 122.181, 4.56958, 0, 0, 2, 100,0), +(1259270, 4, -3852.46, 2144.69, 125.701, 4.64419, 0, 0, 2, 100,0), +(1259270, 5, -3859.27, 2102.81, 130.463, 4.09834, 0, 0, 2, 100,0), +(1259270, 6, -3890.33, 2069.91, 135.302, 3.14408, 0, 0, 2, 100,0), +(1259270, 7, -3959.81, 2086.18, 157.318, 2.91632, 0, 0, 2, 100,0), +(1259270, 8, -4040.09, 2124.8, 171.418, 2.6375, 0, 0, 2, 100,0), +(1259270, 9, -4072.57, 2169.26, 165.294, 1.33374, 0, 0, 2, 100,0), +(1259270, 10, -4064.99, 2207.03, 168.235, 0.179203, 0, 0, 2, 100,0), +(1259270, 11, -4004.62, 2224.87, 164.896, 0.11637, 0, 0, 2, 100,0), +(1259270, 12, -3928.63, 2232.41, 162.067, 0.139932, 0, 0, 2, 100,0), +(1259300, 1, -3949.48, 2304.36, 171.654, 6.06812, 0, 0, 2, 100,0), +(1259300, 2, -3881.05, 2279.63, 154.421, 5.8168, 0, 0, 2, 100,0), +(1259300, 3, -3857.98, 2258.32, 135.208, 5.25525, 0, 0, 2, 100,0), +(1259300, 4, -3840.02, 2223.93, 121.701, 4.75653, 0, 0, 2, 100,0), +(1259300, 5, -3839.27, 2183.51, 122.92, 4.04574, 0, 0, 2, 100,0), +(1259300, 6, -3862.96, 2152.95, 124.671, 4.45414, 0, 0, 2, 100,0), +(1259300, 7, -3864.79, 2109.73, 130.412, 4.31277, 0, 0, 2, 100,0), +(1259300, 8, -3883.63, 2073.73, 128.885, 4.18319, 0, 0, 2, 100,0), +(1259300, 9, -3935.96, 2049.97, 127.05, 3.45669, 0, 0, 2, 100,0), +(1259300, 10, -3987.81, 2020.87, 129.134, 2.65166, 0, 0, 2, 100,0), +(1259300, 11, -4009.99, 2053.36, 132.873, 2.18435, 0, 0, 2, 100,0), +(1259300, 12, -4040.82, 2096.28, 158.469, 1.67384, 0, 0, 2, 100,0), +(1259300, 13, -4031.14, 2157.85, 162.339, 1.43822, 0, 0, 2, 100,0), +(1259300, 14, -4017.71, 2217.55, 168.982, 1.29292, 0, 0, 2, 100,0), +(1259300, 15, -3992.56, 2266.98, 173.162, 0.963052, 0, 0, 2, 100,0), +(1259310, 1, -3900.47, 2224.45, 151.84, 6.21105, 0, 0, 2, 100,0), +(1259310, 2, -3869.76, 2227.03, 145.231, 5.36283, 0, 0, 2, 100,0), +(1259310, 3, -3854.2, 2205.04, 137.46, 5.06045, 0, 0, 2, 100,0), +(1259310, 4, -3844.81, 2150.86, 126.133, 4.71881, 0, 0, 2, 100,0), +(1259310, 5, -3844.5, 2111.13, 123.73, 4.72273, 0, 0, 2, 100,0), +(1259310, 6, -3845.52, 2056.38, 123.894, 3.49202, 0, 0, 2, 100,0), +(1259310, 7, -3884.24, 2038.94, 120.657, 3.16215, 0, 0, 2, 100,0), +(1259310, 8, -3937.46, 2039.53, 128.187, 3.12288, 0, 0, 2, 100,0), +(1259310, 9, -3979.93, 2042.14, 130.443, 3.02863, 0, 0, 2, 100,0), +(1259310, 10, -4006.04, 2045.1, 134.086, 2.21574, 0, 0, 2, 100,0), +(1259310, 11, -4029.41, 2088.36, 144.849, 1.98405, 0, 0, 2, 100,0), +(1259310, 12, -4032.27, 2129.1, 151.644, 1.2929, 0, 0, 2, 100,0), +(1259310, 13, -4046.06, 2167.97, 159.199, 0.460378, 0, 0, 2, 100,0), +(1259310, 14, -3997.94, 2182.24, 147.777, 0.024478, 0, 0, 2, 100,0), +(1259310, 15, -3945.65, 2182.34, 153.491, 0.393615, 0, 0, 2, 100,0), +(1259310, 16, -3917.84, 2209.25, 151.136, 0.868781, 0, 0, 2, 100,0), +(1259320, 1, -3999.39, 2088.57, 154.241, 4.72118, 0, 0, 2, 100,0), +(1259320, 2, -3996.4, 2025.73, 131.159, 5.11387, 0, 0, 2, 100,0), +(1259320, 3, -3980.67, 1984.63, 126.931, 5.64401, 0, 0, 2, 100,0), +(1259320, 4, -3949.4, 1961.52, 120.325, 0.236544, 0, 0, 2, 100,0), +(1259320, 5, -3912.93, 1976.07, 122.084, 0.809885, 0, 0, 2, 100,0), +(1259320, 6, -3881.71, 2029.34, 126.014, 1.21437, 0, 0, 2, 100,0), +(1259320, 7, -3868.52, 2086.93, 126.512, 1.95657, 0, 0, 2, 100,0), +(1259320, 8, -3884.25, 2110.46, 129.245, 2.72233, 0, 0, 2, 100,0), +(1259320, 9, -3928.8, 2132.42, 137.384, 2.99329, 0, 0, 2, 100,0), +(1259320, 10, -3974.01, 2138.49, 141.452, 3.68052, 0, 0, 2, 100,0), +(1259320, 11, -3987.24, 2120.74, 150.055, 4.32454, 0, 0, 2, 100,0), +(1260520, 1, -4076.25, 2220.12, 152.366, 4.94104, 0, 0, 2, 100,0), +(1260520, 2, -4055.83, 2173.18, 151.895, 5.14131, 0, 0, 2, 100,0), +(1260520, 3, -4030.75, 2118.7, 150.714, 5.14131, 0, 0, 2, 100,0), +(1260520, 4, -4013.47, 2072.27, 139.418, 5.05885, 0, 0, 2, 100,0), +(1260520, 5, -3996.36, 2020.97, 126.096, 5.0667, 0, 0, 2, 100,0), +(1260520, 6, -3975.46, 1984.79, 122.488, 5.71465, 0, 0, 2, 100,0), +(1260520, 7, -3938.71, 1972.51, 121.056, 0.012655, 0, 0, 2, 100,0), +(1260520, 8, -3910.65, 1995.43, 123.188, 1.02975, 0, 0, 2, 100,0), +(1260520, 9, -3890.18, 2041.82, 125.367, 1.17897, 0, 0, 2, 100,0), +(1260520, 10, -3875.63, 2074.2, 135.303, 1.84656, 0, 0, 2, 100,0), +(1260520, 11, -3885.37, 2108.05, 141.323, 1.94866, 0, 0, 2, 100,0), +(1260520, 12, -3907.97, 2156.71, 142.056, 1.8819, 0, 0, 2, 100,0), +(1260520, 13, -3918.51, 2202.87, 151.002, 2.23141, 0, 0, 2, 100,0), +(1260520, 14, -3948.5, 2232.25, 150.484, 2.44346, 0, 0, 2, 100,0), +(1260520, 15, -3994.83, 2256.08, 151.702, 2.78904, 0, 0, 2, 100,0), +(1260520, 16, -4048.14, 2253.56, 158.818, 3.42521, 0, 0, 2, 100,0), +(11580, 1, -4108.75, 2120.99, 165.498, 5.40836, 0, 0, 2, 100,0), +(11580, 2, -4099.19, 2100.11, 159.642, 0.11478, 0, 0, 2, 100,0), +(11580, 3, -4043.58, 2116.84, 149.879, 0.354326, 0, 0, 2, 100,0), +(11580, 4, -3984.91, 2130.74, 144.929, 0.189392, 0, 0, 2, 100,0), +(11580, 5, -3904.38, 2138.36, 134.802, 0.083364, 0, 0, 2, 100,0), +(11580, 6, -3878.68, 2156.17, 130.807, 0.613508, 0, 0, 2, 100,0), +(11580, 7, -3861.03, 2178.32, 133.881, 1.32822, 0, 0, 2, 100,0), +(11580, 8, -3864.98, 2235.6, 145.941, 2.33353, 0, 0, 2, 100,0), +(11580, 9, -3908.54, 2253.61, 151.858, 2.88724, 0, 0, 2, 100,0), +(11580, 10, -3960.79, 2246.79, 157.82, 3.53519, 0, 0, 2, 100,0), +(11580, 11, -4009.92, 2224.95, 164.005, 3.67656, 0, 0, 2, 100,0), +(11580, 12, -4060.04, 2180.75, 163.157, 3.93574, 0, 0, 2, 100,0); From 12ac2190eb8cbf7b3e77a91c790f60687f68a242 Mon Sep 17 00:00:00 2001 From: UltraNix <80540499+UltraNix@users.noreply.github.com> Date: Sun, 12 Feb 2023 21:27:59 +0100 Subject: [PATCH 67/87] fix(DB/SAI): Fixed Private Hendel SAI script. (#14866) --- data/sql/updates/pending_db_world/rev_1675540548592980100.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675540548592980100.sql diff --git a/data/sql/updates/pending_db_world/rev_1675540548592980100.sql b/data/sql/updates/pending_db_world/rev_1675540548592980100.sql new file mode 100644 index 000000000..f515a58e5 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675540548592980100.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `action_param3`=1 WHERE `entryorguid`=4966 AND `source_type`=0 AND `id`=7; From 7e7e484cb6f21695c89ecb1c130b7c9338bf3f5b Mon Sep 17 00:00:00 2001 From: Gultask <100873791+Gultask@users.noreply.github.com> Date: Sun, 12 Feb 2023 17:28:06 -0300 Subject: [PATCH 68/87] chore(DB): Add default values to columns in creature_formations table (#14936) --- .../sql/updates/pending_db_world/rev_1676054259396904200.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1676054259396904200.sql diff --git a/data/sql/updates/pending_db_world/rev_1676054259396904200.sql b/data/sql/updates/pending_db_world/rev_1676054259396904200.sql new file mode 100644 index 000000000..cce437316 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676054259396904200.sql @@ -0,0 +1,5 @@ +-- +ALTER TABLE `creature_formations` + CHANGE COLUMN `dist` `dist` FLOAT NOT NULL DEFAULT '0' AFTER `memberGUID`, + CHANGE COLUMN `angle` `angle` FLOAT NOT NULL DEFAULT '0' AFTER `dist`, + CHANGE COLUMN `groupAI` `groupAI` INT(10) UNSIGNED NOT NULL DEFAULT '0' AFTER `angle`; From d0cb8d226e6c2b75950935fe377777de1006012b Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 20:30:30 +0000 Subject: [PATCH 69/87] chore(DB): import pending files Referenced commit(s): 7e7e484cb6f21695c89ecb1c130b7c9338bf3f5b --- .../rev_1675540548592980100.sql => db_world/2023_02_12_08.sql} | 1 + .../rev_1675980877375293800.sql => db_world/2023_02_12_09.sql} | 1 + .../rev_1676054259396904200.sql => db_world/2023_02_12_10.sql} | 1 + .../rev_1676194422036481300.sql => db_world/2023_02_12_11.sql} | 1 + .../rev_1676195324837213600.sql => db_world/2023_02_12_12.sql} | 1 + 5 files changed, 5 insertions(+) rename data/sql/updates/{pending_db_world/rev_1675540548592980100.sql => db_world/2023_02_12_08.sql} (70%) rename data/sql/updates/{pending_db_world/rev_1675980877375293800.sql => db_world/2023_02_12_09.sql} (99%) rename data/sql/updates/{pending_db_world/rev_1676054259396904200.sql => db_world/2023_02_12_10.sql} (86%) rename data/sql/updates/{pending_db_world/rev_1676194422036481300.sql => db_world/2023_02_12_11.sql} (89%) rename data/sql/updates/{pending_db_world/rev_1676195324837213600.sql => db_world/2023_02_12_12.sql} (95%) diff --git a/data/sql/updates/pending_db_world/rev_1675540548592980100.sql b/data/sql/updates/db_world/2023_02_12_08.sql similarity index 70% rename from data/sql/updates/pending_db_world/rev_1675540548592980100.sql rename to data/sql/updates/db_world/2023_02_12_08.sql index f515a58e5..b3b4ec567 100644 --- a/data/sql/updates/pending_db_world/rev_1675540548592980100.sql +++ b/data/sql/updates/db_world/2023_02_12_08.sql @@ -1,2 +1,3 @@ +-- DB update 2023_02_12_07 -> 2023_02_12_08 -- UPDATE `smart_scripts` SET `action_param3`=1 WHERE `entryorguid`=4966 AND `source_type`=0 AND `id`=7; diff --git a/data/sql/updates/pending_db_world/rev_1675980877375293800.sql b/data/sql/updates/db_world/2023_02_12_09.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1675980877375293800.sql rename to data/sql/updates/db_world/2023_02_12_09.sql index 216a31fe7..624ea9a0f 100644 --- a/data/sql/updates/pending_db_world/rev_1675980877375293800.sql +++ b/data/sql/updates/db_world/2023_02_12_09.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_08 -> 2023_02_12_09 -- DELETE FROM `creature` WHERE `guid` IN (125922, 125927, 125930, 125931, 125932, 126052, 1158) AND `id1`=19382; -- Wildhammer Gryphon Rider diff --git a/data/sql/updates/pending_db_world/rev_1676054259396904200.sql b/data/sql/updates/db_world/2023_02_12_10.sql similarity index 86% rename from data/sql/updates/pending_db_world/rev_1676054259396904200.sql rename to data/sql/updates/db_world/2023_02_12_10.sql index cce437316..391452885 100644 --- a/data/sql/updates/pending_db_world/rev_1676054259396904200.sql +++ b/data/sql/updates/db_world/2023_02_12_10.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_09 -> 2023_02_12_10 -- ALTER TABLE `creature_formations` CHANGE COLUMN `dist` `dist` FLOAT NOT NULL DEFAULT '0' AFTER `memberGUID`, diff --git a/data/sql/updates/pending_db_world/rev_1676194422036481300.sql b/data/sql/updates/db_world/2023_02_12_11.sql similarity index 89% rename from data/sql/updates/pending_db_world/rev_1676194422036481300.sql rename to data/sql/updates/db_world/2023_02_12_11.sql index 87cabdeb9..6da31786d 100644 --- a/data/sql/updates/pending_db_world/rev_1676194422036481300.sql +++ b/data/sql/updates/db_world/2023_02_12_11.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_10 -> 2023_02_12_11 -- UPDATE `smart_scripts` SET `target_type`=19, `target_param1`=20635, `target_param2`=20 WHERE `entryorguid`=21926 AND `source_type`=0 AND `id`=2; UPDATE `smart_scripts` SET `target_type`=19, `target_param1`=20771, `target_param2`=20 WHERE `entryorguid`=21926 AND `source_type`=0 AND `id`=3; diff --git a/data/sql/updates/pending_db_world/rev_1676195324837213600.sql b/data/sql/updates/db_world/2023_02_12_12.sql similarity index 95% rename from data/sql/updates/pending_db_world/rev_1676195324837213600.sql rename to data/sql/updates/db_world/2023_02_12_12.sql index 0b53995ab..80b5b32f7 100644 --- a/data/sql/updates/pending_db_world/rev_1676195324837213600.sql +++ b/data/sql/updates/db_world/2023_02_12_12.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_11 -> 2023_02_12_12 -- SET @CGUID := 2000102; DELETE FROM `creature` WHERE `id1`=17578; From d1b4481dd71eb9b00f9c4797342ff76966d4f031 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 17:46:18 -0300 Subject: [PATCH 70/87] refactor(Scripts/Arcatraz): Modernize Dalliah the Doomsayer script (#14978) --- .../Outland/TempestKeep/arcatraz/arcatraz.h | 7 + .../arcatraz/boss_dalliah_the_doomsayer.cpp | 226 ++++++++---------- .../boss_wrath_scryer_soccothrates.cpp | 38 ++- .../arcatraz/instance_arcatraz.cpp | 51 +--- 4 files changed, 127 insertions(+), 195 deletions(-) diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h index 9625baee4..a95acaf31 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h @@ -72,10 +72,17 @@ enum SpellIds SPELL_SOUL_STEAL = 36782 }; +enum Texts +{ + SAY_RIVAL_DIED = 6 // Soccothrates & Delliah +}; + template inline AI* GetArcatrazAI(T* obj) { return GetInstanceAI(obj, ArcatrazScriptName); } +#define RegisterArcatrazCreatureAI(ai_name) RegisterCreatureAIWithFactory(ai_name, GetArcatrazAI) + #endif // ARCATRAZ_H diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp index 92858c621..72c315a62 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp @@ -42,143 +42,107 @@ enum Spells SPELL_SHADOW_WAVE = 39016 }; -enum Events +struct boss_dalliah_the_doomsayer : public BossAI { - EVENT_GIFT_OF_THE_DOOMSAYER = 1, - EVENT_WHIRLWIND = 2, - EVENT_HEAL = 3, - EVENT_SHADOW_WAVE = 4, - EVENT_ME_FIRST = 5, - EVENT_SOCCOTHRATES_DEATH = 6, - EVENT_CHECK_HEALTH = 7, -}; + boss_dalliah_the_doomsayer(Creature* creature) : BossAI(creature, DATA_DALLIAH), _percentHealthCheck(false) { } -class boss_dalliah_the_doomsayer : public CreatureScript -{ -public: - boss_dalliah_the_doomsayer() : CreatureScript("boss_dalliah_the_doomsayer") { } - - struct boss_dalliah_the_doomsayerAI : public BossAI + void Reset() override { - boss_dalliah_the_doomsayerAI(Creature* creature) : BossAI(creature, DATA_DALLIAH) { } - - void Reset() override - { - _Reset(); - events2.Reset(); - me->SetImmuneToAll(false); - } - - void InitializeAI() override - { - BossAI::InitializeAI(); - if (instance->GetBossState(DATA_SOCCOTHRATES) != DONE) - me->SetImmuneToAll(true); - } - - void JustDied(Unit* /*killer*/) override - { - _JustDied(); - Talk(SAY_DEATH); - - if (Creature* soccothrates = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_SOCCOTHRATES))) - if (soccothrates->IsAlive() && !soccothrates->IsInCombat()) - soccothrates->AI()->SetData(1, 1); - } - - void EnterCombat(Unit* /*who*/) override - { - _EnterCombat(); - Talk(SAY_AGGRO); - - events.ScheduleEvent(EVENT_GIFT_OF_THE_DOOMSAYER, urand(1000, 4000)); - events.ScheduleEvent(EVENT_WHIRLWIND, urand(7000, 9000)); - events.ScheduleEvent(EVENT_ME_FIRST, 6000); - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - - if (IsHeroic()) - events.ScheduleEvent(EVENT_SHADOW_WAVE, urand(11000, 16000)); - } - - void KilledUnit(Unit* victim) override - { - if (victim->GetTypeId() == TYPEID_PLAYER) - Talk(SAY_SLAY); - } - - void SetData(uint32 /*type*/, uint32 data) override - { - if (data == 1) - events2.ScheduleEvent(EVENT_SOCCOTHRATES_DEATH, 6000); - } - - void UpdateAI(uint32 diff) override - { - events2.Update(diff); - switch (events2.ExecuteEvent()) - { - case EVENT_SOCCOTHRATES_DEATH: - Talk(SAY_SOCCOTHRATES_DEATH); - break; - } - - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_GIFT_OF_THE_DOOMSAYER: - me->CastSpell(me->GetVictim(), SPELL_GIFT_OF_THE_DOOMSAYER, false); - events.ScheduleEvent(EVENT_GIFT_OF_THE_DOOMSAYER, urand(16000, 21000)); - break; - case EVENT_WHIRLWIND: - me->CastSpell(me, SPELL_WHIRLWIND, false); - Talk(SAY_WHIRLWIND); - events.ScheduleEvent(EVENT_WHIRLWIND, urand(19000, 21000)); - events.ScheduleEvent(EVENT_HEAL, 6000); - break; - case EVENT_HEAL: - me->CastSpell(me, SPELL_HEAL, false); - Talk(SAY_HEAL); - break; - case EVENT_SHADOW_WAVE: - me->CastSpell(me->GetVictim(), SPELL_SHADOW_WAVE, false); - events.ScheduleEvent(EVENT_SHADOW_WAVE, urand(11000, 16000)); - break; - case EVENT_ME_FIRST: - if (Creature* soccothrates = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_SOCCOTHRATES))) - if (soccothrates->IsAlive() && !soccothrates->IsInCombat()) - soccothrates->AI()->Talk(SAY_AGGRO_DALLIAH_FIRST); - break; - case EVENT_CHECK_HEALTH: - if (HealthBelowPct(25)) - { - if (Creature* soccothrates = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_SOCCOTHRATES))) - soccothrates->AI()->Talk(SAY_DALLIAH_25_PERCENT); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - break; - } - - DoMeleeAttackIfReady(); - } - - private: - EventMap events2; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetArcatrazAI(creature); + _Reset(); + _percentHealthCheck = false; + me->SetImmuneToAll(false); } + + void InitializeAI() override + { + BossAI::InitializeAI(); + + if (instance->GetBossState(DATA_SOCCOTHRATES) != DONE) + { + me->SetImmuneToAll(true); + } + } + + void JustDied(Unit* /*killer*/) override + { + _JustDied(); + Talk(SAY_DEATH); + + if (Creature* soccothrates = instance->GetCreature(DATA_SOCCOTHRATES)) + { + if (soccothrates->IsAlive() && !soccothrates->IsInCombat()) + { + soccothrates->AI()->Talk(SAY_RIVAL_DIED, 6s); + } + } + } + + void EnterCombat(Unit* /*who*/) override + { + _EnterCombat(); + Talk(SAY_AGGRO); + + if (Creature* soccothrates = instance->GetCreature(DATA_SOCCOTHRATES)) + { + if (soccothrates->IsAlive() && !soccothrates->IsInCombat()) + { + soccothrates->AI()->Talk(SAY_AGGRO_DALLIAH_FIRST, 6s); + } + } + + scheduler.Schedule(1s, 4s, [this](TaskContext context) + { + DoCastVictim(SPELL_GIFT_OF_THE_DOOMSAYER); + context.Repeat(16s, 21s); + }).Schedule(7s, 9s, [this](TaskContext context) + { + Talk(SAY_WHIRLWIND); + DoCastAOE(SPELL_WHIRLWIND); + context.Repeat(19s, 21s); + + scheduler.Schedule(7s, [this](TaskContext) + { + Talk(SAY_HEAL); + DoCastSelf(SPELL_HEAL); + }); + }); + + if (IsHeroic()) + { + scheduler.Schedule(11s, 16s, [this](TaskContext context) + { + DoCastVictim(SPELL_SHADOW_WAVE); + context.Repeat(11s, 16s); + }); + } + } + + void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damageType*/, SpellSchoolMask /*damageSchoolMask*/) override + { + if (me->HealthBelowPctDamaged(25, damage) && !_percentHealthCheck) + { + if (Creature* soccothrates = instance->GetCreature(DATA_SOCCOTHRATES)) + { + soccothrates->AI()->Talk(SAY_DALLIAH_25_PERCENT); + } + + _percentHealthCheck = true; + } + } + + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer()) + { + Talk(SAY_SLAY); + } + } + +private: + bool _percentHealthCheck; }; void AddSC_boss_dalliah_the_doomsayer() { - new boss_dalliah_the_doomsayer(); + RegisterArcatrazCreatureAI(boss_dalliah_the_doomsayer); } diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp index 47c695435..86b95aeb2 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp @@ -64,10 +64,9 @@ enum Events EVENT_PREFIGHT_8 = 10, EVENT_PREFIGHT_9 = 11, EVENT_ME_FIRST = 12, - EVENT_DALLIAH_DEATH = 13, - EVENT_CHECK_HEALTH = 14, - EVENT_SPELL_CHARGE = 15, - EVENT_FELFIRE = 16, + EVENT_CHECK_HEALTH = 13, + EVENT_SPELL_CHARGE = 14, + EVENT_FELFIRE = 15, }; class boss_wrath_scryer_soccothrates : public CreatureScript @@ -102,9 +101,13 @@ public: _JustDied(); Talk(SAY_DEATH); - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) + { if (dalliah->IsAlive() && !dalliah->IsInCombat()) - dalliah->AI()->SetData(1, 1); + { + dalliah->AI()->Talk(SAY_RIVAL_DIED + 1, 6s); + } + } } void EnterCombat(Unit* /*who*/) override @@ -134,19 +137,13 @@ public: } } - void SetData(uint32 /*type*/, uint32 data) override - { - if (data == 1) - events2.RescheduleEvent(EVENT_DALLIAH_DEATH, 6000); - } - void UpdateAI(uint32 diff) override { events2.Update(diff); switch (events2.ExecuteEvent()) { case EVENT_PREFIGHT_1: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) dalliah->AI()->Talk(SAY_DALLIAH_CONVO_1); events2.ScheduleEvent(EVENT_PREFIGHT_2, 3000); break; @@ -155,7 +152,7 @@ public: events2.ScheduleEvent(EVENT_PREFIGHT_3, 3000); break; case EVENT_PREFIGHT_3: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) dalliah->AI()->Talk(SAY_DALLIAH_CONVO_2); events2.ScheduleEvent(EVENT_PREFIGHT_4, 6000); break; @@ -164,7 +161,7 @@ public: events2.ScheduleEvent(EVENT_PREFIGHT_5, 2000); break; case EVENT_PREFIGHT_5: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) dalliah->AI()->Talk(SAY_DALLIAH_CONVO_3); events2.ScheduleEvent(EVENT_PREFIGHT_6, 3000); break; @@ -173,7 +170,7 @@ public: events2.ScheduleEvent(EVENT_PREFIGHT_7, 2000); break; case EVENT_PREFIGHT_7: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) dalliah->GetMotionMaster()->MovePoint(0, 118.6048f, 96.84852f, 22.44115f); events2.ScheduleEvent(EVENT_PREFIGHT_8, 4000); break; @@ -182,7 +179,7 @@ public: events2.ScheduleEvent(EVENT_PREFIGHT_9, 4000); break; case EVENT_PREFIGHT_9: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) { dalliah->SetFacingToObject(me); dalliah->SetImmuneToAll(false); @@ -192,9 +189,6 @@ public: me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 4.725722f); } break; - case EVENT_DALLIAH_DEATH: - Talk(SAY_DALLIAH_DEATH); - break; } if (!UpdateVictim()) @@ -230,14 +224,14 @@ public: me->CastSpell(me, SPELL_FELFIRE, true); break; case EVENT_ME_FIRST: - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) if (dalliah->IsAlive() && !dalliah->IsInCombat()) dalliah->AI()->Talk(SAY_AGGRO_SOCCOTHRATES_FIRST); break; case EVENT_CHECK_HEALTH: if (HealthBelowPct(25)) { - if (Creature* dalliah = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_DALLIAH))) + if (Creature* dalliah = instance->GetCreature(DATA_DALLIAH)) dalliah->AI()->Talk(SAY_SOCCOTHRATES_25_PERCENT); break; } diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp index 45492b0e5..271be09d4 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp @@ -26,6 +26,13 @@ DoorData const doorData[] = { 0, 0, DOOR_TYPE_ROOM } // END }; +ObjectData const creatureData[] = +{ + { NPC_DALLIAH, DATA_DALLIAH }, + { NPC_SOCCOTHRATES, DATA_SOCCOTHRATES }, + { NPC_MELLICHAR, DATA_WARDEN_MELLICHAR } +}; + class instance_arcatraz : public InstanceMapScript { public: @@ -38,22 +45,7 @@ public: SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUTER); LoadDoorData(doorData); - } - - void OnCreatureCreate(Creature* creature) override - { - switch (creature->GetEntry()) - { - case NPC_DALLIAH: - DalliahGUID = creature->GetGUID(); - break; - case NPC_SOCCOTHRATES: - SoccothratesGUID = creature->GetGUID(); - break; - case NPC_MELLICHAR: - MellicharGUID = creature->GetGUID(); - break; - } + LoadObjectData(creatureData, nullptr); } void OnGameObjectCreate(GameObject* go) override @@ -87,19 +79,6 @@ public: } } - void OnGameObjectRemove(GameObject* go) override - { - switch (go->GetEntry()) - { - case GO_CONTAINMENT_CORE_SECURITY_FIELD_ALPHA: - case GO_CONTAINMENT_CORE_SECURITY_FIELD_BETA: - AddDoor(go, false); - break; - default: - break; - } - } - void SetData(uint32 type, uint32 data) override { switch (type) @@ -111,25 +90,16 @@ public: case DATA_WARDEN_5: if (data < FAIL) HandleGameObject(StasisPodGUIDs[type - DATA_WARDEN_1], data == IN_PROGRESS); - if (Creature* warden = instance->GetCreature(MellicharGUID)) + if (Creature* warden = GetCreature(DATA_WARDEN_MELLICHAR)) warden->AI()->SetData(type, data); break; } } - uint32 GetData(uint32 /*type*/) const override - { - return 0; - } - ObjectGuid GetGuidData(uint32 data) const override { switch (data) { - case DATA_DALLIAH: - return DalliahGUID; - case DATA_SOCCOTHRATES: - return SoccothratesGUID; case DATA_WARDENS_SHIELD: return WardensShieldGUID; } @@ -156,10 +126,7 @@ public: } protected: - ObjectGuid DalliahGUID; - ObjectGuid SoccothratesGUID; ObjectGuid StasisPodGUIDs[5]; - ObjectGuid MellicharGUID; ObjectGuid WardensShieldGUID; }; From f33da284166cd6bd3dbf80ecd8a2dd81ecd030d2 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:18:51 -0300 Subject: [PATCH 71/87] =?UTF-8?q?fix(Scripts/Arcatraz):=20Fix=20Zereketh?= =?UTF-8?q?=20Seed=20of=20Corruption=20damage=20and=20mod=E2=80=A6=20(#149?= =?UTF-8?q?80)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rev_1676241465033054300.sql | 5 + .../arcatraz/boss_zereketh_the_unbound.cpp | 133 +++++++++--------- 2 files changed, 73 insertions(+), 65 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1676241465033054300.sql diff --git a/data/sql/updates/pending_db_world/rev_1676241465033054300.sql b/data/sql/updates/pending_db_world/rev_1676241465033054300.sql new file mode 100644 index 000000000..c534b6bd4 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1676241465033054300.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_zereketh_seed_of_corruption'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(36123, 'spell_zereketh_seed_of_corruption'), +(39367, 'spell_zereketh_seed_of_corruption'); diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp index 87044ef71..b36c13978 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp @@ -31,86 +31,89 @@ enum Spells { SPELL_VOID_ZONE = 36119, SPELL_SHADOW_NOVA = 36127, - SPELL_SEED_OF_CORRUPTION = 36123 + SPELL_SEED_OF_CORRUPTION = 36123, + SPELL_CORRUPTION_PROC = 32865 }; -enum Events +struct boss_zereketh_the_unbound : public BossAI { - EVENT_VOID_ZONE = 1, - EVENT_SHADOW_NOVA = 2, - EVENT_SEED_OF_CORRUPTION = 3 -}; - -class boss_zereketh_the_unbound : public CreatureScript -{ -public: - boss_zereketh_the_unbound() : CreatureScript("boss_zereketh_the_unbound") { } - - struct boss_zereketh_the_unboundAI : public BossAI + boss_zereketh_the_unbound(Creature* creature) : BossAI(creature, DATA_ZEREKETH) { - boss_zereketh_the_unboundAI(Creature* creature) : BossAI(creature, DATA_ZEREKETH) { } - - void JustDied(Unit* /*killer*/) override + scheduler.SetValidator([this] { - _JustDied(); - Talk(SAY_DEATH); - } + return !me->HasUnitState(UNIT_STATE_CASTING); + }); + } - void EnterCombat(Unit* /*who*/) override + void JustDied(Unit* /*killer*/) override + { + _JustDied(); + Talk(SAY_DEATH); + } + + void EnterCombat(Unit* /*who*/) override + { + _EnterCombat(); + Talk(SAY_AGGRO); + + scheduler.Schedule(6s, [this](TaskContext context) { - _EnterCombat(); - events.ScheduleEvent(EVENT_VOID_ZONE, 6000); - events.ScheduleEvent(EVENT_SHADOW_NOVA, 10000); - events.ScheduleEvent(EVENT_SEED_OF_CORRUPTION, 16000); - Talk(SAY_AGGRO); - } - - void KilledUnit(Unit* victim) override + DoCastRandomTarget(SPELL_VOID_ZONE, 0, 60.0f); + context.Repeat(15s); + }).Schedule(10s, [this](TaskContext context) { - if (victim->GetTypeId() == TYPEID_PLAYER) - Talk(SAY_SLAY); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + DoCastAOE(SPELL_SHADOW_NOVA); + if (roll_chance_i(50)) { - case EVENT_VOID_ZONE: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 60.0f, true)) - me->CastSpell(target, SPELL_VOID_ZONE, false); - events.ScheduleEvent(EVENT_VOID_ZONE, 15000); - break; - case EVENT_SHADOW_NOVA: - me->CastSpell(me, SPELL_SHADOW_NOVA, false); - if (roll_chance_i(50)) - Talk(SAY_SHADOW_NOVA); - events.ScheduleEvent(EVENT_SHADOW_NOVA, 12000); - break; - case EVENT_SEED_OF_CORRUPTION: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 30.0f, true)) - me->CastSpell(target, SPELL_SEED_OF_CORRUPTION, false); - events.ScheduleEvent(EVENT_SEED_OF_CORRUPTION, 16000); - break; + Talk(SAY_SHADOW_NOVA); } + context.Repeat(12s); + }).Schedule(16s, [this](TaskContext context) + { + DoCastRandomTarget(SPELL_SEED_OF_CORRUPTION, 0, 30.0f); + context.Repeat(16s); + }); + } - DoMeleeAttackIfReady(); - } - }; - - CreatureAI* GetAI(Creature* creature) const override + void KilledUnit(Unit* victim) override { - return GetArcatrazAI(creature); + if (victim->IsPlayer()) + { + Talk(SAY_SLAY); + } + } +}; + +// 36123, 39367 -- Seed of Corruption +class spell_zereketh_seed_of_corruption: public AuraScript +{ + PrepareAuraScript(spell_zereketh_seed_of_corruption); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + return ValidateSpellInfo({ SPELL_CORRUPTION_PROC }); + } + + void HandleProc(AuraEffect const* /*aurEff*/, ProcEventInfo& /*eventInfo*/) + { + PreventDefaultAction(); + uint32 val = GetSpellInfo()->GetEffect(EFFECT_1).BasePoints; + GetTarget()->RemoveAurasDueToSpell(GetSpellInfo()->Id); + + if (GetCaster()) + { + GetCaster()->CastCustomSpell(SPELL_CORRUPTION_PROC, SPELLVALUE_BASE_POINT0, val, GetTarget(), true); + } + } + + void Register() override + { + OnEffectProc += AuraEffectProcFn(spell_zereketh_seed_of_corruption::HandleProc, EFFECT_1, SPELL_AURA_DUMMY); } }; void AddSC_boss_zereketh_the_unbound() { - new boss_zereketh_the_unbound(); + RegisterArcatrazCreatureAI(boss_zereketh_the_unbound); + RegisterSpellScript(spell_zereketh_seed_of_corruption); } From 6354d1598e8d3fe0520bd6e1fa973b1ed3177959 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 23:21:17 +0000 Subject: [PATCH 72/87] chore(DB): import pending files Referenced commit(s): f33da284166cd6bd3dbf80ecd8a2dd81ecd030d2 --- .../rev_1676241465033054300.sql => db_world/2023_02_12_13.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1676241465033054300.sql => db_world/2023_02_12_13.sql} (85%) diff --git a/data/sql/updates/pending_db_world/rev_1676241465033054300.sql b/data/sql/updates/db_world/2023_02_12_13.sql similarity index 85% rename from data/sql/updates/pending_db_world/rev_1676241465033054300.sql rename to data/sql/updates/db_world/2023_02_12_13.sql index c534b6bd4..e14573b37 100644 --- a/data/sql/updates/pending_db_world/rev_1676241465033054300.sql +++ b/data/sql/updates/db_world/2023_02_12_13.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_12 -> 2023_02_12_13 -- DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_zereketh_seed_of_corruption'; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES From 246b20683f631917868fd0f3f120c3e9fcde5369 Mon Sep 17 00:00:00 2001 From: AnchyDev <35346484+AnchyDev@users.noreply.github.com> Date: Mon, 13 Feb 2023 10:42:58 +1100 Subject: [PATCH 73/87] feat(Core/Warden): Allow sending of custom lua payloads through Warden. (#14723) --- src/server/game/Server/WorldSession.cpp | 5 + src/server/game/Server/WorldSession.h | 1 + src/server/game/Warden/Warden.cpp | 7 +- src/server/game/Warden/Warden.h | 9 + src/server/game/Warden/WardenPayloadMgr.cpp | 150 +++++++++ src/server/game/Warden/WardenPayloadMgr.h | 138 ++++++++ src/server/game/Warden/WardenWin.cpp | 346 ++++++++++++++------ src/server/game/Warden/WardenWin.h | 2 + 8 files changed, 559 insertions(+), 99 deletions(-) create mode 100644 src/server/game/Warden/WardenPayloadMgr.cpp create mode 100644 src/server/game/Warden/WardenPayloadMgr.h diff --git a/src/server/game/Server/WorldSession.cpp b/src/server/game/Server/WorldSession.cpp index 2d9fd18bd..90efea5ff 100644 --- a/src/server/game/Server/WorldSession.cpp +++ b/src/server/game/Server/WorldSession.cpp @@ -1297,6 +1297,11 @@ void WorldSession::InitWarden(SessionKey const& k, std::string const& os) } } +Warden* WorldSession::GetWarden() +{ + return &(*_warden); +} + bool WorldSession::DosProtection::EvaluateOpcode(WorldPacket& p, time_t time) const { uint32 maxPacketCounterAllowed = GetMaxPacketCounterAllowed(p.GetOpcode()); diff --git a/src/server/game/Server/WorldSession.h b/src/server/game/Server/WorldSession.h index d4a0478b1..64ce0703f 100644 --- a/src/server/game/Server/WorldSession.h +++ b/src/server/game/Server/WorldSession.h @@ -374,6 +374,7 @@ public: uint32 GetTotalTime() const { return m_total_time; } void InitWarden(SessionKey const&, std::string const& os); + Warden* GetWarden(); /// Session in auth.queue currently void SetInQueue(bool state) { m_inQueue = state; } diff --git a/src/server/game/Warden/Warden.cpp b/src/server/game/Warden/Warden.cpp index 8b53a43dd..3cc6019cb 100644 --- a/src/server/game/Warden/Warden.cpp +++ b/src/server/game/Warden/Warden.cpp @@ -30,7 +30,7 @@ #include "WorldSession.h" Warden::Warden() : _session(nullptr), _checkTimer(10000/*10 sec*/), _clientResponseTimer(0), - _dataSent(false), _module(nullptr), _initialized(false) + _dataSent(false), _module(nullptr), _initialized(false), _interrupted(false), _checkInProgress(false) { memset(_inputKey, 0, sizeof(_inputKey)); memset(_outputKey, 0, sizeof(_outputKey)); @@ -305,6 +305,11 @@ bool Warden::ProcessLuaCheckResponse(std::string const& msg) return true; } +WardenPayloadMgr* Warden::GetPayloadMgr() +{ + return &_payloadMgr; +} + void WorldSession::HandleWardenDataOpcode(WorldPacket& recvData) { if (!_warden || recvData.empty()) diff --git a/src/server/game/Warden/Warden.h b/src/server/game/Warden/Warden.h index db0222c2b..0c2d04a00 100644 --- a/src/server/game/Warden/Warden.h +++ b/src/server/game/Warden/Warden.h @@ -22,6 +22,7 @@ #include "AuthDefines.h" #include "ByteBuffer.h" #include "WardenCheckMgr.h" +#include "WardenPayloadMgr.h" #include enum WardenOpcodes @@ -113,6 +114,8 @@ public: virtual void InitializeModule() = 0; virtual void RequestHash() = 0; virtual void HandleHashResult(ByteBuffer &buff) = 0; + virtual bool IsCheckInProgress() = 0; + virtual void ForceChecks() = 0; virtual void RequestChecks() = 0; virtual void HandleData(ByteBuffer &buff) = 0; bool ProcessLuaCheckResponse(std::string const& msg); @@ -129,8 +132,11 @@ public: // If no check is passed, the default action from config is executed void ApplyPenalty(uint16 checkId, std::string const& reason); + WardenPayloadMgr* GetPayloadMgr(); + private: WorldSession* _session; + WardenPayloadMgr _payloadMgr; uint8 _inputKey[16]; uint8 _outputKey[16]; uint8 _seed[16]; @@ -141,6 +147,9 @@ private: bool _dataSent; ClientWardenModule* _module; bool _initialized; + bool _interrupted; + bool _checkInProgress; + uint32 _interruptCounter = 0; }; #endif diff --git a/src/server/game/Warden/WardenPayloadMgr.cpp b/src/server/game/Warden/WardenPayloadMgr.cpp new file mode 100644 index 000000000..dcb363dba --- /dev/null +++ b/src/server/game/Warden/WardenPayloadMgr.cpp @@ -0,0 +1,150 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#include "WardenPayloadMgr.h" +#include "StringFormat.h" +#include "Errors.h" +#include "Log.h" + +WardenPayloadMgr::WardenPayloadMgr() { } + +uint16 WardenPayloadMgr::GetFreePayloadId() +{ + uint16 payloadId = WardenPayloadOffsetMin; + + while (CachedChecks.find(payloadId) != CachedChecks.end()) + { + payloadId++; + + if (payloadId > WardenPayloadMgr::WardenPayloadOffsetMax) + { + LOG_ERROR("warden", "Max warden payload id of '{}' passed!", WardenPayloadMgr::WardenPayloadOffsetMax); + return 0; + } + } + + return payloadId; +} + +uint16 WardenPayloadMgr::RegisterPayload(const std::string& payload) +{ + uint16 payloadId = GetFreePayloadId(); + + if (!payloadId || !RegisterPayload(payload, payloadId, false)) + { + LOG_ERROR("warden", "Failed to register payload."); + return 0; + } + + return payloadId; +} + +bool WardenPayloadMgr::RegisterPayload(std::string const& payload, uint16 payloadId, bool replace) +{ + //Payload id should be over or equal to the offset to prevent conflicts. + if (payloadId < WardenPayloadMgr::WardenPayloadOffsetMin) + { + LOG_ERROR("warden", "Tried to register payloadId lower than '{}'.", WardenPayloadMgr::WardenPayloadOffsetMin); + return false; + } + + auto it = CachedChecks.find(payloadId); + if (it != CachedChecks.end() && !replace) + { + LOG_ERROR("warden", "Payload Id '{}' already exists in CachedChecks.", payloadId); + return false; + } + + WardenCheck wCheck; + wCheck.Type = WardenPayloadMgr::WardenPayloadCheckType; + wCheck.Str = payload; + wCheck.CheckId = payloadId; + + std::string idStr = Acore::StringFormat("%04u", payloadId); + ASSERT(idStr.size() == 4); + std::copy(idStr.begin(), idStr.end(), wCheck.IdStr.begin()); + + if (replace) + { + CachedChecks.erase(payloadId); + } + + CachedChecks.emplace(payloadId, wCheck); + + return true; +} + +bool WardenPayloadMgr::UnregisterPayload(uint16 payloadId) +{ + return CachedChecks.erase(payloadId); +} + +WardenCheck* WardenPayloadMgr::GetPayloadById(uint16 payloadId) +{ + auto it = CachedChecks.find(payloadId); + + if (it != CachedChecks.end()) + { + return &it->second; + } + + return nullptr; +} + +void WardenPayloadMgr::QueuePayload(uint16 payloadId, bool pushToFront) +{ + auto it = CachedChecks.find(payloadId); + + //Do not queue a payload if there is no payload matching the payloadId. + if (it == CachedChecks.end()) + { + LOG_ERROR("warden", "Failed to queue payload id '{}' as it does not exist in CachedChecks.", payloadId); + return; + } + + if (pushToFront) + { + QueuedPayloads.push_front(payloadId); + } + else + { + QueuedPayloads.push_back(payloadId); + } +} + +bool WardenPayloadMgr::DequeuePayload(uint16 payloadId) +{ + size_t const queueSize = QueuedPayloads.size(); + QueuedPayloads.remove(payloadId); + + return queueSize != QueuedPayloads.size(); +} + +void WardenPayloadMgr::ClearQueuedPayloads() +{ + QueuedPayloads.clear(); +} + +uint32 WardenPayloadMgr::GetPayloadCountInQueue() +{ + return QueuedPayloads.size(); +} + +std::list* WardenPayloadMgr::GetPayloadsInQueue() +{ + return &QueuedPayloads; +} diff --git a/src/server/game/Warden/WardenPayloadMgr.h b/src/server/game/Warden/WardenPayloadMgr.h new file mode 100644 index 000000000..aa7159519 --- /dev/null +++ b/src/server/game/Warden/WardenPayloadMgr.h @@ -0,0 +1,138 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#ifndef _WARDEN_PAYLOAD_MGR_H +#define _WARDEN_PAYLOAD_MGR_H + +#include "WardenCheckMgr.h" +#include + + /** + * @class WardenPayloadMgr + * @brief The WardenPayloadMgr is responsible for maintaining custom payloads used by modules. + * @details This allows users to send custom lua payloads up to a size of 512 bytes to the game client. + * Some of the things you can achieve with this is: + * - Interaction with the client interface (add custom frames) + * - Access to client CVars + * - Access to protected lua functions. + * + * Opening up many possiblilties for a patch-less custom server. + */ +class WardenPayloadMgr +{ +public: + WardenPayloadMgr(); + + /** + * @brief Finds a free payload id in WardenPayloadMgr::CachedChecks. + * @return uint16 The free payload id. Returns 0 if there is no free id. + */ + uint16 GetFreePayloadId(); + + /** + * @brief Register a payload into cache and returns its payload id. + * @param payload The payload to be stored in WardenPayloadMgr::CachedChecks. + * @return uint16 The payload id for use with WardenPayloadMgr::QueuePayload. Returns 0 if it failed to register. + * @note + * - Payloads are truncated to 512 bytes on the client, you may have to register your payloads in chunks if they are larger than this. + */ + uint16 RegisterPayload(const std::string& payload); + + /** + * @brief Register a payload into cache with a custom id and returns the result. + * @param payload The payload to be stored in WardenPayloadMgr::CachedChecks. + * @param payloadId The payload id to be stored as the key in WardenPayloadMgr::CachedChecks. + * @param replace Whether the key should replace an existing entry value. + * @return bool The payload insertion result. If exists it will return false, otherwise true. + * @note + * - Payloads are truncated to 512 bytes on the client, you may have to register your payloads in chunks if they are larger than this. + * - It's a good idea to keep the value for payloadId between 9000-9999 for self defined payloads as they're the least likely occupied ids. + */ + bool RegisterPayload(std::string const& payload, uint16 payloadId, bool replace = false); + + /** + * @brief Unregister a payload from cache and return if successful. + * @param payloadId The payload to removed from WardenPayloadMgr::CachedChecks. + * @return bool If the payloadId was present. + */ + bool UnregisterPayload(uint16 payloadId); + + /** + * @brief Get a payload by id from the WardenPayloadMgr::CachedChecks. + * @param payloadId The payload to fetched from WardenPayloadMgr::CachedChecks. + * @return WardenCheck* A pointer to the WardenCheck payload. + */ + WardenCheck* GetPayloadById(uint16 payloadId); + + /** + * @brief Queue the payload into the normal warden checks. + * @param payloadId The payloadId to be queued. + * @param pushToFront If payload should be pushed to the front queue. + */ + void QueuePayload(uint16 payloadId, bool pushToFront = false); + + /** + * @brief Dequeue the payload from the WardenPayloadMgr::QueuedPayloads queue. + * @param payloadId The payloadId to be dequeued. + * @return bool If the payload was removed. + */ + bool DequeuePayload(uint16 payloadId); + + /** + * @brief Clear the payloads from the WardenPayloadMgr::QueuedPayloads queue. + */ + void ClearQueuedPayloads(); + + /** + * @brief Get the amount of payloads waiting in WardenPayloadMgr::QueuedPayloads. + * @return The amount of payloads in queue. + */ + uint32 GetPayloadCountInQueue(); + + /** + * @brief Get payloads waiting in WardenPayloadMgr::QueuedPayloads. + * @return The payloads in queue. + */ + std::list* GetPayloadsInQueue(); + + /** + * @brief The minimum id available for custom payloads. + */ + static uint16 constexpr WardenPayloadOffsetMin = 5000; + + /** + * @brief The maximum id available for custom payloads. + */ + static uint16 constexpr WardenPayloadOffsetMax = 9999; + + /** + * @brief The checktype used for warden payloads. + */ + static uint32 constexpr WardenPayloadCheckType = 139; + + /** + * @brief The list of currently queued payload ids to be sent through Warden. + */ + std::list QueuedPayloads; + + /** + * @brief The cached payloads that are accessed by payload id. + */ + std::map CachedChecks; +}; + +#endif // _WARDEN_PAYLOAD_MGR_H diff --git a/src/server/game/Warden/WardenWin.cpp b/src/server/game/Warden/WardenWin.cpp index 3aea6b795..36175755d 100644 --- a/src/server/game/Warden/WardenWin.cpp +++ b/src/server/game/Warden/WardenWin.cpp @@ -61,7 +61,18 @@ static uint16 GetCheckPacketSize(WardenCheck const* check) return 0; } - uint16 size = 1 + GetCheckPacketBaseSize(check->Type); // 1 byte check type + uint16 size = 1; + + if (check->CheckId >= WardenPayloadMgr::WardenPayloadOffsetMin && check->Type == LUA_EVAL_CHECK) + { + // Custom payload has no prefix, midfix, postfix. + size = size + (4 + 1); + } + else + { + size = size + GetCheckPacketBaseSize(check->Type); // 1 byte check type + } + if (!check->Str.empty()) { size += (static_cast(check->Str.length()) + 1); // 1 byte string length @@ -239,10 +250,35 @@ void WardenWin::HandleHashResult(ByteBuffer& buff) _initialized = true; } +/** +* @brief Gets the warden check state. +* @return The warden check state. +*/ +bool WardenWin::IsCheckInProgress() +{ + return _checkInProgress; +} + +/** +* @brief Force call RequestChecks() so they are sent immediately, this interrupts warden and breaks result. +*/ +void WardenWin::ForceChecks() +{ + if (_dataSent) + { + _interrupted = true; + _interruptCounter++; + } + + RequestChecks(); +} + void WardenWin::RequestChecks() { LOG_DEBUG("warden", "Request data"); + _checkInProgress = true; + // If all checks were done, fill the todo list again for (uint8 i = 0; i < MAX_WARDEN_CHECK_TYPES; ++i) { @@ -253,6 +289,30 @@ void WardenWin::RequestChecks() _serverTicks = GameTime::GetGameTimeMS().count(); _CurrentChecks.clear(); + // Erase any nullptrs. + Acore::Containers::EraseIf(_PendingChecks, + [this](uint16 id) + { + WardenCheck const* check = sWardenCheckMgr->GetWardenDataById(id); + + // Custom payload should be loaded in if equal to over offset. + if (!check && id >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + if (_payloadMgr.CachedChecks.find(id) != _payloadMgr.CachedChecks.end()) + { + check = &_payloadMgr.CachedChecks.at(id); + } + } + + if (!check) + { + return true; + } + + return false; + } + ); + // No pending checks if (_PendingChecks.empty()) { @@ -266,6 +326,19 @@ void WardenWin::RequestChecks() break; } + // Load in any custom payloads if available. + if (checkType == WARDEN_CHECK_LUA_TYPE && !_payloadMgr.QueuedPayloads.empty()) + { + uint16 payloadId = _payloadMgr.QueuedPayloads.front(); + + LOG_DEBUG("warden", "Adding custom warden payload '{}' to CurrentChecks.", payloadId); + + _payloadMgr.QueuedPayloads.pop_front(); + _CurrentChecks.push_front(payloadId); + + continue; + } + // Get check id from the end and remove it from todo uint16 const id = _ChecksTodo[checkType].back(); _ChecksTodo[checkType].pop_back(); @@ -288,6 +361,13 @@ void WardenWin::RequestChecks() for (uint16 const checkId : _PendingChecks) { WardenCheck const* check = sWardenCheckMgr->GetWardenDataById(checkId); + + // Custom payload should be loaded in if equal to over offset. + if (!check && checkId >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + check = &_payloadMgr.CachedChecks.at(checkId); + } + if (!hasLuaChecks && check->Type == LUA_EVAL_CHECK) { hasLuaChecks = true; @@ -324,7 +404,21 @@ void WardenWin::RequestChecks() Acore::Containers::EraseIf(_CurrentChecks, [this, &expectedSize](uint16 id) { - uint16 const thisSize = GetCheckPacketSize(sWardenCheckMgr->GetWardenDataById(id)); + WardenCheck const* check = sWardenCheckMgr->GetWardenDataById(id); + + // Custom payload should be loaded in if equal to over offset. + if (!check && id >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + check = &_payloadMgr.CachedChecks.at(id); + } + + // Remove nullptr if it snuck in from earlier check. + if (!check) + { + return true; + } + + uint16 const thisSize = GetCheckPacketSize(check); if ((expectedSize + thisSize) > 500) // warden packets are truncated to 512 bytes clientside { _PendingChecks.push_back(id); @@ -341,6 +435,18 @@ void WardenWin::RequestChecks() for (uint16 const checkId : _CurrentChecks) { WardenCheck const* check = sWardenCheckMgr->GetWardenDataById(checkId); + + // Custom payloads do not have prefix, midfix, postfix. + if (!check && checkId >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + check = &_payloadMgr.CachedChecks.at(checkId); + + buff << uint8(check->Str.size()); + buff.append(check->Str.data(), check->Str.size()); + + continue; + } + switch (check->Type) { case LUA_EVAL_CHECK: @@ -374,6 +480,13 @@ void WardenWin::RequestChecks() for (uint16 const checkId : _CurrentChecks) { WardenCheck const* check = sWardenCheckMgr->GetWardenDataById(checkId); + + // Custom payload should be loaded in if equal to over offset. + if (!check && checkId >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + check = &_payloadMgr.CachedChecks.at(checkId); + } + buff << uint8(check->Type ^ xorByte); switch (check->Type) { @@ -448,63 +561,72 @@ void WardenWin::RequestChecks() void WardenWin::HandleData(ByteBuffer& buff) { - LOG_DEBUG("warden", "Handle data"); - - _dataSent = false; - _clientResponseTimer = 0; - - uint16 Length; - buff >> Length; - uint32 Checksum; - buff >> Checksum; - - if (Length != (buff.size() - buff.rpos())) + if (!_interrupted) { - buff.rfinish(); - ApplyPenalty(0, "Failed size checks in HandleData"); - return; - } + LOG_DEBUG("warden", "Handle data"); - if (!IsValidCheckSum(Checksum, buff.contents() + buff.rpos(), Length)) - { - buff.rpos(buff.wpos()); - LOG_DEBUG("warden", "CHECKSUM FAIL"); - ApplyPenalty(0, "Failed checksum in HandleData"); - return; - } + _dataSent = false; + _clientResponseTimer = 0; - // TIMING_CHECK - { - uint8 result; - buff >> result; - /// @todo: test it. - if (result == 0x00) + uint16 Length; + buff >> Length; + uint32 Checksum; + buff >> Checksum; + + if (Length != (buff.size() - buff.rpos())) { - LOG_DEBUG("warden", "TIMING CHECK FAIL result 0x00"); - // ApplyPenalty(0, "TIMING CHECK FAIL result"); Commented out because of too many false postives. Mostly caused by client stutter. + buff.rfinish(); + ApplyPenalty(0, "Failed size checks in HandleData"); return; } - uint32 newClientTicks; - buff >> newClientTicks; - - uint32 ticksNow = GameTime::GetGameTimeMS().count(); - uint32 ourTicks = newClientTicks + (ticksNow - _serverTicks); - - LOG_DEBUG("warden", "ServerTicks {}", ticksNow); // Now - LOG_DEBUG("warden", "RequestTicks {}", _serverTicks); // At request - LOG_DEBUG("warden", "Ticks {}", newClientTicks); // At response - LOG_DEBUG("warden", "Ticks diff {}", ourTicks - newClientTicks); - } - - uint16 checkFailed = 0; - - for (uint16 const checkId : _CurrentChecks) - { - WardenCheck const* rd = sWardenCheckMgr->GetWardenDataById(checkId); - uint8 const type = rd->Type; - switch (type) + if (!IsValidCheckSum(Checksum, buff.contents() + buff.rpos(), Length)) { + buff.rpos(buff.wpos()); + LOG_DEBUG("warden", "CHECKSUM FAIL"); + ApplyPenalty(0, "Failed checksum in HandleData"); + return; + } + + // TIMING_CHECK + { + uint8 result; + buff >> result; + /// @todo: test it. + if (result == 0x00) + { + LOG_DEBUG("warden", "TIMING CHECK FAIL result 0x00"); + // ApplyPenalty(0, "TIMING CHECK FAIL result"); Commented out because of too many false postives. Mostly caused by client stutter. + return; + } + + uint32 newClientTicks; + buff >> newClientTicks; + + uint32 ticksNow = GameTime::GetGameTimeMS().count(); + uint32 ourTicks = newClientTicks + (ticksNow - _serverTicks); + + LOG_DEBUG("warden", "ServerTicks {}", ticksNow); // Now + LOG_DEBUG("warden", "RequestTicks {}", _serverTicks); // At request + LOG_DEBUG("warden", "Ticks {}", newClientTicks); // At response + LOG_DEBUG("warden", "Ticks diff {}", ourTicks - newClientTicks); + } + + uint16 checkFailed = 0; + + for (uint16 const checkId : _CurrentChecks) + { + WardenCheck const* rd = sWardenCheckMgr->GetWardenDataById(checkId); + + // Custom payload should be loaded in if equal to over offset. + if (!rd && checkId >= WardenPayloadMgr::WardenPayloadOffsetMin) + { + rd = &_payloadMgr.CachedChecks.at(checkId); + } + + uint8 const type = rd->Type; + switch (type) + { case MEM_CHECK: { uint8 Mem_Result; @@ -536,78 +658,106 @@ void WardenWin::HandleData(ByteBuffer& buff) case PAGE_CHECK_B: case DRIVER_CHECK: case MODULE_CHECK: + { + uint8 const byte = 0xE9; + if (memcmp(buff.contents() + buff.rpos(), &byte, sizeof(uint8)) != 0) { - const uint8 byte = 0xE9; - if (memcmp(buff.contents() + buff.rpos(), &byte, sizeof(uint8)) != 0) + if (type == PAGE_CHECK_A || type == PAGE_CHECK_B) { - if (type == PAGE_CHECK_A || type == PAGE_CHECK_B) - LOG_DEBUG("warden", "RESULT PAGE_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); - - if (type == MODULE_CHECK) - LOG_DEBUG("warden", "RESULT MODULE_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); - - if (type == DRIVER_CHECK) - LOG_DEBUG("warden", "RESULT DRIVER_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); - checkFailed = checkId; - buff.rpos(buff.rpos() + 1); - continue; + LOG_DEBUG("warden", "RESULT PAGE_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); } - buff.rpos(buff.rpos() + 1); + if (type == MODULE_CHECK) + { + LOG_DEBUG("warden", "RESULT MODULE_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); + } - if (type == PAGE_CHECK_A || type == PAGE_CHECK_B) - LOG_DEBUG("warden", "RESULT PAGE_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); - else if (type == MODULE_CHECK) - LOG_DEBUG("warden", "RESULT MODULE_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); - else if (type == DRIVER_CHECK) - LOG_DEBUG("warden", "RESULT DRIVER_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); + if (type == DRIVER_CHECK) + { + LOG_DEBUG("warden", "RESULT DRIVER_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); + } + + checkFailed = checkId; + buff.rpos(buff.rpos() + 1); + continue; + } + + buff.rpos(buff.rpos() + 1); + + if (type == PAGE_CHECK_A || type == PAGE_CHECK_B) + { + LOG_DEBUG("warden", "RESULT PAGE_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); + } + else if (type == MODULE_CHECK) + { + LOG_DEBUG("warden", "RESULT MODULE_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); + } + else if (type == DRIVER_CHECK) + { + LOG_DEBUG("warden", "RESULT DRIVER_CHECK passed CheckId {} account Id {}", checkId, _session->GetAccountId()); + } break; } case LUA_EVAL_CHECK: { uint8 const result = buff.read(); + if (result == 0) { buff.read_skip(buff.read()); // discard attached string } LOG_DEBUG("warden", "LUA_EVAL_CHECK CheckId {} account Id {} got in-warden dummy response", checkId, _session->GetAccountId()/* , result */); - break; - } + break; + } case MPQ_CHECK: + { + uint8 Mpq_Result; + buff >> Mpq_Result; + + if (Mpq_Result != 0) { - uint8 Mpq_Result; - buff >> Mpq_Result; - - if (Mpq_Result != 0) - { - LOG_DEBUG("warden", "RESULT MPQ_CHECK not 0x00 account id {}", _session->GetAccountId()); - checkFailed = checkId; - continue; - } - - WardenCheckResult const* rs = sWardenCheckMgr->GetWardenResultById(checkId); - if (memcmp(buff.contents() + buff.rpos(), rs->Result.ToByteArray<20>(false).data(), Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES) != 0) // SHA1 - { - LOG_DEBUG("warden", "RESULT MPQ_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); - checkFailed = checkId; - buff.rpos(buff.rpos() + Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES); // 20 bytes SHA1 - continue; - } - - buff.rpos(buff.rpos() + Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES); // 20 bytes SHA1 - LOG_DEBUG("warden", "RESULT MPQ_CHECK passed, CheckId {} account Id {}", checkId, _session->GetAccountId()); - break; + LOG_DEBUG("warden", "RESULT MPQ_CHECK not 0x00 account id {}", _session->GetAccountId()); + checkFailed = checkId; + continue; } + + WardenCheckResult const* rs = sWardenCheckMgr->GetWardenResultById(checkId); + if (memcmp(buff.contents() + buff.rpos(), rs->Result.ToByteArray<20>(false).data(), Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES) != 0) // SHA1 + { + LOG_DEBUG("warden", "RESULT MPQ_CHECK fail, CheckId {} account Id {}", checkId, _session->GetAccountId()); + checkFailed = checkId; + buff.rpos(buff.rpos() + Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES); // 20 bytes SHA1 + continue; + } + + buff.rpos(buff.rpos() + Acore::Crypto::Constants::SHA1_DIGEST_LENGTH_BYTES); // 20 bytes SHA1 + LOG_DEBUG("warden", "RESULT MPQ_CHECK passed, CheckId {} account Id {}", checkId, _session->GetAccountId()); + break; + } + } + } + + if (checkFailed > 0) + { + ApplyPenalty(checkFailed, ""); } } - - if (checkFailed > 0) + else { - ApplyPenalty(checkFailed, ""); + LOG_DEBUG("warden", "Warden was interrupted by ForceChecks, ignoring results."); + + _interruptCounter--; + + if (_interruptCounter == 0) + { + _interrupted = false; + } } // Set hold off timer, minimum timer should at least be 1 second uint32 const holdOff = sWorld->getIntConfig(CONFIG_WARDEN_CLIENT_CHECK_HOLDOFF); _checkTimer = (holdOff < 1 ? 1 : holdOff) * IN_MILLISECONDS; + + _checkInProgress = false; } diff --git a/src/server/game/Warden/WardenWin.h b/src/server/game/Warden/WardenWin.h index a079fa56b..fa6b72b61 100644 --- a/src/server/game/Warden/WardenWin.h +++ b/src/server/game/Warden/WardenWin.h @@ -81,6 +81,8 @@ public: void RequestHash() override; void HandleHashResult(ByteBuffer& buff) override; void RequestChecks() override; + bool IsCheckInProgress() override; + void ForceChecks() override; void HandleData(ByteBuffer& buff) override; private: From deb7e190c5477da3ca019496a2b6bc1b90e2365a Mon Sep 17 00:00:00 2001 From: NinjaPleezAC <121171014+NinjaPleezAC@users.noreply.github.com> Date: Sun, 12 Feb 2023 15:48:58 -0800 Subject: [PATCH 74/87] fix(CORE/Spell): Book of the Dead unequip fix (#14839) --- src/server/game/Entities/Player/Player.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 96e82f1e1..d5c99078b 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -7006,7 +7006,11 @@ void Player::ApplyItemEquipSpell(Item* item, bool apply, bool form_change) continue; // Spells that should stay on the caster after removing the item. - constexpr std::array spellExceptions = { /*Electromagnetic Gigaflux Reactivator*/ 11826 }; + constexpr std::array spellExceptions = + { + 11826, //Electromagnetic Gigaflux Reactivator + 17490 //Book of the Dead - Summon Skeleton + }; const auto found = std::find(std::begin(spellExceptions), std::end(spellExceptions), spellData.SpellId); // wrong triggering type From 9f149b8072ced70dd1852b697e26e6dc95f8f57e Mon Sep 17 00:00:00 2001 From: Mathematical Shitpost Emissary Date: Sun, 12 Feb 2023 18:49:27 -0500 Subject: [PATCH 75/87] fix(DB/Creature): Rakoria RP event (#14796) --- .../pending_db_world/rev_1675035967923856800.sql | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675035967923856800.sql diff --git a/data/sql/updates/pending_db_world/rev_1675035967923856800.sql b/data/sql/updates/pending_db_world/rev_1675035967923856800.sql new file mode 100644 index 000000000..805f293b6 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675035967923856800.sql @@ -0,0 +1,15 @@ +-- + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 18385; + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 18385) AND (`source_type` = 0) AND (`id` IN (0)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18385, 0, 0, 0, 20, 0, 100, 0, 10201, 0, 0, 0, 0, 80, 1838500, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - On Quest \'And Now, the Moment of Truth\' Finished - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 1838500) AND (`source_type` = 9) AND (`id` IN (0, 1, 2, 3, 4)); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1838500, 9, 0, 0, 0, 0, 100, 0, 100, 100, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - Actionlist - Play Emote 11'), +(1838500, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - Actionlist - Say Line 0'), +(1838500, 9, 2, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - Actionlist - Play Emote 11'), +(1838500, 9, 3, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - Actionlist - Say Line 1'), +(1838500, 9, 4, 0, 0, 0, 100, 0, 100, 100, 0, 0, 0, 5, 29, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Rakoria - Actionlist - Play Emote 29'); From 2eb1c212167fd330ec035faa08cee7b38862b0d2 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Sun, 12 Feb 2023 23:51:49 +0000 Subject: [PATCH 76/87] chore(DB): import pending files Referenced commit(s): 9f149b8072ced70dd1852b697e26e6dc95f8f57e --- .../rev_1675035967923856800.sql => db_world/2023_02_12_14.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1675035967923856800.sql => db_world/2023_02_12_14.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1675035967923856800.sql b/data/sql/updates/db_world/2023_02_12_14.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1675035967923856800.sql rename to data/sql/updates/db_world/2023_02_12_14.sql index 805f293b6..d03e6c831 100644 --- a/data/sql/updates/pending_db_world/rev_1675035967923856800.sql +++ b/data/sql/updates/db_world/2023_02_12_14.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_13 -> 2023_02_12_14 -- UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 18385; From 8a39bd050ae7bf9d4f33cfed5169998fe3706192 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:53:20 -0300 Subject: [PATCH 77/87] feat(Core/SAI): Implement SMART_TARGET_INSTANCE_STORAGE (#14981) --- .../game/AI/SmartScripts/SmartScript.cpp | 27 +++++++++++++++++++ .../game/AI/SmartScripts/SmartScriptMgr.cpp | 10 +++++++ .../game/AI/SmartScripts/SmartScriptMgr.h | 7 +++++ 3 files changed, 44 insertions(+) diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index b48d2fb61..ac51d079a 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -3367,6 +3367,33 @@ void SmartScript::GetTargets(ObjectVector& targets, SmartScriptHolder const& e, } break; } + case SMART_TARGET_INSTANCE_STORAGE: + { + if (InstanceScript* instance = GetBaseObject()->GetInstanceScript()) + { + if (e.target.instanceStorage.type == 1) + { + if (Creature* creature = instance->GetCreature(e.target.instanceStorage.index)) + { + targets.push_back(creature); + } + } + else if (e.target.instanceStorage.type == 2) + { + if (GameObject* go = instance->GetGameObject(e.target.instanceStorage.index)) + { + targets.push_back(go); + } + } + } + else + { + LOG_ERROR("scripts.ai.sai", "SMART_TARGET_INSTANCE_STORAGE: Entry {} SourceType {} Event {} Action {} Target {} called outside an instance map.", + e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.GetTargetType()); + } + + break; + } case SMART_TARGET_NONE: case SMART_TARGET_POSITION: default: diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp index d3d2332ee..5bd1e9494 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp @@ -422,6 +422,16 @@ bool SmartAIMgr::IsTargetValid(SmartScriptHolder const& e) } break; } + case SMART_TARGET_INSTANCE_STORAGE: + { + if (e.target.instanceStorage.type != 1 && e.target.instanceStorage.type != 2) + { + LOG_ERROR("sql.sql", "SmartAIMgr: Entry {} SourceType {} Event {} Action {} has invalid instance storage type as target ({}).", + e.entryOrGuid, e.GetScriptType(), e.GetEventType(), e.GetActionType(), e.target.instanceStorage.type); + return false; + } + break; + } case SMART_TARGET_HOSTILE_SECOND_AGGRO: case SMART_TARGET_HOSTILE_LAST_AGGRO: case SMART_TARGET_HOSTILE_RANDOM: diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h index 0fc4c2c97..65e43fe2d 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h @@ -1426,6 +1426,7 @@ enum SMARTAI_TARGETS SMART_TARGET_RANDOM_POINT = 202, // range, amount (for summoning creature), self als middle (0/1) else use xyz SMART_TARGET_ROLE_SELECTION = 203, // Range Max, TargetMask (Tanks (1), Healer (2) Damage (4)), resize list SMART_TARGET_SUMMONED_CREATURES = 204, // Entry + SMART_TARGET_INSTANCE_STORAGE = 205, // Instance data index, Type (creature (1), gameobject (2)) SMART_TARGET_AC_END = 205 // placeholder }; @@ -1595,6 +1596,12 @@ struct SmartTarget uint32 param3; uint32 param4; } raw; + + struct + { + uint32 index; + uint32 type; + } instanceStorage; }; }; From 1edd29f28a0ed45464f4569a7b5c5a177c4b9f35 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:53:48 -0300 Subject: [PATCH 78/87] refactor(Scripts/TempleOfAhnQiraj): Clean up unused variables (#14979) --- .../Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp | 5 - .../instance_temple_of_ahnqiraj.cpp | 99 +++++-------------- .../TempleOfAhnQiraj/temple_of_ahnqiraj.cpp | 23 +++++ .../TempleOfAhnQiraj/temple_of_ahnqiraj.h | 1 - 4 files changed, 48 insertions(+), 80 deletions(-) diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp index a9fd30bc5..750377820 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp @@ -163,9 +163,6 @@ struct boss_eye_of_cthun : public BossAI me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE); me->SetVisible(true); - //Reset Phase - instance->SetData(DATA_CTHUN_PHASE, PHASE_NOT_STARTED); - //to avoid having a following void zone Creature* pPortal = me->FindNearestCreature(NPC_CTHUN_PORTAL, 10); if (pPortal) @@ -544,8 +541,6 @@ struct boss_cthun : public BossAI { eye->DespawnOrUnsummon(); } - - instance->SetData(DATA_CTHUN_PHASE, PHASE_CTHUN_DONE); } void SummonedCreatureDies(Creature* creature, Unit* /*killer*/) override diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp index f18981d13..ed1299f65 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp @@ -24,18 +24,18 @@ ObjectData const creatureData[] = { - { NPC_VEM, DATA_VEM }, - { NPC_KRI, DATA_KRI }, - { NPC_YAUJ, DATA_YAUJ }, - { NPC_SARTURA, DATA_SARTURA }, - { NPC_CTHUN, DATA_CTHUN }, + { NPC_VEM, DATA_VEM }, + { NPC_KRI, DATA_KRI }, + { NPC_YAUJ, DATA_YAUJ }, + { NPC_SARTURA, DATA_SARTURA }, + { NPC_CTHUN, DATA_CTHUN }, { NPC_EYE_OF_CTHUN, DATA_EYE_OF_CTHUN }, - { NPC_OURO, DATA_OURO }, + { NPC_OURO, DATA_OURO }, { NPC_OURO_SPAWNER, DATA_OURO_SPAWNER }, - { NPC_MASTERS_EYE, DATA_MASTERS_EYE }, - { NPC_VEKLOR, DATA_VEKLOR }, - { NPC_VEKNILASH, DATA_VEKNILASH }, - { NPC_VISCIDUS, DATA_VISCIDUS } + { NPC_MASTERS_EYE, DATA_MASTERS_EYE }, + { NPC_VEKLOR, DATA_VEKLOR }, + { NPC_VEKNILASH, DATA_VEKNILASH }, + { NPC_VISCIDUS, DATA_VISCIDUS } }; DoorData const doorData[] = @@ -66,28 +66,15 @@ public: LoadDoorData(doorData); } - ObjectGuid SkeramGUID; - ObjectGuid CThunGUID; - GuidVector CThunGraspGUIDs; - - uint32 BugTrioDeathCount; - uint32 CthunPhase; - - TaskScheduler scheduler; - void Initialize() override { BugTrioDeathCount = 0; - CthunPhase = 0; } void OnCreatureCreate(Creature* creature) override { switch (creature->GetEntry()) { - case NPC_SKERAM: - SkeramGUID = creature->GetGUID(); - break; case NPC_OURO_SPAWNER: if (GetBossState(DATA_OURO) != DONE) creature->Respawn(); @@ -97,7 +84,6 @@ public: creature->Respawn(true); break; case NPC_CTHUN: - CThunGUID = creature->GetGUID(); if (!creature->IsAlive()) { for (ObjectGuid const& guid : CThunGraspGUIDs) @@ -122,7 +108,7 @@ public: { case GO_CTHUN_GRASP: CThunGraspGUIDs.push_back(go->GetGUID()); - if (Creature* CThun = instance->GetCreature(CThunGUID)) + if (Creature* CThun = GetCreature(DATA_CTHUN)) { if (!CThun->IsAlive()) { @@ -163,6 +149,15 @@ public: } } break; + case NPC_CTHUN: + for (ObjectGuid const& guid : CThunGraspGUIDs) + { + if (GameObject* cthunGrasp = instance->GetGameObject(guid)) + { + cthunGrasp->DespawnOrUnsummon(1s); + } + } + break; default: break; } @@ -174,23 +169,10 @@ public: { case DATA_BUG_TRIO_DEATH: return BugTrioDeathCount; - - case DATA_CTHUN_PHASE: - return CthunPhase; } return 0; } - ObjectGuid GetGuidData(uint32 identifier) const override - { - switch (identifier) - { - case DATA_SKERAM: - return SkeramGUID; - } - return ObjectGuid::Empty; - } - void SetData(uint32 type, uint32 data) override { switch (type) @@ -201,19 +183,6 @@ public: else BugTrioDeathCount = 0; break; - case DATA_CTHUN_PHASE: - CthunPhase = data; - if (data == PHASE_CTHUN_DONE) - { - for (ObjectGuid const& guid : CThunGraspGUIDs) - { - if (GameObject* cthunGrasp = instance->GetGameObject(guid)) - { - cthunGrasp->DespawnOrUnsummon(1s); - } - } - } - break; default: break; } @@ -244,33 +213,15 @@ public: { scheduler.Update(diff); } + + private: + GuidVector CThunGraspGUIDs; + uint32 BugTrioDeathCount; + TaskScheduler scheduler; }; }; -// 4052, At Battleguard Sartura -class at_battleguard_sartura : public AreaTriggerScript -{ -public: - at_battleguard_sartura() : AreaTriggerScript("at_battleguard_sartura") { } - - bool OnTrigger(Player* player, const AreaTrigger* /*at*/) override - { - if (InstanceScript* instance = player->GetInstanceScript()) - { - if (Creature* sartura = instance->GetCreature(DATA_SARTURA)) - { - if (sartura->IsAlive()) - { - sartura->SetInCombatWith(player); - } - } - } - return true; - } -}; - void AddSC_instance_temple_of_ahnqiraj() { new instance_temple_of_ahnqiraj(); - new at_battleguard_sartura(); } diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.cpp index 532c1c5f9..472e8b567 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.cpp @@ -572,6 +572,28 @@ class spell_nullify : public AuraScript } }; +// 4052, At Battleguard Sartura +class at_battleguard_sartura : public AreaTriggerScript +{ +public: + at_battleguard_sartura() : AreaTriggerScript("at_battleguard_sartura") { } + + bool OnTrigger(Player* player, const AreaTrigger* /*at*/) override + { + if (InstanceScript* instance = player->GetInstanceScript()) + { + if (Creature* sartura = instance->GetCreature(DATA_SARTURA)) + { + if (sartura->IsAlive()) + { + sartura->SetInCombatWith(player); + } + } + } + return true; + } +}; + void AddSC_temple_of_ahnqiraj() { RegisterTempleOfAhnQirajCreatureAI(npc_anubisath_defender); @@ -582,4 +604,5 @@ void AddSC_temple_of_ahnqiraj() RegisterTempleOfAhnQirajCreatureAI(npc_ahnqiraji_critter); RegisterSpellScript(spell_aggro_drones); RegisterSpellScript(spell_nullify); + new at_battleguard_sartura(); } diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h index 916b996cf..415929f4c 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h @@ -44,7 +44,6 @@ enum DataTypes DATA_OURO_SPAWNER = 14, DATA_VEKLOR = 15, DATA_VEKNILASH = 16, - DATA_CTHUN_PHASE = 17, DATA_EYE_OF_CTHUN = 18, DATA_MASTERS_EYE = 19 }; From af8a927d850dde23582e3ee08e61c36b9bbbd43b Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:54:37 -0300 Subject: [PATCH 79/87] fix(Scripts/Ulduar): Fix Stormcaller Brundir flying under texture (#14940) --- .../Ulduar/Ulduar/boss_assembly_of_iron.cpp | 30 ++++++++----------- 1 file changed, 12 insertions(+), 18 deletions(-) diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp index 30fb59018..9ebce4506 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp @@ -101,6 +101,7 @@ enum eEnums EVENT_LIGHTNING_TENDRILS = 24, EVENT_LIGHTNING_LAND = 25, EVENT_LAND_LAND = 26, + EVENT_LIGHTNING_FLIGHT = 27, EVENT_ENRAGE = 30 }; @@ -611,7 +612,6 @@ public: EventMap events; InstanceScript* pInstance; uint32 _phase; - bool _flyPhase; ObjectGuid _flyTargetGUID; uint32 _channelTimer; @@ -624,7 +624,6 @@ public: _channelTimer = 0; _phase = 0; - _flyPhase = false; _flyTargetGUID.Clear(); _stunnedAchievement = true; @@ -754,19 +753,6 @@ public: if (!UpdateVictim()) return; - if (_flyPhase) - { - if (Unit* flyTarget = ObjectAccessor::GetUnit(*me, _flyTargetGUID)) - { - if (me->GetDistance2d(flyTarget) >= 6) - { - //float speed = me->GetDistance(_flyTarget->GetPositionX(), _flyTarget->GetPositionY(), _flyTarget->GetPositionZ()+15) / (1500.0f * 0.001f); - me->SendMonsterMove(flyTarget->GetPositionX(), flyTarget->GetPositionY(), flyTarget->GetPositionZ() + 15, 1500, SPLINEFLAG_FLYING); - me->SetPosition(flyTarget->GetPositionX(), flyTarget->GetPositionY(), flyTarget->GetPositionZ(), flyTarget->GetOrientation()); - } - } - } - events.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) return; @@ -796,34 +782,34 @@ public: events.DelayEvents(18000); Talk(SAY_BRUNDIR_FLIGHT); - _flyPhase = true; Unit* oldVictim = me->GetVictim(); _flyTargetGUID = oldVictim->GetGUID(); me->SetRegeneratingHealth(false); me->SetDisableGravity(true); + me->SetHover(true); me->CombatStop(); me->StopMoving(); me->SetReactState(REACT_PASSIVE); me->SetGuidValue(UNIT_FIELD_TARGET, ObjectGuid::Empty); me->SetUnitFlag(UNIT_FLAG_STUNNED); - me->SendMonsterMove(oldVictim->GetPositionX(), oldVictim->GetPositionY(), oldVictim->GetPositionZ() + 15, 1500, SPLINEFLAG_FLYING); me->CastSpell(me, SPELL_LIGHTNING_TENDRILS, true); me->CastSpell(me, 61883, true); events.ScheduleEvent(EVENT_LIGHTNING_LAND, 16000); + events.ScheduleEvent(EVENT_LIGHTNING_FLIGHT, 1s); break; } case EVENT_LIGHTNING_LAND: { float speed = me->GetDistance(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()) / (1000.0f * 0.001f); me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), speed); - _flyPhase = false; events.ScheduleEvent(EVENT_LAND_LAND, 1000); break; } case EVENT_LAND_LAND: me->SetCanFly(false); + me->SetHover(false); me->SetReactState(REACT_AGGRESSIVE); me->SetDisableGravity(false); if (Unit* flyTarget = ObjectAccessor::GetUnit(*me, _flyTargetGUID)) @@ -836,11 +822,19 @@ public: me->RemoveAura(SPELL_LIGHTNING_TENDRILS); me->RemoveAura(61883); DoResetThreatList(); + events.CancelEvent(EVENT_LIGHTNING_FLIGHT); break; case EVENT_ENRAGE: Talk(SAY_BRUNDIR_BERSERK); me->CastSpell(me, SPELL_BERSERK, true); break; + case EVENT_LIGHTNING_FLIGHT: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 0.0f, true)) + { + me->GetMotionMaster()->MovePoint(0, *target); + } + events.ScheduleEvent(EVENT_LIGHTNING_FLIGHT, 6s); + break; } DoMeleeAttackIfReady(); From 1694eec25227c9d7ed44fc91b4bdf018bd9665de Mon Sep 17 00:00:00 2001 From: TuriansNotBad <54774532+TuriansNotBad@users.noreply.github.com> Date: Mon, 13 Feb 2023 04:56:07 +0500 Subject: [PATCH 80/87] fix(DB/Quest): Report to Goldshire RP. (#14813) --- .../pending_db_world/rev_1675168500421561700.sql | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1675168500421561700.sql diff --git a/data/sql/updates/pending_db_world/rev_1675168500421561700.sql b/data/sql/updates/pending_db_world/rev_1675168500421561700.sql new file mode 100644 index 000000000..b9666fd48 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1675168500421561700.sql @@ -0,0 +1,11 @@ +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 197; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 19700); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19700, 9, 0, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 0, 5, 66, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Marshal McBride - Timed Actionlist - Salute'), +(19700, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Marshal McBride - Timed Actionlist - Talk "You are dismissed"'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 197); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(197, 0, 0, 1, 19, 0, 100, 0, 54, 0, 0, 0, 0, 11, 6245, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 'Marshal McBride - On Quest \'Report to Goldshire\' Taken - Cast Force Target Salute (6245)'), +(197, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 80, 19700, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Marshal McBride - On Quest \'Report to Goldshire\' Taken - After 2 seconds salute back and say line'); From 35e993edc7e10c21c1d937cfa7389ed8203a704d Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:57:53 -0300 Subject: [PATCH 81/87] =?UTF-8?q?fix(Scripts/Spells):=20Prevent=20Omen=20o?= =?UTF-8?q?f=20Clarity=20from=20procing=20from=20crafti=E2=80=A6=20(#14910?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/scripts/Spells/spell_druid.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/server/scripts/Spells/spell_druid.cpp b/src/server/scripts/Spells/spell_druid.cpp index 5f17b9633..5cc847ba0 100644 --- a/src/server/scripts/Spells/spell_druid.cpp +++ b/src/server/scripts/Spells/spell_druid.cpp @@ -207,6 +207,12 @@ class spell_dru_omen_of_clarity : public AuraScript return false; } + // Don't proc on crafting items. + if (spellInfo->HasEffect(SPELL_EFFECT_CREATE_ITEM)) + { + return false; + } + if (eventInfo.GetTypeMask() & PROC_FLAG_DONE_SPELL_MELEE_DMG_CLASS) { return spellInfo->HasAttribute(SPELL_ATTR0_ON_NEXT_SWING) || spellInfo->HasAttribute(SPELL_ATTR0_ON_NEXT_SWING_NO_DAMAGE); From 2da4f1ab05781d987a9340b748260d7d70bb72f2 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:58:32 -0300 Subject: [PATCH 82/87] fix(Scripts/HellfireRamparts): Omor the Unscarred shouldn't move (#14751) --- .../HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp index 22ee02767..3c3973c50 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp @@ -55,6 +55,7 @@ public: { boss_omor_the_unscarredAI(Creature* creature) : BossAI(creature, DATA_OMOR_THE_UNSCARRED) { + SetCombatMovement(false); } void Reset() override From 3b178666137eabf56ecdfc547db4179ef08ea38b Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 20:59:40 -0300 Subject: [PATCH 83/87] fix(Scripts/Karazhan): Rework Attumen & Midnight (#14756) --- .../rev_1674942757744333000.sql | 55 ++ .../Karazhan/boss_midnight.cpp | 688 +++++++++--------- .../Karazhan/instance_karazhan.cpp | 7 + .../EasternKingdoms/Karazhan/karazhan.h | 40 +- 4 files changed, 428 insertions(+), 362 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1674942757744333000.sql diff --git a/data/sql/updates/pending_db_world/rev_1674942757744333000.sql b/data/sql/updates/pending_db_world/rev_1674942757744333000.sql new file mode 100644 index 000000000..d056524c8 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1674942757744333000.sql @@ -0,0 +1,55 @@ +-- +SET @ATTUMEN_UNMOUNTED := 15550; +SET @ATTUMEN_MOUNTED := 16152; +SET @MIDNIGHT := 16151; +SET @GMIDNIGHT := 135159; + +DELETE FROM `creature_text` WHERE `CreatureID` IN (@MIDNIGHT, @ATTUMEN_UNMOUNTED, @ATTUMEN_MOUNTED); +INSERT INTO `creature_text` (`CreatureID`, `GroupId`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(@ATTUMEN_UNMOUNTED, 0, 0, 'It was... inevitable.', 14, 0, 100, 0, 0, 9169, 13460, 0, 'attumen SAY_KILL1'), +(@ATTUMEN_UNMOUNTED, 0, 1, 'Another trophy to add to my collection!', 14, 0, 100, 0, 0, 9300, 15333, 0,'attumen SAY_KILL2'), +(@ATTUMEN_UNMOUNTED, 1, 0, 'Such easy sport.', 14, 0, 100, 0, 0, 9170, 0, 0,'attumen SAY_RANDOM1'), +(@ATTUMEN_UNMOUNTED, 1, 1, 'Amateurs! Do not think you can best me! I kill for a living.', 14, 0, 100, 0, 0, 9304, 0, 0, 'attumen SAY_RANDOM2'), +(@ATTUMEN_UNMOUNTED, 2, 0, 'Weapons are merely a convenience for a warrior of my skill!', 14, 0, 100, 0, 0, 9166, 13490, 0, 'attumen SAY_DISARMED'), +(@ATTUMEN_UNMOUNTED, 3, 0, 'Well done, Midnight!', 14, 0, 100, 0, 0, 9173, 15334, 0, 'attumen SAY_MIDNIGHT_KILL'), +(@ATTUMEN_UNMOUNTED, 4, 0, 'Cowards! Wretches!', 14, 0, 100, 0, 0, 9167, 13459, 0, 'attumen SAY_APPEAR1'), +(@ATTUMEN_UNMOUNTED, 4, 1, 'Who dares attack the steed of the Huntsman?', 14, 0, 100, 0, 0, 9298, 15378, 0, 'attumen SAY_APPEAR2'), +(@ATTUMEN_UNMOUNTED, 4, 2, 'Perhaps you would rather test yourselves against a more formidable opponent?!', 14, 0, 100, 0, 0, 9299, 15379, 0, 'attumen SAY_APPEAR3'), +(@ATTUMEN_UNMOUNTED, 5, 0, 'Come Midnight, let\'s disperse this petty rabble!', 14, 0, 100, 0, 0, 9168, 13456, 0, 'attumen SAY_MOUNT'), + +(@ATTUMEN_MOUNTED, 0, 0, 'It was... inevitable.', 14, 0, 100, 0, 0, 9169, 13460, 0, 'attumen SAY_KILL1'), +(@ATTUMEN_MOUNTED, 0, 1, 'Another trophy to add to my collection!', 14, 0, 100, 0, 0, 9300, 15333, 0,'attumen SAY_KILL2'), +(@ATTUMEN_MOUNTED, 1, 0, 'Such easy sport.', 14, 0, 100, 0, 0, 9170, 0, 0,'attumen SAY_RANDOM1'), +(@ATTUMEN_MOUNTED, 1, 1, 'Amateurs! Do not think you can best me! I kill for a living.', 14, 0, 100, 0, 0, 9304, 0, 0, 'attumen SAY_RANDOM2'), +(@ATTUMEN_MOUNTED, 2, 0, 'Weapons are merely a convenience for a warrior of my skill!', 14, 0, 100, 0, 0, 9166, 13490, 0, 'attumen SAY_DISARMED'), +(@ATTUMEN_MOUNTED, 3, 0, 'Always knew... someday I would become... the hunted.', 14, 0, 100, 0, 0, 9165, 13462, 0, 'attumen SAY_DEATH'), + +(@MIDNIGHT, 0, 0, '%s calls for her master!', 16, 0, 100, 0, 0, 0, 13439, 0, 'midnight EMOTE_CALL_ATTUMEN'), +(@MIDNIGHT, 1, 0, '%s rushes to her master\'s aid.', 16, 0, 100, 0, 0, 0, 13455, 0, 'midnight EMOTE_MOUNT_UP'); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 13 AND `SourceEntry` = 29770; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 29770, 0, 0, 31, 0, 3, 15550, 0, 0, 0, 0, '', 'Mount spell only hit Attumen the Huntsmen'); + +DELETE FROM `creature_formations` WHERE `leaderGUID` = 135159; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`, `point_1`, `point_2`) VALUES +(@GMIDNIGHT, @GMIDNIGHT, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135828, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135836, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135829, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135839, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135833, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135840, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135834, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135830, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135841, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135842, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135831, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135837, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135838, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135832, 0, 0, 1, 0, 0), +(@GMIDNIGHT, 135835, 0, 0, 1, 0, 0); + +UPDATE `creature_template` SET `ScriptName` = 'boss_attumen', `lootid` = @ATTUMEN_MOUNTED WHERE `entry` = @ATTUMEN_MOUNTED; +UPDATE `creature_loot_template` SET `entry` = @ATTUMEN_MOUNTED WHERE `entry` = @ATTUMEN_UNMOUNTED; +UPDATE `creature_template` SET `flags_extra` = `flags_extra`|2097152 WHERE `entry` = 16152; diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp index ca23e547b..96f405c56 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp @@ -19,64 +19,290 @@ #include "ScriptedCreature.h" #include "SpellInfo.h" #include "SpellScript.h" +#include "Unit.h" #include "karazhan.h" -enum eSay +enum Texts { - SAY_ATTUMEN1_APPEAR = 0, - SAY_ATTUMEN1_MOUNT = 2, + SAY_KILL = 0, + SAY_RANDOM = 1, + SAY_DISARMED = 2, + SAY_MIDNIGHT_KILL = 3, + SAY_APPEAR = 4, + SAY_MOUNT = 5, - SAY_ATTUMEN2_DEATH = 0, + SAY_DEATH = 3, - SAY_ATTUMEN_KILL = 1, - SAY_ATTUMEN_DISARM = 3, - SAY_ATTUMEN_RANDOM = 4, - SAY_ATTUMEN_MIDNIGHT_KILL = 5, - - SAY_MIDNIGHT_EMOTE = 0 -}; - -enum eSpells -{ // Midnight - SPELL_KNOCKDOWN = 29711, - SPELL_SUMMON_ATTUMEN = 29714, - SPELL_SUMMON_ATTUMEN_MOUNTED = 29799, + EMOTE_CALL_ATTUMEN = 0, + EMOTE_MOUNT_UP = 1 +}; +enum Spells +{ // Attumen - SPELL_SHADOW_CLEAVE = 29832, - SPELL_INTANGIBLE_PRESENCE = 29833, - SPELL_SPAWN_SMOKE1 = 29802, + SPELL_SHADOWCLEAVE = 29832, + SPELL_INTANGIBLE_PRESENCE = 29833, + SPELL_SPAWN_SMOKE = 10389, + SPELL_CHARGE = 29847, - // Attumen 2 - SPELL_CHARGE_MIDNIGHT = 29847, - SPELL_SPAWN_SMOKE2 = 10389, - - // Generic - SPELL_MOUNT_TARGET_ATTUMEN = 29769, - SPELL_MOUNT_TARGET_MIDNIGHT = 29770 + // Midnight + SPELL_KNOCKDOWN = 29711, + SPELL_SUMMON_ATTUMEN = 29714, + SPELL_MOUNT = 29770, + SPELL_SUMMON_ATTUMEN_MOUNTED = 29799 }; -enum eEvents +enum Phases { - EVENT_CHECK_HEALTH_95 = 1, - EVENT_CHECK_HEALTH_25 = 2, - EVENT_SPELL_KNOCKDOWN = 3, - EVENT_SUMMON_ATTUMEN_MOUNTED = 4, - - EVENT_SPELL_SHADOW_CLEAVE = 10, - EVENT_SPELL_INTANGIBLE_PRESENCE = 11, - EVENT_RANDOM_YELL = 12, - - EVENT_SPELL_CHARGE = 20, - - EVENT_KILL_TALK = 30 + PHASE_NONE, + PHASE_ATTUMEN_ENGAGES, + PHASE_MOUNTED }; -enum eMisc +enum Actions { - POINT_MOVE_TO_MIDNIGHT = 1, - DATA_ATTUMEN_READY = 1 + ACTION_SET_MIDNIGHT_PHASE, +}; + +class boss_attumen : public CreatureScript +{ +public: + boss_attumen() : CreatureScript("boss_attumen") { } + + struct boss_attumenAI : public BossAI + { + boss_attumenAI(Creature* creature) : BossAI(creature, DATA_ATTUMEN) + { + Initialize(); + } + + void Initialize() + { + _phase = PHASE_NONE; + } + + void Reset() override + { + Initialize(); + } + + bool CanMeleeHit() + { + return me->GetVictim() && (me->GetVictim()->GetPositionZ() < 53.0f || me->GetVictim()->GetDistance(me->GetHomePosition()) < 50.0f); + } + + void EnterEvadeMode(EvadeReason why) override + { + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + midnight->AI()->EnterEvadeMode(why); + } + + me->DespawnOrUnsummon(); + } + + void ScheduleTasks() override + { + scheduler.Schedule(Seconds(15), Seconds(25), [this](TaskContext task) + { + DoCastVictim(SPELL_SHADOWCLEAVE); + task.Repeat(Seconds(15), Seconds(25)); + }); + + scheduler.Schedule(Seconds(25), Seconds(45), [this](TaskContext task) + { + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) + { + DoCast(target, SPELL_INTANGIBLE_PRESENCE); + } + + task.Repeat(Seconds(25), Seconds(45)); + }); + + scheduler.Schedule(Seconds(30), Seconds(60), [this](TaskContext task) + { + Talk(SAY_RANDOM); + task.Repeat(Seconds(30), Seconds(60)); + }); + } + + void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damageType*/, SpellSchoolMask /*damageSchoolMask*/) override + { + // Attumen does not die until he mounts Midnight, let health fall to 1 and prevent further damage. + if (damage >= me->GetHealth() && _phase != PHASE_MOUNTED) + { + damage = me->GetHealth() - 1; + } + + if (_phase == PHASE_ATTUMEN_ENGAGES && me->HealthBelowPctDamaged(25, damage)) + { + _phase = PHASE_NONE; + + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + midnight->AI()->DoCastAOE(SPELL_MOUNT, true); + } + } + } + + void KilledUnit(Unit* /*victim*/) override + { + Talk(SAY_KILL); + } + + void JustSummoned(Creature* summon) override + { + if (summon->GetEntry() == NPC_ATTUMEN_THE_HUNTSMAN_MOUNTED) + { + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + if (midnight->GetHealth() > me->GetHealth()) + { + summon->SetHealth(midnight->GetHealth()); + } + else + { + summon->SetHealth(me->GetHealth()); + } + + summon->AI()->DoZoneInCombat(); + } + } + + BossAI::JustSummoned(summon); + } + + void IsSummonedBy(WorldObject* summoner) override + { + if (summoner->GetEntry() == NPC_MIDNIGHT) + { + _phase = PHASE_ATTUMEN_ENGAGES; + } + + if (summoner->GetEntry() == NPC_ATTUMEN_THE_HUNTSMAN) + { + _phase = PHASE_MOUNTED; + DoCastSelf(SPELL_SPAWN_SMOKE); + + scheduler.Schedule(Seconds(10), Seconds(25), [this](TaskContext task) + { + Unit* target = nullptr; + std::vector target_list; + + for (auto* ref : me->GetThreatMgr().GetUnsortedThreatList()) + { + target = ref->GetVictim(); + if (target && !target->IsWithinDist(me, 8.00f, false) && target->IsWithinDist(me, 25.0f, false)) + target_list.push_back(target); + + target = nullptr; + } + + if (!target_list.empty()) + { + target = Acore::Containers::SelectRandomContainerElement(target_list); + } + + DoCast(target, SPELL_CHARGE); + task.Repeat(Seconds(10), Seconds(25)); + }); + + scheduler.Schedule(Seconds(25), Seconds(35), [this](TaskContext task) + { + DoCastVictim(SPELL_KNOCKDOWN); + task.Repeat(Seconds(25), Seconds(35)); + }); + } + } + + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_DEATH); + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + midnight->KillSelf(); + } + + _JustDied(); + } + + void UpdateAI(uint32 diff) override + { + if (_phase != PHASE_NONE) + { + if (!UpdateVictim()) + { + return; + } + } + + if (!CanMeleeHit()) + { + BossAI::EnterEvadeMode(EvadeReason::EVADE_REASON_BOUNDARY); + } + + scheduler.Update(diff, + std::bind(&BossAI::DoMeleeAttackIfReady, this)); + } + + void SpellHit(Unit* /*caster*/, SpellInfo const* spellInfo) override + { + if (spellInfo->Mechanic == MECHANIC_DISARM) + { + Talk(SAY_DISARMED); + } + + if (spellInfo->Id == SPELL_MOUNT) + { + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + _phase = PHASE_NONE; + scheduler.CancelAll(); + + midnight->AI()->DoAction(ACTION_SET_MIDNIGHT_PHASE); + midnight->AttackStop(); + midnight->RemoveAllAttackers(); + midnight->SetReactState(REACT_PASSIVE); + midnight->GetMotionMaster()->MoveFollow(me, 2.0f, 0.0f); + midnight->AI()->Talk(EMOTE_MOUNT_UP); + + me->AttackStop(); + me->RemoveAllAttackers(); + me->SetReactState(REACT_PASSIVE); + me->GetMotionMaster()->MoveFollow(midnight, 2.0f, 0.0f); + Talk(SAY_MOUNT); + + scheduler.Schedule(Seconds(1), [this](TaskContext task) + { + if (Creature* midnight = instance->GetCreature(DATA_MIDNIGHT)) + { + if (me->IsWithinDist2d(midnight, 5.0f)) + { + DoCastAOE(SPELL_SUMMON_ATTUMEN_MOUNTED); + me->DespawnOrUnsummon(1s, 0s); + midnight->SetVisible(false); + } + else + { + midnight->GetMotionMaster()->MoveFollow(me, 2.0f, 0.0f); + me->GetMotionMaster()->MoveFollow(midnight, 2.0f, 0.0f); + task.Repeat(); + } + } + }); + } + } + } + + private: + uint8 _phase; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetKarazhanAI(creature); + } }; class boss_midnight : public CreatureScript @@ -86,114 +312,109 @@ public: struct boss_midnightAI : public BossAI { - boss_midnightAI(Creature* creature) : BossAI(creature, DATA_ATTUMEN) { } + boss_midnightAI(Creature* creature) : BossAI(creature, DATA_ATTUMEN), _phase(PHASE_NONE) { } void Reset() override { BossAI::Reset(); me->SetVisible(true); - _healthPct = 100.0f; + me->SetReactState(REACT_DEFENSIVE); + } + + bool CanMeleeHit() + { + return me->GetVictim() && (me->GetVictim()->GetPositionZ() < 53.0f || me->GetVictim()->GetDistance(me->GetHomePosition()) < 50.0f); + } + + void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damageType*/, SpellSchoolMask /*damageSchoolMask*/) override + { + // Midnight never dies, let health fall to 1 and prevent further damage. + if (damage >= me->GetHealth()) + { + damage = me->GetHealth() - 1; + } + + if (_phase == PHASE_NONE && me->HealthBelowPctDamaged(95, damage)) + { + _phase = PHASE_ATTUMEN_ENGAGES; + Talk(EMOTE_CALL_ATTUMEN); + DoCastAOE(SPELL_SUMMON_ATTUMEN); + } + else if (_phase == PHASE_ATTUMEN_ENGAGES && me->HealthBelowPctDamaged(25, damage)) + { + _phase = PHASE_MOUNTED; + DoCastAOE(SPELL_MOUNT, true); + } + } + + void JustSummoned(Creature* summon) override + { + if (summon->GetEntry() == NPC_ATTUMEN_THE_HUNTSMAN) + { + summon->AI()->AttackStart(me->GetVictim()); + summon->AI()->Talk(SAY_APPEAR); + } + + BossAI::JustSummoned(summon); + } + + void DoAction(int32 actionId) override + { + if (actionId == ACTION_SET_MIDNIGHT_PHASE) + { + _phase = PHASE_MOUNTED; + } } void EnterCombat(Unit* who) override { BossAI::EnterCombat(who); - events.ScheduleEvent(EVENT_CHECK_HEALTH_95, 0); - events.ScheduleEvent(EVENT_SPELL_KNOCKDOWN, 6000); - DoZoneInCombat(); + + scheduler.Schedule(Seconds(15), Seconds(25), [this](TaskContext task) + { + DoCastVictim(SPELL_KNOCKDOWN); + task.Repeat(Seconds(15), Seconds(25)); + }); + } + + void EnterEvadeMode(EvadeReason /*why*/) override + { + me->DespawnOnEvade(10s); + _phase = PHASE_NONE; } void KilledUnit(Unit* /*victim*/) override { - if (Creature* attumen = summons.GetCreatureWithEntry(NPC_ATTUMEN_THE_HUNTSMAN)) - attumen->AI()->Talk(SAY_ATTUMEN_MIDNIGHT_KILL); - } - - void JustSummoned(Creature* summon) override - { - summons.Summon(summon); - summon->SetInCombatWithZone(); - - if (summon->GetEntry() == NPC_ATTUMEN_THE_HUNTSMAN_MOUNTED) + if (_phase == PHASE_ATTUMEN_ENGAGES) { - summon->SetHealth(summon->CountPctFromMaxHealth(_healthPct)); - summon->CastSpell(summon, SPELL_SPAWN_SMOKE2, true); - } - else - summon->CastSpell(summon, SPELL_SPAWN_SMOKE1, true); - } - - void SetData(uint32 type, uint32 /*data*/) override - { - if (type == DATA_ATTUMEN_READY) - events.ScheduleEvent(EVENT_SUMMON_ATTUMEN_MOUNTED, 0); - } - - void SummonedCreatureDies(Creature* summon, Unit* /*killer*/) override - { - if (summon->GetEntry() == NPC_ATTUMEN_THE_HUNTSMAN_MOUNTED) - { - summons.clear(); - me->KillSelf(); + if (Creature* attumen = instance->GetCreature(DATA_ATTUMEN)) + { + Talk(SAY_MIDNIGHT_KILL, attumen); + } } } void UpdateAI(uint32 diff) override { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + if (_phase != PHASE_MOUNTED) { - case EVENT_CHECK_HEALTH_95: - if (me->HealthBelowPct(96)) - { - me->CastSpell(me, SPELL_SUMMON_ATTUMEN, true); - events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 0); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH_95, 500); - break; - case EVENT_CHECK_HEALTH_25: - if (me->HealthBelowPct(25)) - { - Talk(SAY_MIDNIGHT_EMOTE); - me->CastSpell(me, SPELL_MOUNT_TARGET_ATTUMEN, true); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 500); - break; - case EVENT_SPELL_KNOCKDOWN: - me->CastSpell(me->GetVictim(), SPELL_KNOCKDOWN, false); - events.ScheduleEvent(EVENT_SPELL_KNOCKDOWN, 20000); - break; - case EVENT_SUMMON_ATTUMEN_MOUNTED: - if (Creature* attumen = summons.GetCreatureWithEntry(NPC_ATTUMEN_THE_HUNTSMAN)) - { - _healthPct = std::max(me->GetHealthPct(), attumen->GetHealthPct()); - attumen->DespawnOrUnsummon(); - } + if (!UpdateVictim()) + { + return; + } - me->CastSpell(me, SPELL_SUMMON_ATTUMEN_MOUNTED, true); - me->SetVisible(false); - break; + if (!CanMeleeHit()) + { + BossAI::EnterEvadeMode(EvadeReason::EVADE_REASON_BOUNDARY); + } } - if (me->IsVisible()) - DoMeleeAttackIfReady(); - } - - bool CheckEvadeIfOutOfCombatArea() const override - { - return me->GetHomePosition().GetExactDist2d(me) > 50.0f || me->GetPositionZ() > 60.0f; + scheduler.Update(diff, + std::bind(&BossAI::DoMeleeAttackIfReady, this)); } private: - float _healthPct; + uint8 _phase; }; CreatureAI* GetAI(Creature* creature) const override @@ -202,224 +423,6 @@ public: } }; -class boss_attumen : public CreatureScript -{ -public: - boss_attumen() : CreatureScript("boss_attumen") { } - - struct boss_attumenAI : public ScriptedAI - { - boss_attumenAI(Creature* creature) : ScriptedAI(creature) - { - } - - void Reset() override - { - _events.Reset(); - } - - void EnterCombat(Unit* /*who*/) override - { - Talk(SAY_ATTUMEN1_APPEAR); - _events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 0); - _events.ScheduleEvent(EVENT_SPELL_SHADOW_CLEAVE, 6000); - _events.ScheduleEvent(EVENT_SPELL_INTANGIBLE_PRESENCE, 15000); - _events.ScheduleEvent(EVENT_RANDOM_YELL, urand(25000, 45000)); - } - - void KilledUnit(Unit* /*victim*/) override - { - if (_events.GetNextEventTime(EVENT_KILL_TALK) == 0) - { - _events.ScheduleEvent(EVENT_KILL_TALK, 5000); - Talk(SAY_ATTUMEN_KILL); - } - } - - void SpellHit(Unit* /*caster*/, SpellInfo const* spellInfo) override - { - if (spellInfo->Mechanic == MECHANIC_DISARM && _events.GetNextEventTime(EVENT_KILL_TALK) == 0) - { - _events.ScheduleEvent(EVENT_KILL_TALK, 5000); - Talk(SAY_ATTUMEN_DISARM); - } - else if (spellInfo->Id == SPELL_MOUNT_TARGET_ATTUMEN) - { - me->CastSpell(me, SPELL_MOUNT_TARGET_MIDNIGHT, true); - } - } - - void SpellHitTarget(Unit* target, SpellInfo const* spellInfo) override - { - if (spellInfo->Id == SPELL_MOUNT_TARGET_MIDNIGHT) - { - Talk(SAY_ATTUMEN1_MOUNT); - _events.Reset(); - me->GetMotionMaster()->MovePoint(POINT_MOVE_TO_MIDNIGHT, target->GetPositionX() + 2.0f * cos(target->GetAngle(me)), target->GetPositionY() + 2.0f * std::sin(target->GetAngle(me)), target->GetPositionZ() + 0.2f, true, true, MOTION_SLOT_CONTROLLED); - } - } - - void MovementInform(uint32 type, uint32 point) override - { - if (type == POINT_MOTION_TYPE && point == POINT_MOVE_TO_MIDNIGHT) - { - if (TempSummon* summon = me->ToTempSummon()) - if (Unit* midnight = summon->GetSummonerUnit()) - midnight->GetAI()->SetData(DATA_ATTUMEN_READY, 0); - } - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - _events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (_events.ExecuteEvent()) - { - case EVENT_SPELL_SHADOW_CLEAVE: - me->CastSpell(me->GetVictim(), SPELL_SHADOW_CLEAVE, false); - _events.ScheduleEvent(EVENT_SPELL_SHADOW_CLEAVE, urand(9000, 14000)); - break; - case EVENT_SPELL_INTANGIBLE_PRESENCE: - me->CastSpell(me->GetVictim(), SPELL_INTANGIBLE_PRESENCE, false); - _events.ScheduleEvent(EVENT_SPELL_INTANGIBLE_PRESENCE, 30000); - break; - case EVENT_RANDOM_YELL: - Talk(SAY_ATTUMEN_RANDOM); - _events.ScheduleEvent(EVENT_RANDOM_YELL, urand(30000, 70000)); - break; - case EVENT_CHECK_HEALTH_25: - if (me->HealthBelowPct(25)) - { - me->CastSpell(me, SPELL_MOUNT_TARGET_MIDNIGHT, true); - break; - } - _events.ScheduleEvent(EVENT_CHECK_HEALTH_25, 500); - break; - } - - DoMeleeAttackIfReady(); - } - - private: - EventMap _events; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetKarazhanAI(creature); - } -}; - -class boss_attumen_midnight : public CreatureScript -{ -public: - boss_attumen_midnight() : CreatureScript("boss_attumen_midnight") { } - - struct boss_attumen_midnightAI : public ScriptedAI - { - boss_attumen_midnightAI(Creature* creature) : ScriptedAI(creature) - { - } - - void Reset() override - { - _events.Reset(); - } - - void EnterCombat(Unit* /*who*/) override - { - _events.ScheduleEvent(EVENT_SPELL_SHADOW_CLEAVE, 6000); - _events.ScheduleEvent(EVENT_SPELL_INTANGIBLE_PRESENCE, 15000); - _events.ScheduleEvent(EVENT_RANDOM_YELL, urand(25000, 45000)); - _events.ScheduleEvent(EVENT_SPELL_CHARGE, 20000); - _events.ScheduleEvent(EVENT_SPELL_KNOCKDOWN, 11000); - } - - void KilledUnit(Unit* /*victim*/) override - { - if (_events.GetNextEventTime(EVENT_KILL_TALK) == 0) - { - _events.ScheduleEvent(EVENT_KILL_TALK, 5000); - Talk(SAY_ATTUMEN_KILL); - } - } - - void JustDied(Unit* /*killer*/) override - { - Talk(SAY_ATTUMEN2_DEATH); - } - - void SpellHit(Unit* /*caster*/, SpellInfo const* spellInfo) override - { - if (spellInfo->Mechanic == MECHANIC_DISARM && _events.GetNextEventTime(EVENT_KILL_TALK) == 0) - { - _events.ScheduleEvent(EVENT_KILL_TALK, 5000); - Talk(SAY_ATTUMEN_DISARM); - } - } - - void MovementInform(uint32 type, uint32 point) override - { - if (type == POINT_MOTION_TYPE && point == POINT_MOVE_TO_MIDNIGHT) - { - if (TempSummon* summon = me->ToTempSummon()) - if (Unit* midnight = summon->GetSummonerUnit()) - midnight->GetAI()->SetData(DATA_ATTUMEN_READY, 0); - } - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - _events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (_events.ExecuteEvent()) - { - case EVENT_SPELL_SHADOW_CLEAVE: - me->CastSpell(me->GetVictim(), SPELL_SHADOW_CLEAVE, false); - _events.ScheduleEvent(EVENT_SPELL_SHADOW_CLEAVE, urand(9000, 14000)); - break; - case EVENT_SPELL_INTANGIBLE_PRESENCE: - me->CastSpell(me->GetVictim(), SPELL_INTANGIBLE_PRESENCE, false); - _events.ScheduleEvent(EVENT_SPELL_INTANGIBLE_PRESENCE, 30000); - break; - case EVENT_RANDOM_YELL: - Talk(SAY_ATTUMEN_RANDOM); - _events.ScheduleEvent(EVENT_RANDOM_YELL, urand(30000, 70000)); - break; - case EVENT_SPELL_CHARGE: - if (Unit* target = SelectTarget(SelectTargetMethod::MinDistance, 0, 24.0f, true)) - me->CastSpell(target, SPELL_CHARGE_MIDNIGHT, false); - _events.ScheduleEvent(EVENT_SPELL_CHARGE, 20000); - break; - case EVENT_SPELL_KNOCKDOWN: - me->CastSpell(me->GetVictim(), SPELL_KNOCKDOWN, false); - _events.ScheduleEvent(EVENT_SPELL_KNOCKDOWN, 20000); - break; - } - - DoMeleeAttackIfReady(); - } - - private: - EventMap _events; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetKarazhanAI(creature); - } -}; - class spell_midnight_fixate : public SpellScriptLoader { public: @@ -460,6 +463,5 @@ void AddSC_boss_attumen() { new boss_midnight(); new boss_attumen(); - new boss_attumen_midnight(); new spell_midnight_fixate(); } diff --git a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp index e6d6115e7..ddcb44139 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp @@ -32,6 +32,12 @@ const Position OptionalSpawn[] = { -10899.903320f, -2085.573730f, 49.474449f, 1.38f } // Rokad the Ravager }; +ObjectData const creatureData[] = +{ + { NPC_ATTUMEN_THE_HUNTSMAN, DATA_ATTUMEN }, + { NPC_MIDNIGHT, DATA_MIDNIGHT } +}; + class instance_karazhan : public InstanceMapScript { public: @@ -48,6 +54,7 @@ public: { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadObjectData(creatureData, nullptr); // 1 - OZ, 2 - HOOD, 3 - RAJ, this never gets altered. OperaEvent = urand(EVENT_OZ, EVENT_RAJ); diff --git a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h index 5cce320c7..3da5b5775 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h +++ b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h @@ -59,7 +59,8 @@ enum KZDataTypes DATA_MASTERS_TERRACE_DOOR_2 = 28, DATA_GO_SIDE_ENTRANCE_DOOR = 29, DATA_PRINCE = 30, - DATA_SPAWN_OPERA_DECORATIONS = 31 + DATA_SPAWN_OPERA_DECORATIONS = 31, + DATA_MIDNIGHT = 32 }; enum KZOperaEvents @@ -71,27 +72,28 @@ enum KZOperaEvents enum KZMiscCreatures { - NPC_HYAKISS_THE_LURKER = 16179, - NPC_ROKAD_THE_RAVAGER = 16181, - NPC_SHADIKITH_THE_GLIDER = 16180, - NPC_TERESTIAN_ILLHOOF = 15688, - NPC_MOROES = 15687, - NPC_ATTUMEN_THE_HUNTSMAN = 15550, + NPC_HYAKISS_THE_LURKER = 16179, + NPC_ROKAD_THE_RAVAGER = 16181, + NPC_SHADIKITH_THE_GLIDER = 16180, + NPC_TERESTIAN_ILLHOOF = 15688, + NPC_MOROES = 15687, + NPC_ATTUMEN_THE_HUNTSMAN = 15550, NPC_ATTUMEN_THE_HUNTSMAN_MOUNTED = 16152, - NPC_NIGHTBANE = 17225, + NPC_MIDNIGHT = 16151, + NPC_NIGHTBANE = 17225, // Trash - NPC_COLDMIST_WIDOW = 16171, - NPC_COLDMIST_STALKER = 16170, - NPC_SHADOWBAT = 16173, - NPC_VAMPIRIC_SHADOWBAT = 16175, - NPC_GREATER_SHADOWBAT = 16174, - NPC_PHASE_HOUND = 16178, - NPC_DREADBEAST = 16177, - NPC_SHADOWBEAST = 16176, - NPC_KILREK = 17229, - NPC_RELAY = 17645, - NPC_BARNES = 16812 + NPC_COLDMIST_WIDOW = 16171, + NPC_COLDMIST_STALKER = 16170, + NPC_SHADOWBAT = 16173, + NPC_VAMPIRIC_SHADOWBAT = 16175, + NPC_GREATER_SHADOWBAT = 16174, + NPC_PHASE_HOUND = 16178, + NPC_DREADBEAST = 16177, + NPC_SHADOWBEAST = 16176, + NPC_KILREK = 17229, + NPC_RELAY = 17645, + NPC_BARNES = 16812 }; enum KZGameObjectIds From 10daa206c661fed110f39f34ab1b6908bb28ad49 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Mon, 13 Feb 2023 00:02:13 +0000 Subject: [PATCH 84/87] chore(DB): import pending files Referenced commit(s): 3b178666137eabf56ecdfc547db4179ef08ea38b --- .../rev_1674942757744333000.sql => db_world/2023_02_13_00.sql} | 1 + .../rev_1675168500421561700.sql => db_world/2023_02_13_01.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1674942757744333000.sql => db_world/2023_02_13_00.sql} (98%) rename data/sql/updates/{pending_db_world/rev_1675168500421561700.sql => db_world/2023_02_13_01.sql} (97%) diff --git a/data/sql/updates/pending_db_world/rev_1674942757744333000.sql b/data/sql/updates/db_world/2023_02_13_00.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1674942757744333000.sql rename to data/sql/updates/db_world/2023_02_13_00.sql index d056524c8..4263aede4 100644 --- a/data/sql/updates/pending_db_world/rev_1674942757744333000.sql +++ b/data/sql/updates/db_world/2023_02_13_00.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_12_14 -> 2023_02_13_00 -- SET @ATTUMEN_UNMOUNTED := 15550; SET @ATTUMEN_MOUNTED := 16152; diff --git a/data/sql/updates/pending_db_world/rev_1675168500421561700.sql b/data/sql/updates/db_world/2023_02_13_01.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1675168500421561700.sql rename to data/sql/updates/db_world/2023_02_13_01.sql index b9666fd48..744317617 100644 --- a/data/sql/updates/pending_db_world/rev_1675168500421561700.sql +++ b/data/sql/updates/db_world/2023_02_13_01.sql @@ -1,3 +1,4 @@ +-- DB update 2023_02_13_00 -> 2023_02_13_01 UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 197; DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 19700); From 65f031c34017b203aa1db3bced000fb10b52ff90 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 12 Feb 2023 23:43:33 -0300 Subject: [PATCH 85/87] refactor(Scripts/BloodFurnace): Modernize Broggok script (#14982) --- .../BloodFurnace/blood_furnace.h | 17 +- .../BloodFurnace/boss_broggok.cpp | 218 ++++++------------ .../BloodFurnace/boss_kelidan_the_breaker.cpp | 5 +- .../BloodFurnace/instance_blood_furnace.cpp | 166 ++++++------- 4 files changed, 160 insertions(+), 246 deletions(-) diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h index af0ef54fb..985cb7618 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h @@ -21,6 +21,10 @@ #include "CreatureAIImpl.h" #include "Player.h" +#define DataHeader "BF" + +constexpr uint32 EncounterCount = 4; + #define BloodFurnaceScriptName "instance_blood_furnace" enum bloodFurnace @@ -33,8 +37,8 @@ enum bloodFurnace DATA_DOOR1 = 10, DATA_DOOR2 = 11, DATA_DOOR3 = 12, - DATA_DOOR4 = 13, - DATA_DOOR5 = 14, + DATA_BROGGOK_REAR_DOOR = 13, + DATA_BROGGOK_LEVER = 14, DATA_DOOR6 = 15, DATA_PRISON_CELL1 = 20, @@ -55,10 +59,19 @@ enum bloodFurnaceNPC NPC_CHANNELER = 17653 }; +enum BloodFurnaceGO +{ + GO_BROGGOK_DOOR_FRONT = 181822, + GO_BROGGOK_DOOR_REAR = 181819, + GO_BROGGOK_LEVER = 181982 +}; + template inline AI* GetBloodFurnaceAI(T* obj) { return GetInstanceAI(obj, BloodFurnaceScriptName); } +#define RegisterBloodFurnaceCreatureAI(ai_name) RegisterCreatureAIWithFactory(ai_name, GetBloodFurnaceAI) + #endif diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp index 3cc1a18f5..da6ff8e70 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp @@ -29,126 +29,63 @@ enum eEnums SPELL_POISON_CLOUD = 30916, SPELL_POISON_BOLT = 30917, SPELL_POISON = 30914, - - EVENT_SPELL_SLIME = 1, - EVENT_SPELL_POISON = 2, - EVENT_SPELL_BOLT = 3 }; -class boss_broggok : public CreatureScript +struct boss_broggok : public BossAI { -public: - boss_broggok() : CreatureScript("boss_broggok") + boss_broggok(Creature* creature) : BossAI(creature, DATA_BROGGOK) { } + + void Reset() override { + _Reset(); + me->SetReactState(REACT_PASSIVE); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToAll(true); } - struct boss_broggokAI : public ScriptedAI + void EnterCombat(Unit* /*who*/) override { - boss_broggokAI(Creature* creature) : ScriptedAI(creature), summons(me) - { - instance = creature->GetInstanceScript(); - } + Talk(SAY_AGGRO); + _EnterCombat(); + } - InstanceScript* instance; - SummonList summons; - bool canAttack; - - void Reset() override - { - events.Reset(); - summons.DespawnAll(); - - me->SetReactState(REACT_PASSIVE); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->SetImmuneToAll(true); - canAttack = false; - - if (instance) - instance->SetData(DATA_BROGGOK, NOT_STARTED); - } - - void EnterCombat(Unit* /*who*/) override - { - Talk(SAY_AGGRO); - } - - void JustSummoned(Creature* summoned) override - { - summons.Summon(summoned); - - summoned->SetFaction(FACTION_MONSTER_2); - summoned->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE); - summoned->CastSpell(summoned, SPELL_POISON, true, 0, 0, me->GetGUID()); - } - - void SummonedCreatureDespawn(Creature* summon) override - { - summons.Despawn(summon); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim() || !canAttack) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_SLIME: - me->CastSpell(me->GetVictim(), SPELL_SLIME_SPRAY, false); - events.RepeatEvent(urand(7000, 12000)); - break; - case EVENT_SPELL_BOLT: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - me->CastSpell(target, SPELL_POISON_BOLT, false); - events.RepeatEvent(urand(6000, 11000)); - break; - case EVENT_SPELL_POISON: - me->CastSpell(me, SPELL_POISON_CLOUD, false); - events.RepeatEvent(20000); - break; - } - - DoMeleeAttackIfReady(); - } - - void JustDied(Unit* /*killer*/) override - { - if (instance) - { - instance->HandleGameObject(instance->GetGuidData(DATA_DOOR4), true); - instance->HandleGameObject(instance->GetGuidData(DATA_DOOR5), true); - instance->SetData(DATA_BROGGOK, DONE); - } - } - - void DoAction(int32 action) override - { - switch (action) - { - case ACTION_PREPARE_BROGGOK: - me->SetInCombatWithZone(); - break; - case ACTION_ACTIVATE_BROGGOK: - events.ScheduleEvent(EVENT_SPELL_SLIME, 10000); - events.ScheduleEvent(EVENT_SPELL_POISON, 5000); - events.ScheduleEvent(EVENT_SPELL_BOLT, 7000); - - me->SetReactState(REACT_AGGRESSIVE); - me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->SetImmuneToAll(false); - canAttack = true; - break; - } - } - }; - - CreatureAI* GetAI(Creature* creature) const override + void JustSummoned(Creature* summoned) override { - return GetBloodFurnaceAI(creature); + summons.Summon(summoned); + + summoned->SetFaction(FACTION_MONSTER_2); + summoned->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE); + summoned->CastSpell(summoned, SPELL_POISON, true, 0, 0, me->GetGUID()); + } + + void DoAction(int32 action) override + { + switch (action) + { + case ACTION_PREPARE_BROGGOK: + me->SetInCombatWithZone(); + instance->SetBossState(DATA_BROGGOK, IN_PROGRESS); + break; + case ACTION_ACTIVATE_BROGGOK: + scheduler.Schedule(10s, [this](TaskContext context) + { + DoCastVictim(SPELL_SLIME_SPRAY); + context.Repeat(7s, 12s); + }).Schedule(5s, [this](TaskContext context) + { + DoCastRandomTarget(SPELL_POISON_BOLT); + context.Repeat(6s, 11s); + }).Schedule(7s, [this](TaskContext context) + { + DoCastSelf(SPELL_POISON_CLOUD); + context.Repeat(20s); + }); + + me->SetReactState(REACT_AGGRESSIVE); + me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetImmuneToAll(false); + break; + } } }; @@ -160,12 +97,16 @@ public: bool OnGossipHello(Player* /*player*/, GameObject* go) override { if (InstanceScript* instance = go->GetInstanceScript()) - if (instance->GetData(DATA_BROGGOK) != DONE && instance->GetData(DATA_BROGGOK) != IN_PROGRESS) - if (Creature* broggok = ObjectAccessor::GetCreature(*go, instance->GetGuidData(DATA_BROGGOK))) + { + if (instance->GetBossState(DATA_BROGGOK) == NOT_STARTED) + { + if (Creature* broggok = instance->GetCreature(DATA_BROGGOK)) { instance->SetData(DATA_BROGGOK, IN_PROGRESS); broggok->AI()->DoAction(ACTION_PREPARE_BROGGOK); } + } + } go->UseDoorOrButton(); return false; @@ -173,46 +114,35 @@ public: }; // 30914, 38462 - Poison (Broggok) -class spell_broggok_poison_cloud : public SpellScriptLoader +class spell_broggok_poison_cloud : public AuraScript { -public: - spell_broggok_poison_cloud() : SpellScriptLoader("spell_broggok_poison_cloud") { } + PrepareAuraScript(spell_broggok_poison_cloud); - class spell_broggok_poison_cloud_AuraScript : public AuraScript + bool Validate(SpellInfo const* spellInfo) override { - PrepareAuraScript(spell_broggok_poison_cloud_AuraScript); + if (!sSpellMgr->GetSpellInfo(spellInfo->Effects[EFFECT_0].TriggerSpell)) + return false; + return true; + } - bool Validate(SpellInfo const* spellInfo) override - { - if (!sSpellMgr->GetSpellInfo(spellInfo->Effects[EFFECT_0].TriggerSpell)) - return false; - return true; - } - - void PeriodicTick(AuraEffect const* aurEff) - { - PreventDefaultAction(); - - uint32 triggerSpell = GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell; - int32 mod = int32(((float(aurEff->GetTickNumber()) / aurEff->GetTotalTicks()) * 0.9f + 0.1f) * 10000 * 2 / 3); - GetTarget()->CastCustomSpell(triggerSpell, SPELLVALUE_RADIUS_MOD, mod, (Unit*)nullptr, TRIGGERED_FULL_MASK, nullptr, aurEff); - } - - void Register() override - { - OnEffectPeriodic += AuraEffectPeriodicFn(spell_broggok_poison_cloud_AuraScript::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); - } - }; - - AuraScript* GetAuraScript() const override + void PeriodicTick(AuraEffect const* aurEff) { - return new spell_broggok_poison_cloud_AuraScript(); + PreventDefaultAction(); + + uint32 triggerSpell = GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell; + int32 mod = int32(((float(aurEff->GetTickNumber()) / aurEff->GetTotalTicks()) * 0.9f + 0.1f) * 10000 * 2 / 3); + GetTarget()->CastCustomSpell(triggerSpell, SPELLVALUE_RADIUS_MOD, mod, (Unit*)nullptr, TRIGGERED_FULL_MASK, nullptr, aurEff); + } + + void Register() override + { + OnEffectPeriodic += AuraEffectPeriodicFn(spell_broggok_poison_cloud::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } }; void AddSC_boss_broggok() { - new boss_broggok(); + RegisterBloodFurnaceCreatureAI(boss_broggok); new go_broggok_lever(); - new spell_broggok_poison_cloud(); + RegisterSpellScript(spell_broggok_poison_cloud); } diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp index e2191c837..8f5741c63 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp @@ -301,8 +301,9 @@ public: Creature* GetKelidan() { - if (me->GetInstanceScript()) - return ObjectAccessor::GetCreature(*me, me->GetInstanceScript()->GetGuidData(DATA_KELIDAN)); + if (InstanceScript* instance = me->GetInstanceScript()) + return instance->GetCreature(DATA_KELIDAN); + return nullptr; } diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp index 3fe7b4bb8..ba5b2a8b0 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp @@ -20,6 +20,25 @@ #include "ScriptMgr.h" #include "blood_furnace.h" +DoorData const doorData[] = +{ + { GO_BROGGOK_DOOR_FRONT, DATA_BROGGOK, DOOR_TYPE_ROOM }, + { GO_BROGGOK_DOOR_REAR, DATA_BROGGOK, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END +}; + +ObjectData const gameobjectData[] = +{ + { GO_BROGGOK_DOOR_REAR, DATA_BROGGOK_REAR_DOOR }, + { GO_BROGGOK_LEVER, DATA_BROGGOK_LEVER } +}; + +ObjectData const creatureData[] = +{ + { NPC_BROGGOK, DATA_BROGGOK }, + { NPC_KELIDAN, DATA_KELIDAN } +}; + class instance_blood_furnace : public InstanceMapScript { public: @@ -27,10 +46,15 @@ public: struct instance_blood_furnace_InstanceMapScript : public InstanceScript { - instance_blood_furnace_InstanceMapScript(Map* map) : InstanceScript(map) {} + instance_blood_furnace_InstanceMapScript(Map* map) : InstanceScript(map) + { + SetHeaders(DataHeader); + SetBossNumber(EncounterCount); + LoadDoorData(doorData); + LoadObjectData(creatureData, gameobjectData); + } uint32 _auiEncounter[MAX_ENCOUNTER]; - ObjectGuid _bossGUIDs[3]; ObjectGuid _doorGUIDs[6]; ObjectGuid _prisonGUIDs[4]; @@ -38,8 +62,6 @@ public: uint8 _prisonerCounter[4]; - ObjectGuid _broggokLeverGUID; - void Initialize() override { memset(&_auiEncounter, 0, sizeof(_auiEncounter)); @@ -48,21 +70,12 @@ public: void OnCreatureCreate(Creature* creature) override { - switch (creature->GetEntry()) + if (creature->GetEntry() == NPC_NASCENT_FEL_ORC) { - case NPC_THE_MAKER: - _bossGUIDs[DATA_THE_MAKER] = creature->GetGUID(); - break; - case NPC_BROGGOK: - _bossGUIDs[DATA_BROGGOK] = creature->GetGUID(); - break; - case NPC_KELIDAN: - _bossGUIDs[DATA_KELIDAN] = creature->GetGUID(); - break; - case NPC_NASCENT_FEL_ORC: - StorePrisoner(creature); - break; + StorePrisoner(creature); } + + InstanceScript::OnCreatureCreate(creature); } void OnUnitDeath(Unit* unit) override @@ -83,14 +96,7 @@ public: if (GetData(DATA_THE_MAKER) == DONE) HandleGameObject(go->GetGUID(), true); } - if (go->GetEntry() == 181822) //Broggok Front door - _doorGUIDs[3] = go->GetGUID(); - if (go->GetEntry() == 181819) //Broggok Rear door - { - _doorGUIDs[4] = go->GetGUID(); - if (GetData(DATA_BROGGOK) == DONE) - HandleGameObject(go->GetGUID(), true); - } + if (go->GetEntry() == 181823) //Kelidan exit door _doorGUIDs[5] = go->GetGUID(); @@ -103,24 +109,16 @@ public: if (go->GetEntry() == 181817) //Broggok prison cell back left _prisonGUIDs[3] = go->GetGUID(); - if (go->GetEntry() == 181982) - _broggokLeverGUID = go->GetGUID(); //Broggok lever + InstanceScript::OnGameObjectCreate(go); } ObjectGuid GetGuidData(uint32 data) const override { switch (data) { - case DATA_THE_MAKER: - case DATA_BROGGOK: - case DATA_KELIDAN: - return _bossGUIDs[data]; - case DATA_DOOR1: case DATA_DOOR2: case DATA_DOOR3: - case DATA_DOOR4: - case DATA_DOOR5: case DATA_DOOR6: return _doorGUIDs[data - DATA_DOOR1]; @@ -134,16 +132,40 @@ public: return ObjectGuid::Empty; } + bool SetBossState(uint32 type, EncounterState state) override + { + if (!InstanceScript::SetBossState(type, state)) + return false; + + if (type == DATA_BROGGOK) + { + if (state == IN_PROGRESS) + { + ActivateCell(DATA_PRISON_CELL1); + HandleGameObject(_doorGUIDs[3], false); + } + else if (state == NOT_STARTED) + { + ResetPrisons(); + HandleGameObject(_doorGUIDs[4], false); + HandleGameObject(_doorGUIDs[3], true); + if (GameObject* lever = GetGameObject(DATA_BROGGOK_LEVER)) + { + lever->Respawn(); + } + } + } + + return true; + } + void SetData(uint32 type, uint32 data) override { switch (type) { case DATA_THE_MAKER: - case DATA_BROGGOK: case DATA_KELIDAN: _auiEncounter[type] = data; - if (type == DATA_BROGGOK) - UpdateBroggokEvent(data); break; } @@ -151,74 +173,17 @@ public: SaveToDB(); } - std::string GetSaveData() override - { - OUT_SAVE_INST_DATA; - - std::ostringstream saveStream; - saveStream << "B F " << _auiEncounter[0] << ' ' << _auiEncounter[1] << ' ' << _auiEncounter[2]; - - OUT_SAVE_INST_DATA_COMPLETE; - return saveStream.str(); - } - uint32 GetData(uint32 type) const override { switch (type) { case DATA_THE_MAKER: - case DATA_BROGGOK: case DATA_KELIDAN: return _auiEncounter[type]; } return 0; } - void Load(const char* strIn) override - { - if (!strIn) - { - OUT_LOAD_INST_DATA_FAIL; - return; - } - - OUT_LOAD_INST_DATA(strIn); - - char dataHead1, dataHead2; - - std::istringstream loadStream(strIn); - loadStream >> dataHead1 >> dataHead2; - - if (dataHead1 == 'B' && dataHead2 == 'F') - { - loadStream >> _auiEncounter[0] >> _auiEncounter[1] >> _auiEncounter[2]; - - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (_auiEncounter[i] == IN_PROGRESS || _auiEncounter[i] == FAIL) - _auiEncounter[i] = NOT_STARTED; - } - - OUT_LOAD_INST_DATA_COMPLETE; - } - - void UpdateBroggokEvent(uint32 data) - { - switch (data) - { - case IN_PROGRESS: - ActivateCell(DATA_PRISON_CELL1); - HandleGameObject(_doorGUIDs[3], false); - break; - case NOT_STARTED: - ResetPrisons(); - HandleGameObject(_doorGUIDs[4], false); - HandleGameObject(_doorGUIDs[3], true); - if (GameObject* lever = instance->GetGameObject(_broggokLeverGUID)) - lever->Respawn(); - break; - } - } - void ResetPrisons() { for (uint8 i = 0; i < 4; ++i) @@ -290,7 +255,7 @@ public: else if (_prisonersCell[2].find(guid) != _prisonersCell[2].end() && --_prisonerCounter[2] <= 0) ActivateCell(DATA_PRISON_CELL4); else if (_prisonersCell[3].find(guid) != _prisonersCell[3].end() && --_prisonerCounter[3] <= 0) - ActivateCell(DATA_DOOR5); + ActivateCell(DATA_BROGGOK_REAR_DOOR); } void ActivateCell(uint8 id) @@ -304,10 +269,15 @@ public: HandleGameObject(_prisonGUIDs[id - DATA_PRISON_CELL1], true); ActivatePrisoners(_prisonersCell[id - DATA_PRISON_CELL1]); break; - case DATA_DOOR5: - HandleGameObject(_doorGUIDs[4], true); - if (Creature* broggok = instance->GetCreature(GetGuidData(DATA_BROGGOK))) + case DATA_BROGGOK_REAR_DOOR: + if (GameObject* go = GetGameObject(DATA_BROGGOK_REAR_DOOR)) + { + HandleGameObject(ObjectGuid::Empty, true, go); + } + if (Creature* broggok = GetCreature(DATA_BROGGOK)) + { broggok->AI()->DoAction(ACTION_ACTIVATE_BROGGOK); + } break; } } From bdc70d8219c064f922358bf73c7ae19d812d1019 Mon Sep 17 00:00:00 2001 From: Skjalf <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 13 Feb 2023 08:54:51 -0300 Subject: [PATCH 86/87] =?UTF-8?q?Revert=20"fix(Core/Unit):=20Fix=20creatur?= =?UTF-8?q?es=20not=20being=20able=20to=20cast=20spells=20d=E2=80=A6=20(#1?= =?UTF-8?q?4987)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/game/Entities/Unit/Unit.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 4af0aa5c4..9d1b0a377 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -17852,13 +17852,6 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp isRewardAllowed = creature->IsDamageEnoughForLootingAndReward(); if (!isRewardAllowed) creature->SetLootRecipient(nullptr); - - // Call creature just died function - if (CreatureAI* ai = creature->AI()) - { - ai->JustDied(killer); - sScriptMgr->OnUnitDeath(creature, killer); - } } // pussywizard: remade this if section (player is on the same map @@ -18081,6 +18074,13 @@ void Unit::Kill(Unit* killer, Unit* victim, bool durabilityLoss, WeaponAttackTyp if (killer && killer->GetTypeId() == TYPEID_UNIT && killer->IsAIEnabled) killer->ToCreature()->AI()->KilledUnit(victim); + // Call creature just died function + if (CreatureAI* ai = creature->AI()) + { + ai->JustDied(killer); + sScriptMgr->OnUnitDeath(creature, killer); + } + if (TempSummon* summon = creature->ToTempSummon()) { if (WorldObject* summoner = summon->GetSummoner()) From fdfa88093eadc3779ba70b0f6b8f5f4197d16ff1 Mon Sep 17 00:00:00 2001 From: Tereneckla <50233983+Tereneckla@users.noreply.github.com> Date: Mon, 13 Feb 2023 17:32:42 +0000 Subject: [PATCH 87/87] fix(Scripts/MoltenCore): revert ragnaros submerge event to 180s (#15001) --- .../BlackrockMountain/MoltenCore/boss_ragnaros.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp index 028d66c57..899cb3a36 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp @@ -481,7 +481,7 @@ public: events.RescheduleEvent(EVENT_WRATH_OF_RAGNAROS, 30s, PHASE_EMERGED, PHASE_EMERGED); events.RescheduleEvent(EVENT_HAND_OF_RAGNAROS, 25s, PHASE_EMERGED, PHASE_EMERGED); events.RescheduleEvent(EVENT_LAVA_BURST, 10s, PHASE_EMERGED, PHASE_EMERGED); - events.RescheduleEvent(EVENT_SUBMERGE, 18s, PHASE_EMERGED, PHASE_EMERGED); + events.RescheduleEvent(EVENT_SUBMERGE, 180s, PHASE_EMERGED, PHASE_EMERGED); events.RescheduleEvent(EVENT_MIGHT_OF_RAGNAROS, 11s, PHASE_EMERGED, PHASE_EMERGED); }