From 6984fbe16b8f422b04fd3d27718b000a168a1893 Mon Sep 17 00:00:00 2001 From: ZxBiohazardZx Date: Mon, 4 Mar 2013 12:52:52 +0100 Subject: DB/Gameobject: Add missing Gameobject Closes #8948 --- sql/updates/world/2013_03_04_00_world_gameobject.sql | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 sql/updates/world/2013_03_04_00_world_gameobject.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_00_world_gameobject.sql b/sql/updates/world/2013_03_04_00_world_gameobject.sql new file mode 100644 index 00000000000..493e34a6a2c --- /dev/null +++ b/sql/updates/world/2013_03_04_00_world_gameobject.sql @@ -0,0 +1,7 @@ +DELETE FROM `gameobject_template` WHERE `entry`=180055; +INSERT INTO `gameobject_template` (`entry`, `type`, `displayId`, `name`, `IconName`, `castBarCaption`, `unk1`, `faction`, `flags`, `size`, `questItem1`, `questItem2`, `questItem3`, `questItem4`, `questItem5`, `questItem6`, `data0`, `data1`, `data2`, `data3`, `data4`, `data5`, `data6`, `data7`, `data8`, `data9`, `data10`, `data11`, `data12`, `data13`, `data14`, `data15`, `data16`, `data17`, `data18`, `data19`, `data20`, `data21`, `data22`, `data23`, `AIName`, `ScriptName`, `WDBVerified`) VALUES +(180055,2,318,'Mysterious Wailing Caverns Chest','',,'',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,'',0); + +DELETE FROM `gameobejct` WHERE `id`=180055; +INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) +(4598,180055,43,1,1,-97.6,173.8,-79,2.08,0,0,0,0,43200,100,1); -- cgit v1.2.3 From e826e37815604d9f8a8ac560eab42bdfe8249f6d Mon Sep 17 00:00:00 2001 From: ZxBiohazardZx Date: Mon, 4 Mar 2013 12:55:56 +0100 Subject: DB/Waypoints: add waypoints for Doomsayer Jurim, thx Kelsarhu Closes #8958 --- .../world/2013_03_04_00_world_waypoint_data.sql | 153 +++++++++++++++++++++ 1 file changed, 153 insertions(+) create mode 100644 sql/updates/world/2013_03_04_00_world_waypoint_data.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_00_world_waypoint_data.sql b/sql/updates/world/2013_03_04_00_world_waypoint_data.sql new file mode 100644 index 00000000000..3a2001e7e36 --- /dev/null +++ b/sql/updates/world/2013_03_04_00_world_waypoint_data.sql @@ -0,0 +1,153 @@ +SET @GUID := 40470; +SET @PATH := @GUID*10; +DELETE FROM `creature` where `id`=18686; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`,`npcflag`,`unit_flags`,`dynamicflags`) VALUES +(@GUID,18686,530,1,1,0,0,-2847.327,3195.10722,7.4167,.0910940,300,0,0,9144,13525,2,0,0,0); +-- Pathing Data +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_flag`,`action`,`action_chance`) VALUES +(@PATH,1,-2843.86,3205.97,5.45323,0,0,0,0,100), +(@PATH,2,-2829.24,3218.81,9.59048,0,0,0,0,100), +(@PATH,3,-2814.12,3235.72,10.1736,0,0,0,0,100), +(@PATH,4,-2792.54,3259.91,5.91885,0,0,0,0,100), +(@PATH,5,-2774.46,3280.17,2.8828,0,0,0,0,100), +(@PATH,6,-2751.21,3306.24,0.199384,0,0,0,0,100), +(@PATH,7,-2728.55,3318.21,-0.833018,0,0,0,0,100), +(@PATH,8,-2719.59,3331.35,-1.04936,0,0,0,0,100), +(@PATH,9,-2708.94,3349.74,-0.819842,0,0,0,0,100), +(@PATH,10,-2694.72,3374.29,-0.156626,0,0,0,0,100), +(@PATH,11,-2685.08,3390.93,0.328583,0,0,0,0,100), +(@PATH,12,-2675.69,3407.16,0.474826,0,0,0,0,100), +(@PATH,13,-2669.68,3416.29,0.743526,0,0,0,0,100), +(@PATH,14,-2660.96,3425.20,0.805554,0,0,0,0,100), +(@PATH,15,-2654.25,3430.82,0.77502,0,0,0,0,100), +(@PATH,16,-2645.46,3437.83,1.28666,0,0,0,0,100), +(@PATH,17,-2639.59,3442.50,3.25542,0,0,0,0,100), +(@PATH,18,-2630.71,3449.41,1.86245,0,0,0,0,100), +(@PATH,19,-2621.54,3456.21,0.653284,0,0,0,0,100), +(@PATH,20,-2617.41,3460.51,0.593326,0,0,0,0,100), +(@PATH,21,-2611.50,3471.52,0.520041,0,0,0,0,100), +(@PATH,22,-2610.04,3475.69,0.53993,0,0,0,0,100), +(@PATH,23,-2606.90,3480.85,0.492544,0,0,0,0,100), +(@PATH,24,-2590.41,3502.84,0.225892,0,0,0,0,100), +(@PATH,25,-2582.03,3512.00,0.101641,0,0,0,0,100), +(@PATH,26,-2566.36,3522.06,0.189451,0,0,0,0,100), +(@PATH,27,-2534.38,3523.07,1.3404,0,0,0,0,100), +(@PATH,28,-2523.33,3527.83,1.66667,0,0,0,0,100), +(@PATH,29,-2516.31,3533.95,1.65006,0,0,0,0,100), +(@PATH,30,-2507.47,3544.67,1.56155,0,0,0,0,100), +(@PATH,31,-2491.83,3549.68,1.43199,0,0,0,0,100), +(@PATH,32,-2471.56,3551.98,1.23732,0,0,0,0,100), +(@PATH,33,-2463.14,3555.66,1.03546,0,0,0,0,100), +(@PATH,34,-2456.30,3555.25,0.942503,0,0,0,0,100), +(@PATH,35,-2452.53,3537.02,0.402467,0,0,0,0,100), +(@PATH,36,-2446.32,3528.59,-0.236494,0,0,0,0,100), +(@PATH,37,-2462.93,3549.41,1.08819,0,0,0,0,100), +(@PATH,38,-2460.92,3557.50,1.00403,0,0,0,0,100), +(@PATH,39,-2425.49,3596.20,0.274173,0,0,0,0,100), +(@PATH,40,-2405.20,3613.88,0.217946,0,0,0,0,100), +(@PATH,41,-2391.31,3632.83,0.792431,0,0,0,0,100), +(@PATH,42,-2383.97,3658.54,0.99065,0,0,0,0,100), +(@PATH,43,-2351.54,3700.72,0.420721,0,0,0,0,100), +(@PATH,44,-2314.59,3729.83,0.0297019,0,0,0,0,100), +(@PATH,45,-2296.57,3749.89,0.363868,0,0,0,0,100), +(@PATH,46,-2285.44,3767.70,0.291327,0,0,0,0,100), +(@PATH,47,-2279.30,3787.95,0.314858,0,0,0,0,100), +(@PATH,48,-2276.30,3799.32,0.521091,0,0,0,0,100), +(@PATH,49,-2254.61,3831.13,2.70024,0,0,0,0,100), +(@PATH,50,-2251.75,3848.92,5.15061,0,0,0,0,100), +(@PATH,51,-2249.52,3869.55,2.39354,0,0,0,0,100), +(@PATH,52,-2244.66,3893.46,1.58335,0,0,0,0,100), +(@PATH,53,-2239.88,3904.19,1.10899,0,0,0,0,100), +(@PATH,54,-2224.28,3927.45,0.706091,0,0,0,0,100), +(@PATH,55,-2187.45,3958.22,0.921813,0,0,0,0,100), +(@PATH,56,-2175.09,3978.98,0.929392,0,0,0,0,100), +(@PATH,57,-2171.14,4011.04,0.450247,0,0,0,0,100), +(@PATH,58,-2175.93,4027.88,0.519539,0,0,0,0,100), +(@PATH,59,-2187.96,4064.43,1.42810,0,0,0,0,100), +(@PATH,60,-2166.44,4102.49,4.27243,0,0,0,0,100), -- Had guid as action_id +(@PATH,61,-1700.15,3993.57,55.6859,0,0,0,0,100), +(@PATH,62,-1710.59,4034.97,60.6101,0,0,0,0,100), +(@PATH,63,-1719.95,4059.83,62.7452,0,0,0,0,100), +(@PATH,64,-1718.67,4104.32,64.3796,0,0,0,0,100), +(@PATH,65,-1743.77,4151.60,62.3929,0,0,0,0,100), +(@PATH,66,-1754.61,4173.29,58.3691,0,0,0,0,100), +(@PATH,67,-1788.41,4206.51,44.1839,0,0,0,0,100), +(@PATH,68,-1818.93,4214.12,33.1137,0,0,0,0,100), +(@PATH,69,-1841.51,4228.10,22.0741,0,0,0,0,100), +(@PATH,70,-1871.54,4263.50,8.22153,0,0,0,0,100), +(@PATH,71,-1891.00,4295.91,3.23019,0,0,0,0,100), +(@PATH,72,-1911.96,4351.49,1.66825,0,0,0,0,100), +(@PATH,73,-1910.12,4389.42,1.77078,0,0,0,0,100), +(@PATH,74,-1907.67,4417.31,2.99456,0,0,0,0,100), +(@PATH,75,-1917.63,4452.07,6.27493,0,0,0,0,100), +(@PATH,76,-1929.40,4473.47,8.90937,0,0,0,0,100), +(@PATH,77,-1942.74,4489.67,11.1029,0,0,0,0,100), +(@PATH,78,-1958.47,4508.45,12.7432,0,0,0,0,100), +(@PATH,79,-1975.36,4519.94,13.1616,0,0,0,0,100), +(@PATH,80,-1982.19,4524.49,13.0993,0,0,0,0,100), +(@PATH,81,-1983.38,4507.03,12.7591,0,0,0,0,100), +(@PATH,82,-1984.02,4496.55,11.9535,0,0,0,0,100), +(@PATH,83,-1984.87,4482.57,11.1499,0,0,0,0,100), +(@PATH,84,-1978.92,4509.87,12.6695,0,0,0,0,100), +(@PATH,85,-1978.12,4527.35,13.36,0,0,0,0,100), +(@PATH,86,-1967.33,4546.79,12.8741,0,0,0,0,100), +(@PATH,87,-1953.04,4566.47,10.1123,0,0,0,0,100), +(@PATH,88,-1946.50,4582.91,7.44598,0,0,0,0,100), +(@PATH,89,-1948.30,4599.58,4.61956,0,0,0,0,100), +(@PATH,90,-1955.08,4637.48,-0.0588505,0,0,0,0,100), +(@PATH,91,-1943.63,4685.04,-2.18987,0,0,0,0,100), +(@PATH,92,-1941.99,4705.25,-2.67768,0,0,0,0,100), +(@PATH,93,-1945.22,4727.47,-3.22917,0,0,0,0,100), +(@PATH,94,-1951.89,4748.79,-2.9388,0,0,0,0,100), +(@PATH,95,-1957.77,4773.70,-1.42409,0,0,0,0,100), +(@PATH,96,-1957.36,4798.11,-0.0807409,0,0,0,0,100), +(@PATH,97,-1944.66,4829.17,0.67,0,0,0,0,100), +(@PATH,98,-1929.68,4851.09,1.64973,0,0,0,0,100), +(@PATH,99,-1918.23,4883.89,2.11937,0,0,0,0,100), +(@PATH,100,-1901.18,4906.49,-1.12705,0,0,0,0,100), +(@PATH,101,-1881.87,4926.69,-9.60835,0,0,0,0,100), +(@PATH,102,-1870.05,4946.21,-17.0149,0,0,0,0,100), +(@PATH,103,-1866.49,4960.25,-20.2899,0,0,0,0,100), +(@PATH,104,-1860.94,5033.3,-26.0991,0,0,0,0,100), +(@PATH,105,-1869.80,4962.46,-20.3781,0,0,0,0,100), +(@PATH,106,-1884.86,4924.67,-8.30171,0,0,0,0,100), +(@PATH,107,-1904.83,4905.16,-0.202733,0,0,0,0,100), +(@PATH,108,-1922.67,4912.5,6.06643,0,0,0,0,100), +(@PATH,109,-1937.46,4934.99,14.8054,0,0,0,0,100), +(@PATH,110,-1953.22,4961.69,24.7149,0,0,0,0,100), +(@PATH,111,-1958.07,4992.99,30.1767,0,0,0,0,100), +(@PATH,112,-1958.74,5013.42,32.4293,0,0,0,0,100), +(@PATH,113,-1947.03,5042.52,25.2899,0,0,0,0,100), +(@PATH,114,-1942.58,5058.03,19.5292,0,0,0,0,100), +(@PATH,115,-1963.32,5083.08,11.1075,0,0,0,0,100), +(@PATH,116,-1984.50,5100.08,7.82778,0,0,0,0,100), +(@PATH,117,-2004.59,5114.07,8.26657,0,0,0,0,100), +(@PATH,118,-2029.48,5123.26,8.48839,0,0,0,0,100), +(@PATH,119,-2055.94,5125.38,7.48301,0,0,0,0,100), +(@PATH,120,-2089.33,5115.44,3.14184,0,0,0,0,100), +(@PATH,121,-2112.53,5107.32,-2.40737,0,0,0,0,100), +(@PATH,122,-2137.40,5108.51,-11.5709,0,0,0,0,100), +(@PATH,123,-2155.69,5115.97,-18.1534,0,0,0,0,100), +(@PATH,124,-2170.60,5125.13,-21.2824,0,0,0,0,100), +(@PATH,125,-2182.81,5131.87,-21.667,0,0,0,0,100), +(@PATH,126,-2198.88,5138.77,-21.2323,0,0,0,0,100), +(@PATH,127,-2219.62,5144.57,-19.6848,0,0,0,0,100), +(@PATH,128,-2238.57,5146.29,-17.4706,0,0,0,0,100), +(@PATH,129,-2266.45,5144.26,-13.0598,0,0,0,0,100), +(@PATH,130,-2290.86,5142.23,-9.17377,0,0,0,0,100), +(@PATH,131,-2308.35,5142.09,-7.11532,0,0,0,0,100), +(@PATH,132,-2333.72,5149.44,-5.0165,0,0,0,0,100), +(@PATH,133,-2365.45,5157.88,-2.8501,0,0,0,0,100), +(@PATH,134,-2390.26,5158.22,-1.19618,0,0,0,0,100), +(@PATH,135,-2417.84,5153.35,0.775549,0,0,0,0,100), +(@PATH,136,-2442.28,5142.04,3.53141,0,0,0,0,100), +(@PATH,137,-2469.81,5120.56,6.76948,0,0,0,0,100), +(@PATH,138,-2498.06,5115.06,7.87731,0,0,0,0,100), +(@PATH,139,-2532.85,5118.89,7.54034,0,0,0,0,100), +(@PATH,140,-2555.60,5120.59,7.69492,0,0,0,0,100), -- GUID+1 as action_id +(@PATH,141,-2843.86,3205.97,5.45323,0,0,0,0,100); +-- Assign Path +DELETE FROM `creature_addon` WHERE `guid`=@GUID; +INSERT INTO `creature_addon` (`guid`,`path_id`) VALUES +(@GUID,@PATH); -- cgit v1.2.3 From 534bdae0c9bf70aaf4634ac6704e5188920c43f9 Mon Sep 17 00:00:00 2001 From: ZxBiohazardZx Date: Mon, 4 Mar 2013 13:00:03 +0100 Subject: DB/Quest: fix some questrequirements in BE start zone by Praxious, Closes #9156 Commit: fix naming on previous file, fix typo in 2013_03_04_00 --- .../world/2013_03_04_00_world_gameobject.sql | 2 +- .../world/2013_03_04_00_world_waypoint_data.sql | 153 --------------------- .../world/2013_03_04_01_world_waypoint_data.sql | 153 +++++++++++++++++++++ .../world/2013_03_04_02_world_quest_template.sql | 2 + 4 files changed, 156 insertions(+), 154 deletions(-) delete mode 100644 sql/updates/world/2013_03_04_00_world_waypoint_data.sql create mode 100644 sql/updates/world/2013_03_04_01_world_waypoint_data.sql create mode 100644 sql/updates/world/2013_03_04_02_world_quest_template.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_00_world_gameobject.sql b/sql/updates/world/2013_03_04_00_world_gameobject.sql index 493e34a6a2c..96960abdc7c 100644 --- a/sql/updates/world/2013_03_04_00_world_gameobject.sql +++ b/sql/updates/world/2013_03_04_00_world_gameobject.sql @@ -2,6 +2,6 @@ DELETE FROM `gameobject_template` WHERE `entry`=180055; INSERT INTO `gameobject_template` (`entry`, `type`, `displayId`, `name`, `IconName`, `castBarCaption`, `unk1`, `faction`, `flags`, `size`, `questItem1`, `questItem2`, `questItem3`, `questItem4`, `questItem5`, `questItem6`, `data0`, `data1`, `data2`, `data3`, `data4`, `data5`, `data6`, `data7`, `data8`, `data9`, `data10`, `data11`, `data12`, `data13`, `data14`, `data15`, `data16`, `data17`, `data18`, `data19`, `data20`, `data21`, `data22`, `data23`, `AIName`, `ScriptName`, `WDBVerified`) VALUES (180055,2,318,'Mysterious Wailing Caverns Chest','',,'',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,'',0); -DELETE FROM `gameobejct` WHERE `id`=180055; +DELETE FROM `gameobject` WHERE `id`=180055; INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) (4598,180055,43,1,1,-97.6,173.8,-79,2.08,0,0,0,0,43200,100,1); diff --git a/sql/updates/world/2013_03_04_00_world_waypoint_data.sql b/sql/updates/world/2013_03_04_00_world_waypoint_data.sql deleted file mode 100644 index 3a2001e7e36..00000000000 --- a/sql/updates/world/2013_03_04_00_world_waypoint_data.sql +++ /dev/null @@ -1,153 +0,0 @@ -SET @GUID := 40470; -SET @PATH := @GUID*10; -DELETE FROM `creature` where `id`=18686; -INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`,`npcflag`,`unit_flags`,`dynamicflags`) VALUES -(@GUID,18686,530,1,1,0,0,-2847.327,3195.10722,7.4167,.0910940,300,0,0,9144,13525,2,0,0,0); --- Pathing Data -DELETE FROM `waypoint_data` WHERE `id`=@PATH; -INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_flag`,`action`,`action_chance`) VALUES -(@PATH,1,-2843.86,3205.97,5.45323,0,0,0,0,100), -(@PATH,2,-2829.24,3218.81,9.59048,0,0,0,0,100), -(@PATH,3,-2814.12,3235.72,10.1736,0,0,0,0,100), -(@PATH,4,-2792.54,3259.91,5.91885,0,0,0,0,100), -(@PATH,5,-2774.46,3280.17,2.8828,0,0,0,0,100), -(@PATH,6,-2751.21,3306.24,0.199384,0,0,0,0,100), -(@PATH,7,-2728.55,3318.21,-0.833018,0,0,0,0,100), -(@PATH,8,-2719.59,3331.35,-1.04936,0,0,0,0,100), -(@PATH,9,-2708.94,3349.74,-0.819842,0,0,0,0,100), -(@PATH,10,-2694.72,3374.29,-0.156626,0,0,0,0,100), -(@PATH,11,-2685.08,3390.93,0.328583,0,0,0,0,100), -(@PATH,12,-2675.69,3407.16,0.474826,0,0,0,0,100), -(@PATH,13,-2669.68,3416.29,0.743526,0,0,0,0,100), -(@PATH,14,-2660.96,3425.20,0.805554,0,0,0,0,100), -(@PATH,15,-2654.25,3430.82,0.77502,0,0,0,0,100), -(@PATH,16,-2645.46,3437.83,1.28666,0,0,0,0,100), -(@PATH,17,-2639.59,3442.50,3.25542,0,0,0,0,100), -(@PATH,18,-2630.71,3449.41,1.86245,0,0,0,0,100), -(@PATH,19,-2621.54,3456.21,0.653284,0,0,0,0,100), -(@PATH,20,-2617.41,3460.51,0.593326,0,0,0,0,100), -(@PATH,21,-2611.50,3471.52,0.520041,0,0,0,0,100), -(@PATH,22,-2610.04,3475.69,0.53993,0,0,0,0,100), -(@PATH,23,-2606.90,3480.85,0.492544,0,0,0,0,100), -(@PATH,24,-2590.41,3502.84,0.225892,0,0,0,0,100), -(@PATH,25,-2582.03,3512.00,0.101641,0,0,0,0,100), -(@PATH,26,-2566.36,3522.06,0.189451,0,0,0,0,100), -(@PATH,27,-2534.38,3523.07,1.3404,0,0,0,0,100), -(@PATH,28,-2523.33,3527.83,1.66667,0,0,0,0,100), -(@PATH,29,-2516.31,3533.95,1.65006,0,0,0,0,100), -(@PATH,30,-2507.47,3544.67,1.56155,0,0,0,0,100), -(@PATH,31,-2491.83,3549.68,1.43199,0,0,0,0,100), -(@PATH,32,-2471.56,3551.98,1.23732,0,0,0,0,100), -(@PATH,33,-2463.14,3555.66,1.03546,0,0,0,0,100), -(@PATH,34,-2456.30,3555.25,0.942503,0,0,0,0,100), -(@PATH,35,-2452.53,3537.02,0.402467,0,0,0,0,100), -(@PATH,36,-2446.32,3528.59,-0.236494,0,0,0,0,100), -(@PATH,37,-2462.93,3549.41,1.08819,0,0,0,0,100), -(@PATH,38,-2460.92,3557.50,1.00403,0,0,0,0,100), -(@PATH,39,-2425.49,3596.20,0.274173,0,0,0,0,100), -(@PATH,40,-2405.20,3613.88,0.217946,0,0,0,0,100), -(@PATH,41,-2391.31,3632.83,0.792431,0,0,0,0,100), -(@PATH,42,-2383.97,3658.54,0.99065,0,0,0,0,100), -(@PATH,43,-2351.54,3700.72,0.420721,0,0,0,0,100), -(@PATH,44,-2314.59,3729.83,0.0297019,0,0,0,0,100), -(@PATH,45,-2296.57,3749.89,0.363868,0,0,0,0,100), -(@PATH,46,-2285.44,3767.70,0.291327,0,0,0,0,100), -(@PATH,47,-2279.30,3787.95,0.314858,0,0,0,0,100), -(@PATH,48,-2276.30,3799.32,0.521091,0,0,0,0,100), -(@PATH,49,-2254.61,3831.13,2.70024,0,0,0,0,100), -(@PATH,50,-2251.75,3848.92,5.15061,0,0,0,0,100), -(@PATH,51,-2249.52,3869.55,2.39354,0,0,0,0,100), -(@PATH,52,-2244.66,3893.46,1.58335,0,0,0,0,100), -(@PATH,53,-2239.88,3904.19,1.10899,0,0,0,0,100), -(@PATH,54,-2224.28,3927.45,0.706091,0,0,0,0,100), -(@PATH,55,-2187.45,3958.22,0.921813,0,0,0,0,100), -(@PATH,56,-2175.09,3978.98,0.929392,0,0,0,0,100), -(@PATH,57,-2171.14,4011.04,0.450247,0,0,0,0,100), -(@PATH,58,-2175.93,4027.88,0.519539,0,0,0,0,100), -(@PATH,59,-2187.96,4064.43,1.42810,0,0,0,0,100), -(@PATH,60,-2166.44,4102.49,4.27243,0,0,0,0,100), -- Had guid as action_id -(@PATH,61,-1700.15,3993.57,55.6859,0,0,0,0,100), -(@PATH,62,-1710.59,4034.97,60.6101,0,0,0,0,100), -(@PATH,63,-1719.95,4059.83,62.7452,0,0,0,0,100), -(@PATH,64,-1718.67,4104.32,64.3796,0,0,0,0,100), -(@PATH,65,-1743.77,4151.60,62.3929,0,0,0,0,100), -(@PATH,66,-1754.61,4173.29,58.3691,0,0,0,0,100), -(@PATH,67,-1788.41,4206.51,44.1839,0,0,0,0,100), -(@PATH,68,-1818.93,4214.12,33.1137,0,0,0,0,100), -(@PATH,69,-1841.51,4228.10,22.0741,0,0,0,0,100), -(@PATH,70,-1871.54,4263.50,8.22153,0,0,0,0,100), -(@PATH,71,-1891.00,4295.91,3.23019,0,0,0,0,100), -(@PATH,72,-1911.96,4351.49,1.66825,0,0,0,0,100), -(@PATH,73,-1910.12,4389.42,1.77078,0,0,0,0,100), -(@PATH,74,-1907.67,4417.31,2.99456,0,0,0,0,100), -(@PATH,75,-1917.63,4452.07,6.27493,0,0,0,0,100), -(@PATH,76,-1929.40,4473.47,8.90937,0,0,0,0,100), -(@PATH,77,-1942.74,4489.67,11.1029,0,0,0,0,100), -(@PATH,78,-1958.47,4508.45,12.7432,0,0,0,0,100), -(@PATH,79,-1975.36,4519.94,13.1616,0,0,0,0,100), -(@PATH,80,-1982.19,4524.49,13.0993,0,0,0,0,100), -(@PATH,81,-1983.38,4507.03,12.7591,0,0,0,0,100), -(@PATH,82,-1984.02,4496.55,11.9535,0,0,0,0,100), -(@PATH,83,-1984.87,4482.57,11.1499,0,0,0,0,100), -(@PATH,84,-1978.92,4509.87,12.6695,0,0,0,0,100), -(@PATH,85,-1978.12,4527.35,13.36,0,0,0,0,100), -(@PATH,86,-1967.33,4546.79,12.8741,0,0,0,0,100), -(@PATH,87,-1953.04,4566.47,10.1123,0,0,0,0,100), -(@PATH,88,-1946.50,4582.91,7.44598,0,0,0,0,100), -(@PATH,89,-1948.30,4599.58,4.61956,0,0,0,0,100), -(@PATH,90,-1955.08,4637.48,-0.0588505,0,0,0,0,100), -(@PATH,91,-1943.63,4685.04,-2.18987,0,0,0,0,100), -(@PATH,92,-1941.99,4705.25,-2.67768,0,0,0,0,100), -(@PATH,93,-1945.22,4727.47,-3.22917,0,0,0,0,100), -(@PATH,94,-1951.89,4748.79,-2.9388,0,0,0,0,100), -(@PATH,95,-1957.77,4773.70,-1.42409,0,0,0,0,100), -(@PATH,96,-1957.36,4798.11,-0.0807409,0,0,0,0,100), -(@PATH,97,-1944.66,4829.17,0.67,0,0,0,0,100), -(@PATH,98,-1929.68,4851.09,1.64973,0,0,0,0,100), -(@PATH,99,-1918.23,4883.89,2.11937,0,0,0,0,100), -(@PATH,100,-1901.18,4906.49,-1.12705,0,0,0,0,100), -(@PATH,101,-1881.87,4926.69,-9.60835,0,0,0,0,100), -(@PATH,102,-1870.05,4946.21,-17.0149,0,0,0,0,100), -(@PATH,103,-1866.49,4960.25,-20.2899,0,0,0,0,100), -(@PATH,104,-1860.94,5033.3,-26.0991,0,0,0,0,100), -(@PATH,105,-1869.80,4962.46,-20.3781,0,0,0,0,100), -(@PATH,106,-1884.86,4924.67,-8.30171,0,0,0,0,100), -(@PATH,107,-1904.83,4905.16,-0.202733,0,0,0,0,100), -(@PATH,108,-1922.67,4912.5,6.06643,0,0,0,0,100), -(@PATH,109,-1937.46,4934.99,14.8054,0,0,0,0,100), -(@PATH,110,-1953.22,4961.69,24.7149,0,0,0,0,100), -(@PATH,111,-1958.07,4992.99,30.1767,0,0,0,0,100), -(@PATH,112,-1958.74,5013.42,32.4293,0,0,0,0,100), -(@PATH,113,-1947.03,5042.52,25.2899,0,0,0,0,100), -(@PATH,114,-1942.58,5058.03,19.5292,0,0,0,0,100), -(@PATH,115,-1963.32,5083.08,11.1075,0,0,0,0,100), -(@PATH,116,-1984.50,5100.08,7.82778,0,0,0,0,100), -(@PATH,117,-2004.59,5114.07,8.26657,0,0,0,0,100), -(@PATH,118,-2029.48,5123.26,8.48839,0,0,0,0,100), -(@PATH,119,-2055.94,5125.38,7.48301,0,0,0,0,100), -(@PATH,120,-2089.33,5115.44,3.14184,0,0,0,0,100), -(@PATH,121,-2112.53,5107.32,-2.40737,0,0,0,0,100), -(@PATH,122,-2137.40,5108.51,-11.5709,0,0,0,0,100), -(@PATH,123,-2155.69,5115.97,-18.1534,0,0,0,0,100), -(@PATH,124,-2170.60,5125.13,-21.2824,0,0,0,0,100), -(@PATH,125,-2182.81,5131.87,-21.667,0,0,0,0,100), -(@PATH,126,-2198.88,5138.77,-21.2323,0,0,0,0,100), -(@PATH,127,-2219.62,5144.57,-19.6848,0,0,0,0,100), -(@PATH,128,-2238.57,5146.29,-17.4706,0,0,0,0,100), -(@PATH,129,-2266.45,5144.26,-13.0598,0,0,0,0,100), -(@PATH,130,-2290.86,5142.23,-9.17377,0,0,0,0,100), -(@PATH,131,-2308.35,5142.09,-7.11532,0,0,0,0,100), -(@PATH,132,-2333.72,5149.44,-5.0165,0,0,0,0,100), -(@PATH,133,-2365.45,5157.88,-2.8501,0,0,0,0,100), -(@PATH,134,-2390.26,5158.22,-1.19618,0,0,0,0,100), -(@PATH,135,-2417.84,5153.35,0.775549,0,0,0,0,100), -(@PATH,136,-2442.28,5142.04,3.53141,0,0,0,0,100), -(@PATH,137,-2469.81,5120.56,6.76948,0,0,0,0,100), -(@PATH,138,-2498.06,5115.06,7.87731,0,0,0,0,100), -(@PATH,139,-2532.85,5118.89,7.54034,0,0,0,0,100), -(@PATH,140,-2555.60,5120.59,7.69492,0,0,0,0,100), -- GUID+1 as action_id -(@PATH,141,-2843.86,3205.97,5.45323,0,0,0,0,100); --- Assign Path -DELETE FROM `creature_addon` WHERE `guid`=@GUID; -INSERT INTO `creature_addon` (`guid`,`path_id`) VALUES -(@GUID,@PATH); diff --git a/sql/updates/world/2013_03_04_01_world_waypoint_data.sql b/sql/updates/world/2013_03_04_01_world_waypoint_data.sql new file mode 100644 index 00000000000..3a2001e7e36 --- /dev/null +++ b/sql/updates/world/2013_03_04_01_world_waypoint_data.sql @@ -0,0 +1,153 @@ +SET @GUID := 40470; +SET @PATH := @GUID*10; +DELETE FROM `creature` where `id`=18686; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`,`npcflag`,`unit_flags`,`dynamicflags`) VALUES +(@GUID,18686,530,1,1,0,0,-2847.327,3195.10722,7.4167,.0910940,300,0,0,9144,13525,2,0,0,0); +-- Pathing Data +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_flag`,`action`,`action_chance`) VALUES +(@PATH,1,-2843.86,3205.97,5.45323,0,0,0,0,100), +(@PATH,2,-2829.24,3218.81,9.59048,0,0,0,0,100), +(@PATH,3,-2814.12,3235.72,10.1736,0,0,0,0,100), +(@PATH,4,-2792.54,3259.91,5.91885,0,0,0,0,100), +(@PATH,5,-2774.46,3280.17,2.8828,0,0,0,0,100), +(@PATH,6,-2751.21,3306.24,0.199384,0,0,0,0,100), +(@PATH,7,-2728.55,3318.21,-0.833018,0,0,0,0,100), +(@PATH,8,-2719.59,3331.35,-1.04936,0,0,0,0,100), +(@PATH,9,-2708.94,3349.74,-0.819842,0,0,0,0,100), +(@PATH,10,-2694.72,3374.29,-0.156626,0,0,0,0,100), +(@PATH,11,-2685.08,3390.93,0.328583,0,0,0,0,100), +(@PATH,12,-2675.69,3407.16,0.474826,0,0,0,0,100), +(@PATH,13,-2669.68,3416.29,0.743526,0,0,0,0,100), +(@PATH,14,-2660.96,3425.20,0.805554,0,0,0,0,100), +(@PATH,15,-2654.25,3430.82,0.77502,0,0,0,0,100), +(@PATH,16,-2645.46,3437.83,1.28666,0,0,0,0,100), +(@PATH,17,-2639.59,3442.50,3.25542,0,0,0,0,100), +(@PATH,18,-2630.71,3449.41,1.86245,0,0,0,0,100), +(@PATH,19,-2621.54,3456.21,0.653284,0,0,0,0,100), +(@PATH,20,-2617.41,3460.51,0.593326,0,0,0,0,100), +(@PATH,21,-2611.50,3471.52,0.520041,0,0,0,0,100), +(@PATH,22,-2610.04,3475.69,0.53993,0,0,0,0,100), +(@PATH,23,-2606.90,3480.85,0.492544,0,0,0,0,100), +(@PATH,24,-2590.41,3502.84,0.225892,0,0,0,0,100), +(@PATH,25,-2582.03,3512.00,0.101641,0,0,0,0,100), +(@PATH,26,-2566.36,3522.06,0.189451,0,0,0,0,100), +(@PATH,27,-2534.38,3523.07,1.3404,0,0,0,0,100), +(@PATH,28,-2523.33,3527.83,1.66667,0,0,0,0,100), +(@PATH,29,-2516.31,3533.95,1.65006,0,0,0,0,100), +(@PATH,30,-2507.47,3544.67,1.56155,0,0,0,0,100), +(@PATH,31,-2491.83,3549.68,1.43199,0,0,0,0,100), +(@PATH,32,-2471.56,3551.98,1.23732,0,0,0,0,100), +(@PATH,33,-2463.14,3555.66,1.03546,0,0,0,0,100), +(@PATH,34,-2456.30,3555.25,0.942503,0,0,0,0,100), +(@PATH,35,-2452.53,3537.02,0.402467,0,0,0,0,100), +(@PATH,36,-2446.32,3528.59,-0.236494,0,0,0,0,100), +(@PATH,37,-2462.93,3549.41,1.08819,0,0,0,0,100), +(@PATH,38,-2460.92,3557.50,1.00403,0,0,0,0,100), +(@PATH,39,-2425.49,3596.20,0.274173,0,0,0,0,100), +(@PATH,40,-2405.20,3613.88,0.217946,0,0,0,0,100), +(@PATH,41,-2391.31,3632.83,0.792431,0,0,0,0,100), +(@PATH,42,-2383.97,3658.54,0.99065,0,0,0,0,100), +(@PATH,43,-2351.54,3700.72,0.420721,0,0,0,0,100), +(@PATH,44,-2314.59,3729.83,0.0297019,0,0,0,0,100), +(@PATH,45,-2296.57,3749.89,0.363868,0,0,0,0,100), +(@PATH,46,-2285.44,3767.70,0.291327,0,0,0,0,100), +(@PATH,47,-2279.30,3787.95,0.314858,0,0,0,0,100), +(@PATH,48,-2276.30,3799.32,0.521091,0,0,0,0,100), +(@PATH,49,-2254.61,3831.13,2.70024,0,0,0,0,100), +(@PATH,50,-2251.75,3848.92,5.15061,0,0,0,0,100), +(@PATH,51,-2249.52,3869.55,2.39354,0,0,0,0,100), +(@PATH,52,-2244.66,3893.46,1.58335,0,0,0,0,100), +(@PATH,53,-2239.88,3904.19,1.10899,0,0,0,0,100), +(@PATH,54,-2224.28,3927.45,0.706091,0,0,0,0,100), +(@PATH,55,-2187.45,3958.22,0.921813,0,0,0,0,100), +(@PATH,56,-2175.09,3978.98,0.929392,0,0,0,0,100), +(@PATH,57,-2171.14,4011.04,0.450247,0,0,0,0,100), +(@PATH,58,-2175.93,4027.88,0.519539,0,0,0,0,100), +(@PATH,59,-2187.96,4064.43,1.42810,0,0,0,0,100), +(@PATH,60,-2166.44,4102.49,4.27243,0,0,0,0,100), -- Had guid as action_id +(@PATH,61,-1700.15,3993.57,55.6859,0,0,0,0,100), +(@PATH,62,-1710.59,4034.97,60.6101,0,0,0,0,100), +(@PATH,63,-1719.95,4059.83,62.7452,0,0,0,0,100), +(@PATH,64,-1718.67,4104.32,64.3796,0,0,0,0,100), +(@PATH,65,-1743.77,4151.60,62.3929,0,0,0,0,100), +(@PATH,66,-1754.61,4173.29,58.3691,0,0,0,0,100), +(@PATH,67,-1788.41,4206.51,44.1839,0,0,0,0,100), +(@PATH,68,-1818.93,4214.12,33.1137,0,0,0,0,100), +(@PATH,69,-1841.51,4228.10,22.0741,0,0,0,0,100), +(@PATH,70,-1871.54,4263.50,8.22153,0,0,0,0,100), +(@PATH,71,-1891.00,4295.91,3.23019,0,0,0,0,100), +(@PATH,72,-1911.96,4351.49,1.66825,0,0,0,0,100), +(@PATH,73,-1910.12,4389.42,1.77078,0,0,0,0,100), +(@PATH,74,-1907.67,4417.31,2.99456,0,0,0,0,100), +(@PATH,75,-1917.63,4452.07,6.27493,0,0,0,0,100), +(@PATH,76,-1929.40,4473.47,8.90937,0,0,0,0,100), +(@PATH,77,-1942.74,4489.67,11.1029,0,0,0,0,100), +(@PATH,78,-1958.47,4508.45,12.7432,0,0,0,0,100), +(@PATH,79,-1975.36,4519.94,13.1616,0,0,0,0,100), +(@PATH,80,-1982.19,4524.49,13.0993,0,0,0,0,100), +(@PATH,81,-1983.38,4507.03,12.7591,0,0,0,0,100), +(@PATH,82,-1984.02,4496.55,11.9535,0,0,0,0,100), +(@PATH,83,-1984.87,4482.57,11.1499,0,0,0,0,100), +(@PATH,84,-1978.92,4509.87,12.6695,0,0,0,0,100), +(@PATH,85,-1978.12,4527.35,13.36,0,0,0,0,100), +(@PATH,86,-1967.33,4546.79,12.8741,0,0,0,0,100), +(@PATH,87,-1953.04,4566.47,10.1123,0,0,0,0,100), +(@PATH,88,-1946.50,4582.91,7.44598,0,0,0,0,100), +(@PATH,89,-1948.30,4599.58,4.61956,0,0,0,0,100), +(@PATH,90,-1955.08,4637.48,-0.0588505,0,0,0,0,100), +(@PATH,91,-1943.63,4685.04,-2.18987,0,0,0,0,100), +(@PATH,92,-1941.99,4705.25,-2.67768,0,0,0,0,100), +(@PATH,93,-1945.22,4727.47,-3.22917,0,0,0,0,100), +(@PATH,94,-1951.89,4748.79,-2.9388,0,0,0,0,100), +(@PATH,95,-1957.77,4773.70,-1.42409,0,0,0,0,100), +(@PATH,96,-1957.36,4798.11,-0.0807409,0,0,0,0,100), +(@PATH,97,-1944.66,4829.17,0.67,0,0,0,0,100), +(@PATH,98,-1929.68,4851.09,1.64973,0,0,0,0,100), +(@PATH,99,-1918.23,4883.89,2.11937,0,0,0,0,100), +(@PATH,100,-1901.18,4906.49,-1.12705,0,0,0,0,100), +(@PATH,101,-1881.87,4926.69,-9.60835,0,0,0,0,100), +(@PATH,102,-1870.05,4946.21,-17.0149,0,0,0,0,100), +(@PATH,103,-1866.49,4960.25,-20.2899,0,0,0,0,100), +(@PATH,104,-1860.94,5033.3,-26.0991,0,0,0,0,100), +(@PATH,105,-1869.80,4962.46,-20.3781,0,0,0,0,100), +(@PATH,106,-1884.86,4924.67,-8.30171,0,0,0,0,100), +(@PATH,107,-1904.83,4905.16,-0.202733,0,0,0,0,100), +(@PATH,108,-1922.67,4912.5,6.06643,0,0,0,0,100), +(@PATH,109,-1937.46,4934.99,14.8054,0,0,0,0,100), +(@PATH,110,-1953.22,4961.69,24.7149,0,0,0,0,100), +(@PATH,111,-1958.07,4992.99,30.1767,0,0,0,0,100), +(@PATH,112,-1958.74,5013.42,32.4293,0,0,0,0,100), +(@PATH,113,-1947.03,5042.52,25.2899,0,0,0,0,100), +(@PATH,114,-1942.58,5058.03,19.5292,0,0,0,0,100), +(@PATH,115,-1963.32,5083.08,11.1075,0,0,0,0,100), +(@PATH,116,-1984.50,5100.08,7.82778,0,0,0,0,100), +(@PATH,117,-2004.59,5114.07,8.26657,0,0,0,0,100), +(@PATH,118,-2029.48,5123.26,8.48839,0,0,0,0,100), +(@PATH,119,-2055.94,5125.38,7.48301,0,0,0,0,100), +(@PATH,120,-2089.33,5115.44,3.14184,0,0,0,0,100), +(@PATH,121,-2112.53,5107.32,-2.40737,0,0,0,0,100), +(@PATH,122,-2137.40,5108.51,-11.5709,0,0,0,0,100), +(@PATH,123,-2155.69,5115.97,-18.1534,0,0,0,0,100), +(@PATH,124,-2170.60,5125.13,-21.2824,0,0,0,0,100), +(@PATH,125,-2182.81,5131.87,-21.667,0,0,0,0,100), +(@PATH,126,-2198.88,5138.77,-21.2323,0,0,0,0,100), +(@PATH,127,-2219.62,5144.57,-19.6848,0,0,0,0,100), +(@PATH,128,-2238.57,5146.29,-17.4706,0,0,0,0,100), +(@PATH,129,-2266.45,5144.26,-13.0598,0,0,0,0,100), +(@PATH,130,-2290.86,5142.23,-9.17377,0,0,0,0,100), +(@PATH,131,-2308.35,5142.09,-7.11532,0,0,0,0,100), +(@PATH,132,-2333.72,5149.44,-5.0165,0,0,0,0,100), +(@PATH,133,-2365.45,5157.88,-2.8501,0,0,0,0,100), +(@PATH,134,-2390.26,5158.22,-1.19618,0,0,0,0,100), +(@PATH,135,-2417.84,5153.35,0.775549,0,0,0,0,100), +(@PATH,136,-2442.28,5142.04,3.53141,0,0,0,0,100), +(@PATH,137,-2469.81,5120.56,6.76948,0,0,0,0,100), +(@PATH,138,-2498.06,5115.06,7.87731,0,0,0,0,100), +(@PATH,139,-2532.85,5118.89,7.54034,0,0,0,0,100), +(@PATH,140,-2555.60,5120.59,7.69492,0,0,0,0,100), -- GUID+1 as action_id +(@PATH,141,-2843.86,3205.97,5.45323,0,0,0,0,100); +-- Assign Path +DELETE FROM `creature_addon` WHERE `guid`=@GUID; +INSERT INTO `creature_addon` (`guid`,`path_id`) VALUES +(@GUID,@PATH); diff --git a/sql/updates/world/2013_03_04_02_world_quest_template.sql b/sql/updates/world/2013_03_04_02_world_quest_template.sql new file mode 100644 index 00000000000..82f01a39a85 --- /dev/null +++ b/sql/updates/world/2013_03_04_02_world_quest_template.sql @@ -0,0 +1,2 @@ +UPDATE `quest_template` SET `PrevQuestId`=0 WHERE `Id`=8345; +UPDATE `quest_template` SET `NextQuestId`=0 WHERE `Id`=8330; -- cgit v1.2.3 From ce08d73fa4adcdbb6586a6d24ed89343183f5883 Mon Sep 17 00:00:00 2001 From: Kirkhammett Date: Mon, 4 Mar 2013 13:03:02 +0100 Subject: DB/SAI: add SAI for quest: The Admiral Revealed (12852) Closes #9094 --- sql/updates/world/2013_03_04_03_world_sai.sql | 77 +++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 sql/updates/world/2013_03_04_03_world_sai.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_03_world_sai.sql b/sql/updates/world/2013_03_04_03_world_sai.sql new file mode 100644 index 00000000000..6cb234cc805 --- /dev/null +++ b/sql/updates/world/2013_03_04_03_world_sai.sql @@ -0,0 +1,77 @@ +-- The Admiral Revealed (12852) - http://www.wowhead.com/quest=12852 +-- http://www.youtube.com/watch?v=I9doc1BVmA8 +SET @WHIRLWIND := 49807; -- Admiral's Whirlwind, AoE, used in phase 1 +SET @STRIKE := 57846; -- Admiral's Heroic Strike, cast on tank, used in phase 1 +SET @CLEAVE := 15284; -- Admiral's Cleave, cast in cone, used in phase 1 +SET @TOUCH := 60501; -- Selfcast on Mal'Ganis, heals him, used in phase 2 +SET @SLEEP := 53045; -- Mal'Ganis Sleep,Cast on random group member, used in phase 2 +SET @BLAST := 60500; -- Mal'Ganis Mind Blast, Cast on random group member, used in phase 2 +SET @CARRION := 60502; -- Mal'Ganis Carrion Swarm, Cast in cone, used in phase 2 +SET @SHIELD := 50161; -- Cast when Admiral on 50 % +SET @ITEMSPELL := 31699; -- Spell to disable shield +SET @ADMIRAL := 29621; -- Grand Admiral Westwind +SET @MALGANIS := 29620; -- Dreadlord Mal'Ganis +SET @PORTAL := 27731; -- Portal visual +SET @LEGION_TELEPORT := 35502; -- Mal'Ganis Legion Portal visual +SET @CREDIT_BUNNY := 29627; -- Cute little flaming bunny +UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN (@CREDIT_BUNNY); +DELETE FROM `smart_scripts` WHERE `entryorguid`=@CREDIT_BUNNY 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 +(@CREDIT_BUNNY, 0, 0, 0, 54, 0, 100, 0, 0, 0, 0, 0, 75, @PORTAL, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Credit Bunny - Just Summoned - Cast Portal'); +-- SAI for Grand Admiral Westwind +UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN (@ADMIRAL,@MALGANIS,@ADMIRAL*100); +DELETE FROM `smart_scripts` WHERE `entryorguid`IN (@ADMIRAL,@ADMIRAL*100) AND `source_type` IN (0,9); +DELETE FROM `smart_scripts` WHERE `entryorguid`=@MALGANIS 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 +(@ADMIRAL, 0, 0, 1, 4, 0, 100, 0, 0, 0, 0, 0, 42, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On aggro - Set invicibility at 1 HP'), +(@ADMIRAL, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Link - Say line 0'), +(@ADMIRAL, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Link - Set phase 1'), +(@ADMIRAL, 0, 3, 4, 2, 0, 100, 1, 0, 50, 0, 0, 11, @SHIELD, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - At 50% HP - Cast Protection Sphere'), +(@ADMIRAL, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - Link - Say line 1'), +(@ADMIRAL, 0, 5, 6, 8, 0, 100, 0, @ITEMSPELL, 0, 0, 0, 28, @SHIELD, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On spell hit - Remove aura'), +(@ADMIRAL, 0, 6, 0, 61, 0, 100, 0, 0, 0, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - Link - Say line 2'), +(@ADMIRAL, 0, 7, 8, 2, 0, 100, 1, 0, 30, 0, 0, 3, @MALGANIS, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - At 30% HP - Morph to Dreadlord Mal''Ganis'), +(@ADMIRAL, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Link - Set phase 2'), +(@ADMIRAL, 0, 9,10, 61, 0, 100, 0, 0, 0, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - Link - Say line 3'), +(@ADMIRAL, 0, 10, 0, 61, 0, 100, 0, 0, 0, 0, 0, 40, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,'Grand Admiral Westwind - Link - Sheath'), +(@ADMIRAL, 0, 11, 0, 2, 0, 100, 1, 0, 15, 0, 0, 1, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - At 15% HP - Say line 4'), +(@ADMIRAL, 0, 12, 0, 1, 0, 100, 0, 0, 0, 0, 0, 3, @ADMIRAL, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On evade - Restore model'), +(@ADMIRAL, 0, 13, 14, 2, 0, 100, 1, 1, 1, 0, 0, 18, 33554434, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On 1 hp - Set unit_flags'), +(@ADMIRAL, 0, 14, 15, 61, 0, 100, 1, 0, 0, 0, 0, 12, @CREDIT_BUNNY, 1, 19000, 0, 0, 0, 8, 0, 0, 0, 7494.893066, 4871.533203, -12.655286, 1.376, 'Grand Admiral Westwind - On Link - Summon Npc'), +(@ADMIRAL, 0, 15, 16, 61, 0, 100, 1, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Link - Stop Combat/Attack Attack State'), +(@ADMIRAL, 0, 16, 0, 61, 0, 100, 0, 0, 0, 0, 0, 80, @ADMIRAL*100, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Link - Start timed script'), +(@ADMIRAL*100, 9, 0, 0, 0, 0, 100, 0, 1500, 1500, 0, 0, 22, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On script - Set phase 3'), +(@ADMIRAL*100, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 69, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7494.788, 4872.567, -12.72154, 0, 'Grand Admiral Westwind - On Script - Move to Pos'), +(@ADMIRAL*100, 9, 2, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 1, 6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Script - Say line 6'), +(@ADMIRAL*100, 9, 3, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 11, @LEGION_TELEPORT, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Script - Cast spell on self'), +(@ADMIRAL*100, 9, 4, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 33, @CREDIT_BUNNY, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Script - Give quest credit'), +(@ADMIRAL*100, 9, 5, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 41, 3500, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Script - Despawn'), +(@ADMIRAL, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 19, 33554434, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Respawn - Unset unit_flags'), +(@ADMIRAL, 0, 18, 0, 0, 1, 100, 0, 15000, 16000, 16000, 16000, 11, @WHIRLWIND, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 1 - Cast Whirlwind'), +(@ADMIRAL, 0, 19, 0, 0, 1, 100, 0, 6000, 7000, 6000, 7000, 11, @STRIKE, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 1 - Cast Heroic Strike'), +(@ADMIRAL, 0, 20, 0, 0, 2, 100, 0, 15000, 16000, 15000, 16000, 11, @SLEEP, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 2 - Cast Sleep'), +(@ADMIRAL, 0, 21, 0, 0, 2, 100, 0, 6000, 7000, 6000, 7000, 11, @TOUCH, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 2- Cast Vampiric Touch'), +(@ADMIRAL, 0, 22, 0, 0, 1, 100, 0, 13000, 13500, 13000, 13500, 11, @CLEAVE, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 1 - Cast Cleave'), +(@ADMIRAL, 0, 23, 0, 0, 2, 100, 0, 8000, 9000, 8000, 9000, 11, @CARRION, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 2 - Cast Carrion Swarm'), +(@ADMIRAL, 0, 24, 0, 0, 2, 100, 0, 18000, 19000, 18000, 19000, 11, @BLAST, 1, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - In combat Phase 2 - Cast Mind Blast'), +(@ADMIRAL, 0, 25, 0, 25, 0, 100, 0, 0, 0, 0, 0, 20, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grand Admiral Westwind - On Reset - Allow Attack State'); +/* +Sound ID's +14429 Final speech - When he uses portal +14428 2% HP - When he becomes immune +14427 15 % - When he rages +14426 30% HP - When he morphs +14207 Sphere removed - When Item spell is used on him +14205 Sphere cast - When he casts sphere on self +14201 Beginning of combat - When he aggros +*/ +-- Sniffed text with sounds +DELETE FROM `creature_text` WHERE `entry` IN (@ADMIRAL,@MALGANIS); +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`) VALUES +(@ADMIRAL,0,0, 'How did you find me? Did Landgren tell?',12,0,100,0,0,14201, 'Grand Admiral Westwind'), +(@ADMIRAL,1,0, 'You thought I would just let you kill me?',12,0,100,0,0,14205, 'Grand Admiral Westwind'), +(@ADMIRAL,2,0, 'WHAT?! No matter. Even without my sphere, I will crush you! Behold my true identity and despair!',14,0,100,0,0,14207, 'Grand Admiral Westwind'), +(@ADMIRAL,3,0, 'Gah! I spent too much time in that weak little shell.',14,0,100,0,0,14426, 'Grand Admiral Westwind'), +(@ADMIRAL,4,0, 'Kirel narak! I am Mal''Ganis. I AM ETERNAL!',14,0,100,0,0,14427, 'Grand Admiral Westwind'), +(@ADMIRAL,5,0, 'ENOUGH! I waste my time here. I must gather my strength on the homeworld.',14,0,100,0,0,14428, 'Grand Admiral Westwind'), +(@ADMIRAL,6,0, 'You''ll never defeat the Lich King without my forces. I''ll have my revenge... on him AND you!',14,0,100,0,0,14429, 'Grand Admiral Westwind'); -- cgit v1.2.3 From 56efb2df44bdd1f1c53165645c59c3dca48cfebc Mon Sep 17 00:00:00 2001 From: ZxBiohazardZx Date: Mon, 4 Mar 2013 13:05:03 +0100 Subject: Commit: its monday....... --- sql/updates/world/2013_03_04_00_world_gameobject.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_00_world_gameobject.sql b/sql/updates/world/2013_03_04_00_world_gameobject.sql index 96960abdc7c..caa6a2d0730 100644 --- a/sql/updates/world/2013_03_04_00_world_gameobject.sql +++ b/sql/updates/world/2013_03_04_00_world_gameobject.sql @@ -3,5 +3,5 @@ INSERT INTO `gameobject_template` (`entry`, `type`, `displayId`, `name`, `IconNa (180055,2,318,'Mysterious Wailing Caverns Chest','',,'',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,'',0); DELETE FROM `gameobject` WHERE `id`=180055; -INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) +INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) VALUES (4598,180055,43,1,1,-97.6,173.8,-79,2.08,0,0,0,0,43200,100,1); -- cgit v1.2.3 From e7d333f708942c50c85a4b8f7a4102147a5e895f Mon Sep 17 00:00:00 2001 From: ZxBiohazardZx Date: Mon, 4 Mar 2013 13:22:32 +0100 Subject: Commit: fuck mondays, i cba to fix it, its out --- sql/updates/world/2013_03_04_00_world_gameobject.sql | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 sql/updates/world/2013_03_04_00_world_gameobject.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_00_world_gameobject.sql b/sql/updates/world/2013_03_04_00_world_gameobject.sql deleted file mode 100644 index caa6a2d0730..00000000000 --- a/sql/updates/world/2013_03_04_00_world_gameobject.sql +++ /dev/null @@ -1,7 +0,0 @@ -DELETE FROM `gameobject_template` WHERE `entry`=180055; -INSERT INTO `gameobject_template` (`entry`, `type`, `displayId`, `name`, `IconName`, `castBarCaption`, `unk1`, `faction`, `flags`, `size`, `questItem1`, `questItem2`, `questItem3`, `questItem4`, `questItem5`, `questItem6`, `data0`, `data1`, `data2`, `data3`, `data4`, `data5`, `data6`, `data7`, `data8`, `data9`, `data10`, `data11`, `data12`, `data13`, `data14`, `data15`, `data16`, `data17`, `data18`, `data19`, `data20`, `data21`, `data22`, `data23`, `AIName`, `ScriptName`, `WDBVerified`) VALUES -(180055,2,318,'Mysterious Wailing Caverns Chest','',,'',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,'',0); - -DELETE FROM `gameobject` WHERE `id`=180055; -INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) VALUES -(4598,180055,43,1,1,-97.6,173.8,-79,2.08,0,0,0,0,43200,100,1); -- cgit v1.2.3 From f37e0ee838fbebee80303b2ee915a6696c124bec Mon Sep 17 00:00:00 2001 From: Shauren Date: Mon, 4 Mar 2013 14:15:52 +0100 Subject: Core/Players: Implemented converting quests on faction change (keeping old faction quests in disabled state - not loaded during login) and restoring them if changing back to original faction Closes #890 Closes #9248 --- sql/base/characters_database.sql | 1 + ...0_characters_character_queststatus_rewarded.sql | 1 + ..._03_04_04_world_player_factionchange_quests.sql | 11 +++ src/server/game/Globals/ObjectMgr.cpp | 83 ++++++++++++------ src/server/game/Globals/ObjectMgr.h | 20 +++-- src/server/game/Handlers/CharacterHandler.cpp | 97 ++++++++++++---------- .../Database/Implementation/CharacterDatabase.cpp | 7 +- .../Database/Implementation/CharacterDatabase.h | 5 +- 8 files changed, 144 insertions(+), 81 deletions(-) create mode 100644 sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql create mode 100644 sql/updates/world/2013_03_04_04_world_player_factionchange_quests.sql (limited to 'sql') diff --git a/sql/base/characters_database.sql b/sql/base/characters_database.sql index 423883a77f4..c5a011871ca 100644 --- a/sql/base/characters_database.sql +++ b/sql/base/characters_database.sql @@ -938,6 +938,7 @@ DROP TABLE IF EXISTS `character_queststatus_rewarded`; CREATE TABLE `character_queststatus_rewarded` ( `guid` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'Global Unique Identifier', `quest` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'Quest Identifier', + `active` tinyint(10) unsigned NOT NULL DEFAULT '1', PRIMARY KEY (`guid`,`quest`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Player System'; /*!40101 SET character_set_client = @saved_cs_client */; diff --git a/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql b/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql new file mode 100644 index 00000000000..e4dbf73ad7a --- /dev/null +++ b/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql @@ -0,0 +1 @@ +ALTER TABLE `character_queststatus_rewarded` ADD `active` tinyint(3) unsigned NOT NULL DEFAULT '1' AFTER `quest`; diff --git a/sql/updates/world/2013_03_04_04_world_player_factionchange_quests.sql b/sql/updates/world/2013_03_04_04_world_player_factionchange_quests.sql new file mode 100644 index 00000000000..163383cf0a5 --- /dev/null +++ b/sql/updates/world/2013_03_04_04_world_player_factionchange_quests.sql @@ -0,0 +1,11 @@ +-- ---------------------------- +-- Table structure for `player_factionchange_quests` +-- ---------------------------- +DROP TABLE IF EXISTS `player_factionchange_quests`; +CREATE TABLE `player_factionchange_quests` ( + `alliance_id` int(10) unsigned NOT NULL, + `horde_id` int(10) unsigned NOT NULL, + PRIMARY KEY (`alliance_id`,`horde_id`), + UNIQUE INDEX `alliance_uniq` (`alliance_id`), + UNIQUE INDEX `horde_uniq` (`horde_id`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index c82ea46f0f7..b421bca7d00 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -7684,13 +7684,13 @@ uint32 ObjectMgr::GetAreaTriggerScriptId(uint32 trigger_id) return 0; } -SpellScriptsBounds ObjectMgr::GetSpellScriptsBounds(uint32 spell_id) +SpellScriptsBounds ObjectMgr::GetSpellScriptsBounds(uint32 spellId) const { - return SpellScriptsBounds(_spellScriptsStore.lower_bound(spell_id), _spellScriptsStore.upper_bound(spell_id)); + return SpellScriptsBounds(_spellScriptsStore.equal_range(spellId)); } // this allows calculating base reputations to offline players, just by race and class -int32 ObjectMgr::GetBaseReputationOff(FactionEntry const* factionEntry, uint8 race, uint8 playerClass) +int32 ObjectMgr::GetBaseReputationOf(FactionEntry const* factionEntry, uint8 race, uint8 playerClass) { if (!factionEntry) return 0; @@ -8600,11 +8600,11 @@ void ObjectMgr::LoadFactionChangeAchievements() uint32 horde = fields[1].GetUInt32(); if (!sAchievementMgr->GetAchievement(alliance)) - sLog->outError(LOG_FILTER_SQL, "Achievement %u referenced in `player_factionchange_achievement` does not exist, pair skipped!", alliance); + sLog->outError(LOG_FILTER_SQL, "Achievement %u (alliance_id) referenced in `player_factionchange_achievement` does not exist, pair skipped!", alliance); else if (!sAchievementMgr->GetAchievement(horde)) - sLog->outError(LOG_FILTER_SQL, "Achievement %u referenced in `player_factionchange_achievement` does not exist, pair skipped!", horde); + sLog->outError(LOG_FILTER_SQL, "Achievement %u (horde_id) referenced in `player_factionchange_achievement` does not exist, pair skipped!", horde); else - FactionChange_Achievements[alliance] = horde; + FactionChangeAchievements[alliance] = horde; ++count; } @@ -8635,11 +8635,11 @@ void ObjectMgr::LoadFactionChangeItems() uint32 horde = fields[1].GetUInt32(); if (!GetItemTemplate(alliance)) - sLog->outError(LOG_FILTER_SQL, "Item %u referenced in `player_factionchange_items` does not exist, pair skipped!", alliance); + sLog->outError(LOG_FILTER_SQL, "Item %u (alliance_id) referenced in `player_factionchange_items` does not exist, pair skipped!", alliance); else if (!GetItemTemplate(horde)) - sLog->outError(LOG_FILTER_SQL, "Item %u referenced in `player_factionchange_items` does not exist, pair skipped!", horde); + sLog->outError(LOG_FILTER_SQL, "Item %u (horde_id) referenced in `player_factionchange_items` does not exist, pair skipped!", horde); else - FactionChange_Items[alliance] = horde; + FactionChangeItems[alliance] = horde; ++count; } @@ -8648,15 +8648,15 @@ void ObjectMgr::LoadFactionChangeItems() sLog->outInfo(LOG_FILTER_SERVER_LOADING, ">> Loaded %u faction change item pairs in %u ms", count, GetMSTimeDiffToNow(oldMSTime)); } -void ObjectMgr::LoadFactionChangeSpells() +void ObjectMgr::LoadFactionChangeQuests() { uint32 oldMSTime = getMSTime(); - QueryResult result = WorldDatabase.Query("SELECT alliance_id, horde_id FROM player_factionchange_spells"); + QueryResult result = WorldDatabase.Query("SELECT alliance_id, horde_id FROM player_factionchange_quests"); if (!result) { - sLog->outError(LOG_FILTER_SERVER_LOADING, ">> Loaded 0 faction change spell pairs. DB table `player_factionchange_spells` is empty."); + sLog->outError(LOG_FILTER_SERVER_LOADING, ">> Loaded 0 faction change quest pairs. DB table `player_factionchange_quests` is empty."); return; } @@ -8669,18 +8669,18 @@ void ObjectMgr::LoadFactionChangeSpells() uint32 alliance = fields[0].GetUInt32(); uint32 horde = fields[1].GetUInt32(); - if (!sSpellMgr->GetSpellInfo(alliance)) - sLog->outError(LOG_FILTER_SQL, "Spell %u referenced in `player_factionchange_spells` does not exist, pair skipped!", alliance); - else if (!sSpellMgr->GetSpellInfo(horde)) - sLog->outError(LOG_FILTER_SQL, "Spell %u referenced in `player_factionchange_spells` does not exist, pair skipped!", horde); + if (!sObjectMgr->GetQuestTemplate(alliance)) + sLog->outError(LOG_FILTER_SQL, "Quest %u (alliance_id) referenced in `player_factionchange_quests` does not exist, pair skipped!", alliance); + else if (!sObjectMgr->GetQuestTemplate(horde)) + sLog->outError(LOG_FILTER_SQL, "Quest %u (horde_id) referenced in `player_factionchange_quests` does not exist, pair skipped!", horde); else - FactionChange_Spells[alliance] = horde; + FactionChangeQuests[alliance] = horde; ++count; } while (result->NextRow()); - sLog->outInfo(LOG_FILTER_SERVER_LOADING, ">> Loaded %u faction change spell pairs in %u ms", count, GetMSTimeDiffToNow(oldMSTime)); + sLog->outInfo(LOG_FILTER_SERVER_LOADING, ">> Loaded %u faction change quest pairs in %u ms", count, GetMSTimeDiffToNow(oldMSTime)); } void ObjectMgr::LoadFactionChangeReputations() @@ -8705,11 +8705,11 @@ void ObjectMgr::LoadFactionChangeReputations() uint32 horde = fields[1].GetUInt32(); if (!sFactionStore.LookupEntry(alliance)) - sLog->outError(LOG_FILTER_SQL, "Reputation %u referenced in `player_factionchange_reputations` does not exist, pair skipped!", alliance); + sLog->outError(LOG_FILTER_SQL, "Reputation %u (alliance_id) referenced in `player_factionchange_reputations` does not exist, pair skipped!", alliance); else if (!sFactionStore.LookupEntry(horde)) - sLog->outError(LOG_FILTER_SQL, "Reputation %u referenced in `player_factionchange_reputations` does not exist, pair skipped!", horde); + sLog->outError(LOG_FILTER_SQL, "Reputation %u (horde_id) referenced in `player_factionchange_reputations` does not exist, pair skipped!", horde); else - FactionChange_Reputation[alliance] = horde; + FactionChangeReputation[alliance] = horde; ++count; } @@ -8718,6 +8718,41 @@ void ObjectMgr::LoadFactionChangeReputations() sLog->outInfo(LOG_FILTER_SERVER_LOADING, ">> Loaded %u faction change reputation pairs in %u ms", count, GetMSTimeDiffToNow(oldMSTime)); } +void ObjectMgr::LoadFactionChangeSpells() +{ + uint32 oldMSTime = getMSTime(); + + QueryResult result = WorldDatabase.Query("SELECT alliance_id, horde_id FROM player_factionchange_spells"); + + if (!result) + { + sLog->outError(LOG_FILTER_SERVER_LOADING, ">> Loaded 0 faction change spell pairs. DB table `player_factionchange_spells` is empty."); + return; + } + + uint32 count = 0; + + do + { + Field* fields = result->Fetch(); + + uint32 alliance = fields[0].GetUInt32(); + uint32 horde = fields[1].GetUInt32(); + + if (!sSpellMgr->GetSpellInfo(alliance)) + sLog->outError(LOG_FILTER_SQL, "Spell %u (alliance_id) referenced in `player_factionchange_spells` does not exist, pair skipped!", alliance); + else if (!sSpellMgr->GetSpellInfo(horde)) + sLog->outError(LOG_FILTER_SQL, "Spell %u (horde_id) referenced in `player_factionchange_spells` does not exist, pair skipped!", horde); + else + FactionChangeSpells[alliance] = horde; + + ++count; + } + while (result->NextRow()); + + sLog->outInfo(LOG_FILTER_SERVER_LOADING, ">> Loaded %u faction change spell pairs in %u ms", count, GetMSTimeDiffToNow(oldMSTime)); +} + void ObjectMgr::LoadFactionChangeTitles() { uint32 oldMSTime = getMSTime(); @@ -8740,11 +8775,11 @@ void ObjectMgr::LoadFactionChangeTitles() uint32 horde = fields[1].GetUInt32(); if (!sCharTitlesStore.LookupEntry(alliance)) - sLog->outError(LOG_FILTER_SQL, "Title %u referenced in `player_factionchange_title` does not exist, pair skipped!", alliance); + sLog->outError(LOG_FILTER_SQL, "Title %u (alliance_id) referenced in `player_factionchange_title` does not exist, pair skipped!", alliance); else if (!sCharTitlesStore.LookupEntry(horde)) - sLog->outError(LOG_FILTER_SQL, "Title %u referenced in `player_factionchange_title` does not exist, pair skipped!", horde); + sLog->outError(LOG_FILTER_SQL, "Title %u (horde_id) referenced in `player_factionchange_title` does not exist, pair skipped!", horde); else - FactionChange_Titles[alliance] = horde; + FactionChangeTitles[alliance] = horde; ++count; } diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index 0a5b878e8fa..e621cf96696 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -379,7 +379,7 @@ struct ScriptInfo typedef std::multimap ScriptMap; typedef std::map ScriptMapMap; typedef std::multimap SpellScriptsContainer; -typedef std::pair SpellScriptsBounds; +typedef std::pair SpellScriptsBounds; extern ScriptMapMap sSpellScripts; extern ScriptMapMap sEventScripts; extern ScriptMapMap sWaypointScripts; @@ -780,7 +780,7 @@ class ObjectMgr AreaTrigger const* GetMapEntranceTrigger(uint32 Map) const; uint32 GetAreaTriggerScriptId(uint32 trigger_id); - SpellScriptsBounds GetSpellScriptsBounds(uint32 spell_id); + SpellScriptsBounds GetSpellScriptsBounds(uint32 spellId) const; RepRewardRate const* GetRepRewardRate(uint32 factionId) const { @@ -799,7 +799,7 @@ class ObjectMgr return NULL; } - int32 GetBaseReputationOff(FactionEntry const* factionEntry, uint8 race, uint8 playerClass); + int32 GetBaseReputationOf(FactionEntry const* factionEntry, uint8 race, uint8 playerClass); RepSpilloverTemplate const* GetRepSpilloverTemplate(uint32 factionId) const { @@ -1205,16 +1205,18 @@ class ObjectMgr value = data[loc_idx]; } - CharacterConversionMap FactionChange_Achievements; - CharacterConversionMap FactionChange_Items; - CharacterConversionMap FactionChange_Spells; - CharacterConversionMap FactionChange_Reputation; - CharacterConversionMap FactionChange_Titles; + CharacterConversionMap FactionChangeAchievements; + CharacterConversionMap FactionChangeItems; + CharacterConversionMap FactionChangeQuests; + CharacterConversionMap FactionChangeReputation; + CharacterConversionMap FactionChangeSpells; + CharacterConversionMap FactionChangeTitles; void LoadFactionChangeAchievements(); void LoadFactionChangeItems(); - void LoadFactionChangeSpells(); + void LoadFactionChangeQuests(); void LoadFactionChangeReputations(); + void LoadFactionChangeSpells(); void LoadFactionChangeTitles(); private: diff --git a/src/server/game/Handlers/CharacterHandler.cpp b/src/server/game/Handlers/CharacterHandler.cpp index eb5326e8094..eb9db1439c6 100644 --- a/src/server/game/Handlers/CharacterHandler.cpp +++ b/src/server/game/Handlers/CharacterHandler.cpp @@ -1896,44 +1896,6 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) trans->Append(stmt); } - // Delete all current quests - stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_QUESTSTATUS); - stmt->setUInt32(0, GUID_LOPART(guid)); - trans->Append(stmt); - - // Delete record of the faction old completed quests - { - std::ostringstream quests; - ObjectMgr::QuestMap const& qTemplates = sObjectMgr->GetQuestTemplates(); - for (ObjectMgr::QuestMap::const_iterator iter = qTemplates.begin(); iter != qTemplates.end(); ++iter) - { - Quest *qinfo = iter->second; - uint32 requiredRaces = qinfo->GetRequiredRaces(); - if (team == TEAM_ALLIANCE) - { - if (requiredRaces & RACEMASK_ALLIANCE) - { - quests << uint32(qinfo->GetQuestId()); - quests << ','; - } - } - else // if (team == TEAM_HORDE) - { - if (requiredRaces & RACEMASK_HORDE) - { - quests << uint32(qinfo->GetQuestId()); - quests << ','; - } - } - } - - std::string questsStr = quests.str(); - questsStr = questsStr.substr(0, questsStr.length() - 1); - - if (!questsStr.empty()) - trans->PAppend("DELETE FROM `character_queststatus_rewarded` WHERE guid='%u' AND quest IN (%s)", lowGuid, questsStr.c_str()); - } - if (!sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_GUILD)) { // Reset guild @@ -1991,7 +1953,7 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) trans->Append(stmt); // Achievement conversion - for (std::map::const_iterator it = sObjectMgr->FactionChange_Achievements.begin(); it != sObjectMgr->FactionChange_Achievements.end(); ++it) + for (std::map::const_iterator it = sObjectMgr->FactionChangeAchievements.begin(); it != sObjectMgr->FactionChangeAchievements.end(); ++it) { uint32 achiev_alliance = it->first; uint32 achiev_horde = it->second; @@ -2009,7 +1971,7 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) } // Item conversion - for (std::map::const_iterator it = sObjectMgr->FactionChange_Items.begin(); it != sObjectMgr->FactionChange_Items.end(); ++it) + for (std::map::const_iterator it = sObjectMgr->FactionChangeItems.begin(); it != sObjectMgr->FactionChangeItems.end(); ++it) { uint32 item_alliance = it->first; uint32 item_horde = it->second; @@ -2021,8 +1983,53 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) trans->Append(stmt); } + // Delete all current quests + stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_QUESTSTATUS); + stmt->setUInt32(0, GUID_LOPART(guid)); + trans->Append(stmt); + + // Quest conversion + for (std::map::const_iterator it = sObjectMgr->FactionChangeQuests.begin(); it != sObjectMgr->FactionChangeQuests.end(); ++it) + { + uint32 quest_alliance = it->first; + uint32 quest_horde = it->second; + + stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_QUESTSTATUS_REWARDED_BY_QUEST); + stmt->setUInt32(0, lowGuid); + stmt->setUInt32(1, (team == TEAM_ALLIANCE ? quest_alliance : quest_horde)); + trans->Append(stmt); + + stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_FACTION_CHANGE); + stmt->setUInt32(0, (team == TEAM_ALLIANCE ? quest_alliance : quest_horde)); + stmt->setUInt32(1, (team == TEAM_ALLIANCE ? quest_horde : quest_alliance)); + stmt->setUInt32(2, lowGuid); + trans->Append(stmt); + } + + // Mark all rewarded quests as "active" (will count for completed quests achievements) + stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE); + stmt->setUInt32(0, lowGuid); + trans->Append(stmt); + + // Disable all old-faction specific quests + { + ObjectMgr::QuestMap const& questTemplates = sObjectMgr->GetQuestTemplates(); + for (ObjectMgr::QuestMap::const_iterator iter = questTemplates.begin(); iter != questTemplates.end(); ++iter) + { + Quest const* quest = iter->second; + uint32 newRaceMask = (team == TEAM_ALLIANCE) ? RACEMASK_ALLIANCE : RACEMASK_HORDE; + if (!(quest->GetRequiredRaces() & newRaceMask)) + { + stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE_BY_QUEST); + stmt->setUInt32(0, lowGuid); + stmt->setUInt32(1, quest->GetQuestId()); + trans->Append(stmt); + } + } + } + // Spell conversion - for (std::map::const_iterator it = sObjectMgr->FactionChange_Spells.begin(); it != sObjectMgr->FactionChange_Spells.end(); ++it) + for (std::map::const_iterator it = sObjectMgr->FactionChangeSpells.begin(); it != sObjectMgr->FactionChangeSpells.end(); ++it) { uint32 spell_alliance = it->first; uint32 spell_horde = it->second; @@ -2040,7 +2047,7 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) } // Reputation conversion - for (std::map::const_iterator it = sObjectMgr->FactionChange_Reputation.begin(); it != sObjectMgr->FactionChange_Reputation.end(); ++it) + for (std::map::const_iterator it = sObjectMgr->FactionChangeReputation.begin(); it != sObjectMgr->FactionChangeReputation.end(); ++it) { uint32 reputation_alliance = it->first; uint32 reputation_horde = it->second; @@ -2066,10 +2073,10 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) FactionEntry const* factionEntry = sFactionStore.LookupEntry(oldReputation); // old base reputation - int32 oldBaseRep = sObjectMgr->GetBaseReputationOff(factionEntry, oldRace, playerClass); + int32 oldBaseRep = sObjectMgr->GetBaseReputationOf(factionEntry, oldRace, playerClass); // new base reputation - int32 newBaseRep = sObjectMgr->GetBaseReputationOff(sFactionStore.LookupEntry(newReputation), race, playerClass); + int32 newBaseRep = sObjectMgr->GetBaseReputationOf(sFactionStore.LookupEntry(newReputation), race, playerClass); // final reputation shouldnt change int32 FinalRep = oldDBRep + oldBaseRep; @@ -2101,7 +2108,7 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData) for (uint32 index = 0; index < ktcount; ++index) knownTitles[index] = atol(tokens[index]); - for (std::map::const_iterator it = sObjectMgr->FactionChange_Titles.begin(); it != sObjectMgr->FactionChange_Titles.end(); ++it) + for (std::map::const_iterator it = sObjectMgr->FactionChangeTitles.begin(); it != sObjectMgr->FactionChangeTitles.end(); ++it) { uint32 title_alliance = it->first; uint32 title_horde = it->second; diff --git a/src/server/shared/Database/Implementation/CharacterDatabase.cpp b/src/server/shared/Database/Implementation/CharacterDatabase.cpp index f4da15aefa3..6b264921360 100644 --- a/src/server/shared/Database/Implementation/CharacterDatabase.cpp +++ b/src/server/shared/Database/Implementation/CharacterDatabase.cpp @@ -114,7 +114,7 @@ void CharacterDatabaseConnection::DoPrepareStatements() PrepareStatement(CHAR_SEL_CHARACTER_SKILLS, "SELECT skill, value, max FROM character_skills WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_CHARACTER_RANDOMBG, "SELECT guid FROM character_battleground_random WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_CHARACTER_BANNED, "SELECT guid FROM character_banned WHERE guid = ? AND active = 1", CONNECTION_ASYNC); - PrepareStatement(CHAR_SEL_CHARACTER_QUESTSTATUSREW, "SELECT quest FROM character_queststatus_rewarded WHERE guid = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_SEL_CHARACTER_QUESTSTATUSREW, "SELECT quest FROM character_queststatus_rewarded WHERE guid = ? AND active = 1", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_ACCOUNT_INSTANCELOCKTIMES, "SELECT instanceId, releaseTime FROM account_instance_times WHERE accountId = ?", CONNECTION_ASYNC); // End LoginQueryHolder content @@ -514,8 +514,11 @@ void CharacterDatabaseConnection::DoPrepareStatements() PrepareStatement(CHAR_UPD_MAIL, "UPDATE mail SET has_items = ?, expire_time = ?, deliver_time = ?, money = ?, cod = ?, checked = ? WHERE id = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_REP_CHAR_QUESTSTATUS, "REPLACE INTO character_queststatus (guid, quest, status, explored, timer, mobcount1, mobcount2, mobcount3, mobcount4, itemcount1, itemcount2, itemcount3, itemcount4, playercount) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHAR_QUESTSTATUS_BY_QUEST, "DELETE FROM character_queststatus WHERE guid = ? AND quest = ?", CONNECTION_ASYNC); - PrepareStatement(CHAR_INS_CHAR_QUESTSTATUS, "INSERT IGNORE INTO character_queststatus_rewarded (guid, quest) VALUES (?, ?)", CONNECTION_ASYNC); + PrepareStatement(CHAR_INS_CHAR_QUESTSTATUS_REWARDED, "INSERT IGNORE INTO character_queststatus_rewarded (guid, quest, active) VALUES (?, ?, 1)", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHAR_QUESTSTATUS_REWARDED_BY_QUEST, "DELETE FROM character_queststatus_rewarded WHERE guid = ? AND quest = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_FACTION_CHANGE, "UPDATE character_queststatus_rewarded SET quest = ? WHERE quest = ? AND guid = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE, "UPDATE character_queststatus_rewarded SET active = 1 WHERE guid = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE_BY_QUEST, "UPDATE character_queststatus_rewarded SET active = 0 WHERE quest = ? AND guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHAR_SKILL_BY_SKILL, "DELETE FROM character_skills WHERE guid = ? AND skill = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_INS_CHAR_SKILLS, "INSERT INTO character_skills (guid, skill, value, max) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_UDP_CHAR_SKILLS, "UPDATE character_skills SET value = ?, max = ? WHERE guid = ? AND skill = ?", CONNECTION_ASYNC); diff --git a/src/server/shared/Database/Implementation/CharacterDatabase.h b/src/server/shared/Database/Implementation/CharacterDatabase.h index 4c5f5d27899..ae15ddb0551 100644 --- a/src/server/shared/Database/Implementation/CharacterDatabase.h +++ b/src/server/shared/Database/Implementation/CharacterDatabase.h @@ -454,8 +454,11 @@ enum CharacterDatabaseStatements CHAR_UPD_MAIL, CHAR_REP_CHAR_QUESTSTATUS, CHAR_DEL_CHAR_QUESTSTATUS_BY_QUEST, - CHAR_INS_CHAR_QUESTSTATUS, + CHAR_INS_CHAR_QUESTSTATUS_REWARDED, CHAR_DEL_CHAR_QUESTSTATUS_REWARDED_BY_QUEST, + CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_FACTION_CHANGE, + CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE, + CHAR_UPD_CHAR_QUESTSTATUS_REWARDED_ACTIVE_BY_QUEST, CHAR_DEL_CHAR_SKILL_BY_SKILL, CHAR_INS_CHAR_SKILLS, CHAR_UDP_CHAR_SKILLS, -- cgit v1.2.3 From 34d94781863cd228124c0150f7b90c5a149fc2d2 Mon Sep 17 00:00:00 2001 From: Kinzcool Date: Mon, 4 Mar 2013 10:12:21 -0500 Subject: DB/Quests: Added a lot of factionchange quests --- ..._03_04_05_world_player_factionchange_quests.sql | 252 +++++++++++++++++++++ 1 file changed, 252 insertions(+) create mode 100644 sql/updates/world/2013_03_04_05_world_player_factionchange_quests.sql (limited to 'sql') diff --git a/sql/updates/world/2013_03_04_05_world_player_factionchange_quests.sql b/sql/updates/world/2013_03_04_05_world_player_factionchange_quests.sql new file mode 100644 index 00000000000..cd08b4cbcc9 --- /dev/null +++ b/sql/updates/world/2013_03_04_05_world_player_factionchange_quests.sql @@ -0,0 +1,252 @@ +DELETE FROM `player_factionchange_quests` WHERE `alliance_id` IN (9524, 8114, 7168, 7169, 7170, 7171, 7172, 8115, 8311, 8960, 8860, 8997, 9520, 9522, 9587, 9869, 9933, 9938, 9940, 9982, 9994, 9996, 10005, 10014, 10033, 10035, 10038, 10040, 10042, 10048, 10051, 10053, 10054, 10055, 10056, 10057, 10076, 10078, 10080, 10083, 10084, 10115, 10116, 10140, 10141, 10122, 10142, 10126, 10145, 10128, 10146, 10130, 10131, 10147, 10148, 10137, 10138, 10139, 10163, 10394, 10397, 10395, 10443, 10444, 10476, 10562, 10563, 10564, 10572, 10582, 10583, 10585, 10586, 10589, 10606, 10612, 10621, 10626, 10662, 10680, 10744, 10772, 10773, 10754, 10762, 10763, 10764, 10759, 10774, 10766, 10775, 10776, 10863, 10869, 10962, 11002, 11117, 11122, 11123, 11150, 11185, 11242, 11302, 11346, 11348, 11349, 11355, 11358, 11359, 11321, 11131, 12135, 11400, 11486, 11502, 11657, 11713, 11704, 11731, 11882, 11921, 11924, 11986, 11993, 12022, 12105, 12129, 12130, 12131, 12133, 12138, 12142, 12143, 12146, 12153, 12161, 12183, 12184, 12185, 12219, 12220, 12222, 12223, 12246, 12247, 12249, 12248, 12250, 12255, 12278, 12464, 12323, 12416, 12417, 12418, 12460, 12479, 12491, 12854, 12858, 12860, 12862, 12870, 12872, 12885, 13186, 13222, 13188, 13226, 13395, 13387, 13388, 13389, 13390, 13391, 13392, 13284, 13393, 13394, 13332, 13334, 13309, 13337, 13338, 13339, 13335, 13336, 13341, 13396, 13397, 13398, 13399, 13400, 13401, 13402, 13403, 13380, 13381, 13382, 13383, 13408, 13410, 13415, 13418, 13480, 13484, 13633, 13625, 13671, 13672, 13679, 13686, 13828, 13835, 13837, 14022, 14023, 14024, 14028, 14030, 14033, 14035, 14048, 14051, 14053, 14054, 14055, 14096, 14111, 20438, 20439, 24498, 24499, 24500, 24510, 24535, 24656, 24657, 24683, 24710, 24711, 24655, 24804, 24848, 25055, 25180, 25253, 25282, 25290, 25414); +INSERT INTO `player_factionchange_quests` (`alliance_id`, `horde_id`) VALUES +(9524, 9525), +(8114, 8121), +(7168, 7163), +(7169, 7164), +(7170, 7165), +(7171, 7166), +(7172, 7167), +(8115, 8122), +(8311, 8312), +(8960, 9032), +(8860, 8861), +(8997, 8998), +(9520, 9535), +(9522, 9536), +(9587, 9588), +(9869, 9870), +(9933, 9934), +(9938, 9937), +(9940, 9939), +(9982, 9983), +(9994, 9995), +(9996, 9997), +(10005, 10006), +(10014, 10015), +(10033, 10034), +(10035, 10036), +(10038, 10039), +(10040, 10041), +(10042, 10043), +(10048, 10049), +(10051, 10052), +(10053, 10059), +(10054, 10060), +(10055, 10086), +(10056, 10158), +(10057, 10062), +(10076, 10074), +(10078, 10087), +(10080, 10089), +(10083, 10090), +(10084, 10092), +(10115, 10118), +(10116, 10117), +(10140, 10120), +(10141, 10121), +(10122, 10150), +(10142, 10123), +(10126, 10151), +(10145, 10127), +(10128, 10153), +(10146, 10129), +(10130, 10152), +(10131, 10154), +(10147, 10133), +(10148, 10135), +(10137, 10155), +(10138, 10156), +(10139, 10157), +(10163, 10162), +(10394, 10390), +(10397, 10392), +(10395, 10393), +(10443, 10442), +(10444, 10448), +(10476, 10479), +(10562, 10595), +(10563, 10596), +(10564, 10598), +(10572, 10597), +(10582, 10600), +(10583, 10601), +(10585, 10602), +(10586, 10603), +(10589, 10604), +(10606, 10611), +(10612, 10613), +(10621, 10623), +(10626, 10627), +(10662, 10663), +(10680, 10681), +(10744, 10745), +(10772, 10750), +(10773, 10751), +(10754, 10755), +(10762, 10756), +(10763, 10757), +(10764, 10758), +(10759, 10761), +(10774, 10765), +(10766, 10767), +(10775, 10768), +(10776, 10769), +(10863, 10862), +(10869, 10868), +(10962, 10963), +(11002, 11003), +(11117, 11431), +(11122, 11412), +(11123, 11124), +(11150, 11205), +(11185, 11186), +(11242, 11403), +(11302, 11312), +(11346, 11350), +(11348, 11352), +(11349, 11351), +(11355, 11365), +(11358, 11366), +(11359, 11367), +(11321, 11413), +(11131, 11219), +(12135, 12139), +(11400, 11419), +(11486, 11487), +(11502, 11503), +(11657, 11923), +(11713, 11684), +(11704, 11702), +(11731, 11922), +(11882, 11915), +(11921, 11926), +(11924, 11925), +(11986, 12026), +(11993, 12058), +(12022, 12191), +(12105, 12423), +(12129, 12165), +(12130, 12196), +(12131, 12197), +(12133, 12155), +(12138, 12198), +(12142, 12144), +(12143, 12145), +(12146, 12147), +(12153, 12199), +(12161, 12425), +(12183, 12201), +(12184, 12202), +(12185, 12203), +(12219, 12207), +(12220, 12213), +(12222, 12256), +(12223, 12257), +(12246, 12229), +(12247, 12231), +(12249, 12236), +(12248, 12241), +(12250, 12242), +(12255, 12259), +(12278, 12306), +(12464, 12285), +(12323, 12324), +(12416, 12448), +(12417, 12449), +(12418, 12450), +(12460, 12461), +(12479, 12480), +(12491, 12492), +(12854, 12895), +(12858, 12926), +(12860, 12927), +(12862, 13060), +(12870, 12882), +(12872, 12928), +(12885, 12929), +(13186, 13185), +(13222, 13223), +(13188, 13189), +(13226, 13227), +(13395, 13236), +(13387, 13259), +(13388, 13262), +(13389, 13263), +(13390, 13271), +(13391, 13275), +(13392, 13282), +(13284, 13301), +(13393, 13304), +(13394, 13305), +(13332, 13306), +(13334, 13307), +(13309, 13310), +(13337, 13312), +(13338, 13316), +(13339, 13328), +(13335, 13329), +(13336, 13330), +(13341, 13340), +(13396, 13348), +(13397, 13349), +(13398, 13359), +(13399, 13360), +(13400, 13361), +(13401, 13362), +(13402, 13363), +(13403, 13364), +(13380, 13373), +(13381, 13374), +(13382, 13376), +(13383, 13379), +(13408, 13409), +(13410, 13411), +(13415, 13416), +(13418, 13419), +(13480, 13479), +(13484, 13483), +(13633, 13634), +(13625, 13677), +(13671, 13676), +(13672, 13678), +(13679, 13680), +(13686, 13687), +(13828, 13829), +(13835, 13838), +(13837, 13839), +(14022, 14036), +(14023, 14037), +(14024, 14040), +(14028, 14041), +(14030, 14044), +(14033, 14043), +(14035, 14047), +(14048, 14061), +(14051, 14062), +(14053, 14059), +(14054, 14060), +(14055, 14058), +(14096, 14142), +(14111, 14100), +(20438, 24556), +(20439, 24451), +(24498, 24507), +(24499, 24511), +(24500, 24802), +(24510, 24506), +(24535, 24563), +(24656, 24541), +(24657, 24576), +(24683, 24682), +(24710, 24712), +(24711, 24713), +(24655, 24536), +(24804, 24805), +(24848, 24850), +(25055, 25092), +(25180, 25181), +(25253, 25228), +(25282, 25254), +(25290, 25288), +(25414, 25293); -- cgit v1.2.3 From 226e0fdd1b08e315cb7f534b97a7d48e33bbf4fe Mon Sep 17 00:00:00 2001 From: Shauren Date: Mon, 4 Mar 2013 17:08:07 +0100 Subject: Unbreak the build and renamed sql file to proper date --- .../2012_03_04_00_characters_character_queststatus_rewarded.sql | 1 - .../2013_03_04_00_characters_character_queststatus_rewarded.sql | 1 + src/server/game/Globals/ObjectMgr.cpp | 6 +++--- src/server/game/Globals/ObjectMgr.h | 4 ++-- src/server/game/Scripting/ScriptMgr.cpp | 8 ++++---- src/server/game/Scripting/ScriptMgr.h | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) delete mode 100644 sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql create mode 100644 sql/updates/characters/2013_03_04_00_characters_character_queststatus_rewarded.sql (limited to 'sql') diff --git a/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql b/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql deleted file mode 100644 index e4dbf73ad7a..00000000000 --- a/sql/updates/characters/2012_03_04_00_characters_character_queststatus_rewarded.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE `character_queststatus_rewarded` ADD `active` tinyint(3) unsigned NOT NULL DEFAULT '1' AFTER `quest`; diff --git a/sql/updates/characters/2013_03_04_00_characters_character_queststatus_rewarded.sql b/sql/updates/characters/2013_03_04_00_characters_character_queststatus_rewarded.sql new file mode 100644 index 00000000000..e4dbf73ad7a --- /dev/null +++ b/sql/updates/characters/2013_03_04_00_characters_character_queststatus_rewarded.sql @@ -0,0 +1 @@ +ALTER TABLE `character_queststatus_rewarded` ADD `active` tinyint(3) unsigned NOT NULL DEFAULT '1' AFTER `quest`; diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index 643b0b7a91b..08b05b1a7e3 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -4919,11 +4919,11 @@ void ObjectMgr::ValidateSpellScripts() for (SpellScriptsContainer::iterator itr = _spellScriptsStore.begin(); itr != _spellScriptsStore.end();) { SpellInfo const* spellEntry = sSpellMgr->GetSpellInfo(itr->first); - std::vector > SpellScriptLoaders; + std::vector > SpellScriptLoaders; sScriptMgr->CreateSpellScriptLoaders(itr->first, SpellScriptLoaders); itr = _spellScriptsStore.upper_bound(itr->first); - for (std::vector >::iterator sitr = SpellScriptLoaders.begin(); sitr != SpellScriptLoaders.end(); ++sitr) + for (std::vector >::iterator sitr = SpellScriptLoaders.begin(); sitr != SpellScriptLoaders.end(); ++sitr) { SpellScript* spellScript = sitr->first->GetSpellScript(); AuraScript* auraScript = sitr->first->GetAuraScript(); @@ -7684,7 +7684,7 @@ uint32 ObjectMgr::GetAreaTriggerScriptId(uint32 trigger_id) return 0; } -SpellScriptsBounds ObjectMgr::GetSpellScriptsBounds(uint32 spellId) const +SpellScriptsBounds ObjectMgr::GetSpellScriptsBounds(uint32 spellId) { return SpellScriptsBounds(_spellScriptsStore.equal_range(spellId)); } diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index e621cf96696..f219b2feb5f 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -379,7 +379,7 @@ struct ScriptInfo typedef std::multimap ScriptMap; typedef std::map ScriptMapMap; typedef std::multimap SpellScriptsContainer; -typedef std::pair SpellScriptsBounds; +typedef std::pair SpellScriptsBounds; extern ScriptMapMap sSpellScripts; extern ScriptMapMap sEventScripts; extern ScriptMapMap sWaypointScripts; @@ -780,7 +780,7 @@ class ObjectMgr AreaTrigger const* GetMapEntranceTrigger(uint32 Map) const; uint32 GetAreaTriggerScriptId(uint32 trigger_id); - SpellScriptsBounds GetSpellScriptsBounds(uint32 spellId) const; + SpellScriptsBounds GetSpellScriptsBounds(uint32 spellId); RepRewardRate const* GetRepRewardRate(uint32 factionId) const { diff --git a/src/server/game/Scripting/ScriptMgr.cpp b/src/server/game/Scripting/ScriptMgr.cpp index 14da3389c2c..32fe5d2ef33 100644 --- a/src/server/game/Scripting/ScriptMgr.cpp +++ b/src/server/game/Scripting/ScriptMgr.cpp @@ -322,7 +322,7 @@ void ScriptMgr::CreateSpellScripts(uint32 spellId, std::list& scri { SpellScriptsBounds bounds = sObjectMgr->GetSpellScriptsBounds(spellId); - for (SpellScriptsContainer::const_iterator itr = bounds.first; itr != bounds.second; ++itr) + for (SpellScriptsContainer::iterator itr = bounds.first; itr != bounds.second; ++itr) { SpellScriptLoader* tmpscript = ScriptRegistry::GetScriptById(itr->second); if (!tmpscript) @@ -343,7 +343,7 @@ void ScriptMgr::CreateAuraScripts(uint32 spellId, std::list& script { SpellScriptsBounds bounds = sObjectMgr->GetSpellScriptsBounds(spellId); - for (SpellScriptsContainer::const_iterator itr = bounds.first; itr != bounds.second; ++itr) + for (SpellScriptsContainer::iterator itr = bounds.first; itr != bounds.second; ++itr) { SpellScriptLoader* tmpscript = ScriptRegistry::GetScriptById(itr->second); if (!tmpscript) @@ -360,12 +360,12 @@ void ScriptMgr::CreateAuraScripts(uint32 spellId, std::list& script } } -void ScriptMgr::CreateSpellScriptLoaders(uint32 spellId, std::vector >& scriptVector) +void ScriptMgr::CreateSpellScriptLoaders(uint32 spellId, std::vector >& scriptVector) { SpellScriptsBounds bounds = sObjectMgr->GetSpellScriptsBounds(spellId); scriptVector.reserve(std::distance(bounds.first, bounds.second)); - for (SpellScriptsContainer::const_iterator itr = bounds.first; itr != bounds.second; ++itr) + for (SpellScriptsContainer::iterator itr = bounds.first; itr != bounds.second; ++itr) { SpellScriptLoader* tmpscript = ScriptRegistry::GetScriptById(itr->second); if (!tmpscript) diff --git a/src/server/game/Scripting/ScriptMgr.h b/src/server/game/Scripting/ScriptMgr.h index 8f8f696e452..b13c2da7f6c 100644 --- a/src/server/game/Scripting/ScriptMgr.h +++ b/src/server/game/Scripting/ScriptMgr.h @@ -861,7 +861,7 @@ class ScriptMgr void CreateSpellScripts(uint32 spellId, std::list& scriptVector); void CreateAuraScripts(uint32 spellId, std::list& scriptVector); - void CreateSpellScriptLoaders(uint32 spellId, std::vector::const_iterator> >& scriptVector); + void CreateSpellScriptLoaders(uint32 spellId, std::vector::iterator> >& scriptVector); public: /* ServerScript */ -- cgit v1.2.3