Scripts/WanderingIsle: Implement yak delivery carts (#31807)
Signed-off-by: luis <[email protected]>
This commit is contained in:
@@ -0,0 +1,375 @@
|
||||
-- The Wandering Isle Carts & Yaks fixes
|
||||
-- NPC: 57207 Spawned Yak Singing Pool
|
||||
-- NPC: 57208 Spawned Cart Yak Singing Pool
|
||||
-- NPC: 57709 Nourished Yak Yak Singing Pool
|
||||
-- NPC: 57710 Cart Yak Singing Pool
|
||||
-- NPC: 59497 Cart at farmstead
|
||||
-- NPC: 59496 Spawned Cart at farmstead
|
||||
-- NPC: 59499 Nourished Yak at farmstead
|
||||
-- NPC: 59498 Spawned Nourished Yak at farmstead
|
||||
-- NPC: 57740 Spawned Cart at Forest
|
||||
-- NPC: 57741 Cart at Forest
|
||||
-- NPC: 57742 Spawned Yak at Forest
|
||||
-- NPC: 57743 Yak at Forest
|
||||
|
||||
|
||||
-- ========================================
|
||||
-- Yak & Cart at Singing Pools
|
||||
-- ========================================
|
||||
UPDATE `creature_template` SET `VehicleId` = 1944 WHERE `entry` = 57208;
|
||||
UPDATE `creature_template` SET `ScriptName` = 'npc_delivery_cart' WHERE `Entry`=57208;
|
||||
|
||||
-- Nourished Yak smart ai
|
||||
SET @ENTRY := 57207;
|
||||
UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' 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`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `action_param7`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`, `Difficulties`) VALUES
|
||||
(@ENTRY, 0, 0, 0, 60, 0, 100, 1, 1400, 1400, 0, 0, 0, 53, 0, 5720700, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Time = 1.4 seconds - Self: Start path #5720700, walk, do not repeat, Passive', ''),
|
||||
(@ENTRY, 0, 1, 0, 58, 0, 100, 0, 0xFFFFFFFF, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'On any waypoint of any path ended - Self: Despawn in 1 s', '');
|
||||
|
||||
DELETE FROM `npc_spellclick_spells` WHERE `npc_entry` IN (57710);
|
||||
INSERT INTO `npc_spellclick_spells` VALUES
|
||||
(57710, 107784, 3, 0),
|
||||
(57710, 115904, 1, 0);
|
||||
|
||||
DELETE FROM `vehicle_template` WHERE `creatureId` = 57208;
|
||||
INSERT INTO `vehicle_template` VALUES (57208, 12000, NULL,0);
|
||||
|
||||
DELETE FROM `waypoint_path` WHERE `PathId` IN (5720700,5720800);
|
||||
INSERT INTO `waypoint_path` (`PathId`, `MoveType`, `Flags`, `Comment`) VALUES
|
||||
(5720700,1,0,'The Wandering Isle Cart & Ox'),
|
||||
(5720800,1,0,'The Wandering Isle Cart & Ox');
|
||||
|
||||
DELETE FROM `waypoint_path_node` WHERE `PathId` IN (5720700,5720800);
|
||||
INSERT INTO `waypoint_path_node` (`PathId`, `NodeId`, `PositionX`, `PositionY`, `PositionZ`) values
|
||||
(5720700, 0, 981.766, 2857.77, 88.7352),
|
||||
(5720700, 1, 978.016, 2848.52, 87.2352),
|
||||
(5720700, 2, 948.266, 2835.52, 87.2352),
|
||||
(5720700, 3, 919.016, 2825.02, 87.2352),
|
||||
(5720700, 4, 895.766, 2811.27, 86.9852),
|
||||
(5720700, 5, 880.766, 2807.02, 83.9852),
|
||||
(5720700, 6, 853.516, 2799.02, 83.7352),
|
||||
(5720700, 7, 825.516, 2790.77, 78.7352),
|
||||
(5720700, 8, 802.266, 2785.27, 76.7352),
|
||||
(5720700, 9, 790.266, 2792.77, 75.7352),
|
||||
(5720700, 10, 763.016, 2815.52, 76.2352),
|
||||
(5720700, 11, 746.766, 2834.77, 75.7352),
|
||||
(5720700, 12, 746.266, 2851.77, 75.9852),
|
||||
(5720700, 13, 755.516, 2869.77, 75.2352),
|
||||
(5720700, 14, 753.516, 2890.02, 74.9852),
|
||||
(5720700, 15, 732.864, 2915.02, 74.7352),
|
||||
(5720700, 16, 703.766, 2939.02, 74.7352),
|
||||
(5720700, 17, 683.766, 2954.77, 75.2352),
|
||||
(5720700, 18, 674.016, 2975.52, 74.9852),
|
||||
(5720700, 19, 667.266, 2983.27, 75.2352),
|
||||
(5720700, 20, 660.516, 2990.77, 79.9852),
|
||||
(5720700, 21, 652.266, 2999.52, 74.9852),
|
||||
(5720700, 22, 645.016, 3006.27, 74.7352),
|
||||
(5720700, 23, 629.016, 3016.52, 75.4852),
|
||||
(5720700, 24, 616.016, 3035.52, 76.7352),
|
||||
(5720700, 25, 612.766, 3061.27, 80.4852),
|
||||
(5720700, 26, 612.766, 3080.27, 84.4852),
|
||||
(5720700, 27, 618.01, 3107.21, 87.5104),
|
||||
(5720700, 28, 617.01, 3131.96, 87.7604),
|
||||
(5720700, 29, 607.01, 3143.96, 88.0104),
|
||||
(5720700, 30, 591.51, 3146.71, 87.0104),
|
||||
(5720700, 31, 574.51, 3148.71, 88.0104),
|
||||
(5720700, 32, 555.01, 3159.21, 78.0104),
|
||||
|
||||
(5720800, 0, 981.864, 2857.8, 88.8159),
|
||||
(5720800, 1, 978.114, 2848.55, 87.3159),
|
||||
(5720800, 2, 948.364, 2835.55, 87.3159),
|
||||
(5720800, 3, 919.114, 2825.05, 87.3159),
|
||||
(5720800, 4, 895.614, 2811.3, 87.0659),
|
||||
(5720800, 5, 880.614, 2807.05, 83.8159),
|
||||
(5720800, 6, 853.364, 2799.05, 83.8159),
|
||||
(5720800, 7, 825.614, 2790.8, 78.5659),
|
||||
(5720800, 8, 802.364, 2785.3, 76.8159),
|
||||
(5720800, 9, 790.364, 2792.8, 75.8159),
|
||||
(5720800, 10, 762.864, 2815.55, 76.0659),
|
||||
(5720800, 11, 746.614, 2834.8, 75.8159),
|
||||
(5720800, 12, 746.364, 2851.8, 76.0659),
|
||||
(5720800, 13, 755.614, 2869.8, 75.3159),
|
||||
(5720800, 14, 753.364, 2890.05, 75.0659),
|
||||
(5720800, 15, 732.864, 2915.05, 74.5659),
|
||||
(5720800, 16, 703.614, 2939.05, 74.5659),
|
||||
(5720800, 17, 683.864, 2954.8, 75.3159),
|
||||
(5720800, 18, 674.114, 2975.55, 75.3159),
|
||||
(5720800, 19, 667.364, 2983.3, 75.3159),
|
||||
(5720800, 20, 660.614, 2990.55, 79.8159),
|
||||
(5720800, 21, 652.364, 2999.52, 75.3159),
|
||||
(5720800, 22, 645.114, 3006.3, 74.8159),
|
||||
(5720800, 23, 629.114, 3016.55, 75.4852),
|
||||
(5720800, 24, 616.114, 3035.55, 76.7352),
|
||||
(5720800, 25, 612.864, 3061.3, 80.4852),
|
||||
(5720800, 26, 612.864, 3080.3, 84.4852),
|
||||
(5720800, 27, 618.01, 3107.21, 87.5442),
|
||||
(5720800, 28, 617.01, 3131.96, 87.7604),
|
||||
(5720800, 29, 607.01, 3143.96, 88.0104),
|
||||
(5720800, 30, 591.51, 3146.71, 87.0104),
|
||||
(5720800, 31, 574.51, 3148.71, 88.0104),
|
||||
(5720800, 32, 555.01, 3159.21, 78.0104),
|
||||
(5720800, 33, 547.302, 3174.96, 77.2942);
|
||||
|
||||
-- ========================================
|
||||
-- Yak & Cart at Farmstead
|
||||
-- ========================================
|
||||
UPDATE `creature_template` SET `VehicleId` = 1944 WHERE `entry` = 59496;
|
||||
UPDATE `creature_template` SET `ScriptName` = 'npc_delivery_cart' WHERE `Entry`=59496;
|
||||
|
||||
-- Nourished Yak smart ai
|
||||
SET @ENTRY := 59498;
|
||||
UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' 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`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `action_param7`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`, `Difficulties`) VALUES
|
||||
(@ENTRY, 0, 0, 0, 60, 0, 100, 1, 1400, 1400, 0, 0, 0, 53, 0, 5949800, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Time = 1.4 seconds - Self: Start path #5949800, walk, do not repeat, Passive', ''),
|
||||
(@ENTRY, 0, 1, 0, 58, 0, 100, 0, 0xFFFFFFFF, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'On any waypoint of any path ended - Self: Despawn in 1 s', '');
|
||||
|
||||
DELETE FROM `npc_spellclick_spells` WHERE `npc_entry` IN (59497);
|
||||
INSERT INTO `npc_spellclick_spells` VALUES
|
||||
(59497, 114453, 3, 0),
|
||||
(59497, 115904, 1, 0);
|
||||
|
||||
DELETE FROM `vehicle_template` WHERE `creatureId` = 59496;
|
||||
INSERT INTO `vehicle_template` VALUES (59496, 12000, NULL,0);
|
||||
|
||||
DELETE FROM `waypoint_path` WHERE `PathId` IN (5949600,5949800);
|
||||
INSERT INTO `waypoint_path` (`PathId`, `MoveType`, `Flags`, `Comment`) VALUES
|
||||
(5949600,1,0,'Spawned Cart at Farmstead'),
|
||||
(5949800,1,0,'Spawned Yak at Farmstead');
|
||||
|
||||
DELETE FROM `waypoint_path_node` WHERE `PathId` IN (5949600,5949800);
|
||||
INSERT INTO `waypoint_path_node` (`PathId`, `NodeId`, `PositionX`, `PositionY`, `PositionZ`) values
|
||||
(5949600, 0, 581.87, 3153.32, 88.284),
|
||||
(5949600, 1, 573.37, 3149.82, 86.534),
|
||||
(5949600, 2, 557.87, 3157.07, 79.284),
|
||||
(5949600, 3, 548.12, 3172.57, 77.534),
|
||||
(5949600, 4, 545.12, 3197.32, 77.284),
|
||||
(5949600, 5, 538.12, 3210.82, 76.284),
|
||||
(5949600, 6, 517.87, 3225.07, 74.534),
|
||||
(5949600, 7, 508.12, 3244.82, 76.534),
|
||||
(5949600, 8, 507.87, 3265.32, 77.784),
|
||||
(5949600, 9, 512.37, 3291.07, 74.534),
|
||||
(5949600, 10, 519.87, 3315.07, 73.534),
|
||||
(5949600, 11, 524.37, 3324.07, 77.784),
|
||||
(5949600, 12, 527.37, 3328.82, 78.284),
|
||||
(5949600, 13, 532.12, 3336.57, 73.784),
|
||||
(5949600, 14, 543.37, 3355.82, 76.784),
|
||||
(5949600, 15, 555.12, 3367.07, 78.534),
|
||||
(5949600, 16, 568.12, 3375.82, 80.534),
|
||||
(5949600, 17, 608.12, 3383.57, 87.034),
|
||||
(5949600, 18, 634.87, 3392.07, 93.034),
|
||||
(5949600, 19, 653.12, 3404.82, 99.034),
|
||||
(5949600, 20, 675.62, 3427.32, 106.784),
|
||||
(5949600, 21, 685.37, 3443.57, 112.034),
|
||||
(5949600, 22, 694.12, 3467.57, 118.034),
|
||||
(5949600, 23, 715.62, 3480.57, 121.534),
|
||||
(5949600, 24, 741.87, 3492.32, 133.784),
|
||||
(5949600, 25, 751.37, 3506.32, 137.784),
|
||||
(5949600, 26, 756.12, 3525.32, 139.784),
|
||||
(5949600, 27, 743.12, 3552.57, 140.784),
|
||||
(5949600, 28, 741.62, 3572.57, 140.784),
|
||||
(5949600, 29, 744.536, 3595.51, 140.547),
|
||||
(5949600, 30, 739.739, 3604.48, 140.749),
|
||||
(5949600, 31, 722.489, 3605.23, 140.749),
|
||||
(5949600, 32, 704.011, 3600.88, 141.999),
|
||||
(5949600, 33, 684.011, 3600.73, 145.999),
|
||||
(5949600, 34, 659.739, 3602.23, 146.999),
|
||||
|
||||
(5949800, 0, 582.076, 3153.46, 88.2618),
|
||||
(5949800, 1, 573.326, 3149.96, 86.7618),
|
||||
(5949800, 2, 558.076, 3156.96, 79.2618),
|
||||
(5949800, 3, 548.076, 3172.46, 77.5118),
|
||||
(5949800, 4, 545.076, 3197.46, 77.5118),
|
||||
(5949800, 5, 538.076, 3210.71, 76.5118),
|
||||
(5949800, 6, 517.826, 3224.96, 74.5118),
|
||||
(5949800, 7, 508.076, 3244.71, 76.5118),
|
||||
(5949800, 8, 508.076, 3265.46, 77.5118),
|
||||
(5949800, 9, 512.326, 3291.21, 74.5118),
|
||||
(5949800, 10, 520.076, 3315.21, 73.5118),
|
||||
(5949800, 11, 524.326, 3323.96, 77.5118),
|
||||
(5949800, 12, 527.326, 3328.71, 78.2618),
|
||||
(5949800, 13, 532.076, 3336.46, 73.7618),
|
||||
(5949800, 14, 543.576, 3355.71, 76.7618),
|
||||
(5949800, 15, 555.076, 3366.96, 78.5118),
|
||||
(5949800, 16, 568.326, 3375.71, 80.5118),
|
||||
(5949800, 17, 608.076, 3383.46, 87.0118),
|
||||
(5949800, 18, 634.876, 3392.07, 93.2618),
|
||||
(5949800, 19, 653.076, 3404.96, 99.0118),
|
||||
(5949800, 20, 675.576, 3427.21, 106.762),
|
||||
(5949800, 21, 685.326, 3443.71, 112.012),
|
||||
(5949800, 22, 694.076, 3467.46, 118.012),
|
||||
(5949800, 23, 715.576, 3480.71, 121.512),
|
||||
(5949800, 24, 741.826, 3492.21, 133.762),
|
||||
(5949800, 25, 751.326, 3506.32, 137.762),
|
||||
(5949800, 26, 756.076, 3525.21, 139.262),
|
||||
(5949800, 27, 743.076, 3552.71, 140.762),
|
||||
(5949800, 28, 741.576, 3572.46, 140.762),
|
||||
(5949800, 29, 744.536, 3595.51, 140.547),
|
||||
(5949800, 30, 739.739, 3604.38, 140.749),
|
||||
(5949800, 31, 722.489, 3605.13, 140.749),
|
||||
(5949800, 32, 704.011, 3600.88, 141.999),
|
||||
(5949800, 33, 684.011, 3600.73, 145.999),
|
||||
(5949800, 34, 659.739, 3602.23, 146.999);
|
||||
|
||||
-- ========================================
|
||||
-- Yak & Cart at the Forbidden Forest - Wreck of the Skyseeker
|
||||
-- ========================================
|
||||
UPDATE `creature_template` SET `VehicleId` = 1944 WHERE `entry` = 57740;
|
||||
UPDATE `creature_template` SET `ScriptName` = 'npc_delivery_cart' WHERE `Entry`=57740;
|
||||
|
||||
-- Nourished Yak smart ai
|
||||
SET @ENTRY := 57742;
|
||||
UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' 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`, `event_param5`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `action_param7`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`, `Difficulties`) VALUES
|
||||
(@ENTRY, 0, 0, 0, 60, 0, 100, 1, 1400, 1400, 0, 0, 0, 53, 0, 5774200, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Time = 1.4 seconds - Self: Start path #5774200, walk, do not repeat, Passive', ''),
|
||||
(@ENTRY, 0, 1, 0, 58, 0, 100, 0, 0xFFFFFFFF, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'On any waypoint of any path ended - Self: Despawn in 1 s', '');
|
||||
|
||||
DELETE FROM `npc_spellclick_spells` WHERE `npc_entry` IN (57741);
|
||||
INSERT INTO `npc_spellclick_spells` (`npc_entry`, `spell_id`, `cast_flags`, `user_type`) VALUES
|
||||
(57741, 108933, 3, 0),
|
||||
(57741, 115904, 1, 0);
|
||||
|
||||
DELETE FROM `vehicle_template` WHERE `creatureId` = 57740;
|
||||
INSERT INTO `vehicle_template` VALUES (57740, 12000, NULL,0);
|
||||
|
||||
-- Forest Cart & Ox
|
||||
DELETE FROM `waypoint_path` WHERE `PathId` IN (5774000,5774200);
|
||||
INSERT INTO `waypoint_path` (`PathId`, `MoveType`, `Flags`, `Comment`) VALUES
|
||||
(5774000,1,0,'The Wandering Isle Forest Cart'),
|
||||
(5774200,1,0,'The Wandering Isle Forest Ox');
|
||||
|
||||
DELETE FROM `waypoint_path_node` WHERE `PathId` IN (5774000,5774200);
|
||||
INSERT INTO `waypoint_path_node` (`PathId`, `NodeId`, `PositionX`, `PositionY`, `PositionZ`, `Orientation`, `Delay`) values
|
||||
(5774000, 1, 277.95, 3881.76, 75.9185, 0, 0),
|
||||
(5774000, 2, 300.7, 3886.26, 78.1685, 0, 0),
|
||||
(5774000, 3, 330.95, 3887.01, 80.1685, 0, 0),
|
||||
(5774000, 4, 359.7, 3886.51, 79.6685, 0, 0),
|
||||
(5774000, 5, 385.2, 3883.51, 79.6685, 0, 0),
|
||||
(5774000, 6, 413.2, 3888.01, 79.6685, 0, 0),
|
||||
(5774000, 7, 437.95, 3884.51, 79.6685, 0, 0),
|
||||
(5774000, 8, 451.45, 3871.26, 79.9185, 0, 0),
|
||||
(5774000, 9, 459.45, 3859.26, 80.1685, 0, 0),
|
||||
(5774000, 10, 466.45, 3839.01, 80.6685, 0, 0),
|
||||
(5774000, 11, 466.95, 3821.51, 86.1685, 0, 0),
|
||||
(5774000, 12, 467.45, 3800.76, 81.1685, 0, 0),
|
||||
(5774000, 13, 466.2, 3780.76, 82.1685, 0, 0),
|
||||
(5774000, 14, 461.2, 3752.76, 83.1685, 0, 0),
|
||||
(5774000, 15, 449.45, 3728.76, 82.6685, 0, 0),
|
||||
(5774000, 16, 431.45, 3707.26, 81.6685, 0, 0),
|
||||
(5774000, 17, 430.2, 3690.51, 81.6685, 0, 0),
|
||||
(5774000, 18, 439.95, 3671.01, 79.4185, 0, 0),
|
||||
(5774000, 19, 460.2, 3642.76, 79.4185, 0, 0),
|
||||
(5774000, 20, 468.7, 3616.51, 79.9185, 0, 0),
|
||||
(5774000, 21, 477.45, 3585.26, 83.9185, 0, 0),
|
||||
(5774000, 22, 499.7, 3582.26, 87.1685, 0, 0),
|
||||
(5774000, 23, 522.45, 3587.51, 91.1685, 0, 0),
|
||||
(5774000, 24, 561.45, 3584.01, 94.6685, 0, 0),
|
||||
(5774000, 25, 589.45, 3585.51, 98.1685, 0, 0),
|
||||
(5774000, 26, 600.45, 3607.26, 110.919, 0, 0),
|
||||
(5774000, 27, 610.7, 3625.76, 123.669, 0, 0),
|
||||
(5774000, 28, 630.45, 3628.26, 134.669, 0, 0),
|
||||
(5774000, 29, 651.7, 3608.76, 145.169, 0, 0),
|
||||
(5774000, 30, 674.45, 3601.01, 146.919, 0, 0),
|
||||
(5774000, 31, 714.7, 3602.26, 140.919, 0, 0),
|
||||
(5774000, 32, 730.7, 3601.51, 140.669, 0, 0),
|
||||
(5774000, 33, 737.028, 3596.41, 140.606, 0, 0),
|
||||
(5774000, 34, 739.551, 3587.62, 140.657, 0, 0),
|
||||
(5774000, 35, 742.051, 3560.37, 140.657, 0, 0),
|
||||
(5774000, 36, 753.551, 3533.87, 139.407, 0, 0),
|
||||
(5774000, 37, 755.301, 3516.62, 138.657, 0, 0),
|
||||
(5774000, 38, 745.801, 3496.87, 135.907, 0, 0),
|
||||
(5774000, 39, 729.547, 3486.77, 128.211, 0, 0),
|
||||
|
||||
(5774200, 1, 277.876, 3881.79, 75.9003, 0, 0),
|
||||
(5774200, 2, 300.626, 3886.29, 78.1503, 0, 0),
|
||||
(5774200, 3, 331.126, 3886.79, 80.1503, 0, 0),
|
||||
(5774200, 4, 359.626, 3886.54, 79.6503, 0, 0),
|
||||
(5774200, 5, 385.376, 3883.54, 79.9003, 0, 0),
|
||||
(5774200, 6, 413.126, 3887.79, 79.6503, 0, 0),
|
||||
(5774200, 7, 437.876, 3884.54, 79.6503, 0, 0),
|
||||
(5774200, 8, 451.626, 3871.29, 79.9003, 0, 0),
|
||||
(5774200, 9, 459.376, 3859.04, 80.1503, 0, 0),
|
||||
(5774200, 10, 466.376, 3839.04, 80.6503, 0, 0),
|
||||
(5774200, 11, 466.876, 3821.54, 86.1503, 0, 0),
|
||||
(5774200, 12, 467.376, 3800.79, 81.1503, 0, 0),
|
||||
(5774200, 13, 466.126, 3780.79, 82.1503, 0, 0),
|
||||
(5774200, 14, 461.126, 3752.79, 83.1503, 0, 0),
|
||||
(5774200, 15, 449.376, 3728.79, 82.6503, 0, 0),
|
||||
(5774200, 16, 431.376, 3707.29, 81.9003, 0, 0),
|
||||
(5774200, 17, 430.126, 3690.54, 81.6503, 0, 0),
|
||||
(5774200, 18, 440.126, 3671.04, 79.4003, 0, 0),
|
||||
(5774200, 19, 460.376, 3642.79, 79.4003, 0, 0),
|
||||
(5774200, 20, 468.626, 3616.54, 79.9003, 0, 0),
|
||||
(5774200, 21, 477.376, 3585.04, 83.9003, 0, 0),
|
||||
(5774200, 22, 499.626, 3582.29, 87.1503, 0, 0),
|
||||
(5774200, 23, 522.376, 3587.54, 91.1503, 0, 0),
|
||||
(5774200, 24, 561.376, 3583.79, 94.6503, 0, 0),
|
||||
(5774200, 25, 589.626, 3585.54, 98.1503, 0, 0),
|
||||
(5774200, 26, 600.376, 3607.29, 110.9, 0, 0),
|
||||
(5774200, 27, 610.626, 3625.79, 123.65, 0, 0),
|
||||
(5774200, 28, 630.376, 3628.29, 134.65, 0, 0),
|
||||
(5774200, 29, 651.876, 3608.79, 145.4, 0, 0),
|
||||
(5774200, 30, 674.376, 3601.04, 146.9, 0, 0),
|
||||
(5774200, 31, 714.876, 3602.29, 140.9, 0, 0),
|
||||
(5774200, 32, 730.876, 3601.54, 140.9, 0, 0),
|
||||
(5774200, 33, 737.028, 3596.41, 140.606, 0, 0),
|
||||
(5774200, 34, 739.532, 3587.64, 140.657, 0, 0),
|
||||
(5774200, 35, 742.032, 3560.39, 140.657, 0, 0),
|
||||
(5774200, 36, 753.532, 3533.89, 139.407, 0, 0),
|
||||
(5774200, 37, 755.532, 3516.64, 138.657, 0, 0),
|
||||
(5774200, 38, 745.782, 3496.89, 135.907, 0, 0),
|
||||
(5774200, 39, 729.547, 3486.77, 128.211, 0, 0);
|
||||
|
||||
-- ========================================
|
||||
-- Addons
|
||||
-- ========================================
|
||||
DELETE FROM `creature_template_addon` WHERE `entry` IN (57740, 57741, 57742, 57743, 59496, 59497, 59498, 59499);
|
||||
INSERT INTO `creature_template_addon` (`entry`, `PathId`, `mount`, `MountCreatureId`, `StandState`, `AnimTier`, `VisFlags`, `SheathState`, `PvPFlags`, `emote`, `aiAnimKit`,
|
||||
`movementAnimKit`, `meleeAnimKit`, `visibilityDistanceType`, `auras`) VALUES
|
||||
-- Cart Yak at Dai-Lo Farmstead
|
||||
(59496, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, '108692'),
|
||||
(59497, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '108692 94567 82358'),
|
||||
(59498, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, ''),
|
||||
(59499, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '82358 94567'),
|
||||
-- Cart Yak at Forbidden forest
|
||||
(57740, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, '108692'),
|
||||
(57741, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '108692 49417 49415'),
|
||||
(57742, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, ''),
|
||||
(57743, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '49415 49417');
|
||||
-- Cart Yak at Singing Pools
|
||||
DELETE FROM `creature_template_addon` WHERE `entry` IN (57208,57207,57710,57709);
|
||||
INSERT INTO `creature_template_addon` (`entry`, `PathId`, `mount`, `MountCreatureID`, `StandState`, `AnimTier`, `VisFlags`, `SheathState`, `PvPFlags`, `emote`, `aiAnimKit`, `movementAnimKit`, `meleeAnimKit`, `visibilityDistanceType`, `auras`) VALUES
|
||||
(57207, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, ''),
|
||||
(57208, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '108692'),
|
||||
(57709, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '84886 94570'),
|
||||
(57710, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, '108692 94570 84886');
|
||||
|
||||
-- ========================================
|
||||
-- Difficulty Records
|
||||
-- ========================================
|
||||
DELETE FROM `creature_template_difficulty` WHERE `entry` IN (57208, 57207, 57710, 57709, 57740, 57741, 57742, 57743, 59496, 59497, 59498, 59499);
|
||||
INSERT INTO `creature_template_difficulty` VALUES
|
||||
-- Cart Yak at Singing Pools
|
||||
(57207, 0, 0, 0, 80, 4, 1, 1, 1, 1, 26777, 0, 0, 0, 0, 0, 0, 0, 0, 268435456 | 0x02000000, 0, 0, 0, 0, 0, 0, 0, 56647),
|
||||
(57208, 0, 0, 0, 80, 4, 1, 1, 1, 1, 26775, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256 | 0x02000000, 0, 0, 0, 0, 0, 56647),
|
||||
(57709, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 26264, 0, 0, 0, 0, 0, 0, 0, 0, 268435456, 0, 0, 0, 0, 0, 0, 0, 56647),
|
||||
(57710, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 26262, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256, 0, 0, 0, 0, 0, 56647),
|
||||
-- Cart Yak at Dai-Lo Farmstead
|
||||
(59496, 0, 0, 0, 80, 4, 1, 1, 1, 1, 23227, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256 | 0x02000000, 0, 0, 0, 0, 0, 56647),
|
||||
(59497, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 23225, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256, 0, 0, 0, 0, 0, 56647),
|
||||
(59498, 0, 0, 0, 80, 4, 1, 1, 1, 1, 23223, 0, 0, 0, 0, 0, 0, 0, 0, 268435456 | 0x02000000, 0, 0, 0, 0, 0, 0, 0, 56647),
|
||||
(59499, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 23221, 0, 0, 0, 0, 0, 0, 0, 0, 268435456, 0, 0, 0, 0, 0, 0, 0, 56647),
|
||||
-- Cart Yak at Forbidden forest
|
||||
(57740, 0, 0, 0, 80, 4, 1, 1, 1, 1, 26236, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256 | 0x02000000, 0, 0, 0, 0, 0, 56647),
|
||||
(57741, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 26235, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 256, 0, 0, 0, 0, 0, 56647),
|
||||
(57742, 0, 0, 0, 80, 4, 1, 1, 1, 1, 26231, 0, 0, 0, 0, 0, 0, 0, 0, 268435456 | 0x02000000, 0, 0, 0, 0, 0, 0, 0, 56647),
|
||||
(57743, 0, 0, 0, 80, 4, 1, 1, 1, 0.2, 26229, 0, 0, 0, 0, 0, 0, 0, 0, 268435456, 0, 0, 0, 0, 0, 0, 0, 56647);
|
||||
|
||||
-- Rope spell conditions
|
||||
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=108627;
|
||||
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `ConditionStringValue1`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
|
||||
(13, 1, 108627, 0, 0, 51, 0, 5, 57207, 0, '', 0, 0, 0, '', 'Ox Cart Rope Left can only hit Nourished Yak'),
|
||||
(13, 1, 108627, 0, 1, 51, 0, 5, 59498, 0, '', 0, 0, 0, '', 'Ox Cart Rope Left can only hit Nourished Yak'),
|
||||
(13, 1, 108627, 0, 2, 51, 0, 5, 57742, 0, '', 0, 0, 0, '', 'Ox Cart Rope Left can only hit Nourished Yak');
|
||||
@@ -38,6 +38,11 @@ namespace Scripts::Pandaria::TheWanderingIsle
|
||||
{
|
||||
namespace Spells
|
||||
{
|
||||
// Generic Vehicle Spells
|
||||
static constexpr uint32 ForceVehicleRide = 46598;
|
||||
static constexpr uint32 EjectPassengers = 50630;
|
||||
static constexpr uint32 OxCartRopeLeft = 108627; // Cart on Yak
|
||||
|
||||
// Singing Pools
|
||||
static constexpr uint32 CurseOfTheFrog = 102938;
|
||||
static constexpr uint32 CurseOfTheSkunk = 102939;
|
||||
@@ -60,12 +65,24 @@ namespace Spells
|
||||
namespace Quests
|
||||
{
|
||||
static constexpr uint32 OnlyTheWorthyShallPass = 29421;
|
||||
static constexpr uint32 TheSourceOfLivelihood = 29680;
|
||||
static constexpr uint32 TheSpiritAndBodyOfShenzinsu = 29775;
|
||||
static constexpr uint32 NewAllies = 29800;
|
||||
}
|
||||
|
||||
namespace Creatures
|
||||
{
|
||||
static constexpr uint32 MasterLiFei = 54135;
|
||||
static constexpr uint32 MasterLiFeiCombat = 54734;
|
||||
|
||||
// Yak and Cart
|
||||
static constexpr uint32 CartSingingPools = 57710;
|
||||
static constexpr uint32 CartFarmstead = 59497;
|
||||
static constexpr uint32 CartForest = 57741;
|
||||
|
||||
static constexpr uint32 CartVehicleSingingPools = 57208;
|
||||
static constexpr uint32 CartVehicleFarmstead = 59496;
|
||||
static constexpr uint32 CartVehicleForest = 57740;
|
||||
}
|
||||
|
||||
namespace Talks
|
||||
@@ -73,6 +90,24 @@ namespace Talks
|
||||
static constexpr uint32 LiFeiDefeat = 0;
|
||||
}
|
||||
|
||||
namespace Paths
|
||||
{
|
||||
// Yak and Cart
|
||||
static constexpr uint32 CartSingingPools = 5720800;
|
||||
static constexpr uint32 CartFarmstead = 5949600;
|
||||
static constexpr uint32 CartForest = 5774000;
|
||||
|
||||
static constexpr int8 NodeCartRemovePassenger = 28;
|
||||
static constexpr int8 NodeForestCartRemovePassenger = 34;
|
||||
}
|
||||
|
||||
namespace Events
|
||||
{
|
||||
// Yak and Cart
|
||||
static constexpr int8 YakCartPathStart = 1;
|
||||
static constexpr int8 YakCartRopes = 2;
|
||||
}
|
||||
|
||||
enum TraineeMisc
|
||||
{
|
||||
SAY_FINISH_FIGHT = 0,
|
||||
@@ -1492,6 +1527,117 @@ class spell_flying_shadow_kick : public SpellScript
|
||||
OnEffectHitTarget += SpellEffectFn(spell_flying_shadow_kick::HandleHitTarget, EFFECT_1, SPELL_EFFECT_SCRIPT_EFFECT);
|
||||
}
|
||||
};
|
||||
|
||||
struct CartData
|
||||
{
|
||||
uint32 Entry = 0;
|
||||
uint32 PathId = 0;
|
||||
Optional<uint8> EjectNodeId;
|
||||
Optional<uint32> CreditNPC;
|
||||
Optional<uint32> QuestId;
|
||||
Optional<uint32> YakNPC;
|
||||
};
|
||||
|
||||
static constexpr CartData CartDataTable[] =
|
||||
{
|
||||
// Carts
|
||||
{
|
||||
.Entry = Creatures::CartVehicleSingingPools,
|
||||
.PathId = Paths::CartSingingPools,
|
||||
.EjectNodeId = Paths::NodeCartRemovePassenger,
|
||||
.CreditNPC = Creatures::CartSingingPools,
|
||||
.QuestId = Quests::TheSourceOfLivelihood,
|
||||
},
|
||||
{
|
||||
.Entry = Creatures::CartVehicleFarmstead,
|
||||
.PathId = Paths::CartFarmstead,
|
||||
.EjectNodeId = Paths::NodeCartRemovePassenger,
|
||||
.CreditNPC = Creatures::CartFarmstead,
|
||||
.QuestId = Quests::TheSpiritAndBodyOfShenzinsu,
|
||||
},
|
||||
{
|
||||
.Entry = Creatures::CartVehicleForest,
|
||||
.PathId = Paths::CartForest,
|
||||
.EjectNodeId = Paths::NodeForestCartRemovePassenger,
|
||||
.CreditNPC = Creatures::CartForest,
|
||||
.QuestId = Quests::NewAllies,
|
||||
}
|
||||
};
|
||||
|
||||
static CartData GetCartData(uint32 entry)
|
||||
{
|
||||
for (CartData const& data : CartDataTable)
|
||||
if (data.Entry == entry)
|
||||
return data;
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
// 57208 - Delivery Cart (Singing Pools)
|
||||
// 59496 - Delivery Cart (Farmstead)
|
||||
// 57740 - Delivery Cart (Forbidden Forest)
|
||||
struct npc_delivery_cart : public ScriptedAI
|
||||
{
|
||||
npc_delivery_cart(Creature* creature) : ScriptedAI(creature), _data(GetCartData(creature->GetEntry())) { }
|
||||
|
||||
void Reset() override
|
||||
{
|
||||
_events.Reset();
|
||||
}
|
||||
|
||||
void PassengerBoarded(Unit* passenger, int8 /*seat*/, bool apply) override
|
||||
{
|
||||
if (!apply)
|
||||
return;
|
||||
|
||||
Player* player = passenger->ToPlayer();
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
me->CastSpell(player, Spells::ForceVehicleRide);
|
||||
|
||||
_events.ScheduleEvent(Events::YakCartPathStart, 1800ms);
|
||||
_events.ScheduleEvent(Events::YakCartRopes, 1s);
|
||||
|
||||
if (_data.QuestId && player->hasQuest(*_data.QuestId) && _data.CreditNPC)
|
||||
player->KilledMonsterCredit(*_data.CreditNPC, player->GetGUID());
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 nodeId, uint32 /*pathId*/) override
|
||||
{
|
||||
if (_data.EjectNodeId && nodeId == *_data.EjectNodeId)
|
||||
me->CastSpell(me, Spells::EjectPassengers);
|
||||
}
|
||||
|
||||
void WaypointPathEnded(uint32 /*nodeId*/, uint32 /*pathId*/) override
|
||||
{
|
||||
me->DespawnOrUnsummon(1s);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
_events.Update(diff);
|
||||
|
||||
while (uint32 eventId = _events.ExecuteEvent())
|
||||
{
|
||||
switch (eventId)
|
||||
{
|
||||
case Events::YakCartRopes:
|
||||
me->CastSpell(me, Spells::OxCartRopeLeft);
|
||||
break;
|
||||
case Events::YakCartPathStart:
|
||||
me->GetMotionMaster()->MovePath(_data.PathId, false);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
EventMap _events;
|
||||
CartData _data;
|
||||
};
|
||||
}
|
||||
|
||||
void AddSC_zone_the_wandering_isle()
|
||||
@@ -1531,4 +1677,6 @@ void AddSC_zone_the_wandering_isle()
|
||||
RegisterCreatureAI(npc_li_fei_combat);
|
||||
RegisterSpellScript(spell_feet_of_fury);
|
||||
RegisterSpellScript(spell_flying_shadow_kick);
|
||||
|
||||
RegisterCreatureAI(npc_delivery_cart);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user