diff options
22 files changed, 386 insertions, 73 deletions
diff --git a/sql/updates/world/2014_08_24_00_world_sai_335.sql b/sql/updates/world/2014_08_24_00_world_sai_335.sql new file mode 100644 index 00000000000..3b5ba744da3 --- /dev/null +++ b/sql/updates/world/2014_08_24_00_world_sai_335.sql @@ -0,0 +1,160 @@ +-- Balizar the Umbrage SAI +SET @ENTRY := 3899; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=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`,`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 +(@ENTRY,0,0,0,0,0,100,0,1000,2000,10000,15000,11,14868,0,0,0,0,0,2,0,0,0,0,0,0,0,"Balizar the Umbrage - In Combat - Cast 'Curse of Agony'"), +(@ENTRY,0,1,0,0,0,100,0,3000,4000,11000,16000,11,11980,0,0,0,0,0,2,0,0,0,0,0,0,0,"Balizar the Umbrage - In Combat - Cast 'Curse of Weakness'"), +(@ENTRY,0,2,0,0,0,100,0,7000,8000,7000,8000,11,20791,0,0,0,0,0,2,0,0,0,0,0,0,0,"Balizar the Umbrage - In Combat - Cast 'Shadow Bolt'"), +(@ENTRY,0,3,0,54,0,100,0,0,0,0,0,18,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Balizar the Umbrage - On Just Summoned - Set Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,4,5,38,0,100,0,1,1,0,0,19,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Balizar the Umbrage - On Data Set - Remove Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,5,6,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,19,3900,0,0,0,0,0,0,"Balizar the Umbrage - On Data Set - Set Data Caedakar the Vicious"), +(@ENTRY,0,6,0,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,19,3898,0,0,0,0,0,0,"Balizar the Umbrage - On Data Set - Set Data Aligar the Tormentor"); + +-- Dark Strand Forsaken Scout SAI +SET @ENTRY := 3893; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=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`,`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 +(@ENTRY,0,0,0,54,0,100,0,0,0,0,0,18,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Forsaken Scout - On Just Summoned - Set Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,1,0,38,0,100,0,1,1,0,0,19,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Forsaken Scout - On Data Set - Remove Unit Flags - Immune to NPC/NPC"); + + +-- Dark Strand Assassin SAI +SET @ENTRY := 3879; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=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`,`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 +(@ENTRY,0,0,0,0,0,100,0,0,5000,11000,18000,11,3405,0,0,0,0,0,2,0,0,0,0,0,0,0,"Dark Strand Assassin - IC - Cast Soul Rend"), +(@ENTRY,0,1,0,0,0,100,0,5000,9000,15000,21000,11,11675,64,0,0,0,0,2,0,0,0,0,0,0,0,"Dark Strand Assassin - IC - Cast Drain Soul"), +(@ENTRY,0,2,0,54,0,100,0,0,0,0,0,18,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Dark Strand Assassin - On Just Summoned - Set Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,3,0,38,0,100,0,1,1,0,0,19,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Dark Strand Assassin - On Data Set - Remove Unit Flags - Immune to NPC/NPC"); + +-- Caedakar the Vicious SAI +SET @ENTRY := 3900; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=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`,`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 +(@ENTRY,0,0,0,54,0,100,1,0,0,0,0,11,7165,2,0,0,0,0,1,0,0,0,0,0,0,0,"Caedakar the Vicious - On Just Summoned - Cast 'Battle Stance' (No Repeat)"), +(@ENTRY,0,1,0,0,0,100,0,4000,9000,11000,16000,11,9080,0,0,0,0,0,2,0,0,0,0,0,0,0,"Caedakar the Vicious - In Combat - Cast 'Hamstring'"), +(@ENTRY,0,2,0,0,0,100,1,3000,4000,8000,15000,11,25712,0,0,0,0,0,2,0,0,0,0,0,0,0,"Caedakar the Vicious - In Combat - Cast 'Heroic Strike' (No Repeat)"), +(@ENTRY,0,3,0,54,0,100,0,0,0,0,0,18,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Caedakar the Vicious - On Just Summoned - Set Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,4,0,38,0,100,0,1,1,0,0,19,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Caedakar the Vicious - On Data Set - Remove Unit Flags - Immune to NPC/NPC"); + +-- Aligar the Tormentor SAI +SET @ENTRY := 3898; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=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`,`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 +(@ENTRY,0,0,0,54,0,100,1,0,0,0,0,11,7165,0,0,0,0,0,1,0,0,0,0,0,0,0,"Aligar the Tormentor - On Just Summoned - Cast 'Battle Stance' (No Repeat)"), +(@ENTRY,0,1,0,0,0,100,0,3000,4000,5000,6000,11,9080,0,0,0,0,0,2,0,0,0,0,0,0,0,"Aligar the Tormentor - In Combat - Cast 'Hamstring'"), +(@ENTRY,0,2,0,0,0,100,1,6000,7000,6000,7000,11,25712,0,0,0,0,0,2,0,0,0,0,0,0,0,"Aligar the Tormentor - In Combat - Cast 'Heroic Strike' (No Repeat)"), +(@ENTRY,0,3,0,54,0,100,0,0,0,0,0,18,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Aligar the Tormentor - On Just Summoned - Set Unit Flags - Immune to NPC/NPC"), +(@ENTRY,0,4,0,38,0,100,0,1,1,0,0,19,768,0,0,0,0,0,1,0,0,0,0,0,0,0,"Aligar the Tormentor - On Data Set - Remove Unit Flags - Immune to NPC/NPC"); + +UPDATE `creature_template` SET `ScriptName`='',`AIName`="SmartAI" WHERE `entry`=4484; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4484 AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=448400 AND `source_type`=9; + +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 +(4484,0,0,1,19,0,100,1,976,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0,'Feero Ironhand - On Quest Accept (Supplies to Aubderdine) - Store Targetlist '), +(4484,0,1,2,61,0,100,1,0,0,0,0,2,774,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Quest Accept (Supplies to Aubderdine) - Set Faction'), +(4484,0,2,3,61,0,100,1,0,0,0,0,19,512,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Quest Accept (Supplies to Aubderdine) - Remove Unit Flags'), +(4484,0,3,0,61,0,100,1,0,0,0,0,1,7,5000,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Quest Accept (Supplies to Aubderdine) - Say Line 7'), +(4484,0,4,0,7,0,100,0,0,0,0,0,19,512,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Evade - Remove Unit Flags'), +(4484,0,5,6,40,0,100,1,18,4484,0,0,1,0,5000,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP18 - Say Line 0'), +(4484,0,6,7,61,0,100,1,0,0,0,0,107,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP18 - Summon Summon Group 0'), +(4484,0,7,0,61,0,100,1,0,0,0,0,54,5000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP18 - Pause WP (2 Seconds)'), +(4484,0,8,0,40,0,100,1,19,4484,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP19 - Say Line 1'), +(4484,0,9,10,40,0,100,1,27,4484,0,0,1,2,5000,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP27 - Say'), +(4484,0,10,11,61,0,100,1,0,0,0,0,107,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached 27 - Summon Summon Group 1'), +(4484,0,11,0,61,0,100,1,0,0,0,0,54,5000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP27 - Pause WP (5 Seconds)'), +(4484,0,12,0,40,0,100,1,28,4484,0,0,1,3,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP28 - Say Line 3'), +(4484,0,13,14,40,0,100,1,41,4484,0,0,1,4,5000,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP41 - Say Line 4'), +(4484,0,14,15,61,0,100,1,0,0,0,0,107,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP41 - Summon Summon Group 2'), +(4484,0,15,0,61,0,100,1,0,0,0,0,54,10000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP41 - Pause WP (10 Seconds)'), +(4484,0,16,17,40,0,100,1,43,4484,0,0,1,6,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP43 - Say Line 5'), +(4484,0,17,18,61,0,100,1,0,0,0,0,15,976,0,0,0,0,0,12,1,0,0,0,0,0,0,'Feero Ironhand - On Reached 43 - Call Areaexploredoreventhappens'), +(4484,0,18,19,61,0,100,1,0,0,0,0,59,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached 43 - Set Run'), +(4484,0,19,0,61,0,100,1,0,0,0,0,54,5000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP43 - Pause WP (5 Seconds)'), +(4484,0,20,0,40,0,100,1,45,4484,0,0,41,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Reached WP45 - Despawn'), +(4484,0,21,0,6,0,100,1,0,0,0,0,6,976,0,0,0,0,0,12,1,0,0,0,0,0,0,'Feero Ironhand - On Death - Fail Quest'), +(4484,0,22,0,52,0,100,1,2,4484,0,0,45,1,1,0,0,0,0,9,3893,0,100,0,0,0,0,'Feero Ironhand - On Text Over line 2 - Set Data Forsaken Scout'), +(4484,0,23,0,52,0,100,1,4,4484,0,0,1,0,5000,0,0,0,0,19,3899,0,0,0,0,0,0,'Feero Ironhand - On Text Over line 4 - Say Line 0 (Balizar the Umbrage)'), +(4484,0,24,25,52,0,100,1,0,3899,0,0,1,5,5000,0,0,0,0,1,0,0,0,0,0,0,0,'Feero Ironhand - On Text Over line 0 (Balizar the Umbrage) - Say Line 5'), +(4484,0,25,0,61,0,100,1,0,0,0,0,45,1,1,0,0,0,0,19,3899,0,0,0,0,0,0,'Feero Ironhand - On Text Over line 0 (Balizar the Umbrage) - Set Data (Balizar the Umbrage)'), +(4484,0,26,0,52,0,100,1,7,4484,0,0,53,0,4484,0,976,0,1,1,0,0,0,0,0,0,0,'Feero Ironhand - On Text Over Line 7 - Start WP'), +(4484,0,27,0,52,0,100,1,0,4484,0,0,45,1,1,0,0,0,0,9,3879,0,100,0,0,0,0,'Feero Ironhand - On Text Over line 0 - Set Data Dark Strand assasin'); + +DELETE FROM `creature_summon_groups` WHERE `summonerId`=4484; +INSERT INTO `creature_summon_groups` (`summonerId`, `summonerType`, `groupId`, `entry`, `position_x`, `position_y`, `position_z`, `orientation`, `summonType`, `summonTime`) VALUES +(4484, 0, 0, 3879, 3491.09, 214.76, 11.36, 3.30, 1, 30000), +(4484, 0, 0, 3879, 3491.18, 212.28, 11.25, 3.03, 1, 30000), +(4484, 0, 0, 3879, 3490.74, 210.59, 11.32, 3.03, 1, 30000), +(4484, 0, 0, 3879, 3490.46, 208.78, 11.39, 2.93, 1, 30000), +(4484, 0, 1, 3893, 3782.51, 145.57, 8.54, 2.93, 1, 30000), +(4484, 0, 1, 3893, 3778.84, 143.46, 8.41, 2.93, 1, 30000), +(4484, 0, 1, 3893, 3782.26, 149.61, 8.34, 2.93, 1, 30000), +(4484, 0, 2, 3900, 4108.34, 53.69, 26.18, 2.93, 1, 30000), +(4484, 0, 2, 3898, 4114.55, 54.48, 27.21, 2.93, 1, 30000), +(4484, 0, 2, 3899, 4116.81, 50.14, 26.15, 2.93, 1, 30000); + +DELETE FROM `creature_text` WHERE `entry` IN(4484,3899); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES +(4484, 0, 0, 'It looks like we''re in trouble. Look lively, here they come!', 12, 7, 100, 0, 0, 0, 'Feero', 1372), +(4484, 1, 0, 'Assassins from that cult you found... Let''s get moving before someone else finds us out here.', 12, 7, 100, 0, 0, 0, 'Feero', 1294), +(4484, 2, 0, 'Hold! I sense an evil presence... Undead!', 12, 7, 100, 0, 0, 0, 'Feero',1373), +(4484, 3, 0, 'They''re coming out of the woodwork today. Let''s keep moving or we may find more things that want me dead.', 12, 7, 100, 0, 0, 0, 'Feero', 1310), +(4484, 4, 0, 'These three again?', 12, 7, 100, 0, 0, 0, 'Feero',1374), +(4484, 5, 0, 'I''ll finish you off for good this time!', 12, 0, 100, 0, 0, 0, 'Feero', 1499), +(4484, 6, 0, 'Well done! I should be fine on my own from here. Remember to talk to Delgren when you return to Maestra''s Post in Ashenvale.', 12, 7, 100, 0, 0, 0, 'Feero', 1315), +(4484, 7, 0, 'We must move quickly. Auberdine isn''t too far away, but many enemies lurk in the forest.', 12, 7, 100, 0, 0, 0, 'Feero', 1292), +(3899, 0, 0, 'Not quite so sure of yourself without the Purifier, hm?', 12, 0, 100, 0, 0, 0, 'Balizar the Umbrage',1313); + +DELETE FROM `waypoints` WHERE `entry`=4484; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(4484, 1, 3175.930908, 193.541306, 3.483540, ''), +(4484, 2, 3187.917969, 197.117691, 4.699296, ''), +(4484, 3, 3203.483643, 192.349060, 5.908475 , ''), +(4484, 4, 3219.118408, 182.236420, 6.588406, ''), +(4484, 5, 3229.847412, 191.230438, 7.494555, ''), +(4484, 6, 3225.035156, 199.438843, 7.096720, ''), +(4484, 7, 3227.651855, 210.760071, 8.629334, ''), +(4484, 8, 3232.935303, 223.724869, 10.052238 , ''), +(4484, 9, 3263.071777, 225.984848, 10.645896 , ''), +(4484, 10, 3284.759521, 220.414124, 10.950543, ''), +(4484, 11, 3315.646973, 210.198044, 11.967686, ''), +(4484, 12, 3341.024414, 214.290497, 13.320419, ''), +(4484, 13, 3367.133789, 224.587524, 11.867117, ''), +(4484, 14, 3409.073242, 226.385315, 9.215232, ''), +(4484, 15, 3432.292236, 225.396271, 10.028325, ''), +(4484, 16, 3454.865723, 219.339172, 12.593150, ''), +(4484, 17, 3470.463867, 214.818161, 13.264424, ''), +(4484, 18, 3481.416992, 212.556610, 12.354552, 'say_1'), +(4484, 19, 3500.315674, 210.936295, 10.226085, 'say_death_1'), +(4484, 20, 3532.806641, 215.041473, 8.372272, ''), +(4484, 21, 3565.314209, 217.748749, 5.300299, ''), +(4484, 22, 3601.654297, 217.771378, 1.299005, ''), +(4484, 23, 3638.605713, 212.525879, 1.433142 , ''), +(4484, 24, 3680.757324, 200.308197, 3.385010, ''), +(4484, 25, 3725.670410, 180.395966, 6.314014, ''), +(4484, 26, 3762.346924, 159.685959, 7.388617, ''), +(4484, 27, 3774.541260, 151.170029, 7.799640, 'say_2'), +(4484, 28, 3789.697754, 140.396774, 9.062237, 'say_death_2'), +(4484, 29, 3821.424072, 111.609528, .258650, ''), +(4484, 30, 3850.376465, 84.710922, 13.941991, ''), +(4484, 31, 3875.349121, 60.388409, 14.988914 , ''), +(4484, 32, 3908.238525, 35.209225, 15.332011, ''), +(4484, 33, 3942.200928, 14.888245, 16.969385, ''), +(4484, 34, 3976.427246, -0.073566, 16.968657, ''), +(4484, 35, 4008.343750, -6.628914, 16.464090, ''), +(4484, 36, 4029.483643, -6.640755, 16.549721, ''), +(4484, 37, 4050.055908, 1.488156, 15.746178, ''), +(4484, 38, 4083.412109, 14.085828, 15.851171, ''), +(4484, 39, 4098.462891, 20.032930, 17.252523, ''), +(4484, 40, 4105.861816, 34.792000, 20.284599, ''), +(4484, 41, 4110.536133, 45.538300, 23.154394, 'say_3_A'), +(4484, 42, 4112.863281, 51.454445, 26.165501, 'say_3_B'), +(4484, 43, 4126.177246, 53.689651, 26.399027, 'say_death_3'), +(4484, 44, 4149.127441, 46.833157, 24.660984, ''), +(4484, 45, 4164.439941, 55.935448, 26.793362, 'despawn'); diff --git a/sql/updates/world/2014_08_24_01_world_sai.sql b/sql/updates/world/2014_08_24_01_world_sai.sql new file mode 100644 index 00000000000..983d54e7b0f --- /dev/null +++ b/sql/updates/world/2014_08_24_01_world_sai.sql @@ -0,0 +1,162 @@ +DELETE FROM `smart_scripts` WHERE `entryorguid`=28503 AND `source_type`=0 AND `id`>4; +DELETE FROM `smart_scripts` WHERE `entryorguid`=2850300 AND `source_type`=9; +DELETE FROM `smart_scripts` WHERE `entryorguid`=-98865 AND `source_type`=0; +UPDATE `creature_template` SET `spell1`=54135, `spell2`=54132, `spell3`=54136 WHERE `entry`=28931; + +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 +(28503, 0, 5, 6, 62, 0, 100, 0, 9731, 0, 0, 0, 64, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Gossip Option 0 Selected - Store Target'), +(28503, 0, 6, 7, 61, 0, 100, 0, 0, 0, 0, 0, 85, 52863, 2, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Gossip Option 0 Selected - Cast Drakuru Betrayal Teleport'), +(28503, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 12, 28998, 1, 600000, 0, 0, 0, 8, 0, 0, 0, 6175.246, -2017.655, 590.9613, 2.984513, 'Overlord Drakuru - On Gossip Option 0 Selected - Summon Drakuru'); + +DELETE FROM `spell_target_position` WHERE `id` IN(52863,57553); +INSERT INTO `spell_target_position` (`id`, `effIndex`, `target_map`, `target_position_x`, `target_position_y`, `target_position_z`, `target_orientation`, `VerifiedBuild`) VALUES +(52863, 0, 571, 6161.15, -2015.36, 590.878, 6.196, 0), -- Drakuru Betrayal Teleport +(57553, 0, 571, 5875.43, -1981.37, 234.671, 0, 0); -- Escape Voltarus + +UPDATE `creature_template` SET `faction`=2082,`unit_flags`=256 WHERE `entry`=28998; -- Correct Faction (Not 35) + +DELETE FROM `creature_template_addon` WHERE `entry`=28998; +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(28998, 0, 0x0, 0x1, '58837 54104'); -- 28998 - 58837, 54104 + +DELETE FROM `spell_linked_spell` WHERE `spell_trigger`IN(-52010,54089); +INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES +(-52010, '-51966', 0,'On Remove Scourge Disguise Expiring - Also Remove Scourge Disguise'), +(54089, '52010', '1', 'On Hit Drop Disguise - Remove Scourge Disguise'); + +DELETE FROM `creature_text` WHERE `entry` =28998; +DELETE FROM `creature_text` WHERE `entry` =28498 AND `groupid`>6; + +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES +(28998, 0, 0, 'Behold, mon! We be creatin'' da greatest Scourge army ever seen!', 12, 0, 100, 396, 0, 14023, 'Overlord Drakuru',29441), +(28998, 1, 0, 'These be da first of many! We shall sweep across Zul''Drak like da wind....', 12, 0, 100, 396, 0, 14024, 'Overlord Drakuru',29442), +(28998, 2, 0, 'What treachery is this?! You be payin'' for this deceit with your life, mon!', 12, 0, 100, 0, 0, 14025, 'Overlord Drakuru',29885), +(28998, 3, 0, 'The Scepter of Domination glows brightly! Use it now!', 41, 0, 100, 0, 0, 0, 'Overlord Drakuru',29886), +(28998, 4, 0, 'How could dis be? Da Lich King said he be havin'' great plans for you, mon...', 14, 0, 100, 0, 0, 14027, 'Overlord Drakuru',29917), +(28998, 4, 1, 'Ya done turned your back on destiny, mon. Now you gunna die!', 14, 0, 100, 0, 0, 14029, 'Overlord Drakuru',29919), +(28998, 4, 2, 'Fool! Ya coulda been havin'' great power, mon!', 14, 0, 100, 0, 0, 14026, 'Overlord Drakuru',29916), +(28998, 4, 3, 'Your betrayal not gunna be slowin'' me down none, mon.', 14, 0, 100, 0, 0, 14030, 'Overlord Drakuru',29920), +(28998, 4, 4, 'I shoulda known not to be trustin'' nobody!', 14, 0, 100, 0, 0, 14028, 'Overlord Drakuru',29918), +(28998, 4, 5, 'I never needed ya, mon. I can crush Zul''Drak without ya!', 14, 0, 100, 0, 0, 14031, 'Overlord Drakuru',29921), +(28998, 5, 0, 'ENOUGH!', 14, 0, 100, 22, 0, 14020, 'Overlord Drakuru',29922), +(28998, 6, 0, 'Dis foolish treachery has cost ya your destiny!', 14, 0, 100, 396, 0, 14021, 'Overlord Drakuru',29923), +(28998, 7, 0, 'Master, dis mortal scum be double-crossin'' us. Dey must be made to suffer!', 12, 0, 100, 396, 0, 14022, 'Overlord Drakuru',29969), +(28998, 8, 0, 'Disguise Failing! Avoid Scourge Contact!', 41, 0, 100, 0, 0, 0, 'Overlord Drakuru',28891), +(28498, 7, 0, 'You have failed me, Drakuru!', 12, 0, 100, 396, 0, 14762, 'The Lich King',29986), +(28498, 8, 0, 'It is you who should suffer. Be content that your death is a quick one....', 12, 0, 100, 397, 0, 14763, 'The Lich King',29982), +(28498, 9, 0, 'As for you...', 12, 0, 100, 397, 0, 14764, 'The Lich King',29983), +(28498, 10, 0, 'I spare your insignificant life as a reward for this amusing betrayal. There may yet be a shred of potential in you.', 12, 0, 100, 396, 0, 14765, 'The Lich King',29984), +(28498, 11, 0, 'Be warned...', 12, 0, 100, 396, 0, 14766, 'The Lich King',29989), +(28498, 12, 0, 'When next we meet I shall require much more to justify your life.', 12, 0, 100, 396, 0, 14767, 'The Lich King',29985); + +UPDATE `smart_scripts` SET `event_param2`=28498 WHERE `entryorguid`=28498 AND `source_type`=0 AND `id` IN(1,3); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry`=28498; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(22, 1, 28498, 0, 0, 23, 1, 4196, 0, 0, 0, 0, 0, '', 'The Lich King - Only Run SAI in Drak Tharon Keep'), +(22, 6, 28498, 0, 0, 23, 1, 4314, 0, 0, 0, 0, 0, '', 'The Lich King - Only Run SAI in Voltarus'); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`IN(54250,54105); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 54250, 0, 0, 31, 0, 3, 28960, 0, 0, 0, 0, '', 'Drakurus Skull Missile targets Totally Generic Bunny'), +(13, 1, 54105, 0, 0, 31, 0, 4, 0, 0, 0, 0, 0, '', 'Blight Fog Targets Player'), +(13, 1, 54105, 0, 1, 31, 0, 3, 28931, 0, 0, 0, 0, '', 'Blight Fog Targets Blightblood Troll'); + +UPDATE `creature_template` SET `ainame`='SmartAI', `scriptname`='' WHERE `entry` IN(28931,28998,28960,29100); +UPDATE `gameobject_template` SET `AIName`='SmartGameObjectAI' WHERE `entry`=202357; + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(2899800,2899801,2849801,2899802) AND `source_type`=9; +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(28998,28931,28960,29100) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(202357) AND `source_type`=1; + +DELETE FROM `smart_scripts` WHERE `entryorguid`=28498 AND `source_type`=0 AND `id`>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`, `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 +(28960, 0, 0, 1, 8, 0, 100, 0, 54250, 0, 0, 0, 11, 54253, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny (JSB) - On Spell hit (Drakurus Skull Missile) - Cast Spawn Drakurus Skull'), +(28960, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 50, 202357, 120, 0, 0, 0, 0, 8, 0, 0, 0, 6185.989, -2029.698, 590.8779, 0, 'Totally Generic Bunny (JSB) - On Spell hit (Drakurus Skull Missile) - Spawn Drakurus Last Wish'), +(28960, 0, 2, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51807, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny (JSB) - On Data Set 1 1 - Cast Athas Portal'), +(28960, 0, 3, 0, 38, 0, 100, 0, 2, 2, 0, 0, 28, 51807, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny (JSB) - On Data Set 2 2 - Remove Aura Athas Portal'), +(29100, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51347, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny x8.0 (JSB) - On Data Set 1 1 - Cast Teleport Visual Only'), +(29100, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 11, 53104, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny x8.0 (JSB) - On Data Set 2 2 - Cast Scourge Spotlight'), +(29100, 0, 2, 0, 38, 0, 100, 0, 3, 3, 0, 0, 28, 53104, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Totally Generic Bunny x8.0 (JSB) - On Data Set 3 3 - Remove Aura Scourge Spotlight'), +(202357, 1, 0, 0, 62, 0, 100, 0, 11091, 0, 0, 0, 85, 57553, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Drakurus Last Wish - On Gossip Select - Invoker Cast Escape Voltarus'), +(28998, 0, 0, 0, 54, 0, 100, 1, 0, 0, 0, 0, 80, 2899800, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Just Summoned Run Script'), +(28998, 0, 1, 0, 7, 0, 100, 0, 0, 0, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Evade - Set Unit Flags'), +(28998, 0, 2, 3, 4, 0, 100, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Agro - Disable Combat Movement'), +(28998, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 9, 29100, 0, 200, 0, 0, 0, 0, 'Overlord Drakuru - On Agro - Set Data'), +(28998, 0, 4, 0, 9, 0, 100, 0, 10, 100, 3000, 7000, 11, 54113, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Range - Cast Shadow Bolt'), +(28998, 0, 5, 0, 0, 0, 100, 0, 5000, 10000, 15000, 35000, 11, 54087, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - IC - Cast Throw Blight Crystal'), +(28998, 0, 6, 0, 0, 0, 100, 0, 15000, 25000, 20000, 35000, 1, 4, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - IC - Say'), +(28998, 0, 7, 0, 2, 0, 100, 1, 0, 10, 0, 0, 80, 2899801, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Less than 10% HP - Run script 2'), +(28998, 0, 8, 0, 38, 0, 100, 0, 1, 1, 0, 0, 80, 2899802, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Data Set - Run Script 3'), +(28998, 0, 9, 10, 1, 0, 100, 0, 90000, 90000, 0, 0, 11, 61492, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - OOC - Cast Despawn Blightblood'), +(28998, 0, 10, 11, 61, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 9, 29100, 0, 200, 0, 0, 0, 0, 'Overlord Drakuru - OOC - Set Data 3 3 on Totally Generic Bunny (JSB)'), +(28998, 0, 11, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - OOC - Despawn'), +(28998, 0, 12, 0, 6, 0, 100, 0, 0, 0, 0, 0, 41, 2000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - On Death - Despawn after 2 seconds'), +(28931, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Data Set 1 1 - Set Unit Flags'), +(28931, 0, 1, 0, 7, 0, 100, 0, 0, 0, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Evade - Set Unit Flags'), +(28931, 0, 2, 0, 8, 0, 100, 0, 61492, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Despawn Blightblood) - Despawn'), +(28931, 0, 3, 0, 54, 0, 100, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Despawn Blightblood) - Despawn'), +(28931, 0, 4, 0, 4, 0, 100, 1, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Agro - Set Phase 2'), +(28931, 0, 5, 0, 8, 0, 100, 1, 53103, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Charm Blightblood Troll) - Set Phase 2'), +(28931, 0, 6, 0, 0, 2, 100, 1, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 19, 29100, 10, 0, 0, 0, 0, 0, 'Blightblood Troll - IC (Phase 2) - Set Data 3 3 on Totally Generic Bunny (JSB)'), +(28931, 0, 7, 0, 1, 2, 100, 1, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 19, 29100, 10, 0, 0, 0, 0, 0, 'Blightblood Troll - OOC (Phase 2) - Set Data 3 3 on Totally Generic Bunny (JSB)'), +(28498, 0, 5, 0, 54, 0, 100, 0, 0, 0, 0, 0, 53, 0, 2849800, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - On Just Summoned - Start Waypoint'), +(28498, 0, 6, 0, 40, 0, 100, 0, 4, 2849800, 0, 0, 1, 7, 0, 0, 0, 0, 0, 19, 28998, 0, 0, 0, 0, 0, 0, 'The Lich King - Reached WP4 - Say'), +(28498, 0, 7, 0, 40, 0, 100, 0, 8, 2849800, 0, 0, 80, 2849801, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Reached WP8 - Run Script'), +(28498, 0, 8, 9, 40, 0, 100, 0, 4, 2849801, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 98914, 28960, 0, 0, 0, 0, 0, 'The Lich King - Reached WP4 (Path 2) - Set Data'), +(28498, 0, 9, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Reached WP4 (Path 2) - Despawn'), +(2899800, 9, 0, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Say'), +(2899800, 9, 1, 0, 0, 0, 100, 0, 4500, 4500, 0, 0, 45, 1, 1, 0, 0, 0, 0, 9, 29100, 0, 200, 0, 0, 0, 0, 'Overlord Drakuru - Script - Say'), +(2899800, 9, 2, 0, 0, 0, 100, 0, 500, 500, 0, 0, 12, 28931, 1, 600000, 0, 0, 0, 8, 0, 0, 0, 6184.146, -1970.17, 586.8419, 4.590216, 'Overlord Drakuru - Script - Summon Blightblood Troll 1'), +(2899800, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 12, 28931, 1, 600000, 0, 0, 0, 8, 0, 0, 0, 6222.855, -2026.631, 586.8419, 3.001966, 'Overlord Drakuru - Script - Summon Blightblood Troll 2'), +(2899800, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 12, 28931, 1, 600000, 0, 0, 0, 8, 0, 0, 0, 6127.512, -2008.651, 586.8419, 6.161012, 'Overlord Drakuru - Script - Summon Blightblood Troll 3'), +(2899800, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 12, 28931, 1, 600000, 0, 0, 0, 8, 0, 0, 0, 6166.278, -2065.312, 586.8419, 1.448623, 'Overlord Drakuru - Script - Summon Blightblood Troll 4'), +(2899800, 9, 6, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Say'), +(2899800, 9, 7, 0, 0, 0, 100, 0, 500, 500, 0, 0, 1, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Say'), +(2899800, 9, 8, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 54089, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Cast Drop Disguise'), +(2899800, 9, 9, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Remove Scourge Disguise from Target'), +(2899800, 9, 10, 0, 0, 0, 100, 0, 0, 0, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Set Unit Flags'), +(2899800, 9, 11, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 9, 28931, 0, 200, 0, 0, 0, 0, 'Overlord Drakuru - Script - Set Data on Blightblood Troll'), +(2899800, 9, 12, 0, 0, 0, 100, 0, 0, 0, 0, 0, 2, 974, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Set Faction'), +(2899800, 9, 13, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script - Say'), +(2849801, 9, 0, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 1, 7, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 1, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 54236, 0, 0, 0, 0, 0, 19, 28998, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Cast Touch of Death'), +(2849801, 9, 3, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 28998, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Set Orientation'), +(2849801, 9, 4, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 66, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Set Orientation'), +(2849801, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 9, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 6, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 10, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 7, 0, 0, 0, 100, 0, 12000, 12000, 0, 0, 1, 11, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 8, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 12, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say'), +(2849801, 9, 9, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 53, 0, 2849801, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Start WP Path 2'), +(2899802, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 54248, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 3 - Cast Drakurus Death'), +(2899802, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 54250, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 3 - Cast Drakurus Skull Missile'), +(2899802, 9, 2, 0, 0, 0, 100, 0, 1500, 1500, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 3 - Die'), +(2899801, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 102, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set HP Regen off'), +(2899801, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set Phase 0'), +(2899801, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 2, 2082, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set Faction'), +(2899801, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Evade'), +(2899801, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Say'), +(2899801, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 61492, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Cast Despawn Blightblood'), +(2899801, 9, 6, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 21, 50, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set Orientation'), +(2899801, 9, 7, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Say'), +(2899801, 9, 8, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 98914, 28960, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set Data'), +(2899801, 9, 9, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 12, 28498, 1, 90000, 0, 0, 0, 8, 0, 0, 0, 6141.839, -2011.344, 590.3961,6.040418, 'Overlord Drakuru - Script 2 - Spawn The Lich King'), +(2899801, 9, 10, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 28498, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - Script 2 - Set Orientation'); + +DELETE FROM `waypoints` WHERE `entry` IN(2849800,2849801); + +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(2849800, 1,6139.436, -2010.837, 589.1911, 'The Lich King'), +(2849800, 2,6140.423, -2010.994, 589.1911, 'The Lich King'), +(2849800, 3,6142.035, -2011.393, 590.5623, 'The Lich King'), +(2849800, 4,6143.037, -2011.641, 590.8799, 'The Lich King'), +(2849800, 5,6145.518, -2012.255, 590.8799, 'The Lich King'), +(2849800, 6,6152.936, -2014.092, 590.8787, 'The Lich King'), +(2849800, 7,6164.27, -2016.898, 590.8779, 'The Lich King'), +(2849800, 8,6164.27, -2016.898, 590.8779, 'The Lich King'), +(2849801, 1,6153.504, -2014.085, 591.119, 'The Lich King'), +(2849801, 2,6145.754, -2012.335, 591.119, 'The Lich King'), +(2849801, 3,6143.254, -2011.835, 591.119, 'The Lich King'), +(2849801, 4,6142.254, -2011.585, 590.869, 'The Lich King'); diff --git a/src/server/game/AI/CoreAI/UnitAI.h b/src/server/game/AI/CoreAI/UnitAI.h index b6743b572cb..979fe4fe558 100644 --- a/src/server/game/AI/CoreAI/UnitAI.h +++ b/src/server/game/AI/CoreAI/UnitAI.h @@ -258,7 +258,6 @@ class UnitAI virtual void sGossipSelectCode(Player* /*player*/, uint32 /*sender*/, uint32 /*action*/, char const* /*code*/) { } virtual void sQuestAccept(Player* /*player*/, Quest const* /*quest*/) { } virtual void sQuestSelect(Player* /*player*/, Quest const* /*quest*/) { } - virtual void sQuestComplete(Player* /*player*/, Quest const* /*quest*/) { } virtual void sQuestReward(Player* /*player*/, Quest const* /*quest*/, uint32 /*opt*/) { } virtual bool sOnDummyEffect(Unit* /*caster*/, uint32 /*spellId*/, SpellEffIndex /*effIndex*/) { return false; } virtual void sOnGameEvent(bool /*start*/, uint16 /*eventId*/) { } diff --git a/src/server/game/AI/SmartScripts/SmartAI.h b/src/server/game/AI/SmartScripts/SmartAI.h index e674bbfdaac..b0d5d4f8343 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.h +++ b/src/server/game/AI/SmartScripts/SmartAI.h @@ -178,8 +178,7 @@ class SmartAI : public CreatureAI void sGossipSelect(Player* player, uint32 sender, uint32 action) override; void sGossipSelectCode(Player* player, uint32 sender, uint32 action, const char* code) override; void sQuestAccept(Player* player, Quest const* quest) override; - //void sQuestSelect(Player* player, Quest const* quest); - //void sQuestComplete(Player* player, Quest const* quest); + //void sQuestSelect(Player* player, Quest const* quest) override; void sQuestReward(Player* player, Quest const* quest, uint32 opt) override; bool sOnDummyEffect(Unit* caster, uint32 spellId, SpellEffIndex effIndex) override; void sOnGameEvent(bool start, uint16 eventId) override; diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 6e2706e7607..876c4a48946 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -16066,6 +16066,8 @@ void Player::SetQuestStatus(uint32 questId, QuestStatus status, bool update /*= if (update) SendQuestUpdate(questId); + + sScriptMgr->OnQuestStatusChange(this, questId, status); } void Player::RemoveActiveQuest(uint32 questId, bool update /*= true*/) diff --git a/src/server/game/Handlers/ArenaTeamHandler.cpp b/src/server/game/Handlers/ArenaTeamHandler.cpp index 2fa73643499..11c889fa726 100644 --- a/src/server/game/Handlers/ArenaTeamHandler.cpp +++ b/src/server/game/Handlers/ArenaTeamHandler.cpp @@ -365,7 +365,7 @@ void WorldSession::HandleArenaTeamRemoveOpcode(WorldPacket& recvData) SendArenaTeamCommandResult(ERR_ARENA_TEAM_QUIT_S, "", "", ERR_ARENA_TEAM_LEADER_LEAVE_S); return; } - + // Player cannot be removed during fights if (arenaTeam->IsFighting()) return; diff --git a/src/server/game/Handlers/QuestHandler.cpp b/src/server/game/Handlers/QuestHandler.cpp index a01cfa6d5e7..cfb7df6c34e 100644 --- a/src/server/game/Handlers/QuestHandler.cpp +++ b/src/server/game/Handlers/QuestHandler.cpp @@ -531,9 +531,6 @@ void WorldSession::HandleQuestgiverCompleteQuest(WorldPacket& recvData) else // no items required _player->PlayerTalkClass->SendQuestGiverOfferReward(quest, guid, true); } - - if (Creature* creature = object->ToCreature()) - sScriptMgr->OnQuestComplete(_player, creature, quest); } void WorldSession::HandleQuestgiverQuestAutoLaunch(WorldPacket& /*recvPacket*/) diff --git a/src/server/game/Scripting/ScriptMgr.cpp b/src/server/game/Scripting/ScriptMgr.cpp index a6201bb7d51..f1e6ba6ca6d 100644 --- a/src/server/game/Scripting/ScriptMgr.cpp +++ b/src/server/game/Scripting/ScriptMgr.cpp @@ -774,17 +774,6 @@ bool ScriptMgr::OnQuestSelect(Player* player, Creature* creature, Quest const* q return tmpscript->OnQuestSelect(player, creature, quest); } -bool ScriptMgr::OnQuestComplete(Player* player, Creature* creature, Quest const* quest) -{ - ASSERT(player); - ASSERT(creature); - ASSERT(quest); - - GET_SCRIPT_RET(CreatureScript, creature->GetScriptId(), tmpscript, false); - player->PlayerTalkClass->ClearMenus(); - return tmpscript->OnQuestComplete(player, creature, quest); -} - bool ScriptMgr::OnQuestReward(Player* player, Creature* creature, Quest const* quest, uint32 opt) { ASSERT(player); @@ -1296,6 +1285,11 @@ void ScriptMgr::OnPlayerUpdateZone(Player* player, uint32 newZone, uint32 newAre FOREACH_SCRIPT(PlayerScript)->OnUpdateZone(player, newZone, newArea); } +void ScriptMgr::OnQuestStatusChange(Player* player, uint32 questId, QuestStatus status) +{ + FOREACH_SCRIPT(PlayerScript)->OnQuestStatusChange(player, questId, status); +} + // Account void ScriptMgr::OnAccountLogin(uint32 accountId) { diff --git a/src/server/game/Scripting/ScriptMgr.h b/src/server/game/Scripting/ScriptMgr.h index 9f52aec848f..506d792ce44 100644 --- a/src/server/game/Scripting/ScriptMgr.h +++ b/src/server/game/Scripting/ScriptMgr.h @@ -445,10 +445,7 @@ class CreatureScript : public UnitScript, public UpdatableScript<Creature> // Called when a player selects a quest in the creature's quest menu. virtual bool OnQuestSelect(Player* /*player*/, Creature* /*creature*/, Quest const* /*quest*/) { return false; } - // Called when a player completes a quest with the creature. - virtual bool OnQuestComplete(Player* /*player*/, Creature* /*creature*/, Quest const* /*quest*/) { return false; } - - // Called when a player selects a quest reward. + // Called when a player completes a quest and is rewarded, opt is the selected item's index or 0 virtual bool OnQuestReward(Player* /*player*/, Creature* /*creature*/, Quest const* /*quest*/, uint32 /*opt*/) { return false; } // Called when the dialog status between a player and the creature is requested. @@ -483,7 +480,7 @@ class GameObjectScript : public ScriptObject, public UpdatableScript<GameObject> // Called when a player accepts a quest from the gameobject. virtual bool OnQuestAccept(Player* /*player*/, GameObject* /*go*/, Quest const* /*quest*/) { return false; } - // Called when a player selects a quest reward. + // Called when a player completes a quest and is rewarded, opt is the selected item's index or 0 virtual bool OnQuestReward(Player* /*player*/, GameObject* /*go*/, Quest const* /*quest*/, uint32 /*opt*/) { return false; } // Called when the dialog status between a player and the gameobject is requested. @@ -768,6 +765,9 @@ class PlayerScript : public UnitScript // Called when a player changes to a new map (after moving to new map) virtual void OnMapChanged(Player* /*player*/) { } + + // Called after a player's quest status has been changed + virtual void OnQuestStatusChange(Player* /*player*/, uint32 /*questId*/, QuestStatus /*status*/) { } }; class AccountScript : public ScriptObject @@ -965,7 +965,6 @@ class ScriptMgr bool OnGossipSelectCode(Player* player, Creature* creature, uint32 sender, uint32 action, const char* code); bool OnQuestAccept(Player* player, Creature* creature, Quest const* quest); bool OnQuestSelect(Player* player, Creature* creature, Quest const* quest); - bool OnQuestComplete(Player* player, Creature* creature, Quest const* quest); bool OnQuestReward(Player* player, Creature* creature, Quest const* quest, uint32 opt); uint32 GetDialogStatus(Player* player, Creature* creature); CreatureAI* GetCreatureAI(Creature* creature); @@ -1074,6 +1073,7 @@ class ScriptMgr void OnPlayerSave(Player* player); void OnPlayerBindToInstance(Player* player, Difficulty difficulty, uint32 mapid, bool permanent); void OnPlayerUpdateZone(Player* player, uint32 newZone, uint32 newArea); + void OnQuestStatusChange(Player* player, uint32 questId, QuestStatus status); public: /* AccountScript */ diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp index 72874bba510..71a5343d160 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp @@ -37,7 +37,7 @@ enum Events { EVENT_CALL_OF_GRAVE = 1, EVENT_TERRIFY, - EVENT_SOUL_SIPHON + EVENT_SOUL_SIPHON }; class boss_azshir_the_sleepless : public CreatureScript @@ -84,7 +84,7 @@ class boss_azshir_the_sleepless : public CreatureScript { if (!UpdateVictim()) return; - + events.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp index 43a9ef32be6..18369c7adfc 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp @@ -39,7 +39,7 @@ enum Events EVENT_FLAME_SHOCK = 1, EVENT_SHADOW_BOLT, EVENT_FLAME_SPIKE, - EVENT_FIRE_NOVA + EVENT_FIRE_NOVA }; class boss_bloodmage_thalnos : public CreatureScript diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp index 0b7ad73fefd..d1d25dd2ba6 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp @@ -133,7 +133,7 @@ class boss_herod : public CreatureScript { BossAI::UpdateAI(diff); } - + private: bool _enrage; }; diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h index 40089cd9817..d4ce3f1614f 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h @@ -45,7 +45,7 @@ enum CreatureIds NPC_MOGRAINE = 3976, NPC_WHITEMANE = 3977, NPC_VORREL = 3981, - + NPC_HORSEMAN = 23682, NPC_HEAD = 23775, NPC_PUMPKIN = 23694 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp index b769c7e141e..69240866742 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp @@ -336,7 +336,7 @@ class spell_mimiron_bomb_bot : public SpellScriptLoader void HandleScript(SpellEffIndex /*effIndex*/) { - if (GetHitPlayer()) + if (GetHitPlayer()) if (InstanceScript* instance = GetCaster()->GetInstanceScript()) if (Creature* mkii = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_LEVIATHAN_MK_II))) mkii->AI()->SetData(DATA_SETUP_BOMB, 0); @@ -425,15 +425,15 @@ class spell_mimiron_fire_search : public SpellScriptLoader { public: spell_mimiron_fire_search() : SpellScriptLoader("spell_mimiron_fire_search") { } - + class spell_mimiron_fire_search_SpellScript : public SpellScript { PrepareSpellScript(spell_mimiron_fire_search_SpellScript); - + bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_WATER_SPRAY)) - return false; + return false; return true; } @@ -459,7 +459,7 @@ class spell_mimiron_fire_search : public SpellScriptLoader if (_noTarget) GetCaster()->GetMotionMaster()->MoveRandom(15.0f); } - + void HandleScript(SpellEffIndex /*effIndex*/) { Unit* caster = GetCaster(); @@ -490,7 +490,7 @@ class spell_mimiron_fire_search : public SpellScriptLoader private: bool _noTarget; }; - + SpellScript* GetSpellScript() const override { return new spell_mimiron_fire_search_SpellScript(); @@ -530,7 +530,7 @@ class spell_mimiron_magnetic_core : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_MAGNETIC_CORE_VISUAL)) - return false; + return false; return true; } @@ -585,7 +585,7 @@ class spell_mimiron_napalm_shell : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_NAPALM_SHELL)) - return false; + return false; return true; } @@ -663,7 +663,7 @@ class spell_mimiron_plasma_blast : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_PLASMA_BLAST)) - return false; + return false; return true; } @@ -701,7 +701,7 @@ class spell_mimiron_proximity_explosion : public SpellScriptLoader PrepareSpellScript(spell_mimiron_proximity_explosion_SpellScript); void OnHit(SpellEffIndex /*effIndex*/) - { + { if (GetHitPlayer()) if (InstanceScript* instance = GetCaster()->GetInstanceScript()) if (Creature* mkII = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_LEVIATHAN_MK_II))) @@ -709,7 +709,7 @@ class spell_mimiron_proximity_explosion : public SpellScriptLoader } void HandleAura(SpellEffIndex /*effIndex*/) - { + { GetCaster()->RemoveAurasDueToSpell(SPELL_PROXIMITY_MINE_PERIODIC_TRIGGER); } @@ -859,7 +859,7 @@ class spell_mimiron_rocket_strike : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SCRIPT_EFFECT_ROCKET_STRIKE)) - return false; + return false; return true; } @@ -907,7 +907,7 @@ class spell_mimiron_rocket_strike_damage : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_NOT_SO_FRIENDLY_FIRE)) - return false; + return false; return true; } @@ -919,7 +919,7 @@ class spell_mimiron_rocket_strike_damage : public SpellScriptLoader void HandleScript(SpellEffIndex /*effIndex*/) { - if (GetHitPlayer()) + if (GetHitPlayer()) if (InstanceScript* instance = GetCaster()->GetInstanceScript()) if (Creature* mkii = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_LEVIATHAN_MK_II))) mkii->AI()->SetData(DATA_SETUP_ROCKET, 0); @@ -957,7 +957,7 @@ class spell_mimiron_rocket_strike_target_select : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_ROCKET_STRIKE)) - return false; + return false; return true; } @@ -1067,7 +1067,7 @@ class spell_mimiron_summon_assault_bot : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_ASSAULT_BOT)) - return false; + return false; return true; } @@ -1104,7 +1104,7 @@ class spell_mimiron_summon_assault_bot_target : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_ASSAULT_BOT_DUMMY)) - return false; + return false; return true; } @@ -1176,7 +1176,7 @@ class spell_mimiron_summon_fire_bot_target : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_FIRE_BOT_DUMMY)) - return false; + return false; return true; } @@ -1202,7 +1202,7 @@ class spell_mimiron_summon_flames_spread : public SpellScriptLoader { public: spell_mimiron_summon_flames_spread() : SpellScriptLoader("spell_mimiron_summon_flames_spread") { } - + class spell_mimiron_summon_flames_spread_SpellScript : public SpellScript { PrepareSpellScript(spell_mimiron_summon_flames_spread_SpellScript); @@ -1224,7 +1224,7 @@ class spell_mimiron_summon_flames_spread : public SpellScriptLoader } void OnHit(SpellEffIndex /*effIndex*/) - { + { GetCaster()->SetInFront(GetHitUnit()); } @@ -1247,7 +1247,7 @@ class spell_mimiron_summon_flames_spread : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_FLAMES_SPREAD)) - return false; + return false; return true; } @@ -1284,7 +1284,7 @@ class spell_mimiron_summon_frost_bomb_target : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_FROST_BOMB)) - return false; + return false; return true; } @@ -1335,7 +1335,7 @@ class spell_mimiron_summon_junk_bot : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_JUNK_BOT)) - return false; + return false; return true; } @@ -1372,7 +1372,7 @@ class spell_mimiron_summon_junk_bot_target : public SpellScriptLoader bool Validate(SpellInfo const* /*spell*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_SUMMON_JUNK_BOT_DUMMY)) - return false; + return false; return true; } diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp index 79f9283eb40..1f9bfe4c3f3 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp @@ -820,7 +820,7 @@ class instance_ulduar : public InstanceMapScript break; case DATA_UNBROKEN: Unbroken = data != 0; - break; + break; case DATA_MIMIRON_ELEVATOR: if (GameObject* gameObject = instance->GetGameObject(MimironElevatorGUID)) gameObject->SetGoState((GOState)data); diff --git a/src/server/scripts/World/npcs_special.cpp b/src/server/scripts/World/npcs_special.cpp index ba17dba602a..aa289e82698 100644 --- a/src/server/scripts/World/npcs_special.cpp +++ b/src/server/scripts/World/npcs_special.cpp @@ -397,7 +397,7 @@ public: return true; } - bool OnQuestComplete(Player* /*player*/, Creature* creature, Quest const* quest) override + bool OnQuestReward(Player* /*player*/, Creature* creature, Quest const* quest, uint32 /*opt*/) override { if (quest->GetQuestId() == QUEST_CLUCK) ENSURE_AI(npc_chicken_cluck::npc_chicken_cluckAI, creature->AI())->Reset(); diff --git a/src/tools/mesh_extractor/ContinentBuilder.cpp b/src/tools/mesh_extractor/ContinentBuilder.cpp index 8f6a918ef8d..8f509e6e8bb 100644 --- a/src/tools/mesh_extractor/ContinentBuilder.cpp +++ b/src/tools/mesh_extractor/ContinentBuilder.cpp @@ -34,13 +34,13 @@ private: ContinentBuilder* cBuilder; public: BuilderThread(ContinentBuilder* _cBuilder, dtNavMeshParams& params) : Params(params), cBuilder(_cBuilder), Free(true) {} - - void SetData(int x, int y, int map, const std::string& cont) - { - X = x; - Y = y; - MapId = map; - Continent = cont; + + void SetData(int x, int y, int map, const std::string& cont) + { + X = x; + Y = y; + MapId = map; + Continent = cont; } int svc() @@ -127,13 +127,13 @@ void ContinentBuilder::Build() CalculateTileBounds(); dtNavMeshParams params; - + std::vector<BuilderThread*> Threads; if (TileMap->IsGlobalModel) { printf("Map %s ( %u ) is a WMO. Building with 1 thread.\n", Continent.c_str(), MapId); - + TileBuilder* builder = new TileBuilder(this, Continent, 0, 0, MapId); builder->AddGeometry(TileMap->Model, TileMap->ModelDefinition); uint8* nav = builder->BuildInstance(params); diff --git a/src/tools/mesh_extractor/DoodadHandler.cpp b/src/tools/mesh_extractor/DoodadHandler.cpp index d56ba4c3bdf..a7d0c77b50c 100644 --- a/src/tools/mesh_extractor/DoodadHandler.cpp +++ b/src/tools/mesh_extractor/DoodadHandler.cpp @@ -21,7 +21,7 @@ #include "Model.h" #include "G3D/Matrix4.h" -DoodadHandler::DoodadHandler( ADT* adt ) : +DoodadHandler::DoodadHandler( ADT* adt ) : ObjectDataHandler(adt), _definitions(NULL), _paths(NULL) { Chunk* mddf = adt->ObjectData->GetChunkByName("MDDF"); @@ -38,7 +38,7 @@ void DoodadHandler::ProcessInternal( MapChunk* mcnk ) { if (!IsSane()) return; - + uint32 refCount = mcnk->Header.DoodadRefs; FILE* stream = mcnk->Source->GetStream(); fseek(stream, mcnk->Source->Offset + mcnk->Header.OffsetMCRF, SEEK_SET); @@ -111,7 +111,7 @@ void DoodadHandler::ReadDoodadPaths( Chunk* id, Chunk* data ) void DoodadHandler::InsertModelGeometry(const DoodadDefinition& def, Model* model) { uint32 vertOffset = Vertices.size(); - + for (std::vector<Vector3>::iterator itr = model->Vertices.begin(); itr != model->Vertices.end(); ++itr) Vertices.push_back(Utils::TransformDoodadVertex(def, *itr)); // Vertices have to be converted based on the information from the DoodadDefinition struct diff --git a/src/tools/mesh_extractor/MeshExtractor.cpp b/src/tools/mesh_extractor/MeshExtractor.cpp index 1926734ac72..9af8b0bcc75 100644 --- a/src/tools/mesh_extractor/MeshExtractor.cpp +++ b/src/tools/mesh_extractor/MeshExtractor.cpp @@ -290,7 +290,7 @@ bool HandleArgs(int argc, char** argv, uint32& threads, std::set<uint32>& mapLis mapList.insert(atoi(token)); token = strtok(NULL, ","); } - + free(copy); printf("Extracting only provided list of maps (%u).\n", uint32(mapList.size())); @@ -448,7 +448,7 @@ int main(int argc, char* argv[]) LoadTile(navMesh, buff); } } - + navMeshQuery->init(navMesh, 2048); float nearestPt[3]; @@ -465,7 +465,7 @@ int main(int argc, char* argv[]) int hops; dtPolyRef* hopBuffer = new dtPolyRef[8192]; dtStatus status = navMeshQuery->findPath(m_startRef, m_endRef, m_spos, m_epos, &m_filter, hopBuffer, &hops, 8192); - + int resultHopCount; float* straightPath = new float[2048*3]; unsigned char* pathFlags = new unsigned char[2048]; diff --git a/src/tools/mesh_extractor/TileBuilder.cpp b/src/tools/mesh_extractor/TileBuilder.cpp index 768314e5101..70d6c1b6c55 100644 --- a/src/tools/mesh_extractor/TileBuilder.cpp +++ b/src/tools/mesh_extractor/TileBuilder.cpp @@ -257,7 +257,7 @@ uint8* TileBuilder::BuildTiled(dtNavMeshParams& navMeshParams) } OutputDebugVertices(); - + uint32 numVerts = _Geometry->Vertices.size(); uint32 numTris = _Geometry->Triangles.size(); float* vertices; diff --git a/src/tools/mesh_extractor/Utils.cpp b/src/tools/mesh_extractor/Utils.cpp index 704acf967ee..1684ba0274d 100644 --- a/src/tools/mesh_extractor/Utils.cpp +++ b/src/tools/mesh_extractor/Utils.cpp @@ -205,7 +205,7 @@ void Utils::SaveToDisk( FILE* stream, const std::string& path ) fclose(stream); return; } - + // And write it in the file size_t wrote = fwrite(data, size, 1, disk); if (wrote != 1) diff --git a/src/tools/mesh_extractor/WorldModelHandler.cpp b/src/tools/mesh_extractor/WorldModelHandler.cpp index c272496c0a7..e3d8e81eeb9 100644 --- a/src/tools/mesh_extractor/WorldModelHandler.cpp +++ b/src/tools/mesh_extractor/WorldModelHandler.cpp @@ -56,7 +56,7 @@ void WorldModelHandler::ProcessInternal( MapChunk* mcnk ) { if (!IsSane()) return; - + uint32 refCount = mcnk->Header.MapObjectRefs; FILE* stream = mcnk->Source->GetStream(); fseek(stream, mcnk->Source->Offset + mcnk->Header.OffsetMCRF, SEEK_SET); |