aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/world/master/2017_01_12_16_world_2016_06_09_02_world.sql21
-rw-r--r--sql/updates/world/master/2017_01_12_17_world_2016_06_09_03_world_335.sql23
-rw-r--r--sql/updates/world/master/2017_01_12_18_world_2016_06_09_04_world.sql6
-rw-r--r--sql/updates/world/master/2017_01_12_19_world_2016_06_09_05_world.sql82
-rw-r--r--src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp46
-rw-r--r--src/server/scripts/World/npcs_special.cpp324
6 files changed, 246 insertions, 256 deletions
diff --git a/sql/updates/world/master/2017_01_12_16_world_2016_06_09_02_world.sql b/sql/updates/world/master/2017_01_12_16_world_2016_06_09_02_world.sql
new file mode 100644
index 00000000000..b2a7d985a9f
--- /dev/null
+++ b/sql/updates/world/master/2017_01_12_16_world_2016_06_09_02_world.sql
@@ -0,0 +1,21 @@
+-- Correct gossip menu option lines, text found in broadcast_text:
+DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (6186,6185,6187,6208,6209,6210,6211);
+INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES
+(6186, 0,0, "I am ready to discover where my fortune lies!",10047,1,1,6185,0,0,0,'',0),
+(6185, 0,0, "I slay the man on the spot as my liege would expect me to do, as he is nothing more than a thief and a liar.", 10049,1,1,6187,0,0,0,'',0),
+(6185, 1,0, "I turn over the man to my liege for punishment, as he has broken the law of the land and it is my sworn duty to enforce it.", 10050,1,1,6187,0,0,0,'',0),
+(6185, 2,0, "I confiscate the corn he has stolen, warn him that stealing is a path towards doom and destruction, but I let him go to return to his family.", 10051,1,1,6187,0,0,0,'',0),
+(6185, 3,0, "I allow the man to take enough corn to feed his family for a couple of days, encouraging him to leave the land.", 10052,1,1,6187,0,0,0,'',0),
+(6187, 0,0, "I execute him as per my liege's instructions, and do it in such a manner that he suffers painfully before he dies as retribution for his crimes against my people.", 10075,1,1,6208,0,0,0,'',0),
+(6187, 1,0, "I execute him as per my liege's instructions, but doing so in as painless of a way as possible. Justice must be served, but I can show some compassion.", 10076,1,1,6208,0,0,0,'',0),
+(6187, 2,0, "I risk my own life and free him so that he may prove his innocence. If I can, I'll help him in any way.", 10077,1,1,6208,0,0,0,'',0),
+(6208, 0,0, "I confront the ruler on his malicious behavior, upholding my liege's honor at the risk of any future diplomacy.", 10079,1,1,6209,0,0,0,'',0),
+(6208, 1,0, "I not-so-quietly ignore the insult, hoping to instill a fear in the ruler that he may have gaffed. I then inform my liege of the insult when I return.", 10080,1,1,6209,0,0,0,'',0),
+(6208, 2,0, "I quietly ignore the insult. I will not tell my liege, as I am to secure peace at all costs. It's only an insult - not a declaration of war.", 10081,1,1,6209,0,0,0,'',0),
+(6209, 0,0, "I would speak against my brother joining the order, rushing a permanent breach in our relationship. He would be a danger to himself and those around him, and that is too great a risk hoping he would improve over time.", 10083,1,1,6210,0,0,0,'',0),
+(6209, 1,0, "I would speak for my brother joining the order, potentially risking the safety of the order. I could help him with the order's regimens, and I'd have faith in his ability to adapt and learn.", 10084,1,1,6210,0,0,0,'',0),
+(6209, 2,0, "I would create some surreptitious means to keep my brother out of the order. I can keep him out without him being any bit wiser, thereby saving our familial bonds.", 10085,1,1,6210,0,0,0,'',0),
+(6210, 0,0, "I would show my liege the beast's ear and claim the beast's death as my own, taking the reward for my own use. It is wrong to claim a deed as your own that someone else in fact did.", 10086,1,1,6211,0,0,0,'',0),
+(6210, 1,0, "I would show my liege the beast's ear and claim the beast's death as my own - after all, I did slay it. I would then offer some of the reward to the destitute knight to help his family.", 10088,1,1,6211,0,0,0,'',0),
+(6210, 2,0, "I would remain silent about the kill and allow the knight to claim the reward to aid his family.", 10089,1,1,6211,0,0,0,'',0),
+(6211, 0,0, "I'd love to get one of those written fortunes you mentioned! I've got the space in my inventory for it.", 10091,1,1,0,0,0,0,'',0);
diff --git a/sql/updates/world/master/2017_01_12_17_world_2016_06_09_03_world_335.sql b/sql/updates/world/master/2017_01_12_17_world_2016_06_09_03_world_335.sql
new file mode 100644
index 00000000000..c4be18500b9
--- /dev/null
+++ b/sql/updates/world/master/2017_01_12_17_world_2016_06_09_03_world_335.sql
@@ -0,0 +1,23 @@
+-- Remove outdated ScriptName from NPC 7775 Gregan Brewspewer
+UPDATE `creature_template` SET `ScriptName`= '' WHERE `entry`= 7775;
+
+-- Remove broadcast_text link from Gregan's default gossip "What can I do for ya?"
+-- to enable npc_text.ID 2433 "Hi there! The name's Gregan. What can I do for ya?"
+-- This mixup is caused by invalid duplicate use of BroadcastTextID0 = 8275,
+-- duplicate of npc_text.ID 5695, used by NPC entry 5167 Fenthwick <Rogue Trainer>
+-- Lookup queries to verify this information:
+-- SELECT * FROM `npc_text` WHERE `BroadcastTextID0`= 8275; -- (ID 2433 + 5695)
+-- SELECT * FROM `gossip_menu` WHERE `text_id`= 5695; -- (4561,5695)
+-- SELECT * FROM `gossip_menu_option` WHERE `menu_id`= 4561; -- (id 0,1,2,4) "I'm lookin' for rogue trainin'."
+-- SELECT * FROM `creature_template` WHERE `gossip_menu_id`= 4561; -- (5167 Fenthwick <Rogue Trainer>)
+
+UPDATE `npc_text` SET `BroadcastTextID0`= 0 WHERE `ID`= 2433; -- old (invalid) BroadcastTextID0 : 8275
+
+-- Activate selection of the next gossip menus in the gossip dialogue
+UPDATE `gossip_menu_option` SET `action_menu_id`= 1801 WHERE `menu_id`= 1802 AND `id`= 0;
+UPDATE `gossip_menu_option` SET `action_menu_id`= 1915 WHERE `menu_id`= 1801 AND `id`= 0;
+
+-- Condition for gossip_menu_option.menu_id 1802, shown in Gregan Brewspewer's default gossip menu 2433
+DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup`= 1802 AND `SourceEntry`=0;
+INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
+(15, 1802, 0, 0, 0, 9, 0, 3909, 0, 0, 0, 0, 0, "", "Show Gossip Menu Option menu_id 1802 id 0 if Quest 3909 is taken (active)");
diff --git a/sql/updates/world/master/2017_01_12_18_world_2016_06_09_04_world.sql b/sql/updates/world/master/2017_01_12_18_world_2016_06_09_04_world.sql
new file mode 100644
index 00000000000..ecff9eb7ce6
--- /dev/null
+++ b/sql/updates/world/master/2017_01_12_18_world_2016_06_09_04_world.sql
@@ -0,0 +1,6 @@
+-- NPC ID 17603 Grandmother gossip_menu_option (new rows)
+DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (7441,7442,7443);
+INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES
+(7441,0,0,"Oh, grandmother, what big ears you have.", 14217,0,0,7442,0,0,0,'',0),
+(7442,0,0,"Oh, grandmother, what big eyes you have.", 14219,0,0,7443,0,0,0,'',0),
+(7443,0,0,"Oh, grandmother, what phat lewts you have.",14221,0,0, 0,0,0,0,'',0);
diff --git a/sql/updates/world/master/2017_01_12_19_world_2016_06_09_05_world.sql b/sql/updates/world/master/2017_01_12_19_world_2016_06_09_05_world.sql
new file mode 100644
index 00000000000..50c99117c03
--- /dev/null
+++ b/sql/updates/world/master/2017_01_12_19_world_2016_06_09_05_world.sql
@@ -0,0 +1,82 @@
+-- NPC entry 29665 (Pazik "The Pick" Prylock), 29725 (Benik Boltshear) and 29728 (Walter Soref)
+SET @MENU_ID := 9823;
+SET @Pazik := 29665;
+SET @Benik := 29725;
+SET @Walter := 29728;
+
+-- Corrected gossip menu options based on text found in broadcast_text:
+DELETE FROM `gossip_menu_option` WHERE `menu_id` = @MENU_ID;
+INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES
+(@MENU_ID, 0,0, "I've lost my key to Scholomance.", 30315,1,1,0,0,0,0,'',0),
+(@MENU_ID, 1,0, "I've lost my key to The Arcatraz.", 30316,1,1,0,0,0,0,'',0),
+(@MENU_ID, 2,0, "I've lost my key to The Shattered Halls.", 30317,1,1,0,0,0,0,'',0),
+(@MENU_ID, 3,0, "I've lost my key to Searing Gorge.", 30318,1,1,0,0,0,0,'',0),
+(@MENU_ID, 4,0, "I've lost my Shadowforge Key.", 30319,1,1,0,0,0,0,'',0),
+(@MENU_ID, 5,0, "I've lost The Eye of Haramad.", 30320,1,1,0,0,0,0,'',0),
+(@MENU_ID, 6,0, "I've lost my key to Karazhan.", 30321,1,1,0,0,0,0,'',0),
+(@MENU_ID, 7,0, "I've lost my key to the Violet Hold.", 35500,1,1,0,0,0,0,'',0),
+(@MENU_ID, 8,0, "I've lost my Essence-Infused Moonstone. Can you replace it?", 20969,1,1,0,0,0,0,'',0);
+
+-- Walter Soref is missing his npcflag for gossip (the other 2 locksmiths are OK)
+UPDATE `creature` SET `npcflag`=(`npcflag`|1) WHERE `id` = @Walter;
+
+UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName`= '' WHERE `entry` IN (@Pazik,@Benik,@Walter);
+
+DELETE FROM `smart_scripts` WHERE `source_type` = 0 AND `entryorguid` IN (@Pazik,@Benik,@Walter);
+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`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
+(@Pazik, 0,0,9,62,0,100,0,9823,0,0,0,11,54883,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 0 selected - cast 'Create Skeleton Key'"),
+(@Pazik, 0,1,9,62,0,100,0,9823,1,0,0,11,54881,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 1 selected - cast 'Create Key to the Arcatraz'"),
+(@Pazik, 0,2,9,62,0,100,0,9823,2,0,0,11,54884,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 2 selected - cast 'Create Shattered Halls Key'"),
+(@Pazik, 0,3,9,62,0,100,0,9823,3,0,0,11,54880,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 3 selected - cast 'Create Key to Searing Gorge'"),
+(@Pazik, 0,4,9,62,0,100,0,9823,4,0,0,11,54882,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 4 selected - cast 'Create Shadowforge Key'"),
+(@Pazik, 0,5,9,62,0,100,0,9823,5,0,0,11,54887,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 5 selected - cast 'Create They Eye of Haramad'"),
+(@Pazik, 0,6,9,62,0,100,0,9823,6,0,0,11,54885,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 6 selected - cast 'Create The Master's Key'"),
+(@Pazik, 0,7,9,62,0,100,0,9823,7,0,0,11,67253,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 7 selected - cast 'Create The Violet Hold Key'"),
+(@Pazik, 0,8,9,62,0,100,0,9823,8,0,0,11,40173,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option 8 selected - cast 'Create Essence-Infused Moonstone'"),
+(@Pazik, 0,9,0,61,0,100,0, 0,0,0,0,72, 0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Pazik \"The Pick\" Prylock - on Gossip Option * selected - close Gossip"),
+(@Benik, 0,0,9,62,0,100,0,9823,0,0,0,11,54883,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 0 selected - cast 'Create Skeleton Key'"),
+(@Benik, 0,1,9,62,0,100,0,9823,1,0,0,11,54881,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 1 selected - cast 'Create Key to the Arcatraz'"),
+(@Benik, 0,2,9,62,0,100,0,9823,2,0,0,11,54884,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 2 selected - cast 'Create Shattered Halls Key'"),
+(@Benik, 0,3,9,62,0,100,0,9823,3,0,0,11,54880,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 3 selected - cast 'Create Key to Searing Gorge'"),
+(@Benik, 0,4,9,62,0,100,0,9823,4,0,0,11,54882,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 4 selected - cast 'Create Shadowforge Key'"),
+(@Benik, 0,5,9,62,0,100,0,9823,5,0,0,11,54887,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 5 selected - cast 'Create They Eye of Haramad'"),
+(@Benik, 0,6,9,62,0,100,0,9823,6,0,0,11,54885,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 6 selected - cast 'Create The Master's Key'"),
+(@Benik, 0,7,9,62,0,100,0,9823,7,0,0,11,67253,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 7 selected - cast 'Create The Violet Hold Key'"),
+(@Benik, 0,8,9,62,0,100,0,9823,8,0,0,11,40173,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option 8 selected - cast 'Create Essence-Infused Moonstone'"),
+(@Benik, 0,9,0,61,0,100,0, 0,0,0,0,72, 0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Benik Boltshear - on Gossip Option * selected - close Gossip"),
+(@Walter,0,0,9,62,0,100,0,9823,0,0,0,11,54883,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 0 selected - cast 'Create Skeleton Key'"),
+(@Walter,0,1,9,62,0,100,0,9823,1,0,0,11,54881,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 1 selected - cast 'Create Key to the Arcatraz'"),
+(@Walter,0,2,9,62,0,100,0,9823,2,0,0,11,54884,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 2 selected - cast 'Create Shattered Halls Key'"),
+(@Walter,0,3,9,62,0,100,0,9823,3,0,0,11,54880,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 3 selected - cast 'Create Key to Searing Gorge'"),
+(@Walter,0,4,9,62,0,100,0,9823,4,0,0,11,54882,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 4 selected - cast 'Create Shadowforge Key'"),
+(@Walter,0,5,9,62,0,100,0,9823,5,0,0,11,54887,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 5 selected - cast 'Create They Eye of Haramad'"),
+(@Walter,0,6,9,62,0,100,0,9823,6,0,0,11,54885,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 6 selected - cast 'Create The Master's Key'"),
+(@Walter,0,7,9,62,0,100,0,9823,7,0,0,11,67253,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 7 selected - cast 'Create The Violet Hold Key'"),
+(@Walter,0,8,9,62,0,100,0,9823,8,0,0,11,40173,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option 8 selected - cast 'Create Essence-Infused Moonstone'"),
+(@Walter,0,9,0,61,0,100,0, 0,0,0,0,72, 0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Walter Soref - on Gossip Option * selected - close Gossip");
+
+-- conditions for gossip_menu_option.menu_id 9823:
+DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup`= @MENU_ID;
+INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
+(15,@MENU_ID,0,0, 0, 8,0, 5505,0,0, 0,0,0,'',"Show gossip option 9823 id 0 if quest 5505 is rewarded AND player does NOT have item 13704."),
+(15,@MENU_ID,0,0, 0, 2,0,13704,1,0, 1,0,0,'',"Show gossip option 9823 id 0 if player does NOT have item 13704 AND quest 5505 is rewarded."),
+(15,@MENU_ID,0,0, 1, 8,0, 5511,0,0, 0,0,0,'',"Show gossip option 9823 id 0 if quest 5511 is rewarded AND player does NOT have item 13704."),
+(15,@MENU_ID,0,0, 1, 2,0,13704,1,0, 1,0,0,'',"Show gossip option 9823 id 0 if player does NOT have item 13704 AND quest 5511 is rewarded."),
+(15,@MENU_ID,1,0, 0, 8,0,10704,0,0, 0,0,0,'',"Show gossip option 9823 id 1 if quest 10704 is rewarded AND player does NOT have item 31084."),
+(15,@MENU_ID,1,0, 0, 2,0,31084,1,0, 1,0,0,'',"Show gossip option 9823 id 1 if player does NOT have item 31084 AND quest 10704 is rewarded."),
+(15,@MENU_ID,2,0, 0, 8,0,10758,0,0, 0,0,0,'',"Show gossip option 9823 id 2 if quest 10758 is rewarded AND player does NOT have item 28395."),
+(15,@MENU_ID,2,0, 0, 2,0,28395,1,0, 1,0,0,'',"Show gossip option 9823 id 2 if player does NOT have item 28395 AND quest 10758 is rewarded."),
+(15,@MENU_ID,2,0, 1, 8,0,10764,0,0, 0,0,0,'',"Show gossip option 9823 id 2 if quest 10764 is rewarded AND player does NOT have item 28395."),
+(15,@MENU_ID,2,0, 1, 2,0,28395,1,0, 1,0,0,'',"Show gossip option 9823 id 2 if player does NOT have item 28395 AND quest 10764 is rewarded."),
+(15,@MENU_ID,3,0, 0, 8,0, 3201,0,0, 0,0,0,'',"Show gossip option 9823 id 3 if quest 3201 is rewarded AND player does NOT have item 5396."),
+(15,@MENU_ID,3,0, 0, 2,0, 5396,1,0, 1,0,0,'',"Show gossip option 9823 id 3 if player does NOT have item 5396 AND quest 3201 is rewarded."),
+(15,@MENU_ID,4,0, 0, 8,0, 3802,0,0, 0,0,0,'',"Show gossip option 9823 id 4 if quest 3802 is rewarded AND player does NOT have item 11000."),
+(15,@MENU_ID,4,0, 0, 2,0,11000,1,0, 1,0,0,'',"Show gossip option 9823 id 4 if player does NOT have item 11000 AND quest 3802 is rewarded."),
+(15,@MENU_ID,5,0, 0, 8,0,10982,0,0, 0,0,0,'',"Show gossip option 9823 id 5 if quest 10982 is rewarded AND player does NOT have item 32092."),
+(15,@MENU_ID,5,0, 0, 2,0,32092,1,0, 1,0,0,'',"Show gossip option 9823 id 5 if player does NOT have item 32092 AND quest 10982 is rewarded."),
+(15,@MENU_ID,6,0, 0, 8,0, 9837,0,0, 0,0,0,'',"Show gossip option 9823 id 6 if quest 9837 is rewarded AND player does NOT have item 24490."),
+(15,@MENU_ID,6,0, 0, 2,0,24490,1,0, 1,0,0,'',"Show gossip option 9823 id 6 if player does NOT have item 24490 AND quest 9837 is rewarded."),
+(15,@MENU_ID,7,0, 0, 8,0,13159,0,0, 0,0,0,'',"Show gossip option 9823 id 7 if quest 13159 is rewarded AND player does NOT have item 42482."),
+(15,@MENU_ID,7,0, 0, 2,0,42482,1,0, 1,0,0,'',"Show gossip option 9823 id 7 if player does NOT have item 42482 AND quest 13159 is rewarded."),
+(15,@MENU_ID,8,0, 0, 8,0,11011,0,0, 0,0,0,'',"Show gossip option 9823 id 8 if quest 11011 is rewarded AND player does NOT have item 32449."),
+(15,@MENU_ID,8,0, 0, 2,0,32449,1,0, 1,0,0,'',"Show gossip option 9823 id 8 if player does NOT have item 32449 AND quest 11011 is rewarded.");
diff --git a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp
index a9ff21f4881..63d0d020417 100644
--- a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp
+++ b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp
@@ -797,46 +797,44 @@ enum RedRidingHood
SAY_WOLF_AGGRO = 0,
SAY_WOLF_SLAY = 1,
SAY_WOLF_HOOD = 2,
+ OPTION_WHAT_PHAT_LEWTS_YOU_HAVE = 7443,
SOUND_WOLF_DEATH = 9275,
SPELL_LITTLE_RED_RIDING_HOOD = 30768,
SPELL_TERRIFYING_HOWL = 30752,
SPELL_WIDE_SWIPE = 30761,
- CREATURE_BIG_BAD_WOLF = 17521,
+ CREATURE_BIG_BAD_WOLF = 17521
};
-
-#define GOSSIP_GRANDMA "What phat lewtz you have grandmother?"
-
-
-
class npc_grandmother : public CreatureScript
{
-public:
- npc_grandmother() : CreatureScript("npc_grandmother") { }
+ public:
+ npc_grandmother() : CreatureScript("npc_grandmother") { }
- bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action) override
- {
- player->PlayerTalkClass->ClearMenus();
- if (action == GOSSIP_ACTION_INFO_DEF)
+ struct npc_grandmotherAI : public ScriptedAI
{
- if (Creature* pBigBadWolf = creature->SummonCreature(CREATURE_BIG_BAD_WOLF, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
- pBigBadWolf->AI()->AttackStart(player);
+ npc_grandmotherAI(Creature* creature) : ScriptedAI(creature) { }
- creature->DespawnOrUnsummon();
- }
- return true;
- }
+ void sGossipSelect(Player* player, uint32 menuId, uint32 gossipListId) override
+ {
+ if (menuId == OPTION_WHAT_PHAT_LEWTS_YOU_HAVE && gossipListId == 0)
+ {
+ player->CLOSE_GOSSIP_MENU();
- bool OnGossipHello(Player* player, Creature* creature) override
- {
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_GRANDMA, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF);
- player->SEND_GOSSIP_MENU(8990, creature->GetGUID());
+ if (Creature* pBigBadWolf = me->SummonCreature(CREATURE_BIG_BAD_WOLF, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
+ pBigBadWolf->AI()->AttackStart(player);
- return true;
- }
+ me->DespawnOrUnsummon();
+ }
+ }
+ };
+
+ CreatureAI* GetAI(Creature* creature) const override
+ {
+ return new npc_grandmotherAI(creature);
+ }
};
class boss_bigbadwolf : public CreatureScript
diff --git a/src/server/scripts/World/npcs_special.cpp b/src/server/scripts/World/npcs_special.cpp
index 2e91859fb26..dfd203be7b7 100644
--- a/src/server/scripts/World/npcs_special.cpp
+++ b/src/server/scripts/World/npcs_special.cpp
@@ -36,7 +36,6 @@ npc_doctor 100% Gustaf Vanhowzen and Gregory Victor, quest 6622
npc_sayge 100% Darkmoon event fortune teller, buff player based on answers given
npc_snake_trap_serpents 80% AI for snakes that summoned by Snake Trap
npc_shadowfiend 100% restore 5% of owner's mana when shadowfiend die from damage
-npc_locksmith 75% list of keys needs to be confirmed
npc_firework 100% NPC's summoned by rockets and rocket clusters, for making them cast visual
npc_train_wrecker 100% Wind-Up Train Wrecker that kills train set
EndContentData */
@@ -1182,36 +1181,49 @@ public:
enum Sayge
{
- SPELL_DMG = 23768, // dmg
- SPELL_RES = 23769, // res
- SPELL_ARM = 23767, // arm
- SPELL_SPI = 23738, // spi
- SPELL_INT = 23766, // int
- SPELL_STM = 23737, // stm
- SPELL_STR = 23735, // str
- SPELL_AGI = 23736, // agi
- SPELL_FORTUNE = 23765 // faire fortune
+ GOSSIP_MENU_OPTION_ID_ANSWER_1 = 0,
+ GOSSIP_MENU_OPTION_ID_ANSWER_2 = 1,
+ GOSSIP_MENU_OPTION_ID_ANSWER_3 = 2,
+ GOSSIP_MENU_OPTION_ID_ANSWER_4 = 3,
+ GOSSIP_I_AM_READY_TO_DISCOVER = 6186,
+ GOSSIP_MENU_OPTION_SAYGE1 = 6185,
+ GOSSIP_MENU_OPTION_SAYGE2 = 6185,
+ GOSSIP_MENU_OPTION_SAYGE3 = 6185,
+ GOSSIP_MENU_OPTION_SAYGE4 = 6185,
+ GOSSIP_MENU_OPTION_SAYGE5 = 6187,
+ GOSSIP_MENU_OPTION_SAYGE6 = 6187,
+ GOSSIP_MENU_OPTION_SAYGE7 = 6187,
+ GOSSIP_MENU_OPTION_SAYGE8 = 6208,
+ GOSSIP_MENU_OPTION_SAYGE9 = 6208,
+ GOSSIP_MENU_OPTION_SAYGE10 = 6208,
+ GOSSIP_MENU_OPTION_SAYGE11 = 6209,
+ GOSSIP_MENU_OPTION_SAYGE12 = 6209,
+ GOSSIP_MENU_OPTION_SAYGE13 = 6209,
+ GOSSIP_MENU_OPTION_SAYGE14 = 6210,
+ GOSSIP_MENU_OPTION_SAYGE15 = 6210,
+ GOSSIP_MENU_OPTION_SAYGE16 = 6210,
+ GOSSIP_MENU_OPTION_SAYGE17 = 6211,
+ GOSSIP_MENU_I_HAVE_LONG_KNOWN = 7339,
+ GOSSIP_MENU_YOU_HAVE_BEEN_TASKED = 7340,
+ GOSSIP_MENU_SWORN_EXECUTIONER = 7341,
+ GOSSIP_MENU_DIPLOMATIC_MISSION = 7361,
+ GOSSIP_MENU_YOUR_BROTHER_SEEKS = 7362,
+ GOSSIP_MENU_A_TERRIBLE_BEAST = 7363,
+ GOSSIP_MENU_YOUR_FORTUNE_IS_CAST = 7364,
+ GOSSIP_MENU_HERE_IS_YOUR_FORTUNE = 7365,
+ GOSSIP_MENU_CANT_GIVE_YOU_YOUR = 7393,
+
+ SPELL_STRENGTH = 23735, // +10% Strength
+ SPELL_AGILITY = 23736, // +10% Agility
+ SPELL_STAMINA = 23737, // +10% Stamina
+ SPELL_SPIRIT = 23738, // +10% Spirit
+ SPELL_INTELLECT = 23766, // +10% Intellect
+ SPELL_ARMOR = 23767, // +10% Armor
+ SPELL_DAMAGE = 23768, // +10% Damage
+ SPELL_RESISTANCE = 23769, // +25 Magic Resistance (All)
+ SPELL_FORTUNE = 23765 // Darkmoon Faire Fortune
};
-#define GOSSIP_HELLO_SAYGE "Yes"
-#define GOSSIP_SENDACTION_SAYGE1 "Slay the Man"
-#define GOSSIP_SENDACTION_SAYGE2 "Turn him over to liege"
-#define GOSSIP_SENDACTION_SAYGE3 "Confiscate the corn"
-#define GOSSIP_SENDACTION_SAYGE4 "Let him go and have the corn"
-#define GOSSIP_SENDACTION_SAYGE5 "Execute your friend painfully"
-#define GOSSIP_SENDACTION_SAYGE6 "Execute your friend painlessly"
-#define GOSSIP_SENDACTION_SAYGE7 "Let your friend go"
-#define GOSSIP_SENDACTION_SAYGE8 "Confront the diplomat"
-#define GOSSIP_SENDACTION_SAYGE9 "Show not so quiet defiance"
-#define GOSSIP_SENDACTION_SAYGE10 "Remain quiet"
-#define GOSSIP_SENDACTION_SAYGE11 "Speak against your brother openly"
-#define GOSSIP_SENDACTION_SAYGE12 "Help your brother in"
-#define GOSSIP_SENDACTION_SAYGE13 "Keep your brother out without letting him know"
-#define GOSSIP_SENDACTION_SAYGE14 "Take credit, keep gold"
-#define GOSSIP_SENDACTION_SAYGE15 "Take credit, share the gold"
-#define GOSSIP_SENDACTION_SAYGE16 "Let the knight take credit"
-#define GOSSIP_SENDACTION_SAYGE17 "Thanks"
-
class npc_sayge : public CreatureScript
{
public:
@@ -1222,19 +1234,19 @@ public:
if (creature->IsQuestGiver())
player->PrepareQuestMenu(creature->GetGUID());
- if (player->GetSpellHistory()->HasCooldown(SPELL_INT) ||
- player->GetSpellHistory()->HasCooldown(SPELL_ARM) ||
- player->GetSpellHistory()->HasCooldown(SPELL_DMG) ||
- player->GetSpellHistory()->HasCooldown(SPELL_RES) ||
- player->GetSpellHistory()->HasCooldown(SPELL_STR) ||
- player->GetSpellHistory()->HasCooldown(SPELL_AGI) ||
- player->GetSpellHistory()->HasCooldown(SPELL_STM) ||
- player->GetSpellHistory()->HasCooldown(SPELL_SPI))
- player->SEND_GOSSIP_MENU(7393, creature->GetGUID());
+ if (player->GetSpellHistory()->HasCooldown(SPELL_STRENGTH) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_AGILITY) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_STAMINA) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_SPIRIT) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_INTELLECT) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_ARMOR) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_DAMAGE) ||
+ player->GetSpellHistory()->HasCooldown(SPELL_RESISTANCE))
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_CANT_GIVE_YOU_YOUR, creature->GetGUID());
else
{
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HELLO_SAYGE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
- player->SEND_GOSSIP_MENU(7339, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_I_AM_READY_TO_DISCOVER, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_I_HAVE_LONG_KNOWN, creature->GetGUID());
}
return true;
@@ -1245,43 +1257,43 @@ public:
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE4, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5);
- player->SEND_GOSSIP_MENU(7340, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE1, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE2, GOSSIP_MENU_OPTION_ID_ANSWER_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE3, GOSSIP_MENU_OPTION_ID_ANSWER_3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE4, GOSSIP_MENU_OPTION_ID_ANSWER_4, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_YOU_HAVE_BEEN_TASKED, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE5, GOSSIP_SENDER_MAIN + 1, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE6, GOSSIP_SENDER_MAIN + 2, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE7, GOSSIP_SENDER_MAIN + 3, GOSSIP_ACTION_INFO_DEF);
- player->SEND_GOSSIP_MENU(7341, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE5, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN + 1, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE6, GOSSIP_MENU_OPTION_ID_ANSWER_2, GOSSIP_SENDER_MAIN + 2, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE7, GOSSIP_MENU_OPTION_ID_ANSWER_3, GOSSIP_SENDER_MAIN + 3, GOSSIP_ACTION_INFO_DEF);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_SWORN_EXECUTIONER, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE8, GOSSIP_SENDER_MAIN + 4, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE9, GOSSIP_SENDER_MAIN + 5, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE10, GOSSIP_SENDER_MAIN + 2, GOSSIP_ACTION_INFO_DEF);
- player->SEND_GOSSIP_MENU(7361, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE8, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN + 4, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE9, GOSSIP_MENU_OPTION_ID_ANSWER_2, GOSSIP_SENDER_MAIN + 5, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE10,GOSSIP_MENU_OPTION_ID_ANSWER_3, GOSSIP_SENDER_MAIN + 2, GOSSIP_ACTION_INFO_DEF);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_DIPLOMATIC_MISSION, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE11, GOSSIP_SENDER_MAIN + 6, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE12, GOSSIP_SENDER_MAIN + 7, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE13, GOSSIP_SENDER_MAIN + 8, GOSSIP_ACTION_INFO_DEF);
- player->SEND_GOSSIP_MENU(7362, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE11, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN + 6, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE12, GOSSIP_MENU_OPTION_ID_ANSWER_2, GOSSIP_SENDER_MAIN + 7, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE13, GOSSIP_MENU_OPTION_ID_ANSWER_3, GOSSIP_SENDER_MAIN + 8, GOSSIP_ACTION_INFO_DEF);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_YOUR_BROTHER_SEEKS, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE14, GOSSIP_SENDER_MAIN + 5, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE15, GOSSIP_SENDER_MAIN + 4, GOSSIP_ACTION_INFO_DEF);
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE16, GOSSIP_SENDER_MAIN + 3, GOSSIP_ACTION_INFO_DEF);
- player->SEND_GOSSIP_MENU(7363, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE14, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN + 5, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE15, GOSSIP_MENU_OPTION_ID_ANSWER_2, GOSSIP_SENDER_MAIN + 4, GOSSIP_ACTION_INFO_DEF);
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE16, GOSSIP_MENU_OPTION_ID_ANSWER_3, GOSSIP_SENDER_MAIN + 3, GOSSIP_ACTION_INFO_DEF);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_A_TERRIBLE_BEAST, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF:
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SENDACTION_SAYGE17, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 6);
- player->SEND_GOSSIP_MENU(7364, creature->GetGUID());
+ player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_OPTION_SAYGE17, GOSSIP_MENU_OPTION_ID_ANSWER_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 6);
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_YOUR_FORTUNE_IS_CAST, creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6:
creature->CastSpell(player, SPELL_FORTUNE, false);
- player->SEND_GOSSIP_MENU(7365, creature->GetGUID());
+ player->SEND_GOSSIP_MENU(GOSSIP_MENU_HERE_IS_YOUR_FORTUNE, creature->GetGUID());
break;
}
}
@@ -1289,52 +1301,44 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 sender, uint32 action) override
{
player->PlayerTalkClass->ClearMenus();
+ uint32 spellId = 0;
switch (sender)
{
case GOSSIP_SENDER_MAIN:
SendAction(player, creature, action);
break;
case GOSSIP_SENDER_MAIN + 1:
- creature->CastSpell(player, SPELL_DMG, false);
- player->GetSpellHistory()->AddCooldown(SPELL_DMG, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_DAMAGE;
break;
case GOSSIP_SENDER_MAIN + 2:
- creature->CastSpell(player, SPELL_RES, false);
- player->GetSpellHistory()->AddCooldown(SPELL_RES, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_RESISTANCE;
break;
case GOSSIP_SENDER_MAIN + 3:
- creature->CastSpell(player, SPELL_ARM, false);
- player->GetSpellHistory()->AddCooldown(SPELL_ARM, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_ARMOR;
break;
case GOSSIP_SENDER_MAIN + 4:
- creature->CastSpell(player, SPELL_SPI, false);
- player->GetSpellHistory()->AddCooldown(SPELL_SPI, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_SPIRIT;
break;
case GOSSIP_SENDER_MAIN + 5:
- creature->CastSpell(player, SPELL_INT, false);
- player->GetSpellHistory()->AddCooldown(SPELL_INT, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_INTELLECT;
break;
case GOSSIP_SENDER_MAIN + 6:
- creature->CastSpell(player, SPELL_STM, false);
- player->GetSpellHistory()->AddCooldown(SPELL_STM, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_STAMINA;
break;
case GOSSIP_SENDER_MAIN + 7:
- creature->CastSpell(player, SPELL_STR, false);
- player->GetSpellHistory()->AddCooldown(SPELL_STR, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_STRENGTH;
break;
case GOSSIP_SENDER_MAIN + 8:
- creature->CastSpell(player, SPELL_AGI, false);
- player->GetSpellHistory()->AddCooldown(SPELL_AGI, 0, std::chrono::hours(2));
- SendAction(player, creature, action);
+ spellId = SPELL_AGILITY;
break;
}
+
+ if (spellId)
+ {
+ creature->CastSpell(player, spellId, false);
+ player->GetSpellHistory()->AddCooldown(spellId, 0, std::chrono::hours(2));
+ SendAction(player, creature, action);
+ }
return true;
}
};
@@ -1746,149 +1750,6 @@ public:
};
/*######
-## npc_locksmith
-######*/
-
-enum LockSmith
-{
- QUEST_HOW_TO_BRAKE_IN_TO_THE_ARCATRAZ = 10704,
- QUEST_DARK_IRON_LEGACY = 3802,
- QUEST_THE_KEY_TO_SCHOLOMANCE_A = 5505,
- QUEST_THE_KEY_TO_SCHOLOMANCE_H = 5511,
- QUEST_HOTTER_THAN_HELL_A = 10758,
- QUEST_HOTTER_THAN_HELL_H = 10764,
- QUEST_RETURN_TO_KHAGDAR = 9837,
- QUEST_CONTAINMENT = 13159,
- QUEST_ETERNAL_VIGILANCE = 11011,
- QUEST_KEY_TO_THE_FOCUSING_IRIS = 13372,
- QUEST_HC_KEY_TO_THE_FOCUSING_IRIS = 13375,
-
- ITEM_ARCATRAZ_KEY = 31084,
- ITEM_SHADOWFORGE_KEY = 11000,
- ITEM_SKELETON_KEY = 13704,
- ITEM_SHATTERED_HALLS_KEY = 28395,
- ITEM_THE_MASTERS_KEY = 24490,
- ITEM_VIOLET_HOLD_KEY = 42482,
- ITEM_ESSENCE_INFUSED_MOONSTONE = 32449,
- ITEM_KEY_TO_THE_FOCUSING_IRIS = 44582,
- ITEM_HC_KEY_TO_THE_FOCUSING_IRIS = 44581,
-
- SPELL_ARCATRAZ_KEY = 54881,
- SPELL_SHADOWFORGE_KEY = 54882,
- SPELL_SKELETON_KEY = 54883,
- SPELL_SHATTERED_HALLS_KEY = 54884,
- SPELL_THE_MASTERS_KEY = 54885,
- SPELL_VIOLET_HOLD_KEY = 67253,
- SPELL_ESSENCE_INFUSED_MOONSTONE = 40173,
-};
-
-#define GOSSIP_LOST_ARCATRAZ_KEY "I've lost my key to the Arcatraz."
-#define GOSSIP_LOST_SHADOWFORGE_KEY "I've lost my key to the Blackrock Depths."
-#define GOSSIP_LOST_SKELETON_KEY "I've lost my key to the Scholomance."
-#define GOSSIP_LOST_SHATTERED_HALLS_KEY "I've lost my key to the Shattered Halls."
-#define GOSSIP_LOST_THE_MASTERS_KEY "I've lost my key to the Karazhan."
-#define GOSSIP_LOST_VIOLET_HOLD_KEY "I've lost my key to the Violet Hold."
-#define GOSSIP_LOST_ESSENCE_INFUSED_MOONSTONE "I've lost my Essence-Infused Moonstone."
-#define GOSSIP_LOST_KEY_TO_THE_FOCUSING_IRIS "I've lost my Key to the Focusing Iris."
-#define GOSSIP_LOST_HC_KEY_TO_THE_FOCUSING_IRIS "I've lost my Heroic Key to the Focusing Iris."
-
-class npc_locksmith : public CreatureScript
-{
-public:
- npc_locksmith() : CreatureScript("npc_locksmith") { }
-
- bool OnGossipHello(Player* player, Creature* creature) override
- {
- // Arcatraz Key
- if (player->GetQuestRewardStatus(QUEST_HOW_TO_BRAKE_IN_TO_THE_ARCATRAZ) && !player->HasItemCount(ITEM_ARCATRAZ_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_ARCATRAZ_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
-
- // Shadowforge Key
- if (player->GetQuestRewardStatus(QUEST_DARK_IRON_LEGACY) && !player->HasItemCount(ITEM_SHADOWFORGE_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_SHADOWFORGE_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
-
- // Skeleton Key
- if ((player->GetQuestRewardStatus(QUEST_THE_KEY_TO_SCHOLOMANCE_A) || player->GetQuestRewardStatus(QUEST_THE_KEY_TO_SCHOLOMANCE_H)) &&
- !player->HasItemCount(ITEM_SKELETON_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_SKELETON_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
-
- // Shatered Halls Key
- if ((player->GetQuestRewardStatus(QUEST_HOTTER_THAN_HELL_A) || player->GetQuestRewardStatus(QUEST_HOTTER_THAN_HELL_H)) &&
- !player->HasItemCount(ITEM_SHATTERED_HALLS_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_SHATTERED_HALLS_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4);
-
- // Master's Key
- if (player->GetQuestRewardStatus(QUEST_RETURN_TO_KHAGDAR) && !player->HasItemCount(ITEM_THE_MASTERS_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_THE_MASTERS_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5);
-
- // Violet Hold Key
- if (player->GetQuestRewardStatus(QUEST_CONTAINMENT) && !player->HasItemCount(ITEM_VIOLET_HOLD_KEY, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_VIOLET_HOLD_KEY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 6);
-
- // Essence-Infused Moonstone
- if (player->GetQuestRewardStatus(QUEST_ETERNAL_VIGILANCE) && !player->HasItemCount(ITEM_ESSENCE_INFUSED_MOONSTONE, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_ESSENCE_INFUSED_MOONSTONE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 7);
-
- // Key to the Focusing Iris
- if (player->GetQuestRewardStatus(QUEST_KEY_TO_THE_FOCUSING_IRIS) && !player->HasItemCount(ITEM_KEY_TO_THE_FOCUSING_IRIS, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_KEY_TO_THE_FOCUSING_IRIS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 8);
-
- // Heroic Key to the Focusing Iris
- if (player->GetQuestRewardStatus(QUEST_HC_KEY_TO_THE_FOCUSING_IRIS) && !player->HasItemCount(ITEM_HC_KEY_TO_THE_FOCUSING_IRIS, 1, true))
- player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_LOST_HC_KEY_TO_THE_FOCUSING_IRIS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 9);
-
- player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID());
-
- return true;
- }
-
- bool OnGossipSelect(Player* player, Creature* /*creature*/, uint32 /*sender*/, uint32 action) override
- {
- player->PlayerTalkClass->ClearMenus();
- switch (action)
- {
- case GOSSIP_ACTION_INFO_DEF + 1:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_ARCATRAZ_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 2:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_SHADOWFORGE_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 3:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_SKELETON_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 4:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_SHATTERED_HALLS_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 5:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_THE_MASTERS_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 6:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_VIOLET_HOLD_KEY, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 7:
- player->CLOSE_GOSSIP_MENU();
- player->CastSpell(player, SPELL_ESSENCE_INFUSED_MOONSTONE, false);
- break;
- case GOSSIP_ACTION_INFO_DEF + 8:
- player->CLOSE_GOSSIP_MENU();
- player->AddItem(ITEM_KEY_TO_THE_FOCUSING_IRIS, 1);
- break;
- case GOSSIP_ACTION_INFO_DEF + 9:
- player->CLOSE_GOSSIP_MENU();
- player->AddItem(ITEM_HC_KEY_TO_THE_FOCUSING_IRIS, 1);
- break;
- }
- return true;
- }
-};
-
-/*######
## npc_experience
######*/
@@ -2530,7 +2391,6 @@ void AddSC_npcs_special()
new npc_training_dummy();
new npc_wormhole();
new npc_pet_trainer();
- new npc_locksmith();
new npc_experience();
new npc_firework();
new npc_spring_rabbit();