diff options
65 files changed, 2129 insertions, 472 deletions
diff --git a/sql/updates/world/2015_11_09_02_world335.sql b/sql/updates/world/2015_11_09_02_world_335.sql index 84c0fd423ad..84c0fd423ad 100644 --- a/sql/updates/world/2015_11_09_02_world335.sql +++ b/sql/updates/world/2015_11_09_02_world_335.sql diff --git a/sql/updates/world/2015_12_16_02_world335.sql b/sql/updates/world/2015_12_16_02_world_335.sql index 20c1ac94a39..20c1ac94a39 100644 --- a/sql/updates/world/2015_12_16_02_world335.sql +++ b/sql/updates/world/2015_12_16_02_world_335.sql diff --git a/sql/updates/world/2015_12_20_00_world.sql b/sql/updates/world/2015_12_20_00_world.sql index 51f762c5fd7..7c658877f13 100644 --- a/sql/updates/world/2015_12_20_00_world.sql +++ b/sql/updates/world/2015_12_20_00_world.sql @@ -1,5 +1,5 @@ SET @OGUID:=78976; -DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+543; +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+544; INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES (@OGUID+0 , 187567, 530, 1, 1, -2972.565, 2562.675, 83.66947, 5.829401, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3744) (@OGUID+1 , 187567, 530, 1, 1, -2955.605, 2554.495, 110.3285, 5.846854, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3744) diff --git a/sql/updates/world/2016_01_02_00_world335.sql b/sql/updates/world/2016_01_02_00_world_335.sql index b46a41bc6e9..b46a41bc6e9 100644 --- a/sql/updates/world/2016_01_02_00_world335.sql +++ b/sql/updates/world/2016_01_02_00_world_335.sql diff --git a/sql/updates/world/2016_01_10_05_world335.sql b/sql/updates/world/2016_01_10_05_world_335.sql index 7fb021cc9dd..7fb021cc9dd 100644 --- a/sql/updates/world/2016_01_10_05_world335.sql +++ b/sql/updates/world/2016_01_10_05_world_335.sql diff --git a/sql/updates/world/2016_01_12_01_world335.sql b/sql/updates/world/2016_01_12_01_world_335.sql index c3206e70ac4..c3206e70ac4 100644 --- a/sql/updates/world/2016_01_12_01_world335.sql +++ b/sql/updates/world/2016_01_12_01_world_335.sql diff --git a/sql/updates/world/2016_01_12_02_world335.sql b/sql/updates/world/2016_01_12_02_world_335.sql index 354d0bc129d..354d0bc129d 100644 --- a/sql/updates/world/2016_01_12_02_world335.sql +++ b/sql/updates/world/2016_01_12_02_world_335.sql diff --git a/sql/updates/world/2016_01_15_00_world.sql b/sql/updates/world/2016_01_15_00_world.sql new file mode 100644 index 00000000000..b5f3da2dd99 --- /dev/null +++ b/sql/updates/world/2016_01_15_00_world.sql @@ -0,0 +1,29 @@ +-- +SET @GUID := 52323; +SET @pool_id := 1107; + +DELETE FROM `creature` WHERE `guid` BETWEEN @GUID AND @GUID+3; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`curhealth`,`curmana`,`MovementType`) VALUES +(@GUID+0, 18684, 530, 1, 1, 0, 0, -1768.23, 6737.47, -21.3348, 6.18901, 28800, 15, 9784, 5692, 1), +(@GUID+1, 18684, 530, 1, 1, 0, 0, -2585.25, 6416.29, 26.8608, 5.44446, 28800, 15, 9784, 5692, 1), +(@GUID+2, 18684, 530, 1, 1, 0, 0, -2002.52, 7622.98, -88.0942, 5.61332, 28800, 15, 9784, 5692, 1), +(@GUID+3, 18684, 530, 1, 1, 0, 0, -1200.42, 8810.52, 41.1305, 4.35118, 28800, 15, 9784, 5692, 1); + +DELETE FROM `pool_template` WHERE `entry` = @pool_id; +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@pool_id, 1, 'Bro''Gaz the Clanless'); + +DELETE FROM `pool_creature` WHERE `guid` BETWEEN @GUID AND @GUID+3; +INSERT INTO `pool_creature` (`guid`, `pool_entry`, `chance`, `description`) VALUES +(@GUID+0, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 1'), +(@GUID+1, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 2'), +(@GUID+2, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 3'), +(@GUID+3, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 4'); + +SET @ENTRY := 18684; +UPDATE `creature_template` SET `AIName`='SmartAI', `unit_flags`=0 WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@ENTRY; +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,2000,7000,10000,16000,11,12468,0,0,0,0,0,2,0,0,0,0,0,0,0,'Bro''Gaz the Clanless - IC - Cast Flamestrike'), +(@ENTRY,0,1,0,0,0,100,0,8000,11000,12000,15000,11,15586,0,0,0,0,0,1,0,0,0,0,0,0,0,'Bro''Gaz the Clanless IC - Cast heal'), +(@ENTRY,0,2,0,0,0,100,0,6000,10000,9000,10000,11,12555,0,0,0,0,0,2,0,0,0,0,0,0,0,'Bro''Gaz the Clanless IC - Cast Pummel'); diff --git a/sql/updates/world/2016_01_16_00_world_335.sql b/sql/updates/world/2016_01_16_00_world_335.sql new file mode 100644 index 00000000000..14362432555 --- /dev/null +++ b/sql/updates/world/2016_01_16_00_world_335.sql @@ -0,0 +1,5 @@ +-- +UPDATE `creature` SET `phaseMask`=1 WHERE `id` IN (25328,31105) AND `guid` IN (26169,68282); +UPDATE `creature` SET `phaseMask`=16 WHERE `id` IN (38421, 37950); +UPDATE `creature` SET `phaseMask`=64 WHERE `id` IN (31314, 30698, 31306, 31428); +UPDATE `creature` SET `phaseMask`=255 WHERE `phaseMask` =131; diff --git a/sql/updates/world/2016_01_16_01_world.sql b/sql/updates/world/2016_01_16_01_world.sql new file mode 100644 index 00000000000..235378a7a84 --- /dev/null +++ b/sql/updates/world/2016_01_16_01_world.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `npc_text` WHERE `ID` = 10884; +DELETE FROM `gossip_menu` WHERE `entry`=8441 AND `text_id`=10884; diff --git a/sql/updates/world/2016_01_16_02_world.sql b/sql/updates/world/2016_01_16_02_world.sql new file mode 100644 index 00000000000..b36d7d69ff6 --- /dev/null +++ b/sql/updates/world/2016_01_16_02_world.sql @@ -0,0 +1,7 @@ +-- +DELETE FROM `creature_template_addon` WHERE `entry` IN (16525); +INSERT INTO `creature_template_addon` (`entry`, `bytes2`, `auras`) VALUES +(16525, 1, '29920'); + +UPDATE `smart_scripts` SET `event_chance`=100 WHERE `entryorguid`=16525 AND `source_type`=0; +UPDATE `smart_scripts` SET `event_flags`=3, `event_param1`=0, `event_param2`=0, `event_param3`=0, `event_param4`=0, `action_type`=28, `comment`="Spell Shade - In Combat - Remove Aura 'Phasing Invisibility' (Normal Dungeon)" WHERE `entryorguid`=16525 AND `source_type`=0 AND `id`=3; diff --git a/sql/updates/world/2016_01_16_03_world.sql b/sql/updates/world/2016_01_16_03_world.sql new file mode 100644 index 00000000000..5a06cfaecca --- /dev/null +++ b/sql/updates/world/2016_01_16_03_world.sql @@ -0,0 +1,11 @@ +-- +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=29333; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=29333; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN (29329, 29330, 29338) AND `id`=2; +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 +(29329,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Paladin - On spell hit "Darkmender''s Tincture" - Despawn'), +(29330,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Harbor Guard - On spell hit "Darkmender''s Tincture" - Despawn'), +(29338,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Raven Bishop - On spell hit "Darkmender''s Tincture" - Despawn'), +(29333,0,0,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Gryphon Rider - On spell hit "Darkmender''s Tincture" - Despawn'); + +UPDATE `spell_scripts` SET `datalong2`=2, `dataint`=0 WHERE `id`=52741 AND `command`=15; diff --git a/sql/updates/world/2016_01_16_04_world.sql b/sql/updates/world/2016_01_16_04_world.sql new file mode 100644 index 00000000000..a6bb7ae185c --- /dev/null +++ b/sql/updates/world/2016_01_16_04_world.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_script_names` WHERE `spell_id`=53651; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(53651, 'spell_pal_light_s_beacon'); diff --git a/sql/updates/world/2016_01_16_05_world.sql b/sql/updates/world/2016_01_16_05_world.sql new file mode 100644 index 00000000000..46511cb0de8 --- /dev/null +++ b/sql/updates/world/2016_01_16_05_world.sql @@ -0,0 +1,32 @@ +-- +SET @guid=87572; +DELETE FROM `creature` WHERE `guid` BETWEEN 87572 AND 87592; +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `curhealth`) VALUES +(@Guid+0, 23008, 530, 1, 1, 0, 0, 3647.45, 1918.92, 118.17, 3.80525, 600, 0, 13285), +(@Guid+1, 23008, 530, 1, 1, 0, 0, 3600.99, 1898.07, 111.36, 4.56316, 600, 0, 13285), +(@Guid+2, 23008, 530, 1, 1, 0, 0, 3573.03, 1861.43, 108.895, 2.74103, 600, 0, 13285), +(@Guid+3, 23008, 530, 1, 1, 0, 0, 3669.82, 1815.83, 126.059, 6.17322, 600, 0, 13285), +(@Guid+4, 23008, 530, 1, 1, 0, 0, 3685.04, 1772.15, 130.008, 5.97294, 600, 0, 13285), +(@Guid+5, 23008, 530, 1, 1, 0, 0, 3718.62, 1728.71, 138.644, 5.75303, 600, 0, 13285), +(@Guid+6, 23008, 530, 1, 1, 0, 0, 3770.45, 1704.41, 149.751, 4.0016, 600, 0, 13285), +(@Guid+7, 23008, 530, 1, 1, 0, 0, 3793.48, 1638.27, 135.625, 0.0691063, 600, 0, 13285), +(@Guid+8, 23008, 530, 1, 1, 0, 0, 3805.98, 1573.23, 118.196, 1.39643, 600, 0, 13285), +(@Guid+9, 23008, 530, 1, 1, 0, 0, 3835.62, 1614.66, 127.926, 1.56529, 600, 0, 13285), +(@Guid+10, 23008, 530, 1, 1, 0, 0, 3894.74, 1649.2, 127.552, 4.65976, 600, 0, 13285), +(@Guid+11, 23008, 530, 1, 1, 0, 0, 3930.28, 1647.93, 126.538, 0.685644, 600, 0, 13285), +(@Guid+12, 23008, 530, 1, 1, 0, 0, 4057.55, 1698.7, 136.879, 4.81684, 600, 0, 13285), +(@Guid+13, 23008, 530, 1, 1, 0, 0, 4097.41, 1710.19, 137.963, 0.756329, 600, 0, 13285), +(@Guid+14, 23008, 530, 1, 1, 0, 0, 4123.97, 1661.08, 126.587, 0.316505, 600, 0, 13285), +(@Guid+15, 23008, 530, 1, 1, 0, 0, 4162.44, 1671.21, 116.169, 1.18437, 600, 0, 13285), +(@Guid+16, 23008, 530, 1, 1, 0, 0, 4196.29, 1697.37, 118.356, 1.66346, 600, 0, 13285), +(@Guid+17, 23008, 530, 1, 1, 0, 0, 4227.59, 1710.46, 121.084, 2.26429, 600, 0, 13285), +(@Guid+18, 23008, 530, 1, 1, 0, 0, 4221.32, 1766.66, 130.509, 2.1779, 600, 0, 13285), +(@Guid+19, 23008, 530, 1, 1, 0, 0, 4252.49, 1835.95, 143.106, 2.0758, 600, 0, 13285), +(@Guid+20, 23008, 530, 1, 1, 0, 0, 4285.64, 1900.79, 134.852, 2.0758, 600, 0, 13285); + +SET @ENTRY := 23008; +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@ENTRY; +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,3000,4000,12000,16000,11,35924,0,0,0,0,0,2,0,0,0,0,0,0,0,'Ethereum Jailor - IC - Cast Energy Flux'), +(@ENTRY,0,1,0,0,0,100,0,4000,5000,9000,17000,11,36513,0,0,0,0,0,2,0,0,0,0,0,0,0,'Ethereum Jailor - IC - Cast Intangible Presence'); diff --git a/sql/updates/world/2016_01_17_00_world_335.sql b/sql/updates/world/2016_01_17_00_world_335.sql new file mode 100644 index 00000000000..abb3579fb07 --- /dev/null +++ b/sql/updates/world/2016_01_17_00_world_335.sql @@ -0,0 +1,26 @@ +-- +SET @NPC := 26577; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-2369.16,`position_y`=-876.936,`position_z`=-9.42208 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-2369.16,-876.936,-9.42208,0,0,0,0,100,0), +(@PATH,2,-2366.53,-856.691,-9.36085,0,0,0,0,100,0), +(@PATH,3,-2357.15,-811.864,-9.42138,0,0,0,0,100,0), +(@PATH,4,-2345.23,-748.967,-9.42454,0,0,0,0,100,0), +(@PATH,5,-2341.13,-700.582,-9.29519,0,0,0,0,100,0), +(@PATH,6,-2335.57,-673.555,-9.41523,0,0,0,0,100,0), +(@PATH,7,-2323.8,-641.711,-9.34184,0,0,0,0,100,0), +(@PATH,8,-2310.09,-613.217,-9.42431,0,0,0,0,100,0), +(@PATH,9,-2295.38,-586.808,-9.4231,2.396761,21600,0,0,100,0), +(@PATH,10,-2323.09,-595.375,-9.42242,0,0,0,0,100,0), +(@PATH,11,-2312.27,-614.66,-9.42405,0,0,0,0,100,0), +(@PATH,12,-2326.41,-645.536,-9.34993,0,0,0,0,100,0), +(@PATH,13,-2336.51,-676.214,-9.40864,0,0,0,0,100,0), +(@PATH,14,-2344.05,-723.843,-9.42353,0,0,0,0,100,0), +(@PATH,15,-2346.75,-760.367,-9.42353,0,0,0,0,100,0), +(@PATH,16,-2357.56,-811.652,-9.42353,0,0,0,0,100,0), +(@PATH,17,-2366.12,-855.675,-9.32695,0,0,0,0,100,0), +(@PATH,18,-2376.83,-896.428,-9.39643,6.216497,21600,0,0,100,0); diff --git a/sql/updates/world/2016_01_17_01_world.sql b/sql/updates/world/2016_01_17_01_world.sql new file mode 100644 index 00000000000..8e5bcd22a07 --- /dev/null +++ b/sql/updates/world/2016_01_17_01_world.sql @@ -0,0 +1,9 @@ +-- +DELETE FROM `creature_template_addon` WHERE `entry` IN (21694,21914,17796,17797,20629,20630); +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(21694,0,0x0,0x1,'18950'), -- 21694 - 18950 +(21914,0,0x0,0x1,'18950'), -- 21914 - 18950 +(17796,0,0x0,0x1,'18950'), -- 17796 - 18950 +(17797,0,0x0,0x1,'18950'), -- 17797 - 18950 +(20629,0,0x0,0x1,'18950'), -- 20629 - 18950 +(20630,0,0x0,0x1,'18950'); -- 20630 - 18950 diff --git a/sql/updates/world/2016_01_17_02_world.sql b/sql/updates/world/2016_01_17_02_world.sql new file mode 100644 index 00000000000..f019b927228 --- /dev/null +++ b/sql/updates/world/2016_01_17_02_world.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `creature_onkill_reputation` WHERE `creature_id`=20477; +INSERT INTO `creature_onkill_reputation` (`creature_id`, `RewOnKillRepFaction1`, `RewOnKillRepFaction2`, `MaxStanding1`, `IsTeamAward1`, `RewOnKillRepValue1`, `MaxStanding2`, `IsTeamAward2`, `RewOnKillRepValue2`, `TeamDependent`) VALUES +(20477, 942, 0, 5, 0, 7, 0, 0, 0, 0); diff --git a/sql/updates/world/2016_01_17_03_world.sql b/sql/updates/world/2016_01_17_03_world.sql new file mode 100644 index 00000000000..cf43c650888 --- /dev/null +++ b/sql/updates/world/2016_01_17_03_world.sql @@ -0,0 +1,46 @@ +SET @OGUID:=66937; +SET @CGUID:=12545; +SET @Event:=2; + +-- Add missing xmas ornaments in silvermoon +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+26; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 187567, 530, 1, 1, 9757.145, -7186.155, 23.50618, 2.897245, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+1, 187567, 530, 1, 1, 9799.123, -7310.608, 35.23363, 2.199115, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+2, 187567, 530, 1, 1, 9790.945, -7316.393, 35.23556, 2.234018, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+3, 187567, 530, 1, 1, 9752.514, -7336.514, 34.97601, 1.919862, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+4, 187567, 530, 1, 1, 9724.499, -7346.248, 34.95547, 1.919862, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+5, 187567, 530, 1, 1, 9743.402, -7339.749, 34.94567, 1.902409, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+6, 187567, 530, 1, 1, 9734.03, -7343.019, 35.02362, 1.902409, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+7, 187567, 530, 1, 1, 9767.382, -7480.58, 28.18164, 3.194002, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+8, 187567, 530, 1, 1, 9767.383, -7495.052, 28.28906, 3.054327, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+9, 187567, 530, 1, 1, 9694.368, -7495.957, 25.62033, 1.605702, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+10, 187567, 530, 1, 1, 9683.361, -7495.406, 26.99795, 1.53589, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+11, 187567, 530, 1, 1, 9638.369, -7397.279, 22.68563, 4.782203, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+12, 187567, 530, 1, 1, 9672.388, -7495.991, 25.67016, 1.53589, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+13, 187567, 530, 1, 1, 9648.386, -7152.304, 23.26344, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+14, 187567, 530, 1, 1, 9665.867, -7135.831, 23.16022, 3.106652, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+15, 187567, 530, 1, 1, 9631.138, -7135.575, 23.11801, 6.265733, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+16, 187567, 530, 1, 1, 9648.528, -7119.087, 23.2984, 4.729844, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+17, 187567, 530, 1, 1, 9485.029, -7132.405, 24.43083, 0, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+18, 187194, 530, 1, 1, 9954.997, -7098.571, 59.86189, 3.996807, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+19, 187194, 530, 1, 1, 10007.34, -7030.903, 57.97285, 4.06662, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+20, 187194, 530, 1, 1, 10002.23, -7202.467, 44.06782, 1.466076, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+21, 187194, 530, 1, 1, 10010.68, -7199.167, 44.22095, 2.478367, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+22, 187194, 530, 1, 1, 9992.33, -7205.063, 44.06255, 2.18166, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+23, 187194, 530, 1, 1, 9952.419, -7232.268, 43.9028, 2.234018, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+24, 187194, 530, 1, 1, 9945.498, -7242.049, 43.90578, 2.792518, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+25, 187235, 530, 1, 1, 9982.972, -7098.827, 47.70499, 6.056293, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3487) +(@OGUID+26, 187235, 530, 1, 1, 9987.122, -7093.597, 47.70498, 5.253442, 0, 0, 0, 1, 120, 255, 1); -- 187235 (Area: 3487) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+26 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+26; + +-- Add spawns Pat's Snowcloud Guy +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 530, 9346.396, -7265.283, 20.67977, 6.021386, 120, 0), -- 15730 (Area: 0) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 530, 9347.098, -7267.961, 20.6914, 3.263766, 120, 0); -- 15730 (Area: 0) (Auras: 26000 - 26000) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+1; diff --git a/sql/updates/world/2016_01_17_04_world.sql b/sql/updates/world/2016_01_17_04_world.sql new file mode 100644 index 00000000000..6d72807e0b1 --- /dev/null +++ b/sql/updates/world/2016_01_17_04_world.sql @@ -0,0 +1,81 @@ +SET @OGUID:=79522; +SET @CGUID:=52022; +SET @Event:=2; + +-- Add missing xmas ornaments in Azuremyst Isle (Exodar) +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+61; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0 , 178425, 530, 1, 1, -3949.436, -11658.67, -138.7108, 3.141593, 0, 0, 0, 1, 120, 255, 1), -- 178425 (Area: 0) +(@OGUID+1 , 178746, 530, 1, 1, -3954.361, -11657.59, -138.7044, 2.513274, 0, 0, 0, 1, 120, 255, 1), -- 178746 (Area: 0) +(@OGUID+2 , 178428, 530, 1, 1, -3951.378, -11661.31, -138.977, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+3 , 178428, 530, 1, 1, -3953.229, -11658.62, -138.7581, 2.426008, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+4 , 178428, 530, 1, 1, -3951.486, -11658.68, -138.7432, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+5 , 178429, 530, 1, 1, -3950.01, -11652.94, -138.6416, 5.358162, 0, 0, 0, 1, 120, 255, 1), -- 178429 (Area: 0) +(@OGUID+6 , 178429, 530, 1, 1, -3950.755, -11660.4, -138.7645, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 178429 (Area: 0) +(@OGUID+7 , 178430, 530, 1, 1, -3952.516, -11660.61, -138.7691, 3.38594, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+8 , 178430, 530, 1, 1, -3949.488, -11653.97, -138.6341, 1.954769, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+9 , 178430, 530, 1, 1, -3951.285, -11659.1, -138.3316, 1.047198, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+10, 178431, 530, 1, 1, -3952.399, -11660.72, -138.4649, 2.426008, 0, 0, 0, 1, 120, 255, 1), -- 178431 (Area: 0) +(@OGUID+11, 178431, 530, 1, 1, -3950.715, -11659.36, -138.9473, 1.134463, 0, 0, 0, 1, 120, 255, 1), -- 178431 (Area: 0) +(@OGUID+12, 178432, 530, 1, 1, -3950.486, -11661.66, -138.9796, 6.073746, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+13, 178432, 530, 1, 1, -3951.252, -11654.2, -138.6518, 4.468043, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+14, 178432, 530, 1, 1, -3952.455, -11658.96, -138.7532, 2.705255, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+15, 178433, 530, 1, 1, -3949.59, -11660.9, -138.9695, 4.921829, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+16, 178433, 530, 1, 1, -3953.01, -11659.64, -138.7615, 1.815142, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+17, 178433, 530, 1, 1, -3950.47, -11653.59, -138.645, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+18, 187567, 530, 1, 1, -4213.729, -11685.4, -130.8234, 0.9424766, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+19, 187567, 530, 1, 1, -4145.799, -11745.62, -124.1529, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+20, 187567, 530, 1, 1, -4205.994, -12527.13, 50.12775, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+21, 187567, 530, 1, 1, -4152.035, -12529.42, 49.52319, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3576) +(@OGUID+22, 187567, 530, 1, 1, -4171.053, -13734.39, 82.08741, 2.775069, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3526) +(@OGUID+23, 187567, 530, 1, 1, -4054.646, -13772.28, 84.39475, 5.881761, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3527) +(@OGUID+24, 187235, 530, 1, 1, -4214.633, -12476, 45.07409, 5.497789, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+25, 187235, 530, 1, 1, -4212.527, -12510.34, 45.44406, 0.2268925, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+26, 187235, 530, 1, 1, -4209.379, -12517.65, 45.81722, 0.3316107, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+27, 187235, 530, 1, 1, -4185.712, -12504.83, 44.36132, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+28, 187235, 530, 1, 1, -4158.139, -12463.08, 45.08138, 3.717554, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+29, 187235, 530, 1, 1, -4176.958, -12493.97, 44.361, 1.361356, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+30, 187235, 530, 1, 1, -4171.624, -12506.62, 44.36132, 5.550147, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+31, 187235, 530, 1, 1, -4153.742, -12484.6, 44.51342, 3.909541, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+32, 187235, 530, 1, 1, -4158.644, -12533.33, 45.45204, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+33, 187235, 530, 1, 1, -3928.31, -11712.54, -135.2059, 5.148723, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+34, 187235, 530, 1, 1, -3938.107, -11702.05, -135.2763, 1.500983, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+35, 187235, 530, 1, 1, -3891.189, -11640.65, -134.4907, 1.291542, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+36, 187235, 530, 1, 1, -3919.52, -11641.97, -134.8313, 0.2094394, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+37, 187235, 530, 1, 1, -3905.643, -11638.75, -134.6634, 5.864307, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+38, 187235, 530, 1, 1, -3943.941, -11674.08, -135.2386, 3.595379, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+39, 187235, 530, 1, 1, -3939.98, -11660.92, -135.1454, 3.874631, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+40, 187235, 530, 1, 1, -3943.487, -11689.1, -135.2892, 0.6108634, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+41, 187235, 530, 1, 1, -3931.237, -11649.39, -135.003, 1.710422, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+42, 187235, 530, 1, 1, -3877.953, -11647.35, -134.3679, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+43, 187235, 530, 1, 1, -4040.372, -11581.41, -138.4519, 0.6806767, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+44, 187235, 530, 1, 1, -4025.329, -11590.4, -138.3277, 1.762782, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+45, 187235, 530, 1, 1, -4006.567, -11572.73, -138.0419, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+46, 187235, 530, 1, 1, -4228.949, -11818.94, -115.9345, 0.802851, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+47, 187235, 530, 1, 1, -4048.503, -13778.93, 75.01585, 0.2967052, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3527) +(@OGUID+48, 187193, 530, 1, 1, -3929.128, -11744.82, -138.6122, 0.6283169, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+49, 187193, 530, 1, 1, -3970.78, -11722.88, -138.8356, 1.518436, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+50, 187193, 530, 1, 1, -3862.003, -11617.36, -136.8326, 4.939284, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+51, 187193, 530, 1, 1, -3935.253, -11599.68, -138.455, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+52, 187193, 530, 1, 1, -3903.503, -11599.64, -137.7858, 3.926996, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+53, 187193, 530, 1, 1, -3821.196, -11515.72, -138.6442, 1.518436, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+54, 187193, 530, 1, 1, -3843.451, -11503.5, -139.0975, 0.7853968, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+55, 187193, 530, 1, 1, -3753.633, -11517.73, -134.327, 2.094393, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+56, 187193, 530, 1, 1, -3898.609, -11445.35, -132.8523, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+57, 187193, 530, 1, 1, -3732.545, -11501.01, -134.0293, 2.373644, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+58, 187193, 530, 1, 1, -3657.605, -11491.42, -119.0973, 1.989672, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+59, 187193, 530, 1, 1, -3640.533, -11468.59, -118.8086, 3.019413, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+60, 187193, 530, 1, 1, -3903.453, -11420.75, -132.7737, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+61, 187193, 530, 1, 1, -3985.045, -11695.91, -139.3659, 5.742135, 0, 0, 0, 1, 120, 255, 1); -- 187193 (Area: 0) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+61 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+61; + +-- Add spawns Pat's Snowcloud Guy +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 530, -3997.986, -11908.32, -1.411356, 0.2617994, 120, 0), -- 15730 (Area: 0) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 530, -3997.807, -11908.79, 0.8329293, 4.782202, 120, 0); -- 15730 (Area: 0) (Auras: 26000 - 26000) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+1; diff --git a/sql/updates/world/2016_01_17_05_world.sql b/sql/updates/world/2016_01_17_05_world.sql new file mode 100644 index 00000000000..2d253bae713 --- /dev/null +++ b/sql/updates/world/2016_01_17_05_world.sql @@ -0,0 +1,16 @@ +UPDATE`spell_dbc` SET `Effect1`=28, `EffectMiscValueB1`=64 WHERE `Id`IN(14313,14307,14252); + +-- Spell 14313 Summon Enraged Gryphon +-- Spell 14307 Summon Enraged Wyvern +-- Spell 14252 Summon Enraged Felbat +-- Spell 14329 Summon Enraged Hippogryph + +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9297 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9526 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9521 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9527 AND `id`=1; + +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14307, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9297; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14313, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9526; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14252, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9521; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14329, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9527; diff --git a/sql/updates/world/2016_01_17_06_world.sql b/sql/updates/world/2016_01_17_06_world.sql new file mode 100644 index 00000000000..659f146845a --- /dev/null +++ b/sql/updates/world/2016_01_17_06_world.sql @@ -0,0 +1,5 @@ +UPDATE `smart_scripts` SET `id`=5 WHERE `source_type` = 9 AND `entryorguid` = 2229300 AND `id`=4 AND `action_type`=51; + +DELETE FROM `smart_scripts` WHERE `source_type` = 9 AND `entryorguid` = 2229300 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 +(2229300, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 85, 38758, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Inactive Fel Reaver - Action list - Invoker Cast [PH] Quest reward: Nether Gas In a Fel Fire Engine'); diff --git a/sql/updates/world/2016_01_17_07_world.sql b/sql/updates/world/2016_01_17_07_world.sql new file mode 100644 index 00000000000..df588168d38 --- /dev/null +++ b/sql/updates/world/2016_01_17_07_world.sql @@ -0,0 +1,22 @@ +DELETE FROM `creature_formations` WHERE `leaderGUID`=33658; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(33658, 33658, 0, 0, 1), +(33658, 33657, 10, 0, 2); + +-- Pathing for Hazzas Entry: 5722 'TDB FORMAT' +SET @NPC := 33658; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-649.7056,`position_y`=131.495,`position_z`=-90.5838 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-649.7056,131.495,-90.5838,0,0,1,0,100,0), -- 14:04:57 +(@PATH,2,-665.5804,131.4927,-90.58052,0,0,1,0,100,0), -- 14:05:00 +(@PATH,3,-673.0132,94.911,-90.58176,0,0,1,0,100,0), -- 14:05:02 +(@PATH,4,-673.0271,83.92074,-90.58344,0,0,1,0,100,0), -- 14:05:04 +(@PATH,5,-665.4554,60.56186,-90.5854,0,0,1,0,100,0), -- 14:05:07 +(@PATH,6,-649.9196,60.34818,-90.58607,0,0,1,0,100,0), -- 14:05:08 +(@PATH,7,-641.7787,99.33066,-90.58942,0,0,1,0,100,0), -- 14:05:10 +(@PATH,8,-644.1965,115.6559,-90.58284,0,0,1,0,100,0); -- 14:05:13 +-- 0x1C30A00DA00596800034A9000018FBD3 .go -649.7056 131.495 -90.5838 diff --git a/sql/updates/world/2016_01_17_08_world.sql b/sql/updates/world/2016_01_17_08_world.sql new file mode 100644 index 00000000000..48cd420a242 --- /dev/null +++ b/sql/updates/world/2016_01_17_08_world.sql @@ -0,0 +1,408 @@ +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57733; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4259.922,`position_y`=-11744.17,`position_z`=-132.7823 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4259.922,-11744.17,-132.7823,0,0,0,0,100,0), -- 10:11:34 +(@PATH,2,-4253.737,-11752.62,-132.103,0,0,0,0,100,0), -- 10:11:50 +(@PATH,3,-4251.487,-11755.87,-132.603,0,0,0,0,100,0), -- 10:11:50 +(@PATH,4,-4248.737,-11759.37,-132.603,0,0,0,0,100,0), -- 10:11:50 +(@PATH,5,-4242.487,-11767.87,-131.853,0,0,0,0,100,0), -- 10:11:50 +(@PATH,6,-4234.163,-11770.65,-131.4757,0,0,0,0,100,0), -- 10:12:04 +(@PATH,7,-4205.663,-11771.65,-131.9757,0,0,0,0,100,0), -- 10:12:04 +(@PATH,8,-4199.815,-11770.93,-132.2653,0,0,0,0,100,0), -- 10:12:20 +(@PATH,9,-4176.882,-11762.18,-132.0013,0,0,0,0,100,0), -- 10:12:29 +(@PATH,10,-4166.132,-11757.68,-136.7513,0,0,0,0,100,0), -- 10:12:29 +(@PATH,11,-4166.266,-11739.91,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,12,-4166.516,-11733.41,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,13,-4166.766,-11730.66,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,14,-4179.53,-11763.62,-132.2955,0,0,0,0,100,0), -- 10:13:15 +(@PATH,15,-4180.446,-11764.02,-132.2955,0,0,0,0,100,0), -- 10:13:15 +(@PATH,16,-4200.114,-11771.23,-132.5309,0,0,0,0,100,0), -- 10:13:15 +(@PATH,17,-4202.051,-11771.94,-132.4386,0,0,0,0,100,0), -- 10:13:15 +(@PATH,18,-4202.051,-11771.94,-132.4386,0,0,0,0,100,0), -- 10:13:15 +(@PATH,19,-4205.86,-11771.68,-132.0416,0,0,0,0,100,0), -- 10:13:17 +(@PATH,20,-4234.11,-11770.68,-131.5416,0,0,0,0,100,0), -- 10:13:17 +(@PATH,21,-4248.942,-11759.42,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,22,-4251.192,-11755.92,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,23,-4253.692,-11752.67,-132.0334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,24,-4258.692,-11745.92,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,25,-4259.942,-11744.17,-132.7834,0,0,0,0,100,0); -- 10:13:33 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57732; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4216.665,`position_y`=-11647.06,`position_z`=-143.7448 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4216.665,-11647.06,-143.7448,4.590216,5000,0,0,100,0), -- 10:39:00 +(@PATH,2,-4216.917,-11623.43,-132.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,3,-4216.917,-11613.93,-128.6019,0,0,0,0,100,0), -- 10:39:16 +(@PATH,4,-4216.917,-11607.68,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,5,-4216.917,-11604.68,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,6,-4216.917,-11602.93,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,7,-4217.17,-11602.3,-125.959,4.817109,5000,0,0,100,0), -- 10:39:36 +(@PATH,8,-4197.176,-11597.41,-124.0743,0,0,0,0,100,0), -- 10:39:56 +(@PATH,9,-4195.676,-11597.16,-125.3243,0,0,0,0,100,0), -- 10:39:56 +(@PATH,10,-4187.176,-11595.16,-124.8243,0,0,0,0,100,0), -- 10:39:56 +(@PATH,11,-4183.45,-11596.95,-124.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,12,-4179.45,-11604.45,-121.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,13,-4175.45,-11610.7,-119.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,14,-4164.444,-11628.77,-104.9988,0,0,0,0,100,0), -- 10:40:21 +(@PATH,15,-4160.194,-11635.52,-97.99881,0,0,0,0,100,0), -- 10:40:21 +(@PATH,16,-4162.848,-11643.82,-98.11985,0,0,0,0,100,0), -- 10:40:31 +(@PATH,17,-4165.893,-11649.45,-98.40599,3.246312,5000,0,0,100,0), -- 10:40:39 +(@PATH,18,-4166.085,-11630.18,-104.5746,0,0,0,0,100,0), -- 10:40:53 +(@PATH,19,-4174.826,-11610.26,-119.0268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,20,-4178.826,-11602.76,-121.5268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,21,-4182.576,-11596.51,-124.0268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,22,-4186.426,-11593.54,-124.7621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,23,-4193.426,-11591.54,-124.7621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,24,-4198.176,-11589.79,-125.2621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,25,-4209.176,-11586.04,-125.5121,0,0,0,0,100,0), -- 10:41:19 +(@PATH,26,-4211.554,-11587.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,27,-4212.304,-11589.44,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,28,-4213.554,-11592.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,29,-4215.804,-11597.44,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,30,-4217.054,-11600.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,31,-4217.554,-11601.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,32,-4218.49,-11603.42,-126.0363,4.834562,5000,0,0,100,0), -- 10:41:39 +(@PATH,33,-4217.827,-11613.99,-128.6406,0,0,0,0,100,0), -- 10:41:55 +(@PATH,34,-4217.577,-11622.99,-132.6406,0,0,0,0,100,0), -- 10:41:55 +(@PATH,35,-4217.077,-11638.74,-139.8906,0,0,0,0,100,0), -- 10:41:55 +(@PATH,36,-4216.827,-11644.74,-143.3906,0,0,0,0,100,0); -- 10:41:55 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57731; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4055.538,`position_y`=-11719.55,`position_z`=-138.8952 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4055.538,-11719.55,-138.8952,0,0,0,0,100,0), -- 10:45:16 +(@PATH,2,-4069.275,-11725.09,-138.3611,0,0,0,0,100,0), -- 10:45:34 +(@PATH,3,-4092.408,-11723.83,-139.1332,0,0,0,0,100,0), -- 10:45:49 +(@PATH,4,-4099.328,-11724.08,-139.0543,0,0,0,0,100,0), -- 10:45:56 +(@PATH,5,-4111.578,-11729.58,-139.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,6,-4117.578,-11732.08,-136.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,7,-4119.328,-11733.08,-136.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,8,-4139.16,-11723.72,-136.5828,0,0,0,0,100,0), -- 10:46:09 +(@PATH,9,-4143.91,-11720.22,-136.5828,0,0,0,0,100,0), -- 10:46:09 +(@PATH,10,-4125.933,-11733.08,-136.3418,0,0,0,0,100,0), -- 10:46:21 +(@PATH,11,-4117.555,-11732.18,-136.3103,0,0,0,0,100,0), -- 10:46:31 +(@PATH,12,-4111.555,-11729.43,-139.3103,0,0,0,0,100,0), -- 10:46:31 +(@PATH,13,-4099.305,-11723.93,-139.0603,0,0,0,0,100,0), -- 10:46:31 +(@PATH,14,-4080.146,-11728.12,-138.7241,0,0,0,0,100,0), -- 10:46:43 +(@PATH,15,-4069.389,-11725.02,-138.4003,0,0,0,0,100,0), -- 10:46:51 +(@PATH,16,-4067.389,-11724.27,-138.4003,0,0,0,0,100,0), -- 10:46:51 +(@PATH,17,-4055.639,-11719.52,-138.9003,0,0,0,0,100,0); -- 10:46:51 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=57722; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(57722, 57722, 0, 0, 1), +(57722, 57723, 2, 270, 2); + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57722; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4035.478,`position_y`=-11451.96,`position_z`=-55.53455 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4035.478,-11451.96,-55.53455,0,15000,0,0,100,0), -- 10:28:52 +(@PATH,2,-4038.098,-11441.65,-62.00945,0,0,0,0,100,0), -- 10:29:19 +(@PATH,3,-4048.067,-11425.79,-72.46973,0,0,0,0,100,0), -- 10:29:29 +(@PATH,4,-4072.011,-11409.6,-88.05364,0,0,0,0,100,0), -- 10:29:37 +(@PATH,5,-4090.952,-11407.41,-98.80654,0,0,0,0,100,0), -- 10:29:48 +(@PATH,6,-4100.202,-11406.66,-104.3065,0,0,0,0,100,0), -- 10:29:48 +(@PATH,7,-4118.357,-11413.92,-114.891,0,0,0,0,100,0), -- 10:30:01 +(@PATH,8,-4134.707,-11426.21,-125.61,0,0,0,0,100,0), -- 10:30:13 +(@PATH,9,-4137.963,-11431.42,-128.7505,0,0,0,0,100,0), -- 10:30:21 +(@PATH,10,-4144.455,-11462.52,-130.7656,0,0,0,0,100,0), -- 10:30:26 +(@PATH,11,-4143.278,-11481.03,-130.6259,0,0,0,0,100,0), -- 10:30:36 +(@PATH,12,-4141.778,-11489.78,-130.6259,0,0,0,0,100,0), -- 10:30:36 +(@PATH,13,-4133.984,-11497.89,-130.5813,0,0,0,0,100,0), -- 10:30:46 +(@PATH,14,-4123.734,-11506.64,-135.3313,0,0,0,0,100,0), -- 10:30:46 +(@PATH,15,-4118.456,-11529.87,-135.6161,0,0,0,0,100,0), -- 10:30:57 +(@PATH,16,-4118.632,-11541.07,-135.6777,0,15000,0,0,100,0), -- 10:31:08 +(@PATH,17,-4107.033,-11536.5,-135.5405,0,0,0,0,100,0), -- 10:31:33 +(@PATH,18,-4095.169,-11530.58,-135.5151,0,0,0,0,100,0), -- 10:31:43 +(@PATH,19,-4072.678,-11526.62,-135.1866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,20,-4068.678,-11527.37,-135.6866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,21,-4062.178,-11528.87,-138.1866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,22,-4044.695,-11532.02,-138.1443,0,0,0,0,100,0), -- 10:31:59 +(@PATH,23,-4042.251,-11532.67,-138.0262,0,0,0,0,100,0), -- 10:32:05 +(@PATH,24,-4035.501,-11537.42,-138.0262,0,0,0,0,100,0), -- 10:32:05 +(@PATH,25,-4028.77,-11550.78,-137.9687,0,0,0,0,100,0), -- 10:32:09 +(@PATH,26,-4026.27,-11555.78,-137.9687,0,0,0,0,100,0), -- 10:32:09 +(@PATH,27,-4020.903,-11567.01,-137.9309,0,0,0,0,100,0), -- 10:32:18 +(@PATH,28,-4006.608,-11590.79,-135.6749,0,0,0,0,100,0), -- 10:32:27 +(@PATH,29,-4001.739,-11597.25,-134.446,0,15000,0,0,100,0), -- 10:32:37 +(@PATH,30,-4003.607,-11589.51,-135.0951,0,0,0,0,100,0), -- 10:33:00 +(@PATH,31,-4008.607,-11582.01,-137.5951,0,0,0,0,100,0), -- 10:33:00 +(@PATH,32,-4020.018,-11566.11,-137.9106,0,0,0,0,100,0), -- 10:33:08 +(@PATH,33,-4028.915,-11551.29,-137.955,0,0,0,0,100,0), -- 10:33:18 +(@PATH,34,-4035.739,-11537.94,-137.9934,0,0,0,0,100,0), -- 10:33:27 +(@PATH,35,-4044.477,-11531.19,-138.0956,0,0,0,0,100,0), -- 10:33:30 +(@PATH,36,-4064.476,-11525.09,-135.8434,0,0,0,0,100,0), -- 10:33:36 +(@PATH,37,-4070.578,-11522.78,-135.0313,0,0,0,0,100,0), -- 10:33:44 +(@PATH,38,-4073.483,-11514.04,-135.0202,0,15000,0,0,100,0), -- 10:33:47 +(@PATH,39,-4112.552,-11504.43,-135.4866,0,0,0,0,100,0), -- 10:34:12 +(@PATH,40,-4118.729,-11500.47,-135.2996,0,0,0,0,100,0), -- 10:34:27 +(@PATH,41,-4131.229,-11491.97,-130.2996,0,0,0,0,100,0), -- 10:34:27 +(@PATH,42,-4134.815,-11481.72,-130.2471,0,0,0,0,100,0), -- 10:34:37 +(@PATH,43,-4135.565,-11478.97,-130.2471,0,0,0,0,100,0), -- 10:34:37 +(@PATH,44,-4136.778,-11458.39,-130.6105,0,0,0,0,100,0), -- 10:34:47 +(@PATH,45,-4136.778,-11457.14,-130.6105,0,0,0,0,100,0), -- 10:34:47 +(@PATH,46,-4133.271,-11441.38,-130.0716,0,0,0,0,100,0), -- 10:34:56 +(@PATH,47,-4122.668,-11422.46,-118.9364,0,0,0,0,100,0), -- 10:35:04 +(@PATH,48,-4108.187,-11412.36,-108.8878,0,0,0,0,100,0), -- 10:35:11 +(@PATH,49,-4089.786,-11408.53,-98.16229,0,0,0,0,100,0), -- 10:35:20 +(@PATH,50,-4071.33,-11410.57,-87.74048,0,0,0,0,100,0), -- 10:35:28 +(@PATH,51,-4054.675,-11419.34,-76.96556,0,0,0,0,100,0), -- 10:35:37 +(@PATH,52,-4047.425,-11424.59,-72.71556,0,0,0,0,100,0), -- 10:35:37 +(@PATH,53,-4042.097,-11435.35,-65.71899,0,0,0,0,100,0), -- 10:35:48 +(@PATH,54,-4039.347,-11441.85,-62.21899,0,0,0,0,100,0); -- 10:35:48 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=57721; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(57721, 57721, 0, 0, 1), +(57721, 57720, 2, 270, 2); + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57721; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-3967.541,`position_y`=-11439.45,`position_z`=-136.5146 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-3967.541,-11439.45,-136.5146,0,0,0,0,100,0), -- 10:19:30 +(@PATH,2,-3988.034,-11458.35,-136.91,0,0,0,0,100,0), -- 10:19:56 +(@PATH,3,-3995.157,-11467.58,-136.9,0,0,0,0,100,0), -- 10:20:09 +(@PATH,4,-3998.407,-11481.33,-137.15,0,0,0,0,100,0), -- 10:20:09 +(@PATH,5,-3998.143,-11483.91,-137.1721,0,0,0,0,100,0), -- 10:20:18 +(@PATH,6,-3993.893,-11490.66,-137.1721,0,0,0,0,100,0), -- 10:20:18 +(@PATH,7,-3991.643,-11494.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,8,-3990.893,-11495.41,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,9,-3985.393,-11504.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,10,-3982.393,-11509.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,11,-3978.886,-11514.21,-136.8319,0,0,0,0,100,0), -- 10:20:31 +(@PATH,12,-3965.32,-11535.52,-135.6286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,13,-3962.82,-11541.27,-134.3786,0,0,0,0,100,0), -- 10:20:39 +(@PATH,14,-3962.07,-11543.27,-134.1286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,15,-3960.32,-11547.27,-134.1286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,16,-3953.078,-11561.7,-133.8862,0,0,0,0,100,0), -- 10:20:49 +(@PATH,17,-3952.157,-11563.7,-133.8141,0,0,0,0,100,0), -- 10:20:55 +(@PATH,18,-3954.035,-11559.74,-134.0775,0,0,0,0,100,0), -- 10:21:18 +(@PATH,19,-3958.522,-11542.85,-134.0628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,20,-3958.772,-11541.35,-134.3128,0,0,0,0,100,0), -- 10:21:24 +(@PATH,21,-3959.772,-11534.6,-135.5628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,22,-3960.772,-11530.1,-136.5628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,23,-3976.953,-11511.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,24,-3980.453,-11507.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,25,-3984.203,-11503.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,26,-3991.703,-11495.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,27,-3992.703,-11494.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,28,-3995.201,-11491.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,29,-4000.951,-11484.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,30,-4001.701,-11483.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,31,-3997.792,-11464.48,-137.0493,0,0,0,0,100,0), -- 10:22:02 +(@PATH,32,-3990.042,-11456.23,-136.7993,0,0,0,0,100,0), -- 10:22:02 +(@PATH,33,-3987.292,-11453.23,-136.7993,0,0,0,0,100,0), -- 10:22:02 +(@PATH,34,-3986.042,-11451.73,-136.7993,0,0,0,0,100,0); -- 10:22:02 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57735; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4251.791,`position_y`=-11767.84,`position_z`=-93.89223 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4251.791,-11767.84,-93.89223,0,0,0,0,100,0), -- 10:07:56 +(@PATH,2,-4253.477,-11770.7,-93.53635,0,0,0,0,100,0), -- 10:08:00 +(@PATH,3,-4266.667,-11783.95,-93.56421,0,0,0,0,100,0), -- 10:08:04 +(@PATH,4,-4287.891,-11793.3,-94.06949,0,0,0,0,100,0), -- 10:08:13 +(@PATH,5,-4292.896,-11799.17,-94.09827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,6,-4291.396,-11801.67,-94.09827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,7,-4284.396,-11814.92,-99.59827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,8,-4283.396,-11816.67,-99.59827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,9,-4271.257,-11813.78,-99.64638,0,0,0,0,100,0), -- 10:08:33 +(@PATH,10,-4247.323,-11799.34,-95.82317,0,0,0,0,100,0), -- 10:08:40 +(@PATH,11,-4244.717,-11797.41,-95.79004,0,0,0,0,100,0), -- 10:08:50 +(@PATH,12,-4237.407,-11793.06,-95.55835,0,0,0,0,100,0), -- 10:08:53 +(@PATH,13,-4233.212,-11797.79,-95.51921,0,0,0,0,100,0), -- 10:08:57 +(@PATH,14,-4230.32,-11804.69,-95.54309,0,0,0,0,100,0), -- 10:08:59 +(@PATH,15,-4242.375,-11806.88,-95.75206,0,0,0,0,100,0), -- 10:09:02 +(@PATH,16,-4249.163,-11807,-98.797,0,0,0,0,100,0), -- 10:09:08 +(@PATH,17,-4271.709,-11816.08,-99.78216,0,0,0,0,100,0), -- 10:09:15 +(@PATH,18,-4278.459,-11818.83,-99.78216,0,0,0,0,100,0), -- 10:09:15 +(@PATH,19,-4278.884,-11823.21,-99.79669,0,0,0,0,100,0), -- 10:09:21 +(@PATH,20,-4277.884,-11824.96,-99.79669,0,0,0,0,100,0), -- 10:09:21 +(@PATH,21,-4267.689,-11842.01,-112.3755,0,0,0,0,100,0), -- 10:09:25 +(@PATH,22,-4266.437,-11843.94,-112.2757,0,0,0,0,100,0), -- 10:09:34 +(@PATH,23,-4257.481,-11844.73,-112.4191,0,0,0,0,100,0), -- 10:09:36 +(@PATH,24,-4256.231,-11843.73,-112.4191,0,0,0,0,100,0), -- 10:09:36 +(@PATH,25,-4255.231,-11843.23,-112.1691,0,0,0,0,100,0), -- 10:09:36 +(@PATH,26,-4249.231,-11839.98,-115.6691,0,0,0,0,100,0), -- 10:09:36 +(@PATH,27,-4239.349,-11833.89,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,28,-4231.849,-11829.14,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,29,-4226.349,-11825.89,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,30,-4221.665,-11822.42,-116.7485,0,0,0,0,100,0), -- 10:09:55 +(@PATH,31,-4219.165,-11820.92,-117.9985,0,0,0,0,100,0), -- 10:09:55 +(@PATH,32,-4216.665,-11819.17,-119.2485,0,0,0,0,100,0), -- 10:09:55 +(@PATH,33,-4207.821,-11811.86,-123.7914,0,0,0,0,100,0), -- 10:10:00 +(@PATH,34,-4204.571,-11808.86,-125.5414,0,0,0,0,100,0), -- 10:10:00 +(@PATH,35,-4202.321,-11806.86,-126.7914,0,0,0,0,100,0), -- 10:10:00 +(@PATH,36,-4199.845,-11803.17,-128.7961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,37,-4198.095,-11800.17,-130.2961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,38,-4194.845,-11794.67,-132.7961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,39,-4199.826,-11803.24,-128.946,0,0,0,0,100,0), -- 10:10:15 +(@PATH,40,-4207.697,-11811.62,-124.236,0,0,0,0,100,0), -- 10:10:20 +(@PATH,41,-4210.447,-11813.87,-122.736,0,0,0,0,100,0), -- 10:10:20 +(@PATH,42,-4216.582,-11818.92,-119.3844,0,0,0,0,100,0), -- 10:10:27 +(@PATH,43,-4218.832,-11820.67,-118.1344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,44,-4221.582,-11822.42,-116.6344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,45,-4222.832,-11823.42,-115.6344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,46,-4224.417,-11824.55,-115.6566,0,0,0,0,100,0), -- 10:10:32 +(@PATH,47,-4226.417,-11825.8,-115.6566,0,0,0,0,100,0), -- 10:10:32 +(@PATH,48,-4231.917,-11829.3,-115.9066,0,0,0,0,100,0), -- 10:10:32 +(@PATH,49,-4239.417,-11833.8,-115.9066,0,0,0,0,100,0), -- 10:10:32 +(@PATH,50,-4255.09,-11843.43,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,51,-4255.84,-11843.93,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,52,-4257.34,-11844.68,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,53,-4259.59,-11846.18,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,54,-4266.089,-11844.57,-112.6297,0,0,0,0,100,0), -- 10:10:51 +(@PATH,55,-4267.195,-11842.41,-112.1786,0,0,0,0,100,0), -- 10:10:54 +(@PATH,56,-4278.661,-11823.64,-99.84711,0,0,0,0,100,0), -- 10:11:03 +(@PATH,57,-4271.714,-11815.94,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,58,-4269.714,-11815.19,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,59,-4266.714,-11813.94,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,60,-4249.543,-11807.19,-99.2198,0,0,0,0,100,0), -- 10:11:13 +(@PATH,61,-4238.826,-11807.14,-95.64388,0,0,0,0,100,0), -- 10:11:21 +(@PATH,62,-4234.899,-11806.84,-95.56003,0,0,0,0,100,0), -- 10:11:25 +(@PATH,63,-4230.451,-11804.73,-95.52745,0,0,0,0,100,0), -- 10:11:28 +(@PATH,64,-4237.342,-11793.27,-95.53383,0,0,0,0,100,0), -- 10:11:30 +(@PATH,65,-4244.645,-11797.43,-95.85562,0,0,0,0,100,0), -- 10:11:34 +(@PATH,66,-4247.373,-11799.21,-95.78325,0,0,0,0,100,0), -- 10:11:38 +(@PATH,67,-4252.373,-11802.46,-99.03325,0,0,0,0,100,0), -- 10:11:38 +(@PATH,68,-4270.794,-11813.47,-99.60289,0,0,0,0,100,0), -- 10:11:48 +(@PATH,69,-4284.358,-11814.79,-99.57885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,70,-4291.358,-11801.79,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,71,-4292.858,-11799.29,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,72,-4294.358,-11796.54,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,73,-4282.959,-11793.07,-93.84309,0,0,0,0,100,0), -- 10:12:07 +(@PATH,74,-4266.636,-11784.24,-93.59824,0,0,0,0,100,0), -- 10:12:14 +(@PATH,75,-4252.229,-11768.59,-93.55703,0,0,0,0,100,0); -- 10:12:24 + +-- Pathing for Worker Entry: 18800 'TDB FORMAT' +SET @NPC := 67155; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4045.227,`position_y`=-11567.36,`position_z`=-138.4557 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4045.227,-11567.36,-138.4557,2.657736,60000,0,0,100,0), -- 10:20:52 +(@PATH,2,-4041.453,-11566.98,-138.16,0,0,0,0,100,0), -- 10:21:06 +(@PATH,3,-4037.367,-11566.4,-138.3107,0,0,0,0,100,0), -- 10:21:08 +(@PATH,4,-4031.307,-11552.28,-137.9972,0,0,0,0,100,0), -- 10:21:13 +(@PATH,5,-4042.002,-11530.51,-138.0085,0,0,0,0,100,0), -- 10:21:19 +(@PATH,6,-4041.574,-11527.51,-138.0677,0,0,0,0,100,0), -- 10:21:24 +(@PATH,7,-4038.824,-11520.26,-141.0677,0,0,0,0,100,0), -- 10:21:24 +(@PATH,8,-4026.281,-11500.64,-140.7895,0,0,0,0,100,0), -- 10:21:29 +(@PATH,9,-4015.825,-11486.67,-139.4373,0,0,0,0,100,0), -- 10:21:42 +(@PATH,10,-4014.075,-11484.67,-138.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,11,-4012.325,-11483.17,-137.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,12,-4009.575,-11480.42,-137.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,13,-3995.471,-11465.6,-136.9284,0,0,0,0,100,0), -- 10:21:51 +(@PATH,14,-3967.808,-11441.67,-136.644,0,0,0,0,100,0), -- 10:22:00 +(@PATH,15,-3952.092,-11437.37,-136.3886,0,0,0,0,100,0), -- 10:22:13 +(@PATH,16,-3933.094,-11436.87,-134.5441,0,0,0,0,100,0), -- 10:22:20 +(@PATH,17,-3913.105,-11438.32,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,18,-3905.355,-11438.57,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,19,-3898.855,-11439.07,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,20,-3894.605,-11439.32,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,21,-3878.679,-11443.58,-132.5145,0,0,0,0,100,0), -- 10:22:44 +(@PATH,22,-3872.179,-11446.33,-132.2645,0,0,0,0,100,0), -- 10:22:44 +(@PATH,23,-3840.745,-11457.86,-131.9258,0,0,0,0,100,0), -- 10:22:59 +(@PATH,24,-3839.995,-11457.86,-131.9258,0,0,0,0,100,0), -- 10:22:59 +(@PATH,25,-3834.995,-11459.36,-135.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,26,-3829.995,-11461.11,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,27,-3828.745,-11461.61,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,28,-3825.995,-11462.36,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,29,-3819.628,-11464.71,-138.4012,0,0,0,0,100,0), -- 10:23:11 +(@PATH,30,-3812.128,-11467.21,-138.1512,0,0,0,0,100,0), -- 10:23:11 +(@PATH,31,-3795.622,-11472.34,-137.6514,0,0,0,0,100,0), -- 10:23:21 +(@PATH,32,-3789.372,-11473.84,-134.6514,0,0,0,0,100,0), -- 10:23:21 +(@PATH,33,-3786.872,-11474.34,-134.4014,0,0,0,0,100,0), -- 10:23:21 +(@PATH,34,-3778.248,-11477.4,-134.2023,0,20000,0,0,100,0), -- 10:23:29 +(@PATH,35,-3779.69,-11479.03,-134.2154,0,0,0,0,100,0), -- 10:23:51 +(@PATH,36,-3790.385,-11476.55,-134.3773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,37,-3795.885,-11475.05,-137.3773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,38,-3796.885,-11474.8,-137.8773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,39,-3798.306,-11474.22,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,40,-3800.556,-11473.22,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,41,-3812.556,-11467.97,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,42,-3819.806,-11464.72,-138.103,0,0,0,0,100,0), -- 10:24:02 +(@PATH,43,-3825.306,-11462.22,-138.103,0,0,0,0,100,0), -- 10:24:02 +(@PATH,44,-3829.718,-11460.37,-138.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,45,-3834.718,-11458.62,-135.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,46,-3839.718,-11456.87,-132.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,47,-3840.718,-11456.62,-132.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,48,-3872.166,-11446.86,-132.4203,0,0,0,0,100,0), -- 10:24:22 +(@PATH,49,-3880.416,-11444.36,-132.4203,0,0,0,0,100,0), -- 10:24:22 +(@PATH,50,-3894.63,-11440.23,-132.5016,0,0,0,0,100,0), -- 10:24:39 +(@PATH,51,-3898.38,-11438.98,-132.7516,0,0,0,0,100,0), -- 10:24:39 +(@PATH,52,-3905.38,-11436.98,-132.7516,0,0,0,0,100,0), -- 10:24:39 +(@PATH,53,-3909.953,-11436.46,-132.7919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,54,-3919.703,-11436.96,-132.7919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,55,-3932.703,-11437.46,-134.2919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,56,-3955.675,-11438.13,-136.1737,0,0,0,0,100,0), -- 10:25:01 +(@PATH,57,-3967.982,-11443.01,-136.5633,0,0,0,0,100,0), -- 10:25:10 +(@PATH,58,-3987.157,-11453.09,-136.8458,0,0,0,0,100,0), -- 10:25:22 +(@PATH,59,-3990.157,-11456.09,-136.8458,0,0,0,0,100,0), -- 10:25:22 +(@PATH,60,-3998.407,-11464.34,-137.0958,0,0,0,0,100,0), -- 10:25:22 +(@PATH,61,-3999.407,-11465.34,-137.0958,0,0,0,0,100,0), -- 10:25:22 +(@PATH,62,-4014.187,-11479.69,-137.1316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,63,-4015.437,-11481.19,-138.1316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,64,-4017.937,-11483.44,-139.6316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,65,-4019.687,-11485.19,-140.6316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,66,-4020.62,-11486.18,-140.636,0,0,0,0,100,0), -- 10:25:41 +(@PATH,67,-4029.12,-11499.68,-140.886,0,0,0,0,100,0), -- 10:25:41 +(@PATH,68,-4042.905,-11526.72,-138.0882,0,0,0,0,100,0), -- 10:25:57 +(@PATH,69,-4041.908,-11531.32,-138.0012,0,0,0,0,100,0), -- 10:26:02 +(@PATH,70,-4035.658,-11537.57,-138.0012,0,0,0,0,100,0), -- 10:26:02 +(@PATH,71,-4033.483,-11539.54,-137.9768,0,0,0,0,100,0), -- 10:26:08 +(@PATH,72,-4033.447,-11555.33,-138.039,0,0,0,0,100,0), -- 10:26:12 +(@PATH,73,-4041.411,-11566.91,-138.1366,0,0,0,0,100,0), -- 10:26:19 +(@PATH,74,-4043.277,-11567.36,-138.179,0,0,0,0,100,0); -- 10:26:21 + +-- Add missing Exodar Peace Keepers +SET @CGUID:=87912; +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+15; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 16733, 530, -4014.95, -11691.79, -134.8826, 3.211406, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+1, 16733, 530, -3872.768, -11745.65, -107.2824, 1.937315, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+2, 16733, 530, -3858.128, -11736.21, -107.0747, 2.111848, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+3, 16733, 530, -3874.034, -11619.76, -137.4797, 4.118977, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+4, 16733, 530, -3896.759, -11608.23, -137.7288, 4.13643, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+5, 16733, 530, -3883.912, -11577.22, -132.7659, 1.169371, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+6, 16733, 530, -3857.081, -11591.1, -132.5431, 0.8901179, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+7, 16733, 530, -3928.165, -11568.19, -150.2529, 1.012291, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+8, 16733, 530, -3983.486, -11659.17, -139.0413, 6.126106, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+9, 16733, 530, -4128.439, -11441.22, -130.4346, 3.892084, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+10, 16733, 530, -4145.358, -11432.4, -130.6977, 4.13643, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+11, 16733, 530, -3958.252, -11432.68, -136.5482, 3.089233, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+12, 16733, 530, -3957.141, -11443.25, -136.5704, 2.984513, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+13, 16733, 530, -3914.363, -11441.08, -132.8212, 0.01745329, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+14, 16733, 530, -3915.224, -11430.32, -132.7888, 0, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+15, 16733, 530, -3735.099, -11505.95, -133.9994, 2.722714, 120, 0); -- 16733 (Area: -1) (Auras: ) diff --git a/sql/updates/world/2016_01_17_09_world.sql b/sql/updates/world/2016_01_17_09_world.sql new file mode 100644 index 00000000000..85e6f535866 --- /dev/null +++ b/sql/updates/world/2016_01_17_09_world.sql @@ -0,0 +1,31 @@ +SET @OGUID:=6362; +SET @CGUID:=78301; +SET @Event:=2; + +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+2; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 180796, 0, 1, 1, -3826.189, -771.3663, 8.083211, 2.146753, 0, 0, 0, 1, 120, 255, 1), -- 180796 (Area: 150) +(@OGUID+1, 180797, 0, 1, 1, -3825.66, -770.9445, 8.083211, 5.270896, 0, 0, 0, 1, 120, 255, 1), -- 180797 (Area: 150) +(@OGUID+2, 178746, 0, 1, 1, -3822.936, -769.4861, 8.083211, 1.518436, 0, 0, 0, 1, 120, 255, 1); -- 178746 (Area: 150) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+2 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+2; + +-- Add spawns Pat's Snowcloud Guy & Wonderform Operator <Smokywood Pastures> +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+10; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 0, 2051.343, 272.4555, 57.25123, 0, 120, 0), -- 15730 (Area: 159) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 0, 2051.359, 272.4567, 57.25214, 0, 120, 0), -- 15730 (Area: 159) (Auras: 26000 - 26000) +(@CGUID+2, 15730, 0, -5049.26, -818.5426, 495.3753, 0, 120, 0), -- 15730 (Area: 809) (Auras: 26000 - 26000) +(@CGUID+3, 15730, 0, -5049.293, -818.5344, 495.3785, 0, 120, 0), -- 15730 (Area: 809) (Auras: 26000 - 26000) +(@CGUID+4, 15730, 0, -8823.889, 540.5417, 96.89484, 5.951573, 120, 0), -- 15730 (Area: 5148) (Auras: 26000 - 26000) +(@CGUID+5, 15730, 0, -8823.89, 540.528, 96.89533, 2.443461, 120, 0), -- 15730 (Area: 5148) (Auras: 26000 - 26000) +(@CGUID+6, 15730, 0, -14294.22, 516.1476, 9.037167, 5.340707, 120, 0), -- 15730 (Area: 35) (Auras: 26000 - 26000) +(@CGUID+7, 15730, 0, -14294.3, 516.146, 9.037253, 1.815142, 120, 0), -- 15730 (Area: 35) (Auras: 26000 - 26000) +(@CGUID+8, 15730, 0, -3826.132, -771.75, 8.083211, 0.1396263, 120, 0), -- 15730 (Area: 150) (Auras: 26000 - 26000) +(@CGUID+9, 15730, 0, -3826.108, -771.7864, 8.083211, 3.665191, 120, 0), -- 15730 (Area: 150) (Auras: 26000 - 26000) +(@CGUID+10, 15732, 0, -3821.368, -768.9375, 8.083211, 1.745329, 120, 0); -- 15732 (Area: 150) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+10 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+10; + diff --git a/sql/updates/world/2016_01_17_10_world.sql b/sql/updates/world/2016_01_17_10_world.sql new file mode 100644 index 00000000000..0fdc04eb60f --- /dev/null +++ b/sql/updates/world/2016_01_17_10_world.sql @@ -0,0 +1 @@ +UPDATE `creature` SET `MovementType`=0 WHERE `guid`=131180; diff --git a/sql/updates/world/2016_01_17_11_world.sql b/sql/updates/world/2016_01_17_11_world.sql new file mode 100644 index 00000000000..9ab963a2ff2 --- /dev/null +++ b/sql/updates/world/2016_01_17_11_world.sql @@ -0,0 +1,10 @@ +UPDATE `smart_scripts` SET `event_type`=4 WHERE `entryorguid` in (18942,7823,18789,16587,17554,2859,2858,523,352,26876,3615,18937,24032,26852,16192,4312,27344,1571,12596,2409,931,6026,12577,16822,1572,8610,4407,1387,3310,19181,18808,1573,2995,2835,3838,2389,12740,2226,18939,3841,2299,26879,18931,2432,10897,6726,2851,2861,2941,12578,4321,3305,4314,11899,15178,31426,12636,4267,26881,4317,4319,4551,22935,6706,7824,8018,8019,8020,20762,18791,8609,12616,18807,19317,26878,10378,11138,11139,37915,26846,22485,11900,11901,12617,13177,18938,15177,16189,16227,17555,24366,18785,18788,18809,26602,18930,18953,19558,20234,21107,26844,22936,23736,24061,24155,26847,25288,26566,26845,26848,26850,26853,26877,26880,29762,30271) and id =2; +UPDATE `smart_scripts` SET `link`=3, `event_type`=4 WHERE `entryorguid`=18931 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26602 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26853 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26881 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=20234 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26876 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=3, `event_type`=4 WHERE `entryorguid`=18930 AND `source_type`=0 AND `id`=2 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=2385900 AND `source_type`=9 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14313, `action_param2`=2, `action_param3`=0, `target_type`=1 WHERE `entryorguid`=2385900 AND `source_type`=9 AND `id`=1 AND `link`=0; diff --git a/sql/updates/world/2016_01_17_12_world.sql b/sql/updates/world/2016_01_17_12_world.sql new file mode 100644 index 00000000000..e4e8ab5e9e2 --- /dev/null +++ b/sql/updates/world/2016_01_17_12_world.sql @@ -0,0 +1,30 @@ +-- +SET @pool_id=369; +SET @GUID=87572; +DELETE FROM `pool_template` WHERE `entry` = @pool_id; +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@pool_id, 5, 'Ethereum Jailor'); + +DELETE FROM `pool_creature` WHERE `guid` BETWEEN @GUID AND @GUID+20; +INSERT INTO `pool_creature` (`guid`, `pool_entry`, `chance`, `description`) VALUES +(@GUID+0, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+1, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+2, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+3, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+4, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+5, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+6, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+7, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+8, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+9, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+10, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+11, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+12, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+13, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+14, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+15, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+16, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+17, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+18, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+19, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+20, @pool_id, 0, 'Ethereum Jailor'); diff --git a/sql/updates/world/2016_01_17_13_world.sql b/sql/updates/world/2016_01_17_13_world.sql new file mode 100644 index 00000000000..163aa3fb659 --- /dev/null +++ b/sql/updates/world/2016_01_17_13_world.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `creature` WHERE `guid`=66270; +UPDATE `creature` SET `position_x`=-3047.323, `position_y`=4081.128, `position_z`=2.707369, `orientation`=5.484657, `spawndist`=10, `MovementType`=1 WHERE `guid`=66343; diff --git a/sql/updates/world/2016_01_17_14_world.sql b/sql/updates/world/2016_01_17_14_world.sql new file mode 100644 index 00000000000..c8b9405abff --- /dev/null +++ b/sql/updates/world/2016_01_17_14_world.sql @@ -0,0 +1,203 @@ +-- Delete all existing spawns +DELETE FROM `creature` WHERE `guid` IN (97259, 97261, 97258, 97257, 97256, 97255, 131106, 109804, 109803, 109802); + +-- Respawn all spawns +SET @CGUID:=134849; +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+31; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `curhealth`) VALUES +(@CGUID+0 , 27284, 571, 3970.129, -831.1373, 123.1972, 1.419617, 120, 10, 0), -- 27284 (Area: 4177) (possible waypoints or random movement) +(@CGUID+1 , 27284, 571, 3892.15, -898.545, 116.7031, 4.747295, 120, 0, 0), -- 27284 (Area: 0) (Auras: 51307 - 51307) +(@CGUID+2 , 27284, 571, 3877.338, -886.6799, 119.6563, 5.410521, 120, 0, 0), -- 27284 (Area: 0) (Auras: 51307 - 51307) +(@CGUID+3 , 27284, 571, 3981.821, -915.338, 103.8165, 0.4941546, 120, 10, 0), -- 27284 (Area: 4178) (possible waypoints or random movement) +(@CGUID+4 , 27284, 571, 4063.601, -863.5172, 112.0916, 3.294994, 120, 10, 0), -- 27284 (Area: 0) (possible waypoints or random movement) +(@CGUID+5 , 27284, 571, 4029.796, -817.8798, 122.6137, 5.148721, 120, 10, 0), -- 27284 (Area: 0) (possible waypoints or random movement) +(@CGUID+6 , 27284, 571, 4020.966, -913.8099, 107.1895, 1.902651, 120, 0, 0), -- 27284 (Area: 0) +(@CGUID+7 , 27401, 571, 4012.309, -778.3416, 119.4081, 5.117236, 120, 10, 0), -- 27401 (Area: 4177) (Auras: ) (possible waypoints or random movement) +(@CGUID+8 , 27401, 571, 3957.39, -879.4473, 120.6337, 1.665177, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+9 , 27401, 571, 3979.763, -878.6928, 118.7674, 2.167667, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+10, 27401, 571, 3891.449, -871.9622, 110.0855, 4.131083, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+11, 27401, 571, 3908.99, -867.735, 108.25, 0.07704493, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+12, 27401, 571, 4005.749, -911.3463, 107.528, 3.572126, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+13, 27401, 571, 4018.18, -838.5659, 120.1189, 3.396627, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+14, 27401, 571, 3997.235, -935.1, 104.7279, 0.895307, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+15, 27401, 571, 4046.337, -872.1385, 115.5023, 2.777797, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+16, 27401, 571, 4040.803, -824.1927, 119.995, 3.689994, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+17, 27401, 571, 4079.794, -860.7454, 111.5424, 3.844261, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+18, 27401, 571, 4112.891, -862.1273, 114.5041, 5.726786, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+19, 27401, 571, 3962.095, -841.9584, 121.1146, 1.314913, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+20, 27401, 571, 3972.828, -817.3924, 124.1117, 1.684451, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+21, 27401, 571, 3927.054, -862.1707, 121.9197, 5.969274, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+22, 27401, 571, 3983.165, -884.7412, 117.6653, 3.801475, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+23, 27401, 571, 4000.266, -806.4115, 124.4378, 2.8901, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+24, 27401, 571, 3996.695, -804.8523, 124.5836, 5.710121, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+25, 27401, 571, 4029.536, -842.3114, 117.1135, 5.811058, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+26, 27401, 571, 4063.478, -903.8126, 115.2312, 3.785855, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+27, 27401, 571, 3971.025, -913.7602, 104.5964, 1.58825, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+28, 27401, 571, 3992.506, -939.1702, 105.5502, 4.213991, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+29, 27401, 571, 3930.066, -870.2675, 104.4508, 0.4872836, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+30, 27401, 571, 3961.272, -872.5833, 104.2002, 2.95032, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+31, 27401, 571, 3912.686, -865.0364, 120.8479, 6.199958, 120, 0, 0); -- 27401 (Area: 0) (Auras: ) + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134849; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3962.255,`position_y`=-845.7626,`position_z`=120.7226 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3962.255,-845.7626,120.7226,0,0,0,0,100,0), -- 17:07:32 +(@PATH,2,3964.674,-842.7882,121.4607,0,0,0,0,100,0), -- 17:07:33 +(@PATH,3,3967.174,-837.5382,122.2107,0,0,0,0,100,0), -- 17:07:33 +(@PATH,4,3971.408,-823.0021,124.1822,0,0,0,0,100,0), -- 17:07:39 +(@PATH,5,3972.536,-818.4142,124.181,0,0,0,0,100,0), -- 17:07:44 +(@PATH,6,3974.286,-811.9142,124.181,0,0,0,0,100,0), -- 17:07:44 +(@PATH,7,3977.374,-807.4382,123.8934,0,0,0,0,100,0), -- 17:07:49 +(@PATH,8,3990.374,-797.4382,122.8934,0,0,0,0,100,0), -- 17:07:49 +(@PATH,9,3996.358,-796.3887,122.3552,0,0,0,0,100,0), -- 17:07:58 +(@PATH,10,4002.608,-795.8887,121.8552,0,0,0,0,100,0), -- 17:07:58 +(@PATH,11,4005.141,-794.809,121.2954,0,0,0,0,100,0), -- 17:08:19 +(@PATH,12,3991.292,-796.7651,122.3158,0,0,0,0,100,0), -- 17:08:19 +(@PATH,13,3989.065,-798.5057,122.8027,0,0,0,0,100,0), -- 17:08:23 +(@PATH,14,3977.315,-807.5057,123.8027,0,0,0,0,100,0), -- 17:08:23 +(@PATH,15,3973.799,-814.1797,124.0833,0,0,0,0,100,0), -- 17:08:32 +(@PATH,16,3972.049,-819.9297,124.0833,0,0,0,0,100,0), -- 17:08:32 +(@PATH,17,3971.736,-820.819,124.0339,0,0,0,0,100,0), -- 17:08:37 +(@PATH,18,3970.236,-831.069,123.5339,0,0,0,0,100,0), -- 17:08:37 +(@PATH,19,3967.212,-837.6317,122.1643,0,0,0,0,100,0), -- 17:08:41 +(@PATH,20,3964.712,-842.6317,121.4143,0,0,0,0,100,0), -- 17:08:41 +(@PATH,21,3955.197,-848.4968,121.6359,0,0,0,0,100,0), -- 17:08:48 +(@PATH,22,3950.197,-850.4968,122.3859,0,0,0,0,100,0), -- 17:08:48 +(@PATH,23,3946.476,-852.2645,122.539,0,0,0,0,100,0), -- 17:08:54 +(@PATH,24,3938.226,-855.0145,122.289,0,0,0,0,100,0), -- 17:08:54 +(@PATH,25,3935.217,-855.6635,122.2252,0,0,0,0,100,0), -- 17:08:59 +(@PATH,26,3928.967,-856.4135,121.7252,0,0,0,0,100,0), -- 17:08:59 +(@PATH,27,3935.146,-855.8206,122.0987,0,0,0,0,100,0), -- 17:09:05 +(@PATH,28,3938.241,-854.9574,122.219,0,0,0,0,100,0), -- 17:09:07 +(@PATH,29,3946.491,-852.2074,122.719,0,0,0,0,100,0), -- 17:09:07 +(@PATH,30,3954.914,-848.747,121.6653,0,0,0,0,100,0); -- 17:09:13 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134854; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=4008.271,`position_y`=-870.0803,`position_z`=117.5745 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,4008.271,-870.0803,117.5745,0,0,0,0,100,0), -- 16:58:23 +(@PATH,2,3996.876,-880.48,118.3026,0,0,0,0,100,0), -- 16:58:29 +(@PATH,3,3991.834,-882.1507,118.5546,0,0,0,0,100,0), -- 16:58:32 +(@PATH,4,3961.252,-886.0806,119.2003,0,0,0,0,100,0), -- 16:58:43 +(@PATH,5,3958.834,-887.8701,119.2766,0,0,0,0,100,0), -- 16:58:47 +(@PATH,6,3958.712,-888.809,119.2599,0,0,0,0,100,0), -- 16:58:48 +(@PATH,7,3983.712,-886.309,118.0099,0,0,0,0,100,0), -- 16:58:48 +(@PATH,8,3990.516,-884.9421,118.4627,0,0,0,0,100,0), -- 16:58:59 +(@PATH,9,4001.527,-882.609,118.6914,0,0,0,0,100,0), -- 16:59:05 +(@PATH,10,4009.196,-881.325,118.3849,0,0,0,0,100,0), -- 16:59:09 +(@PATH,11,4017.301,-863.9352,116.9195,0,0,0,0,100,0), -- 16:59:16 +(@PATH,12,4023.301,-849.1852,116.9195,0,0,0,0,100,0), -- 16:59:16 +(@PATH,13,4025.668,-847.6936,116.7459,0,0,0,0,100,0), -- 16:59:23 +(@PATH,14,4036.918,-842.1936,116.7459,0,0,0,0,100,0), -- 16:59:23 +(@PATH,15,4041.683,-837.2839,117.6779,0,0,0,0,100,0), -- 16:59:31 +(@PATH,16,4031.176,-820.0336,121.8801,0,0,0,0,100,0), -- 16:59:47 +(@PATH,17,4027.651,-834.1048,118.0815,0,0,0,0,100,0), -- 16:59:47 +(@PATH,18,4023.714,-843.688,117.5524,0,0,0,0,100,0), -- 16:59:50 +(@PATH,19,4020.757,-848.9363,117.5502,0,0,0,0,100,0), -- 16:59:55 +(@PATH,20,4010.505,-867.1548,117.3328,0,0,0,0,100,0); -- 17:00:03 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134855; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3998.09,`position_y`=-941.3831,`position_z`=105.5378 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3998.09,-941.3831,105.5378,0,0,0,0,100,0), -- 16:58:00 +(@PATH,2,3982.87,-921.863,104.2338,0,0,0,0,100,0), -- 16:58:00 +(@PATH,3,3980.532,-918.3081,104.4937,0,0,0,0,100,0), -- 16:58:01 +(@PATH,4,3980.812,-915.6993,104.2544,0,0,0,0,100,0), -- 16:58:03 +(@PATH,5,3993.312,-909.1993,106.0044,0,0,0,0,100,0), -- 16:58:03 +(@PATH,6,4001.392,-906.8644,107.0495,0,0,0,0,100,0), -- 16:58:10 +(@PATH,7,4005.606,-907.3997,107.3568,0,0,0,0,100,0), -- 16:58:13 +(@PATH,8,4018.356,-914.8997,106.8568,0,0,0,0,100,0), -- 16:58:13 +(@PATH,9,4019.2,-915.515,107.0822,0,0,0,0,100,0), -- 16:58:21 +(@PATH,10,4016.712,-901.4606,107.2446,0,0,0,0,100,0), -- 16:58:23 +(@PATH,11,4006.091,-900.8485,107.6517,0,0,0,0,100,0), -- 16:58:28 +(@PATH,12,3999.341,-903.3485,107.4017,0,0,0,0,100,0), -- 16:58:28 +(@PATH,13,3990.741,-907.1246,106.0392,0,0,0,0,100,0), -- 16:58:38 +(@PATH,14,3981.241,-911.3746,104.0392,0,0,0,0,100,0), -- 16:58:38 +(@PATH,15,3998.09,-941.3831,105.5378,0,0,0,0,100,0); -- 16:59:21 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134852; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3954.649,`position_y`=-896.4279,`position_z`=104.172 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3954.649,-896.4279,104.172,0,0,0,0,100,0), -- 16:57:59 +(@PATH,2,3956.389,-893.2208,104.3171,0,0,0,0,100,0), -- 16:58:01 +(@PATH,3,3950.639,-880.2208,104.8171,0,0,0,0,100,0), -- 16:58:01 +(@PATH,4,3948.071,-877.5638,104.6277,0,0,0,0,100,0), -- 16:58:09 +(@PATH,5,3934.321,-870.3138,103.8777,0,0,0,0,100,0), -- 16:58:09 +(@PATH,6,3933.527,-870.0614,103.9755,0,0,0,0,100,0), -- 16:58:16 +(@PATH,7,3922.027,-870.3114,105.9755,0,0,0,0,100,0), -- 16:58:16 +(@PATH,8,3917.903,-870.4968,106.363,0,0,0,0,100,0), -- 16:58:22 +(@PATH,9,3905.903,-870.4968,108.363,0,0,0,0,100,0), -- 16:58:22 +(@PATH,10,3897.389,-869.1989,109.0091,0,0,0,0,100,0), -- 16:58:28 +(@PATH,11,3895.139,-868.6989,109.0091,0,0,0,0,100,0), -- 16:58:28 +(@PATH,12,3893.163,-868.3932,109.3621,0,0,0,0,100,0), -- 16:58:33 +(@PATH,13,3903.502,-871.1569,108.7203,0,0,0,0,100,0), -- 16:58:34 +(@PATH,14,3918.319,-872.118,105.7782,0,0,0,0,100,0), -- 16:58:49 +(@PATH,15,3935.749,-871.7728,103.4062,0,0,0,0,100,0), -- 16:58:49 +(@PATH,16,3937.464,-872.5975,104.0017,0,0,0,0,100,0), -- 16:58:51 +(@PATH,17,3946.714,-877.3475,104.5017,0,0,0,0,100,0), -- 16:58:51 +(@PATH,18,3953.698,-875.124,104.5628,0,0,0,0,100,0), -- 16:58:57 +(@PATH,19,3959.198,-868.874,104.0628,0,0,0,0,100,0), -- 16:58:57 +(@PATH,20,3964.888,-870.4577,104.2536,0,0,0,0,100,0), -- 16:59:04 +(@PATH,21,3960.319,-875.5621,104.8488,0,0,0,0,100,0), -- 16:59:07 +(@PATH,22,3955.069,-879.8121,104.8488,0,0,0,0,100,0), -- 16:59:07 +(@PATH,23,3953.761,-883.5623,104.9101,0,0,0,0,100,0), -- 16:59:13 +(@PATH,24,3954.511,-894.0623,104.4101,0,0,0,0,100,0); -- 16:59:13 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134853; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=4070.011,`position_y`=-911.9304,`position_z`=115.397 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,4070.011,-911.9304,115.397,0,0,0,0,100,0), -- 17:00:27 +(@PATH,2,4063.844,-904.7043,115.3745,0,0,0,0,100,0), -- 17:00:29 +(@PATH,3,4058.64,-895.9709,115.1423,0,0,0,0,100,0), -- 17:00:34 +(@PATH,4,4057.89,-894.7209,115.1423,0,0,0,0,100,0), -- 17:00:34 +(@PATH,5,4055.97,-891.5008,115.2825,0,0,0,0,100,0), -- 17:00:38 +(@PATH,6,4052.97,-881.5008,114.5325,0,0,0,0,100,0), -- 17:00:38 +(@PATH,7,4052.165,-878.6388,114.2091,0,0,0,0,100,0), -- 17:00:44 +(@PATH,8,4051.415,-864.6388,113.4591,0,0,0,0,100,0), -- 17:00:44 +(@PATH,9,4054.136,-862.9764,112.8409,0,0,0,0,100,0), -- 17:00:50 +(@PATH,10,4066.636,-860.9764,112.3409,0,0,0,0,100,0), -- 17:00:50 +(@PATH,11,4072.034,-859.8044,112.1062,0,0,0,0,100,0), -- 17:00:57 +(@PATH,12,4086.284,-857.0544,112.1062,0,0,0,0,100,0), -- 17:00:57 +(@PATH,13,4091.908,-853.9102,112.7256,0,0,0,0,100,0), -- 17:01:05 +(@PATH,14,4101.408,-844.1602,113.7256,0,0,0,0,100,0), -- 17:01:05 +(@PATH,15,4105.021,-846.8843,114.2492,0,0,0,0,100,0), -- 17:01:14 +(@PATH,16,4106.521,-848.6343,114.2492,0,0,0,0,100,0), -- 17:01:14 +(@PATH,17,4109.933,-852.9023,114.737,0,0,0,0,100,0), -- 17:01:18 +(@PATH,18,4111.266,-854.6176,115.0273,0,0,0,0,100,0), -- 17:01:19 +(@PATH,19,4108.093,-862.4123,113.6716,0,0,0,0,100,0), -- 17:01:22 +(@PATH,20,4093.593,-861.4123,113.6716,0,0,0,0,100,0), -- 17:01:22 +(@PATH,21,4087.883,-860.7225,112.5768,0,0,0,0,100,0), -- 17:01:30 +(@PATH,22,4084.479,-860.3036,112.2872,0,0,0,0,100,0), -- 17:01:32 +(@PATH,23,4063.229,-863.3036,112.5372,0,0,0,0,100,0), -- 17:01:32 +(@PATH,24,4059.42,-867.1846,112.8684,0,0,0,0,100,0), -- 17:01:43 +(@PATH,25,4058.17,-873.9346,113.6184,0,0,0,0,100,0), -- 17:01:43 +(@PATH,26,4058.563,-877.7594,113.9066,0,0,0,0,100,0), -- 17:01:47 +(@PATH,27,4060.313,-890.0094,114.1566,0,0,0,0,100,0), -- 17:01:47 +(@PATH,28,4065.274,-896.5776,114.7585,0,0,0,0,100,0), -- 17:01:54 +(@PATH,29,4071.021,-903.6585,115.7979,0,0,0,0,100,0), -- 17:02:00 +(@PATH,30,4073.021,-911.4085,115.0479,0,0,0,0,100,0); -- 17:02:00 diff --git a/sql/updates/world/2016_01_17_15_world.sql b/sql/updates/world/2016_01_17_15_world.sql new file mode 100644 index 00000000000..da949d7100d --- /dev/null +++ b/sql/updates/world/2016_01_17_15_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_text` SET `TextRange`=3 WHERE `entry`=32871; diff --git a/sql/updates/world/2016_01_18_00_world.sql b/sql/updates/world/2016_01_18_00_world.sql new file mode 100644 index 00000000000..85f41cfc0c5 --- /dev/null +++ b/sql/updates/world/2016_01_18_00_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `action_param2`=0 WHERE `entryorguid`=21126 AND `source_type`=0 AND `id` IN (4,5); diff --git a/sql/updates/world/2016_01_18_01_world.sql b/sql/updates/world/2016_01_18_01_world.sql new file mode 100644 index 00000000000..9768ecda6c0 --- /dev/null +++ b/sql/updates/world/2016_01_18_01_world.sql @@ -0,0 +1,8 @@ +UPDATE `creature` SET `MovementType`=1 WHERE `guid` IN (134870, 134856, 134857, 134859, 134861, 134862, 134863, 134864, 134865, 134866, 134868, 134871, 134878, 134872, 134873, 134874, 134875); +UPDATE `creature` SET `spawndist`=0 WHERE `guid`=131180; + +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26853 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26881 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=20234 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26876 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26602 AND `source_type`=0 AND `id`=2 AND `link`=0; diff --git a/sql/updates/world/2016_01_18_02_world.sql b/sql/updates/world/2016_01_18_02_world.sql new file mode 100644 index 00000000000..ec9a8748cc8 --- /dev/null +++ b/sql/updates/world/2016_01_18_02_world.sql @@ -0,0 +1,39 @@ +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(27450,27355) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(2735500) 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 +(27450,0,0,1,8,0,100,0,48790,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0,'Neltharions Flame Control Bunny - On Spellhit (Neltharions Flame) - Store Targetlist'), +(27450,0,1,2,61,0,100,0,48790,0,0,0,33,27450,0,0,0,0,0,7,0,0,0,0,0,0,0,'Neltharions Flame Control Bunny - On Spellhit (Neltharions Flame) - Give Kill Credit'), +(27450,0,2,3,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,9,27449,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Set Data 1 1 on Neltharions Flame Fire Bunny'), +(27450,0,3,4,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,9,27355,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Set Data 1 1 on Rothin the Decaying'), +(27450,0,4,0,61,0,100,0,0,0,0,0,100,1,0,0,0,0,0,9,27355,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Send Targetlist to Rothin the Decaying'), +(27355,0,0,0,25,0,100,0,0,0,0,0,22,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Reset - Set Phase 0'), +(27355,0,1,2,4,0,100,0,0,0,0,0,11,9613,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Agro - Cast Shadowbolt'), +(27355,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,'Rothin the Decaying <Cult of the Damned> - Linked with Previous Event - Set Phase 1'), +(27355,0,3,0,9,1,100,0,0,40,3400,4800,11,9613,64,0,0,0,0,7,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Range (Phase 1) - Cast Shadow Bolt'), +(27355,0,4,0,0,0,100,0,12000,17000,15000,20000,11,51337,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - IC - On Range (Phase 1) - Cast Shadow Flame'), +(27355,0,5,0,2,0,100,1,0,30,9500,11000,11,51512,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Less than 30% HP - Cast Aegis of Neltharion'), +(27355,0,6,0,6,0,100,0,0,0,0,0,1,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Death - Say'), +(27355,0,7,0,1,0,100,0,10000,10000,10000,10000,11,48685,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - OOC - Cast Imbue Power'), +(27355,0,8,0,25,0,100,0,0,0,0,0,8,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - On Reset - Set Passive'), +(27355,0,9,0,38,0,100,0,1,1,30000,30000,80,2735500,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Rothin the Decaying - On Data Set 1 1 - Run Script'), +(2735500,9,0,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,12,1,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Face Target'), +(2735500,9,1,0,0,0,100,0,0,0,0,0,28,48685,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Remove Aura Imbue Power'), +(2735500,9,2,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Say'), +(2735500,9,3,0,0,0,100,0,7000,7000,0,0,28,48695,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - Script - Remove Aura Imbue Power Shield State'), +(2735500,9,4,0,0,0,100,0,0,0,0,0,8,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - Script - Set Aggresive'), +(2735500,9,5,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - script - Say'), +(2735500,9,6,0,0,0,100,0,0,0,0,0,49,0,0,0,0,0,0,12,1,0,0,0,0,0,0,'Rothin the Decaying - Script - Attack Target'); + +DELETE FROM `creature_template_addon` WHERE `entry`=27355; +INSERT INTO `creature_template_addon` (`entry`, `path_id`, `mount`, `bytes1`, `bytes2`, `emote`, `auras`) VALUES +(27355, 0, 0, 0x0, 0x1, 0, '48695'); -- -- 27355 - 48695 - 48695 + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=48685; +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry`=27355; + +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 48685, 0, 0, 31, 0, 3, 27418, 0, 0, 0, 0, '', 'Imbue Power targets Rothins Spell Bunny'), +(13, 1, 48685, 0, 1, 31, 0, 3, 26475, 0, 0, 0, 0, '', 'Imbue Power targets Magmawyrm'), +(22, 10, 27355, 0, 0, 36, 1, 0, 0, 0, 0, 0, 0, '', 'Only execute SAI if Rothin the Decaying alive'), +(22, 2, 27355, 0, 0, 1, 1, 48695, 0, 0, 1, 0, 0, '', 'Only execute SAI if Rothin the Decaying does not have aura Imbue Power Shield State'); diff --git a/sql/updates/world/2016_01_18_03_world.sql b/sql/updates/world/2016_01_18_03_world.sql new file mode 100644 index 00000000000..4b8eb4ae0c9 --- /dev/null +++ b/sql/updates/world/2016_01_18_03_world.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `creature_text` WHERE `entry` = 11856; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(11856, 0, 0, "Let's go before they find out I'm free!", 12, 0, 100, 1, 0, 0, 8327, 0, 'Kaya SAY_START'), +(11856, 1, 0, "Look out! We're under attack!", 12, 0, 100, 5, 0, 0, 8328, 0, 'Kaya SAY_AMBUSH'), +(11856, 2, 0, "Thank you for helping me. I know my way back from here.", 12, 0, 100, 3, 0, 0, 8329, 0, 'Kaya SAY_END'); diff --git a/sql/updates/world/2016_01_18_04_world.sql b/sql/updates/world/2016_01_18_04_world.sql new file mode 100644 index 00000000000..28ab2d96731 --- /dev/null +++ b/sql/updates/world/2016_01_18_04_world.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `creature` WHERE id=27535; +DELETE FROM `vehicle_template_accessory` WHERE `entry` IN (27761); +INSERT INTO `vehicle_template_accessory` (`entry`, `accessory_entry`, `minion`, `description`, `summontype`) VALUES (27761, 27535,1, "Fordragon Battle Steed", 7); +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=27761; diff --git a/sql/updates/world/2016_01_18_05_world.sql b/sql/updates/world/2016_01_18_05_world.sql new file mode 100644 index 00000000000..0d28cd17642 --- /dev/null +++ b/sql/updates/world/2016_01_18_05_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `creature` SET `MovementType`= 1 WHERE `guid`= 134869 AND `id`= 27401; +DELETE FROM `creature_addon` WHERE `guid` IN (97255,97256,97257,97258,97259,97261,131106); diff --git a/sql/updates/world/2016_01_18_06_world.sql b/sql/updates/world/2016_01_18_06_world.sql new file mode 100644 index 00000000000..f8b90c15f54 --- /dev/null +++ b/sql/updates/world/2016_01_18_06_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `disenchant_loot_template` SET `MinCount`=2,`MaxCount`=3 WHERE `Entry` IN (15,34) AND `Item`=34054; +UPDATE `disenchant_loot_template` SET `MinCount`=4,`MaxCount`=7 WHERE `Entry` IN (16,35) AND `Item`=34054; diff --git a/sql/updates/world/2016_01_19_00_world.sql b/sql/updates/world/2016_01_19_00_world.sql new file mode 100644 index 00000000000..f210b95c13a --- /dev/null +++ b/sql/updates/world/2016_01_19_00_world.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `achievement_criteria_data` WHERE `criteria_id`=11142; +INSERT INTO `achievement_criteria_data` (`criteria_id`, `type`, `value1`, `value2`) VALUES +(11142, 5, 66303, 0), +(11142, 16, 404, 0); diff --git a/sql/updates/world/2016_01_19_01_world.sql b/sql/updates/world/2016_01_19_01_world.sql new file mode 100644 index 00000000000..a10bc7e278f --- /dev/null +++ b/sql/updates/world/2016_01_19_01_world.sql @@ -0,0 +1,28 @@ +-- +DELETE FROM `gossip_menu` WHERE `entry` IN (7482, 7483); +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(7482, 9067), +(7483, 9068); + +DELETE FROM `npc_text` WHERE `ID` IN (9068); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `lang0`, `Probability0`, `em0_0`, `BroadcastTextID0`) VALUES +(9068, 'How did you learn about the ore? Not even the Baron knew...$B$BTake the cursed things. They''ve brought me nothing but misfortune anyway. I hid them IN the stables just off the courtyard.$B$B<A low growl begins TO emanate FROM the back of Landen''s throat.>', '', 0, 1, 20, 14393); + +DELETE FROM `gossip_menu_option` WHERE (`menu_id`=7482); +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(7482,0,0,'Listen to me, human. I care nothing for your plight, but you have something I require. Tell me where to find the bloodforged ingots.',14392,1,1,7483,0,0,0,'',0); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=7482; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,7482,0,0,9,9692,0,0,0,'', 'gossip option on Landen Stilwell requires The Path of the Adept taken'); + +UPDATE `creature_template` SET `npcflag`=1,`gossip_menu_id` =7482, `AIName`='SmartAI', `flags_extra`=0 WHERE `entry` =17822; + +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=17822; +DELETE FROM `smart_scripts` WHERE `source_type`=9 AND `entryorguid`=1782200; +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 +(17822,0,0,0,64,0,100,1,0,0,0,0,80,1782200,2,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - on gossip hello - Actionlist'), +(1782200,9,0,0,0,0,100,0,20000,20000,0,0,11,31310,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - Action list - cast Landen Stilwell Transform'), +(1782200,9,1,0,0,0,100,0,0,0,0,0,2,14,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - Action list - set faction'), +(1782200,9,2,0,0,0,100,0,0,0,0,0,49,0,0,0,0,0,0,21,50,0,0,0,0,0,0,'Landen Stilwell - Action list - start attack'), +(17822,0,1,0,0,0,100,1,0,0,0,0,11,31310,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - IC - cast Landen Stilwell Transform'); diff --git a/sql/updates/world/2016_01_19_02_world.sql b/sql/updates/world/2016_01_19_02_world.sql new file mode 100644 index 00000000000..7c71156b248 --- /dev/null +++ b/sql/updates/world/2016_01_19_02_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `BaseAttackTime` = 1200 WHERE `entry` = 15516; diff --git a/sql/updates/world/2016_01_19_03_world.sql b/sql/updates/world/2016_01_19_03_world.sql new file mode 100644 index 00000000000..0d559ace044 --- /dev/null +++ b/sql/updates/world/2016_01_19_03_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `InhabitType` = 5 WHERE `entry` = 14517; diff --git a/sql/updates/world/2016_01_19_04_world.sql b/sql/updates/world/2016_01_19_04_world.sql new file mode 100644 index 00000000000..f4fe95f5539 --- /dev/null +++ b/sql/updates/world/2016_01_19_04_world.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `gameobject` WHERE `guid`=7230 AND `id`=175946; +DELETE FROM `gameobject` WHERE `guid`=250 AND `id`=175946; +UPDATE `gameobject` SET `orientation`=5.323256 WHERE `guid`=67867; +UPDATE `gameobject_template` SET `faction`=114, `flags`=32 WHERE `entry`=176965; +UPDATE `gameobject_template` SET `faction`=14 WHERE `entry`=177807; diff --git a/sql/updates/world/2016_01_19_05_world.sql b/sql/updates/world/2016_01_19_05_world.sql new file mode 100644 index 00000000000..5afd9e2b8a5 --- /dev/null +++ b/sql/updates/world/2016_01_19_05_world.sql @@ -0,0 +1 @@ +DELETE FROM `creature_text` WHERE `entry` IN (17900,17901) AND `BroadcastTextId`=8329; diff --git a/sql/updates/world/2016_01_19_06_world.sql b/sql/updates/world/2016_01_19_06_world.sql new file mode 100644 index 00000000000..cece0c623bf --- /dev/null +++ b/sql/updates/world/2016_01_19_06_world.sql @@ -0,0 +1,97 @@ +-- gothik the harvester rework +-- creature (13 entries) +SET @CGUID = 127618; -- PR NOTE: This needs to match the value set in boss_gothik.cpp for the CGUID_TRIGGER const + +-- boss messages +DELETE FROM `creature_text` WHERE `entry`=16060; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`probability`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(16060,0,0,"Foolishly you have sought your own demise.",14,100,8807,13030,3,"Gothik SAY_INTRO_1"), +(16060,1,0,"Brazenly you have disregarded powers beyond your understanding.",14,100,0,13031,3,"Gothik SAY_INTRO_2"), +(16060,2,0,"You have fought hard to invade the realm of the harvester.",14,100,0,13032,3,"Gothik SAY_INTRO_3"), +(16060,3,0,"Now there is only one way out- to walk the lonely path of the damned.",14,100,0,13033,3,"Gothik SAY_INTRO_4"), +(16060,4,0,"I have waited long enough. Now you face the harvester of souls.",14,100,8808,13028,3,"Gothik SAY_PHASE_TWO"), +(16060,5,0,"I... am... undone.",14,100,8805,13026,3,"Gothik SAY_DEATH"), +(16060,6,0,"Death is the only escape!",14,20,8806,13027,3,"Gothik SAY_KILL"), +(16060,7,0,"%s teleports into the fray!",41,100,0,32306,3,"Gothik EMOTE_PHASE_TWO"), +(16060,8,0,"The central gate opens!",41,100,0,32307,3,"Gothik EMOTE_GATE_OPENED"); + +-- minion AI +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingtrainee" WHERE `entry`=16124; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingknight" WHERE `entry`=16125; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingrider" WHERE `entry`=16126; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectraltrainee" WHERE `entry`=16127; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralknight" WHERE `entry`=16148; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralrider" WHERE `entry`=16150; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralhorse" WHERE `entry`=16149; + +-- minion difficulty spell entries +DELETE FROM `spelldifficulty_dbc` WHERE `id` IN (55604,27825,27831,27989,56408,27993,55606,27994,55648); +INSERT INTO `spelldifficulty_dbc` (`id`,`spellid0`,`spellid1`) VALUES +(55604,55604,55645), -- death plague +(27831,27831,55638), -- shadow bolt volley +(27989,27989,56407), -- arcane explosion +(55606,55606,55608), -- unholy aura +(27994,27994,55646), -- drain life +(55648,55648,27995); -- unholy frenzy + +-- rider damage aura + visual aura +DELETE FROM `creature_template_addon` WHERE `entry` IN (16126,29986,16148,29990,16150,29988); +INSERT INTO `creature_template_addon` (`entry`,`mount`,`auras`) VALUES +(16126,25278,"55606"), +(29986,25278,"55608"), +(16148, 0,"10848"), +(29990, 0,"10848"), +(16150, 0,"55606 10848"), +(29988, 0,"55608 10848"); + +-- trigger AI +UPDATE `creature_template` SET `ScriptName`="npc_gothik_trigger",`InhabitType`=7 WHERE `entry`=16137; +-- re-do spawn locations for triggers +DELETE FROM `creature` WHERE `id`=16137; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`movementtype`) VALUES +(@CGUID+00,16137,533,3,1,2643.731,-3399.681,284.1829,0,0,0,0), -- living side soul trigger (south) +(@CGUID+01,16137,533,3,1,2739.995,-3399.779,284.2946,0,0,0,0), -- living side soul trigger (north) +(@CGUID+02,16137,533,3,1,2643.731,-3321.727,284.2327,0,0,0,0), -- spectral side soul trigger (south) +(@CGUID+03,16137,533,3,1,2739.995,-3321.727,284.2316,0,0,0,0), -- spectral side soul trigger (north) +(@CGUID+04,16137,533,3,1,2692.161,-3430.746,268.6462,0,0,0,0), -- living side spawn trigger (center back) +(@CGUID+05,16137,533,3,1,2714.562,-3430.61 ,268.6462,0,0,0,0), -- living side spawn trigger (north) +(@CGUID+06,16137,533,3,1,2692.213,-3428.783,268.6462,0,0,0,0), -- living side spawn trigger (center front) +(@CGUID+07,16137,533,3,1,2669.581,-3428.859,268.6462,0,0,0,0), -- living side spawn trigger (south) +(@CGUID+08,16137,533,3,1,2733.457,-3349.388,267.7677,0,0,0,0), -- spectral side spawn trigger (northeast) +(@CGUID+09,16137,533,3,1,2725.818,-3309.567,267.7686,0,0,0,0), -- spectral side spawn trigger (northwest) +(@CGUID+10,16137,533,3,1,2700.269,-3322.354,267.7678,0,0,0,0), -- spectral side spawn trigger (center) +(@CGUID+11,16137,533,3,1,2664.872,-3340.749,267.7674,0,0,0,0), -- spectral side spawn trigger (southeast) +(@CGUID+12,16137,533,3,1,2683.886,-3304.213,267.768 ,0,0,0,0); -- spectral side spawn trigger (southwest) + +-- make visuals target proper triggers +-- to anchor 1: 27892 (Trainee), 27928 (DK), 27935 (Rider) +-- to anchor 2: 27893 (Trainee), 27929 (DK), 27936 (Rider) +-- anchor -> skull: 27915 (Trainee), 27931 (DK), 27937 (Rider) +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN (27892,27928,27935,27893,27929,27936,27915,27931,27937); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ConditionTypeOrReference`,`ConditionTarget`,`ElseGroup`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`Comment`) VALUES +(13,1,27892,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27892,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), +(13,1,27928,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27928,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), +(13,1,27935,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27935,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), + +(13,1,27893,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27893,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"), +(13,1,27929,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27929,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"), +(13,1,27936,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27936,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"); + +-- disable LoS check for visuals to ensure they always work +DELETE FROM `disables` WHERE `sourceType`=0 AND `entry` IN (27892,27928,27935,27893,27929,27936,27915,27931,27937); +INSERT INTO `disables` (`sourceType`,`entry`,`flags`,`comment`) VALUES +(0,27892,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27928,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27935,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27893,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27929,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27936,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27915,64,"Gothik - Anchor To Skulls - Ignore LoS"), +(0,27931,64,"Gothik - Anchor To Skulls - Ignore LoS"), +(0,27937,64,"Gothik - Anchor To Skulls - Ignore LoS"); diff --git a/sql/updates/world/2016_01_04_horsemen.sql b/sql/updates/world/2016_01_19_07_world.sql index e1a72398a5f..e1a72398a5f 100644 --- a/sql/updates/world/2016_01_04_horsemen.sql +++ b/sql/updates/world/2016_01_19_07_world.sql diff --git a/src/server/game/AI/CreatureAI.h b/src/server/game/AI/CreatureAI.h index 3b7c489e018..f250a79ea25 100644 --- a/src/server/game/AI/CreatureAI.h +++ b/src/server/game/AI/CreatureAI.h @@ -80,7 +80,7 @@ class CreatureAI : public UnitAI Creature* DoSummonFlyer(uint32 entry, WorldObject* obj, float flightZ, float radius = 5.0f, uint32 despawnTime = 30000, TempSummonType summonType = TEMPSUMMON_CORPSE_TIMED_DESPAWN); bool CheckBoundary(Position* who = nullptr) const; - void SetBoundary(CreatureBoundary const* boundary) { _boundary = boundary; CheckInRoom(); } + void SetBoundary(CreatureBoundary const* boundary) { _boundary = boundary; me->DoImmediateBoundaryCheck(); } public: enum EvadeReason { diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp index cff02234ab6..52e0deaf86f 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp @@ -365,7 +365,7 @@ bool BattlegroundIC::SetupBattleground() // setting correct factions for Keep Cannons for (uint8 i = BG_IC_NPC_KEEP_CANNON_1; i <= BG_IC_NPC_KEEP_CANNON_12; ++i) GetBGCreature(i)->setFaction(BG_IC_Factions[0]); - for (uint8 i = BG_IC_NPC_KEEP_CANNON_13; i <= BG_IC_NPC_KEEP_CANNON_25; ++i) + for (uint8 i = BG_IC_NPC_KEEP_CANNON_13; i <= BG_IC_NPC_KEEP_CANNON_24; ++i) GetBGCreature(i)->setFaction(BG_IC_Factions[1]); // correcting spawn time for keeps bombs diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h index 72e9990b7c1..44666819feb 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h @@ -390,7 +390,6 @@ enum BG_IC_NPCs BG_IC_NPC_KEEP_CANNON_22, BG_IC_NPC_KEEP_CANNON_23, BG_IC_NPC_KEEP_CANNON_24, - BG_IC_NPC_KEEP_CANNON_25, BG_IC_NPC_SIEGE_ENGINE_A, BG_IC_NPC_SIEGE_ENGINE_H, @@ -444,7 +443,7 @@ enum BannersTypes enum BG_IC_MaxSpawns { MAX_NORMAL_GAMEOBJECTS_SPAWNS = BG_IC_GO_DOODAD_ND_WINTERORC_WALL_GATEFX_DOOR03+1, - MAX_NORMAL_NPCS_SPAWNS = BG_IC_NPC_KEEP_CANNON_25+1, + MAX_NORMAL_NPCS_SPAWNS = BG_IC_NPC_KEEP_CANNON_24+1, MAX_WORKSHOP_SPAWNS = 10, MAX_DOCKS_SPAWNS = 12, MAX_SPIRIT_GUIDES_SPAWNS = 7, @@ -506,9 +505,8 @@ const ICNpc BG_IC_NpcSpawnlocs[MAX_NORMAL_NPCS_SPAWNS] = {BG_IC_NPC_KEEP_CANNON_20, NPC_KEEP_CANNON, TEAM_HORDE, 1137.72f, -688.517f, 88.4023f, 3.9619f}, // 30 {BG_IC_NPC_KEEP_CANNON_21, NPC_KEEP_CANNON, TEAM_HORDE, 1135.29f, -840.878f, 88.0252f, 2.30383f}, // 31 {BG_IC_NPC_KEEP_CANNON_22, NPC_KEEP_CANNON, TEAM_HORDE, 1144.33f, -833.309f, 87.9268f, 2.14675f}, // 32 - {BG_IC_NPC_KEEP_CANNON_23, NPC_KEEP_CANNON, TEAM_HORDE, 1135.29f, -840.878f, 88.0252f, 2.30383f}, // 33 - {BG_IC_NPC_KEEP_CANNON_24, NPC_KEEP_CANNON, TEAM_HORDE, 1142.59f, -691.946f, 87.9756f, 3.9619f}, // 34 - {BG_IC_NPC_KEEP_CANNON_25, NPC_KEEP_CANNON, TEAM_HORDE, 1166.13f, -858.391f, 87.9653f, 5.63741f} // 35 + {BG_IC_NPC_KEEP_CANNON_23, NPC_KEEP_CANNON, TEAM_HORDE, 1142.59f, -691.946f, 87.9756f, 3.9619f}, // 33 + {BG_IC_NPC_KEEP_CANNON_24, NPC_KEEP_CANNON, TEAM_HORDE, 1166.13f, -858.391f, 87.9653f, 5.63741f} // 34 }; const Position BG_IC_WorkshopVehicles[5] = diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp index 3e67f709816..31320e4d65e 100644 --- a/src/server/game/Entities/Creature/Creature.cpp +++ b/src/server/game/Entities/Creature/Creature.cpp @@ -2739,7 +2739,7 @@ bool Creature::FocusTarget(Spell const* focusSpell, WorldObject const* target) } } if (shouldDelay) - shouldDelay = (!focusSpell->IsTriggered() && !focusSpell->GetCastTime()); + shouldDelay = !(focusSpell->IsTriggered() || focusSpell->GetCastTime() || focusSpell->GetSpellInfo()->IsChanneled()); } } diff --git a/src/server/game/Entities/Creature/Creature.h b/src/server/game/Entities/Creature/Creature.h index b0318ed33e2..3ee1ba7db7b 100644 --- a/src/server/game/Entities/Creature/Creature.h +++ b/src/server/game/Entities/Creature/Creature.h @@ -605,6 +605,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject float GetRespawnRadius() const { return m_respawnradius; } void SetRespawnRadius(float dist) { m_respawnradius = dist; } + void DoImmediateBoundaryCheck() { m_boundaryCheckTime = 0; } uint32 GetCombatPulseDelay() const { return m_combatPulseDelay; } void SetCombatPulseDelay(uint32 delay) // (secs) interval at which the creature pulses the entire zone into combat (only works in dungeons) { diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 24ddcd358ea..a826f841058 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -157,6 +157,28 @@ ProcEventInfo::ProcEventInfo(Unit* actor, Unit* actionTarget, Unit* procTarget, _damageInfo(damageInfo), _healInfo(healInfo) { } +SpellInfo const* ProcEventInfo::GetSpellInfo() const +{ + if (_spell) + return _spell->GetSpellInfo(); + if (_damageInfo) + return _damageInfo->GetSpellInfo(); + if (_healInfo) + return _healInfo->GetSpellInfo(); + return nullptr; +} + +SpellSchoolMask ProcEventInfo::GetSchoolMask() const +{ + if (_spell) + return _spell->GetSpellInfo()->GetSchoolMask(); + if (_damageInfo) + return _damageInfo->GetSchoolMask(); + if (_healInfo) + return _healInfo->GetSchoolMask(); + return SPELL_SCHOOL_MASK_NONE; +} + Unit::Unit(bool isWorldObject) : WorldObject(isWorldObject), m_movedPlayer(NULL), m_lastSanctuaryTime(0), IsAIEnabled(false), NeedChangeAI(false), LastCharmerGUID(), @@ -6365,54 +6387,6 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere } case SPELLFAMILY_PALADIN: { - // Light's Beacon - Beacon of Light - if (dummySpell->Id == 53651) - { - if (!victim || !procSpell) - return false; - triggered_spell_id = 0; - Unit* beaconTarget = NULL; - if (GetTypeId() != TYPEID_PLAYER) - { - beaconTarget = triggeredByAura->GetBase()->GetCaster(); - if (!beaconTarget || beaconTarget == this || !(beaconTarget->GetAura(53563, victim->GetGUID()))) - return false; - basepoints0 = int32(damage); - triggered_spell_id = procSpell->IsRankOf(sSpellMgr->GetSpellInfo(635)) ? 53652 : 53654; - } - else - { // Check Party/Raid Group - if (Group* group = ToPlayer()->GetGroup()) - { - for (GroupReference* itr = group->GetFirstMember(); itr != NULL; itr = itr->next()) - { - if (Player* member = itr->GetSource()) - { - // check if it was heal by paladin which cast this beacon of light - if (member->GetAura(53563, victim->GetGUID())) - { - // do not proc when target of beacon of light is healed - if (member == this) - return false; - - beaconTarget = member; - basepoints0 = int32(damage); - triggered_spell_id = procSpell->IsRankOf(sSpellMgr->GetSpellInfo(635)) ? 53652 : 53654; - break; - } - } - } - } - } - - if (triggered_spell_id && beaconTarget) - { - victim->CastCustomSpell(beaconTarget, triggered_spell_id, &basepoints0, NULL, NULL, true); - return true; - } - - return false; - } // Judgements of the Wise if (dummySpell->SpellIconID == 3017) { @@ -14187,8 +14161,8 @@ void Unit::ProcDamageAndSpellFor(bool isVictim, Unit* target, uint32 procFlag, u Unit* actionTarget = !isVictim ? target : this; DamageInfo damageInfo = DamageInfo(actor, actionTarget, damage, procSpell, procSpell ? SpellSchoolMask(procSpell->SchoolMask) : SPELL_SCHOOL_MASK_NORMAL, SPELL_DIRECT_DAMAGE); - HealInfo healInfo = HealInfo(damage); - ProcEventInfo eventInfo = ProcEventInfo(actor, actionTarget, target, procFlag, 0, 0, procExtra, NULL, &damageInfo, &healInfo); + HealInfo healInfo = HealInfo(actor, actionTarget, damage, procSpell, procSpell ? SpellSchoolMask(procSpell->SchoolMask) : SPELL_SCHOOL_MASK_NORMAL); + ProcEventInfo eventInfo = ProcEventInfo(actor, actionTarget, target, procFlag, 0, 0, procExtra, nullptr, &damageInfo, &healInfo); ProcTriggeredList procTriggered; // Fill procTriggered list diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index c64667feeca..8572c791d67 100644 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -863,22 +863,30 @@ public: class HealInfo { private: - uint32 m_heal; - uint32 m_absorb; + Unit* const _healer; + Unit* const _target; + uint32 _heal; + uint32 _absorb; + SpellInfo const* const _spellInfo; + SpellSchoolMask const _schoolMask; + public: - explicit HealInfo(uint32 heal) - : m_heal(heal) - { - m_absorb = 0; - } + explicit HealInfo(Unit* healer, Unit* target, uint32 heal, SpellInfo const* spellInfo, SpellSchoolMask schoolMask) + : _healer(healer), _target(target), _heal(heal), _absorb(0), _spellInfo(spellInfo), _schoolMask(schoolMask) { } + void AbsorbHeal(uint32 amount) { amount = std::min(amount, GetHeal()); - m_absorb += amount; - m_heal -= amount; + _absorb += amount; + _heal -= amount; } - uint32 GetHeal() const { return m_heal; } + Unit* GetHealer() const { return _healer; } + Unit* GetTarget() const { return _target; } + uint32 GetHeal() const { return _heal; } + uint32 GetAbsorb() const { return _absorb; } + SpellInfo const* GetSpellInfo() const { return _spellInfo; }; + SpellSchoolMask GetSchoolMask() const { return _schoolMask; }; }; class ProcEventInfo @@ -897,14 +905,8 @@ public: uint32 GetSpellPhaseMask() const { return _spellPhaseMask; } uint32 GetHitMask() const { return _hitMask; } - SpellInfo const* GetSpellInfo() const { return NULL; } - SpellInfo const* EnsureSpellInfo() const - { - SpellInfo const* spellInfo = GetSpellInfo(); - ASSERT(spellInfo); - return spellInfo; - } - SpellSchoolMask GetSchoolMask() const { return SPELL_SCHOOL_MASK_NONE; } + SpellInfo const* GetSpellInfo() const; + SpellSchoolMask GetSchoolMask() const; DamageInfo* GetDamageInfo() const { return _damageInfo; } HealInfo* GetHealInfo() const { return _healInfo; } diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index eb6d9a187d6..1575b50098f 100644 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -30,6 +30,12 @@ #include "WorldSession.h" #include "Opcodes.h" +BossBoundaryData::~BossBoundaryData() +{ + for (const_iterator it = begin(); it != end(); ++it) + delete it->Boundary; +} + void InstanceScript::SaveToDB() { std::string data = GetSaveData(); @@ -99,8 +105,8 @@ void InstanceScript::SetHeaders(std::string const& dataHeaders) void InstanceScript::LoadBossBoundaries(const BossBoundaryData& data) { for (BossBoundaryEntry const& entry : data) - if (entry.bossId < bosses.size()) - bosses[entry.bossId].boundary.insert(entry.boundary); + if (entry.BossId < bosses.size()) + bosses[entry.BossId].boundary.insert(entry.Boundary); } void InstanceScript::LoadMinionData(const MinionData* data) diff --git a/src/server/game/Instances/InstanceScript.h b/src/server/game/Instances/InstanceScript.h index 8285eaa7346..ce83061e162 100644 --- a/src/server/game/Instances/InstanceScript.h +++ b/src/server/game/Instances/InstanceScript.h @@ -75,10 +75,23 @@ struct DoorData struct BossBoundaryEntry { - uint32 const bossId; - AreaBoundary const* const boundary; + uint32 BossId; + AreaBoundary const* Boundary; +}; + +struct BossBoundaryData +{ + typedef std::vector<BossBoundaryEntry> StorageType; + typedef StorageType::const_iterator const_iterator; + + BossBoundaryData(std::initializer_list<BossBoundaryEntry> data) : _data(data) { } + ~BossBoundaryData(); + const_iterator begin() const { return _data.begin(); } + const_iterator end() const { return _data.end(); } + + private: + StorageType _data; }; -typedef std::list<BossBoundaryEntry> BossBoundaryData; struct MinionData { diff --git a/src/server/game/Maps/AreaBoundary.h b/src/server/game/Maps/AreaBoundary.h index 7df72c3dc12..a134b783ca6 100644 --- a/src/server/game/Maps/AreaBoundary.h +++ b/src/server/game/Maps/AreaBoundary.h @@ -32,15 +32,16 @@ class AreaBoundary BOUNDARY_PARALLELOGRAM, BOUNDARY_Z_RANGE, }; + virtual ~AreaBoundary() { } BoundaryType GetBoundaryType() const { return m_boundaryType; } bool IsWithinBoundary(const Position* pos) const { return (IsWithinBoundaryArea(pos) != m_isInvertedBoundary); } struct DoublePosition : Position { double d_positionX, d_positionY, d_positionZ; - DoublePosition(double x = 0, double y = 0, double z = 0, float o = 0) - : Position((float)x, (float)y, (float)z, o), d_positionX(x), d_positionY(y), d_positionZ(z) { } - DoublePosition(float x = 0, float y = 0, float z = 0, float o = 0) + DoublePosition(double x = 0.0, double y = 0.0, double z = 0.0, float o = 0.0f) + : Position(x, y, z, o), d_positionX(x), d_positionY(y), d_positionZ(z) { } + DoublePosition(float x, float y = 0.0f, float z = 0.0f, float o = 0.0f) : Position(x, y, z, o), d_positionX(x), d_positionY(y), d_positionZ(z) { } DoublePosition(const Position& pos) : DoublePosition(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), pos.GetOrientation()) { } diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index e96ed8c6799..e0b9bf53b63 100644 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -969,10 +969,12 @@ bool SpellMgr::CanSpellTriggerProcOnEvent(SpellProcEntry const& procEntry, ProcE // check spell family name/flags (if set) for spells if (eventInfo.GetTypeMask() & (PERIODIC_PROC_FLAG_MASK | SPELL_PROC_FLAG_MASK | PROC_FLAG_DONE_TRAP_ACTIVATION)) { - if (procEntry.spellFamilyName && eventInfo.GetSpellInfo() && (procEntry.spellFamilyName != eventInfo.EnsureSpellInfo()->SpellFamilyName)) + SpellInfo const* eventSpellInfo = eventInfo.GetSpellInfo(); + + if (procEntry.spellFamilyName && eventSpellInfo && (procEntry.spellFamilyName != eventSpellInfo->SpellFamilyName)) return false; - if (procEntry.spellFamilyMask && eventInfo.GetSpellInfo() && !(procEntry.spellFamilyMask & eventInfo.EnsureSpellInfo()->SpellFamilyFlags)) + if (procEntry.spellFamilyMask && eventSpellInfo && !(procEntry.spellFamilyMask & eventSpellInfo->SpellFamilyFlags)) return false; } @@ -3332,6 +3334,8 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->Attributes |= SPELL_ATTR0_PASSIVE; break; case 17364: // Stormstrike + case 48278: // Paralyze + case 53651: // Light's Beacon spellInfo->AttributesEx3 |= SPELL_ATTR3_STACK_FOR_DIFF_CASTERS; break; case 51798: // Brewfest - Relay Race - Intro - Quest Complete @@ -3565,7 +3569,6 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->AreaGroupId = 0; // originally, these require area 4522, which is... outside of Icecrown Citadel break; case 70602: // Corruption - case 48278: // Paralyze spellInfo->AttributesEx3 |= SPELL_ATTR3_STACK_FOR_DIFF_CASTERS; break; case 70715: // Column of Frost (visual marker) diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp index 269e115189a..d5ed2421efc 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp @@ -77,7 +77,7 @@ public: Talk(SAY_RESPAWN); } - bool CheckInRoom() + bool CheckInRoom() override { if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 50) { diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp index 93583364ef6..238942c15f6 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp @@ -78,7 +78,7 @@ public: Talk(SAY_BUFF); } - bool CheckInRoom() + bool CheckInRoom() override { if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 50) { diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp index e5ac2676ad0..b1a0f0217c4 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp @@ -22,12 +22,11 @@ #include "Player.h" #include "TemporarySummon.h" -AreaBoundary const* const mainBoundary = new CircleBoundary(Position(563.26f, 139.6f), 75.0); BossBoundaryData const boundaries = { - { BOSS_BEASTS, mainBoundary }, - { BOSS_JARAXXUS, mainBoundary }, - { BOSS_CRUSADERS, mainBoundary }, - { BOSS_VALKIRIES, mainBoundary }, + { BOSS_BEASTS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_JARAXXUS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_CRUSADERS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_VALKIRIES, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, { BOSS_ANUBARAK, new EllipseBoundary(Position(746.0f, 135.0f), 100.0, 75.0) } }; diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp index 9bdbce81dbf..ac094588d35 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp @@ -265,7 +265,7 @@ class boss_sindragosa : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_SINDRAGOSA, victim->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_SEQUENCE_BREAK); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -276,6 +276,13 @@ class boss_sindragosa : public CreatureScript Talk(SAY_AGGRO); } + void EnterEvadeMode(EvadeReason why) override + { + if (_isInAirPhase && why == EVADE_REASON_BOUNDARY) + return; + BossAI::EnterEvadeMode(why); + } + void JustReachedHome() override { BossAI::JustReachedHome(); diff --git a/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp b/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp index c9684cf10cf..c875a336aaf 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp @@ -20,30 +20,70 @@ #include "SpellScript.h" #include "GridNotifiers.h" #include "CombatAI.h" +#include "AreaBoundary.h" #include "naxxramas.h" +/* Constants */ enum Yells { - SAY_SPEECH = 0, - SAY_KILL = 1, - SAY_DEATH = 2, - SAY_TELEPORT = 3 + SAY_INTRO_1 = 0, + SAY_INTRO_2 = 1, + SAY_INTRO_3 = 2, + SAY_INTRO_4 = 3, + SAY_PHASE_TWO = 4, + SAY_DEATH = 5, + SAY_KILL = 6, + + EMOTE_PHASE_TWO = 7, + EMOTE_GATE_OPENED = 8 }; -//Gothik enum Spells { + /* living trainee spells */ + SPELL_DEATH_PLAGUE = 55604, + + /* living knight spells */ + SPELL_SHADOW_MARK = 27825, + + /* living rider spells */ + SPELL_SHADOW_BOLT_VOLLEY = 27831, + + /* spectral trainee spells */ + SPELL_ARCANE_EXPLOSION = 27989, + + /* spectral knight spells */ + SPELL_WHIRLWIND = 56408, + + /* spectral rider spells */ + SPELL_DRAIN_LIFE = 27994, + SPELL_UNHOLY_FRENZY = 55648, + + /* spectral horse spells */ + SPELL_STOMP = 27993, + + /* gothik phase two spells */ SPELL_HARVEST_SOUL = 28679, SPELL_SHADOW_BOLT = 29317, - SPELL_INFORM_LIVE_TRAINEE = 27892, - SPELL_INFORM_LIVE_KNIGHT = 27928, - SPELL_INFORM_LIVE_RIDER = 27935, - SPELL_INFORM_DEAD_TRAINEE = 27915, - SPELL_INFORM_DEAD_KNIGHT = 27931, - SPELL_INFORM_DEAD_RIDER = 27937, - - SPELL_SHADOW_MARK = 27825 + + /* visual spells */ + SPELL_ANCHOR_1_TRAINEE = 27892, + SPELL_ANCHOR_1_DK = 27928, + SPELL_ANCHOR_1_RIDER = 27935, + + SPELL_ANCHOR_2_TRAINEE = 27893, + SPELL_ANCHOR_2_DK = 27929, + SPELL_ANCHOR_2_RIDER = 27936, + + SPELL_SKULLS_TRAINEE = 27915, + SPELL_SKULLS_DK = 27931, + SPELL_SKULLS_RIDER = 27937, + + /* teleport spells */ + SPELL_TELEPORT_DEAD = 28025, + SPELL_TELEPORT_LIVE = 28026 }; +#define SPELLHELPER_UNHOLY_FRENZY RAID_MODE<uint32>(SPELL_UNHOLY_FRENZY,27995) enum Creatures { @@ -53,108 +93,205 @@ enum Creatures NPC_DEAD_TRAINEE = 16127, NPC_DEAD_KNIGHT = 16148, NPC_DEAD_RIDER = 16150, - NPC_DEAD_HORSE = 16149 + NPC_DEAD_HORSE = 16149, + + NPC_TRIGGER = 16137 }; -struct Waves { uint32 entry, time, mode; }; -// wave setups are not the same in heroic and normal difficulty, -// mode is 0 only normal, 1 both and 2 only heroic -// but this is handled in DoGothikSummon function -const Waves waves[] = +enum Phases { - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 10000, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 15000, 1}, - {NPC_LIVE_KNIGHT, 5000, 1}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 0, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 10000, 2}, - {NPC_LIVE_RIDER, 10000, 0}, - {NPC_LIVE_RIDER, 5000, 2}, - {NPC_LIVE_TRAINEE, 5000, 0}, - {NPC_LIVE_TRAINEE, 15000, 2}, - {NPC_LIVE_KNIGHT, 15000, 0}, - {NPC_LIVE_TRAINEE, 0, 0}, - {NPC_LIVE_RIDER, 10000, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 10000, 0}, - {NPC_LIVE_RIDER, 10000, 2}, - {NPC_LIVE_TRAINEE, 0, 2}, - {NPC_LIVE_RIDER, 5000, 1}, - {NPC_LIVE_TRAINEE, 0, 2}, - {NPC_LIVE_KNIGHT, 5000, 1}, - {NPC_LIVE_RIDER, 0, 2}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_RIDER, 0, 1}, - {NPC_LIVE_KNIGHT, 0, 1}, - {NPC_LIVE_TRAINEE, 25000, 2}, - {NPC_LIVE_TRAINEE, 15000, 0}, - {NPC_LIVE_TRAINEE, 25000, 0}, - {0, 0, 1}, + PHASE_ONE = 1, + PHASE_TWO = 2 }; -#define POS_Y_GATE -3360.78f -#define POS_Y_WEST -3285.0f -#define POS_Y_EAST -3434.0f -#define POS_X_NORTH 2750.49f -#define POS_X_SOUTH 2633.84f - -#define IN_LIVE_SIDE(who) (who->GetPositionY() < POS_Y_GATE) - enum Events { - EVENT_NONE, + EVENT_INTRO_2 = 1, + EVENT_INTRO_3, + EVENT_INTRO_4, + EVENT_PHASE_TWO, EVENT_SUMMON, + EVENT_DOORS_UNLOCK, + EVENT_TELEPORT, EVENT_HARVEST, EVENT_BOLT, - EVENT_TELEPORT -}; -enum Pos -{ - POS_LIVE = 6, - POS_DEAD = 5 + EVENT_RESUME_ATTACK }; -const Position PosSummonLive[POS_LIVE] = +enum Actions { - {2669.7f, -3428.76f, 268.56f, 1.6f}, - {2692.1f, -3428.76f, 268.56f, 1.6f}, - {2714.4f, -3428.76f, 268.56f, 1.6f}, - {2669.7f, -3431.67f, 268.56f, 1.6f}, - {2692.1f, -3431.67f, 268.56f, 1.6f}, - {2714.4f, -3431.67f, 268.56f, 1.6f}, + ACTION_GATE_OPENED = 1, + ACTION_MINION_EVADE, + ACTION_ACQUIRE_TARGET }; -const Position PosSummonDead[POS_DEAD] = + +/* Room side checking logic */ +static AreaBoundary* const livingSide = new RectangleBoundary(2633.84f, 2750.49f, -3434.0f, -3360.78f); +static AreaBoundary* const deadSide = new RectangleBoundary(2633.84f, 2750.49f, -3360.78f, -3285.0f); +enum Side { - {2725.1f, -3310.0f, 268.85f, 3.4f}, - {2699.3f, -3322.8f, 268.60f, 3.3f}, - {2733.1f, -3348.5f, 268.84f, 3.1f}, - {2682.8f, -3304.2f, 268.85f, 3.9f}, - {2664.8f, -3340.7f, 268.23f, 3.7f}, + SIDE_NONE = 0, + SIDE_LIVING, + SIDE_DEAD }; +inline static Side GetSide(Position const* who) +{ + if (livingSide->IsWithinBoundary(who)) + return SIDE_LIVING; + if (deadSide->IsWithinBoundary(who)) + return SIDE_DEAD; + return SIDE_NONE; +} +inline static bool IsOnSameSide(Position const* who, Position const* other) +{ + return (GetSide(who) == GetSide(other)); +} +static Player* FindEligibleTarget(Creature const* me, bool isGateOpen) +{ + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + for (Map::PlayerList::const_iterator it = players.begin(); it != players.end(); ++it) + { + Player* player = it->GetSource(); + if (player && (isGateOpen || IsOnSameSide(me, player)) && me->CanSeeOrDetect(player) && me->IsValidAttackTarget(player) && player->isInAccessiblePlaceFor(me)) + { + return player; + } + } -float const PosGroundLiveSide[4] = {2691.2f, -3387.0f, 267.68f, 1.52f}; -float const PosGroundDeadSide[4] = {2693.5f, -3334.6f, 267.68f, 4.67f}; -float const PosPlatform[4] = {2640.5f, -3360.6f, 285.26f, 0.0f}; + return nullptr; +} -// Predicate function to check that the r efzr unit is NOT on the same side as the source. -struct NotOnSameSide : public std::unary_function<Unit*, bool> -{ - NotOnSameSide(Unit* source) : _onLiveSide(IN_LIVE_SIDE(source)) { } - bool operator() (Unit const* target) +/* Wave data */ +typedef std::pair<uint32, uint8> GothikWaveEntry; // (npcEntry, npcCount) +typedef std::set<GothikWaveEntry> GothikWave; +typedef std::pair<GothikWave, uint8> GothikWaveInfo; // (wave, secondsToNext) +typedef std::vector<GothikWaveInfo> GothikWaveData; +const GothikWaveData waves10 = +{ { - return (_onLiveSide != IN_LIVE_SIDE(target)); - } + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 15}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}, {NPC_LIVE_KNIGHT, 1}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 15}, + { + {{NPC_LIVE_TRAINEE, 2}, {NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_KNIGHT, 1}, {NPC_LIVE_TRAINEE, 2}}, + 15}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 0} +}; - private: - bool _onLiveSide; +const GothikWaveData waves25 = +{ + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 15}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}, {NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 15}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_TRAINEE, 3}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}, {NPC_LIVE_TRAINEE, 3}}, + 5}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_KNIGHT, 2}, {NPC_LIVE_TRAINEE, 3}}, + 0} }; + +// GUID of first trigger NPC (used as offset for guid checks) +// 0-1 are living side soul triggers, 2-3 are spectral side soul triggers, 4 is living rider spawn trigger, 5-7 are living other spawn trigger, 8-12 are skull pile triggers +const uint32 CGUID_TRIGGER = 127618; +/* Creature AI */ class boss_gothik : public CreatureScript { public: @@ -165,29 +302,18 @@ class boss_gothik : public CreatureScript boss_gothikAI(Creature* creature) : BossAI(creature, BOSS_GOTHIK) { Initialize(); - waveCount = 0; } void Initialize() { - mergedSides = false; - phaseTwo = false; - thirtyPercentReached = false; + _waveCount = 0; + _gateCanOpen = false; + _gateIsOpen = true; + _lastTeleportDead = false; } - uint32 waveCount; - bool mergedSides; - bool phaseTwo; - bool thirtyPercentReached; - - GuidVector LiveTriggerGUID; - GuidVector DeadTriggerGUID; - void Reset() override { - LiveTriggerGUID.clear(); - DeadTriggerGUID.clear(); - me->SetReactState(REACT_PASSIVE); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); _Reset(); @@ -196,43 +322,29 @@ class boss_gothik : public CreatureScript void EnterCombat(Unit* /*who*/) override { - for (uint32 i = 0; i < POS_LIVE; ++i) - if (Creature* trigger = DoSummon(WORLD_TRIGGER, PosSummonLive[i])) - LiveTriggerGUID.push_back(trigger->GetGUID()); - for (uint32 i = 0; i < POS_DEAD; ++i) - if (Creature* trigger = DoSummon(WORLD_TRIGGER, PosSummonDead[i])) - DeadTriggerGUID.push_back(trigger->GetGUID()); - - if (LiveTriggerGUID.size() < POS_LIVE || DeadTriggerGUID.size() < POS_DEAD) - { - TC_LOG_ERROR("scripts", "Script Gothik: cannot summon triggers!"); - EnterEvadeMode(); - return; - } - _EnterCombat(); - waveCount = 0; - events.ScheduleEvent(EVENT_SUMMON, 30000); - DoTeleportTo(PosPlatform); - Talk(SAY_SPEECH); + events.SetPhase(PHASE_ONE); + events.ScheduleEvent(EVENT_SUMMON, 25 * IN_MILLISECONDS, 0, PHASE_ONE); + events.ScheduleEvent(EVENT_DOORS_UNLOCK, 205 * IN_MILLISECONDS, 0, PHASE_ONE); + events.ScheduleEvent(EVENT_PHASE_TWO, 270 * IN_MILLISECONDS, 0, PHASE_ONE); + Talk(SAY_INTRO_1); + events.ScheduleEvent(EVENT_INTRO_2, 4 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_INTRO_3, 9 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_INTRO_4, 14 * IN_MILLISECONDS); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_READY); + _gateIsOpen = false; } void JustSummoned(Creature* summon) override { - if (summon->GetEntry() == WORLD_TRIGGER) - summon->setActive(true); - else if (!mergedSides) + summons.Summon(summon); + if (me->IsInCombat()) { - summon->AI()->DoAction(me->HasReactState(REACT_PASSIVE) ? 1 : 0); - summon->AI()->EnterEvadeMode(); + summon->AI()->DoAction(_gateIsOpen ? ACTION_GATE_OPENED : ACTION_ACQUIRE_TARGET); + summon->SetCombatPulseDelay(5); } else - { - summon->AI()->DoAction(0); - summon->AI()->DoZoneInCombat(); - } - summons.Summon(summon); + summon->DespawnOrUnsummon(); } void SummonedCreatureDespawn(Creature* summon) override @@ -240,256 +352,202 @@ class boss_gothik : public CreatureScript summons.Despawn(summon); } - void KilledUnit(Unit* /*victim*/) override + void KilledUnit(Unit* victim) override { - if (!(rand32() % 5)) + if (victim && victim->GetTypeId() == TYPEID_PLAYER) Talk(SAY_KILL); } void JustDied(Unit* /*killer*/) override { - LiveTriggerGUID.clear(); - DeadTriggerGUID.clear(); _JustDied(); Talk(SAY_DEATH); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); + _gateIsOpen = false; } - void DoGothikSummon(uint32 entry) + void OpenGate() { - if (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL) - { - switch (entry) - { - case NPC_LIVE_TRAINEE: - { - if (Creature* liveTrigger = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[0])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger, 1); - if (Creature* liveTrigger1 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[1])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger1, 1); - if (Creature* liveTrigger2 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[2])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger2, 1); - break; - } - case NPC_LIVE_KNIGHT: - { - if (Creature* liveTrigger3 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[3])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger3, 1); - if (Creature* liveTrigger5 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[5])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger5, 1); - break; - } - case NPC_LIVE_RIDER: - { - if (Creature* liveTrigger4 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_RIDER, liveTrigger4, 1); - break; - } - } - } - else - { - switch (entry) - { - case NPC_LIVE_TRAINEE: - { - if (Creature* liveTrigger = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger, 1); - if (Creature* liveTrigger2 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger2, 1); - break; - } - case NPC_LIVE_KNIGHT: - { - if (Creature* liveTrigger5 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger5, 1); - break; - } - case NPC_LIVE_RIDER: - { - if (Creature* liveTrigger4 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_RIDER, liveTrigger4, 1); - break; - } - } - } - } - - bool CheckGroupSplitted() - { - bool checklife = false; - bool checkdead = false; - Map::PlayerList const &PlayerList = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) - { - if (i->GetSource() && i->GetSource()->IsAlive() && - i->GetSource()->GetPositionX() <= POS_X_NORTH && - i->GetSource()->GetPositionX() >= POS_X_SOUTH && - i->GetSource()->GetPositionY() <= POS_Y_GATE && - i->GetSource()->GetPositionY() >= POS_Y_EAST) - { - checklife = true; - } - else if (i->GetSource() && i->GetSource()->IsAlive() && - i->GetSource()->GetPositionX() <= POS_X_NORTH && - i->GetSource()->GetPositionX() >= POS_X_SOUTH && - i->GetSource()->GetPositionY() >= POS_Y_GATE && - i->GetSource()->GetPositionY() <= POS_Y_WEST) - { - checkdead = true; - } - - if (checklife && checkdead) - return true; - } - - return false; - } - - void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override - { - uint32 spellId = 0; - switch (spell->Id) - { - case SPELL_INFORM_LIVE_TRAINEE: spellId = SPELL_INFORM_DEAD_TRAINEE; break; - case SPELL_INFORM_LIVE_KNIGHT: spellId = SPELL_INFORM_DEAD_KNIGHT; break; - case SPELL_INFORM_LIVE_RIDER: spellId = SPELL_INFORM_DEAD_RIDER; break; - } - if (spellId && me->IsInCombat()) - { - me->HandleEmoteCommand(EMOTE_ONESHOT_SPELL_CAST); - if (Creature* pRandomDeadTrigger = ObjectAccessor::GetCreature(*me, DeadTriggerGUID[rand32() % POS_DEAD])) - me->CastSpell(pRandomDeadTrigger, spellId, true); - } + if (_gateIsOpen) + return; + instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); + Talk(EMOTE_GATE_OPENED); + _gateIsOpen = true; + + for (ObjectGuid summonGuid : summons) + if (Creature* summon = ObjectAccessor::GetCreature(*me, summonGuid)) + summon->AI()->DoAction(ACTION_GATE_OPENED); } void DamageTaken(Unit* /*who*/, uint32& damage) override { - if (!phaseTwo) + if (!events.IsInPhase(PHASE_TWO)) damage = 0; } - void SpellHitTarget(Unit* target, SpellInfo const* spell) override + void DoAction(int32 action) override { - if (!me->IsInCombat()) - return; - - switch (spell->Id) + switch (action) { - case SPELL_INFORM_DEAD_TRAINEE: - DoSummon(NPC_DEAD_TRAINEE, target, 0); - break; - case SPELL_INFORM_DEAD_KNIGHT: - DoSummon(NPC_DEAD_KNIGHT, target, 0); - break; - case SPELL_INFORM_DEAD_RIDER: - DoSummon(NPC_DEAD_RIDER, target, 1.0f); - DoSummon(NPC_DEAD_HORSE, target, 1.0f); + case ACTION_MINION_EVADE: + if (_gateIsOpen || me->getThreatManager().isThreatListEmpty()) + return EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + if (_gateCanOpen) + OpenGate(); break; } } + void EnterEvadeMode(EvadeReason why) override + { + BossAI::EnterEvadeMode(why); + Position const& home = me->GetHomePosition(); + me->NearTeleportTo(home.GetPositionX(), home.GetPositionY(), home.GetPositionZ(), home.GetOrientation()); + } + void UpdateAI(uint32 diff) override { if (!UpdateVictim()) return; - events.Update(diff); - - if (!thirtyPercentReached && HealthBelowPct(30) && phaseTwo) + if (me->HasReactState(REACT_AGGRESSIVE) && !_gateIsOpen && !IsOnSameSide(me, me->GetVictim())) { - thirtyPercentReached = true; - instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); + // NBD: this should only happen in practice if there is nobody left alive on our side (we should open gate) + // thus we only do a cursory check to make sure (edge cases?) + if (Player* newTarget = FindEligibleTarget(me, _gateIsOpen)) + { + me->getThreatManager().resetAllAggro(); + me->AddThreat(newTarget, 1.0f); + AttackStart(newTarget); + } + else + OpenGate(); } - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + events.Update(diff); + + if (!_gateIsOpen && HealthBelowPct(30) && events.IsInPhase(PHASE_TWO)) + OpenGate(); while (uint32 eventId = events.ExecuteEvent()) { switch (eventId) { case EVENT_SUMMON: - if (waves[waveCount].entry) + { + if (RAID_MODE(waves10,waves25).size() <= _waveCount) // bounds check { - if ((waves[waveCount].mode == 2) && (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL)) - DoGothikSummon(waves[waveCount].entry); - else if ((waves[waveCount].mode == 0) && (GetDifficulty() == RAID_DIFFICULTY_10MAN_NORMAL)) - DoGothikSummon(waves[waveCount].entry); - else if (waves[waveCount].mode == 1) - DoGothikSummon(waves[waveCount].entry); - - // if group is not splitted, open gate and merge both sides at ~ 2 minutes (wave 11) - if (waveCount == 11) + TC_LOG_INFO("scripts", "GothikAI: Wave count %d is out of range for difficulty %d.", _waveCount, GetDifficulty()); + break; + } + + std::list<Creature*> triggers; + me->GetCreatureListWithEntryInGrid(triggers, NPC_TRIGGER, 150.0f); + for (GothikWaveEntry entry : RAID_MODE(waves10, waves25)[_waveCount].first) + for (uint8 i = 0; i < entry.second; ++i) { - if (!CheckGroupSplitted()) + // GUID layout is as follows: + // CGUID+4: center (back of platform) - primary rider spawn + // CGUID+5: north (back of platform) - primary knight spawn + // CGUID+6: center (front of platform) - second spawn + // CGUID+7: south (front of platform) - primary trainee spawn + uint32 targetDBGuid; + switch (entry.first) { - instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); - DummyEntryCheckPredicate pred; - summons.DoAction(0, pred); //! Magic numbers fail - summons.DoZoneInCombat(); - mergedSides = true; + case NPC_LIVE_RIDER: // only spawns from center (back) > north + targetDBGuid = (CGUID_TRIGGER + 4) + (i % 2); + break; + case NPC_LIVE_KNIGHT: // spawns north > center (front) > south + targetDBGuid = (CGUID_TRIGGER + 5) + (i % 3); + break; + case NPC_LIVE_TRAINEE: // spawns south > center (front) > north + targetDBGuid = (CGUID_TRIGGER + 7) - (i % 3); + break; } + + for (Creature* trigger : triggers) + if (trigger && trigger->GetSpawnId() == targetDBGuid) + { + DoSummon(entry.first, trigger, 1.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + } } - if (waves[waveCount].mode == 1) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else if ((waves[waveCount].mode == 2) && (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL)) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else if ((waves[waveCount].mode == 0) && (GetDifficulty() == RAID_DIFFICULTY_10MAN_NORMAL)) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else - events.ScheduleEvent(EVENT_SUMMON, 0); + if (uint8 timeToNext = RAID_MODE(waves10, waves25)[_waveCount].second) + events.ScheduleEvent(EVENT_SUMMON, timeToNext * IN_MILLISECONDS, 0, PHASE_ONE); - ++waveCount; - } - else - { - phaseTwo = true; - Talk(SAY_TELEPORT); - DoTeleportTo(PosGroundLiveSide); - me->SetReactState(REACT_AGGRESSIVE); - DummyEntryCheckPredicate pred; - summons.DoAction(0, pred); //! Magic numbers fail - summons.DoZoneInCombat(); - events.ScheduleEvent(EVENT_BOLT, 1000); - events.ScheduleEvent(EVENT_HARVEST, urand(3000, 15000)); - events.ScheduleEvent(EVENT_TELEPORT, 20000); - } + ++_waveCount; break; - case EVENT_BOLT: - DoCastVictim(SPELL_SHADOW_BOLT); - events.ScheduleEvent(EVENT_BOLT, 1000); + } + case EVENT_DOORS_UNLOCK: + _gateCanOpen = true; + for (ObjectGuid summonGuid : summons) + if (Creature* summon = ObjectAccessor::GetCreature(*me, summonGuid)) + if (summon->IsAlive() && (!summon->IsInCombat() || summon->IsInEvadeMode())) + { + OpenGate(); + break; + } break; - case EVENT_HARVEST: - DoCastVictim(SPELL_HARVEST_SOUL, true); - events.ScheduleEvent(EVENT_HARVEST, urand(20000, 25000)); + case EVENT_PHASE_TWO: + events.SetPhase(PHASE_TWO); + events.ScheduleEvent(EVENT_TELEPORT, 20 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_HARVEST, 15 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_RESUME_ATTACK, 2 * IN_MILLISECONDS, 0, PHASE_TWO); + Talk(SAY_PHASE_TWO); + Talk(EMOTE_PHASE_TWO); + me->SetReactState(REACT_PASSIVE); + me->getThreatManager().resetAllAggro(); + DoCastAOE(SPELL_TELEPORT_LIVE); break; case EVENT_TELEPORT: - if (!thirtyPercentReached) + if (!HealthBelowPct(30)) { + me->CastStop(); me->AttackStop(); - if (IN_LIVE_SIDE(me)) - DoTeleportTo(PosGroundDeadSide); - else - DoTeleportTo(PosGroundLiveSide); - - me->getThreatManager().resetAggro(NotOnSameSide(me)); - if (Unit* target = SelectTarget(SELECT_TARGET_NEAREST, 0)) - { - me->getThreatManager().addThreat(target, 100.0f); - AttackStart(target); - } - - events.ScheduleEvent(EVENT_TELEPORT, 20000); + me->StopMoving(); + me->SetReactState(REACT_PASSIVE); + me->getThreatManager().resetAllAggro(); + DoCastAOE(_lastTeleportDead ? SPELL_TELEPORT_LIVE : SPELL_TELEPORT_DEAD); + _lastTeleportDead = !_lastTeleportDead; + + events.CancelEvent(EVENT_BOLT); + events.ScheduleEvent(EVENT_TELEPORT, 20 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_RESUME_ATTACK, 2 * IN_MILLISECONDS, 0, PHASE_TWO); } break; + + case EVENT_HARVEST: + DoCastAOE(SPELL_HARVEST_SOUL, true); // triggered allows this to go "through" shadow bolt + events.ScheduleEvent(EVENT_HARVEST, 15 * IN_MILLISECONDS, 0, PHASE_TWO); + break; + case EVENT_RESUME_ATTACK: + me->SetReactState(REACT_AGGRESSIVE); + events.ScheduleEvent(EVENT_BOLT, 0, 0, PHASE_TWO); + // return to the start of this method so victim side etc is re-evaluated + return UpdateAI(0u); // tail recursion for efficiency + case EVENT_BOLT: + DoCastVictim(SPELL_SHADOW_BOLT); + events.ScheduleEvent(EVENT_BOLT, 1 * IN_MILLISECONDS, 0, PHASE_TWO); + break; + case EVENT_INTRO_2: + Talk(SAY_INTRO_2); + break; + case EVENT_INTRO_3: + Talk(SAY_INTRO_3); + break; + case EVENT_INTRO_4: + Talk(SAY_INTRO_4); + break; } } - - if (!phaseTwo) - DoMeleeAttackIfReady(); } + + private: + uint32 _waveCount; + bool _gateCanOpen; + bool _gateIsOpen; + bool _lastTeleportDead; }; CreatureAI* GetAI(Creature* creature) const override @@ -498,86 +556,407 @@ class boss_gothik : public CreatureScript } }; -class npc_gothik_minion : public CreatureScript +struct npc_gothik_minion_baseAI : public ScriptedAI { public: - npc_gothik_minion() : CreatureScript("npc_gothik_minion") { } + npc_gothik_minion_baseAI(Creature* creature, uint32 deathNotify=0) : ScriptedAI(creature), _deathNotify(deathNotify), _gateIsOpen(false) { } + + void JustDied(Unit* /*killer*/) override + { + if (_deathNotify) + DoCastAOE(_deathNotify, true); + } + + inline bool isOnSameSide(Unit const* who) const + { + return IsOnSameSide(me, who); + } - struct npc_gothik_minionAI : public CombatAI + void DamageTaken(Unit* attacker, uint32 &damage) override + { // do not allow minions to take damage before the gate is opened + if (!_gateIsOpen && !isOnSameSide(attacker)) + damage = 0; + } + + void DoAction(int32 action) override { - npc_gothik_minionAI(Creature* creature) : CombatAI(creature) + switch (action) { - liveSide = IN_LIVE_SIDE(me); - gateClose = false; + case ACTION_GATE_OPENED: + _gateIsOpen = true; + // intentional missing break + case ACTION_ACQUIRE_TARGET: + if (Player* target = FindEligibleTarget(me, _gateIsOpen)) + { + me->AddThreat(target, 1.0f); + AttackStart(target); + } + else + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + break; + } + } + + void EnterEvadeMode(EvadeReason why) override + { + ScriptedAI::EnterEvadeMode(why); + + if (InstanceScript* instance = me->GetInstanceScript()) + if (Creature* gothik = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_GOTHIK))) + gothik->AI()->DoAction(ACTION_MINION_EVADE); + } + + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; + + if (!_gateIsOpen && !isOnSameSide(me->GetVictim())) + { // reset threat, then try to find someone on same side as us to attack + if (Player* newTarget = FindEligibleTarget(me, _gateIsOpen)) + { + me->RemoveAurasByType(SPELL_AURA_MOD_TAUNT); + me->getThreatManager().resetAllAggro(); + me->AddThreat(newTarget, 1.0f); + AttackStart(newTarget); + } + else + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); } - bool liveSide; - bool gateClose; + _UpdateAI(diff); + } + + virtual void _UpdateAI(uint32 diff) { ScriptedAI::UpdateAI(diff); }; - bool isOnSameSide(Unit const* who) const + private: + uint32 _deathNotify; + bool _gateIsOpen; +}; + +class npc_gothik_minion_livingtrainee : public CreatureScript +{ + public: + npc_gothik_minion_livingtrainee() : CreatureScript("npc_gothik_minion_livingtrainee") { } + + struct npc_gothik_minion_livingtraineeAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingtraineeAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_TRAINEE), _deathPlagueTimer(urandms(5,20)) { } + + void _UpdateAI(uint32 diff) { - return (liveSide == IN_LIVE_SIDE(who)); + if (diff < _deathPlagueTimer) + _deathPlagueTimer -= diff; + else + { + DoCastAOE(SPELL_DEATH_PLAGUE); + _deathPlagueTimer = urandms(5, 20); + } + DoMeleeAttackIfReady(); } + uint32 _deathPlagueTimer; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingtraineeAI>(creature); + } +}; + +class npc_gothik_minion_livingknight : public CreatureScript +{ + public: + npc_gothik_minion_livingknight() : CreatureScript("npc_gothik_minion_livingknight") { } - void DoAction(int32 param) override + struct npc_gothik_minion_livingknightAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingknightAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_DK), _whirlwindTimer(urandms(5,10)) { } + + void _UpdateAI(uint32 diff) { - gateClose = param != 0; + if (diff < _whirlwindTimer) + _whirlwindTimer -= diff; + else + { + DoCastAOE(SPELL_SHADOW_MARK); + _whirlwindTimer = urandms(15, 20); + } + DoMeleeAttackIfReady(); } + uint32 _whirlwindTimer; + }; - void DamageTaken(Unit* attacker, uint32 &damage) override + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingknightAI>(creature); + } +}; + +class npc_gothik_minion_livingrider : public CreatureScript +{ + public: + npc_gothik_minion_livingrider() : CreatureScript("npc_gothik_minion_livingrider") { } + + struct npc_gothik_minion_livingriderAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingriderAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_RIDER), _boltVolleyTimer(urandms(5,10)) { } + + void _UpdateAI(uint32 diff) { - if (gateClose && !isOnSameSide(attacker)) - damage = 0; + if (diff < _boltVolleyTimer) + _boltVolleyTimer -= diff; + else + { + DoCastAOE(SPELL_SHADOW_BOLT_VOLLEY); + _boltVolleyTimer = urandms(10, 15); + } + if (!me->HasUnitState(UNIT_STATE_CASTING)) + DoMeleeAttackIfReady(); } + uint32 _boltVolleyTimer; + }; - void JustDied(Unit* /*killer*/) override + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingriderAI>(creature); + } +}; + +class npc_gothik_minion_spectraltrainee : public CreatureScript +{ + public: + npc_gothik_minion_spectraltrainee() : CreatureScript("npc_gothik_minion_spectraltrainee") { } + + struct npc_gothik_minion_spectraltraineeAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectraltraineeAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _explosionTimer(2 * IN_MILLISECONDS) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _explosionTimer) + _explosionTimer -= diff; + else { - if (me->IsSummon()) - if (Unit* owner = me->ToTempSummon()->GetSummoner()) - CombatAI::JustDied(owner); + DoCastAOE(SPELL_ARCANE_EXPLOSION); + _explosionTimer = 2 * IN_MILLISECONDS; } + DoMeleeAttackIfReady(); + } + uint32 _explosionTimer; + }; - void EnterEvadeMode(EvadeReason why) override + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectraltraineeAI>(creature); + } +}; + +class npc_gothik_minion_spectralknight : public CreatureScript +{ + public: + npc_gothik_minion_spectralknight() : CreatureScript("npc_gothik_minion_spectralknight") { } + + struct npc_gothik_minion_spectralknightAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralknightAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _whirlwindTimer(urandms(15,25)) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _whirlwindTimer) + _whirlwindTimer -= diff; + else { - if (!gateClose) - { - CombatAI::EnterEvadeMode(why); - return; - } + DoCastAOE(SPELL_WHIRLWIND); + _whirlwindTimer = urandms(20, 25); + } + DoMeleeAttackIfReady(); + } + uint32 _whirlwindTimer; + }; - if (!_EnterEvadeMode()) - return; + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralknightAI>(creature); + } +}; + +class npc_gothik_minion_spectralrider : public CreatureScript +{ + public: + npc_gothik_minion_spectralrider() : CreatureScript("npc_gothik_minion_spectralrider") { } + + struct npc_gothik_minion_spectralriderAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralriderAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _frenzyTimer(urandms(2,5)), _drainTimer(urandms(8,12)) { } - Map::PlayerList const &PlayerList = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) + void _UpdateAI(uint32 diff) + { + if (diff < _frenzyTimer) + _frenzyTimer -= diff; + else if (me->HasUnitState(UNIT_STATE_CASTING)) + _frenzyTimer = 0; + else + { // target priority: knight > other rider > horse > gothik + std::list<Creature*> potentialTargets = DoFindFriendlyMissingBuff(30.0, SPELLHELPER_UNHOLY_FRENZY); + Creature *knightTarget = nullptr, *riderTarget = nullptr, *horseTarget = nullptr, *gothikTarget = nullptr; + for (Creature* pTarget : potentialTargets) { - if (i->GetSource() && i->GetSource()->IsAlive() && isOnSameSide(i->GetSource())) + switch (pTarget->GetEntry()) { - AttackStart(i->GetSource()); - return; + case NPC_DEAD_KNIGHT: + knightTarget = pTarget; + break; + case NPC_DEAD_RIDER: + riderTarget = pTarget; + break; + case NPC_DEAD_HORSE: + horseTarget = pTarget; + break; + case NPC_GOTHIK: + gothikTarget = pTarget; + break; } + if (knightTarget) + break; } + Creature* target = knightTarget ? knightTarget : riderTarget ? riderTarget : horseTarget ? horseTarget : gothikTarget ? gothikTarget : nullptr; + if (target) + DoCast(target, SPELL_UNHOLY_FRENZY); + _frenzyTimer = 20 * IN_MILLISECONDS; + } - me->GetMotionMaster()->MoveIdle(); - Reset(); + if (diff < _drainTimer) + _drainTimer -= diff; + else + { + DoCastVictim(SPELL_DRAIN_LIFE); + _drainTimer = urandms(10,15); } - void UpdateAI(uint32 diff) override + if (!me->HasUnitState(UNIT_STATE_CASTING)) + DoMeleeAttackIfReady(); + } + uint32 _frenzyTimer, _drainTimer; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralriderAI>(creature); + } +}; + +class npc_gothik_minion_spectralhorse : public CreatureScript +{ + public: + npc_gothik_minion_spectralhorse() : CreatureScript("npc_gothik_minion_spectralhorse") { } + + struct npc_gothik_minion_spectralhorseAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralhorseAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _stompTimer(urandms(10,15)) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _stompTimer) + _stompTimer -= diff; + else { - if (gateClose && (!isOnSameSide(me) || (me->GetVictim() && !isOnSameSide(me->GetVictim())))) - { - EnterEvadeMode(EVADE_REASON_OTHER); - return; - } + DoCastAOE(SPELL_STOMP); + _stompTimer = urandms(14, 18); + } + DoMeleeAttackIfReady(); + } + uint32 _stompTimer; + }; - CombatAI::UpdateAI(diff); + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralhorseAI>(creature); + } +}; + +class npc_gothik_trigger : public CreatureScript +{ +public: + npc_gothik_trigger() : CreatureScript("npc_gothik_trigger") { } + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_triggerAI>(creature); + } + + struct npc_gothik_triggerAI : public ScriptedAI + { + npc_gothik_triggerAI(Creature* creature) : ScriptedAI(creature) { creature->SetDisableGravity(true); } + + void EnterEvadeMode(EvadeReason /*why*/) override { } + void UpdateAI(uint32 /*diff*/) override { } + void EnterCombat(Unit* /*who*/) override { } + void DamageTaken(Unit* /*who*/, uint32& damage) override { damage = 0; } + + Creature* SelectRandomSkullPile() + { + std::list<Creature*> triggers; + me->GetCreatureListWithEntryInGrid(triggers, NPC_TRIGGER, 150.0f); + uint32 targetDBGuid = CGUID_TRIGGER + urand(8, 12); // CGUID+8 to CGUID+12 are the triggers for the skull piles on dead side + for (Creature* trigger : triggers) + if (trigger && trigger->GetSpawnId() == targetDBGuid) + return trigger; + + return nullptr; + } + void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override + { + if (!spell) + return; + + switch (spell->Id) + { + case SPELL_ANCHOR_1_TRAINEE: + DoCastAOE(SPELL_ANCHOR_2_TRAINEE, true); + break; + case SPELL_ANCHOR_1_DK: + DoCastAOE(SPELL_ANCHOR_2_DK, true); + break; + case SPELL_ANCHOR_1_RIDER: + DoCastAOE(SPELL_ANCHOR_2_RIDER, true); + break; + case SPELL_ANCHOR_2_TRAINEE: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_TRAINEE, true); + break; + case SPELL_ANCHOR_2_DK: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_DK, true); + break; + case SPELL_ANCHOR_2_RIDER: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_RIDER, true); + break; + case SPELL_SKULLS_TRAINEE: + DoSummon(NPC_DEAD_TRAINEE, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + case SPELL_SKULLS_DK: + DoSummon(NPC_DEAD_KNIGHT, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + case SPELL_SKULLS_RIDER: + DoSummon(NPC_DEAD_RIDER, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + DoSummon(NPC_DEAD_HORSE, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; } - }; + } - CreatureAI* GetAI(Creature* creature) const override + // dead side summons are "owned" by gothik + void JustSummoned(Creature* summon) override + { + if (Creature* gothik = ObjectAccessor::GetCreature(*me, me->GetInstanceScript()->GetGuidData(DATA_GOTHIK))) + gothik->AI()->JustSummoned(summon); + } + void SummonedCreatureDespawn(Creature* summon) override { - return new npc_gothik_minionAI(creature); + if (Creature* gothik = ObjectAccessor::GetCreature(*me, me->GetInstanceScript()->GetGuidData(DATA_GOTHIK))) + gothik->AI()->SummonedCreatureDespawn(summon); } + }; }; class spell_gothik_shadow_bolt_volley : public SpellScriptLoader @@ -609,6 +988,13 @@ class spell_gothik_shadow_bolt_volley : public SpellScriptLoader void AddSC_boss_gothik() { new boss_gothik(); - new npc_gothik_minion(); + new npc_gothik_minion_livingtrainee(); + new npc_gothik_minion_livingknight(); + new npc_gothik_minion_livingrider(); + new npc_gothik_minion_spectraltrainee(); + new npc_gothik_minion_spectralknight(); + new npc_gothik_minion_spectralrider(); + new npc_gothik_minion_spectralhorse(); + new npc_gothik_trigger(); new spell_gothik_shadow_bolt_volley(); } diff --git a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp index 35557b2301b..c8a4eb7fbc8 100644 --- a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp +++ b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp @@ -167,6 +167,9 @@ class instance_naxxramas : public InstanceMapScript case NPC_RAZUVIOUS: RazuviousGUID = creature->GetGUID(); break; + case NPC_GOTHIK: + GothikGUID = creature->GetGUID(); + break; case NPC_THANE: ThaneGUID = creature->GetGUID(); break; @@ -378,6 +381,8 @@ class instance_naxxramas : public InstanceMapScript return FaerlinaGUID; case DATA_RAZUVIOUS: return RazuviousGUID; + case DATA_GOTHIK: + return GothikGUID; case DATA_THANE: return ThaneGUID; case DATA_LADY: @@ -655,6 +660,7 @@ class instance_naxxramas : public InstanceMapScript // Instructor Razuvious ObjectGuid RazuviousGUID; // Gothik the Harvester + ObjectGuid GothikGUID; ObjectGuid GothikGateGUID; // The Four Horsemen ObjectGuid ThaneGUID; diff --git a/src/server/scripts/Northrend/Naxxramas/naxxramas.h b/src/server/scripts/Northrend/Naxxramas/naxxramas.h index aef8e8cd52b..c0caa86e93f 100644 --- a/src/server/scripts/Northrend/Naxxramas/naxxramas.h +++ b/src/server/scripts/Northrend/Naxxramas/naxxramas.h @@ -64,6 +64,7 @@ enum Data64 DATA_ANUBREKHAN, DATA_FAERLINA, DATA_RAZUVIOUS, + DATA_GOTHIK, DATA_THANE, DATA_LADY, DATA_BARON, @@ -86,6 +87,7 @@ enum CreaturesIds NPC_ANUBREKHAN = 15956, NPC_FAERLINA = 15953, NPC_RAZUVIOUS = 16061, + NPC_GOTHIK = 16060, NPC_THANE = 16064, NPC_LADY = 16065, NPC_BARON = 30549, diff --git a/src/server/scripts/Outland/zone_zangarmarsh.cpp b/src/server/scripts/Outland/zone_zangarmarsh.cpp index 48bbb7bad4a..6f38cce0e5b 100644 --- a/src/server/scripts/Outland/zone_zangarmarsh.cpp +++ b/src/server/scripts/Outland/zone_zangarmarsh.cpp @@ -48,8 +48,6 @@ EndContentData */ enum AshyenAndKeleth { - GOSSIP_REWARD_BLESS = 0, - NPC_ASHYEN = 17900, NPC_KELETH = 17901, @@ -117,7 +115,6 @@ public: if (spell) { creature->CastSpell(player, spell, true); - creature->AI()->Talk(GOSSIP_REWARD_BLESS); } } @@ -145,7 +142,6 @@ public: if (spell) { creature->CastSpell(player, spell, true); - creature->AI()->Talk(GOSSIP_REWARD_BLESS); } } player->CLOSE_GOSSIP_MENU(); diff --git a/src/server/scripts/Spells/spell_paladin.cpp b/src/server/scripts/Spells/spell_paladin.cpp index 9f6b4947328..13e7697910b 100644 --- a/src/server/scripts/Spells/spell_paladin.cpp +++ b/src/server/scripts/Spells/spell_paladin.cpp @@ -43,6 +43,12 @@ enum PaladinSpells SPELL_PALADIN_BLESSING_OF_LOWER_CITY_PRIEST = 37880, SPELL_PALADIN_BLESSING_OF_LOWER_CITY_SHAMAN = 37881, + SPELL_PALADIN_BEACON_OF_LIGHT = 53563, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1 = 53652, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_2 = 53653, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3 = 53654, + SPELL_PALADIN_HOLY_LIGHT = 635, + SPELL_PALADIN_DIVINE_STORM = 53385, SPELL_PALADIN_DIVINE_STORM_DUMMY = 54171, SPELL_PALADIN_DIVINE_STORM_HEAL = 54172, @@ -1153,6 +1159,68 @@ class spell_pal_lay_on_hands : public SpellScriptLoader } }; +// 53651 - Light's Beacon - Beacon of Light +class spell_pal_light_s_beacon : public SpellScriptLoader +{ + public: + spell_pal_light_s_beacon() : SpellScriptLoader("spell_pal_light_s_beacon") { } + + class spell_pal_light_s_beacon_AuraScript : public AuraScript + { + PrepareAuraScript(spell_pal_light_s_beacon_AuraScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_2) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_HOLY_LIGHT)) + return false; + return true; + } + + bool CheckProc(ProcEventInfo& eventInfo) + { + if (GetTarget()->HasAura(SPELL_PALADIN_BEACON_OF_LIGHT, eventInfo.GetActor()->GetGUID())) + return false; + return true; + } + + void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) + { + PreventDefaultAction(); + + SpellInfo const* procSpell = eventInfo.GetSpellInfo(); + if (!procSpell) + return; + + uint32 healSpellId = procSpell->IsRankOf(sSpellMgr->GetSpellInfo(SPELL_PALADIN_HOLY_LIGHT)) ? SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1 : SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3; + uint32 heal = CalculatePct(eventInfo.GetHealInfo()->GetHeal(), aurEff->GetAmount()); + + Unit* beaconTarget = GetCaster(); + if (!beaconTarget || !beaconTarget->HasAura(SPELL_PALADIN_BEACON_OF_LIGHT, eventInfo.GetActor()->GetGUID())) + return; + + /// @todo: caster must be the healed unit to perform distance checks correctly + /// but that will break animation on clientside + /// caster in spell packets must be the healing unit + eventInfo.GetActor()->CastCustomSpell(healSpellId, SPELLVALUE_BASE_POINT0, heal, beaconTarget, true); + } + + void Register() override + { + DoCheckProc += AuraCheckProcFn(spell_pal_light_s_beacon_AuraScript::CheckProc); + OnEffectProc += AuraEffectProcFn(spell_pal_light_s_beacon_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_pal_light_s_beacon_AuraScript(); + } +}; + // 31789 - Righteous Defense class spell_pal_righteous_defense : public SpellScriptLoader { @@ -1338,6 +1406,7 @@ void AddSC_paladin_spell_scripts() new spell_pal_judgement("spell_pal_judgement_of_wisdom", SPELL_PALADIN_JUDGEMENT_OF_WISDOM); new spell_pal_judgement_of_command(); new spell_pal_lay_on_hands(); + new spell_pal_light_s_beacon(); new spell_pal_righteous_defense(); new spell_pal_sacred_shield(); new spell_pal_seal_of_righteousness(); |