From 57e599fa024a0e5def3ddb5a4a790cfb5d9d8d4b Mon Sep 17 00:00:00 2001 From: MitchesD Date: Wed, 22 Jan 2014 23:46:45 +0100 Subject: Scripts/ZulGurub/Jeklik: fixed flying in first phase, reworked spawn and rewritten to EventMap Closes #11277 --- sql/updates/world/2014_01_21_00_world_sai.sql | 2 ++ sql/updates/world/2014_01_21_world_sai.sql | 2 -- sql/updates/world/2014_01_22_01_world_creature_template.sql | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 sql/updates/world/2014_01_21_00_world_sai.sql delete mode 100644 sql/updates/world/2014_01_21_world_sai.sql create mode 100644 sql/updates/world/2014_01_22_01_world_creature_template.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_21_00_world_sai.sql b/sql/updates/world/2014_01_21_00_world_sai.sql new file mode 100644 index 00000000000..6ea92fc1aef --- /dev/null +++ b/sql/updates/world/2014_01_21_00_world_sai.sql @@ -0,0 +1,2 @@ +-- Fix Saronite Mine Slave so these actually despawn when gossip option selected for quest credit +UPDATE `smart_scripts` SET `target_type`=1 WHERE `entryorguid`=3139700 AND `source_type`=9 AND `id`=3 AND `link`=0; diff --git a/sql/updates/world/2014_01_21_world_sai.sql b/sql/updates/world/2014_01_21_world_sai.sql deleted file mode 100644 index 6ea92fc1aef..00000000000 --- a/sql/updates/world/2014_01_21_world_sai.sql +++ /dev/null @@ -1,2 +0,0 @@ --- Fix Saronite Mine Slave so these actually despawn when gossip option selected for quest credit -UPDATE `smart_scripts` SET `target_type`=1 WHERE `entryorguid`=3139700 AND `source_type`=9 AND `id`=3 AND `link`=0; diff --git a/sql/updates/world/2014_01_22_01_world_creature_template.sql b/sql/updates/world/2014_01_22_01_world_creature_template.sql new file mode 100644 index 00000000000..376a6c007c8 --- /dev/null +++ b/sql/updates/world/2014_01_22_01_world_creature_template.sql @@ -0,0 +1 @@ +UPDATE `creature_template` SET `InhabitType`=5 WHERE `entry` IN (11368,14965); -- cgit v1.2.3 From 984b7126ffa76f865089ba9afb4bfd3c21989cda Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:26:50 +0100 Subject: DB/Quest: Fix Karuk's Oath availability By Raszagal closes #11451 --- sql/updates/world/2014_01_23_00_world_quest_template.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/world/2014_01_23_00_world_quest_template.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_00_world_quest_template.sql b/sql/updates/world/2014_01_23_00_world_quest_template.sql new file mode 100644 index 00000000000..4c6f5e55841 --- /dev/null +++ b/sql/updates/world/2014_01_23_00_world_quest_template.sql @@ -0,0 +1,2 @@ +-- Fix Karuk quests - Remove Karuk's Oath as NextQuestId in A Diplomatic Mission, as this blocks Horde from doing Karuk's Oath after turning in Seek Out Karuk! +UPDATE quest_template SET NextQuestId=0 WHERE Id=12141; -- cgit v1.2.3 From 4c0c9820b8d280e366936602e9a0140921ce36f5 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:31:05 +0100 Subject: DB/Conditions: Fix Banishing Crystal By MitchesD closes #11430 --- sql/updates/world/2014_01_23_01_conditions.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 sql/updates/world/2014_01_23_01_conditions.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_01_conditions.sql b/sql/updates/world/2014_01_23_01_conditions.sql new file mode 100644 index 00000000000..4afa30ee13d --- /dev/null +++ b/sql/updates/world/2014_01_23_01_conditions.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `conditions` WHERE `SourceEntry` = 40817; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `Comment`) VALUES +(17,0,40817,0,0,23,0,3785,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Wrath'), +(17,0,40817,0,1,23,0,3784,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Terror'); -- cgit v1.2.3 From 52aa14fbfb6307153430128f1cac68e7fc902a6f Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:34:56 +0100 Subject: DB/SAI: Fix Dragon maw scout By dr-j closes #11414 --- sql/updates/world/2014_01_23_02_sai.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/world/2014_01_23_02_sai.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_02_sai.sql b/sql/updates/world/2014_01_23_02_sai.sql new file mode 100644 index 00000000000..f55db997a4c --- /dev/null +++ b/sql/updates/world/2014_01_23_02_sai.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `event_phase_mask`=1 WHERE `entryorguid`=2103 AND `event_phase_mask`=2; -- cgit v1.2.3 From 3527630ce7c4a52b63cf77d10b608e5489badb42 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:38:40 +0100 Subject: DB/Conditions Fix gnome mount vendors By dr-j closes #11406 --- sql/updates/world/2014_01_23_03_conditions.sql | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 sql/updates/world/2014_01_23_03_conditions.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_03_conditions.sql b/sql/updates/world/2014_01_23_03_conditions.sql new file mode 100644 index 00000000000..df83d50fd51 --- /dev/null +++ b/sql/updates/world/2014_01_23_03_conditions.sql @@ -0,0 +1,3 @@ +-- +UPDATE `conditions` SET `ElseGroup`=1 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=5 AND `ConditionTarget`=0 AND `ConditionValue1`=54 AND `ConditionValue2`=128 AND `ConditionValue3`=0; +UPDATE `conditions` SET `ConditionValue1`=64 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=16 AND `ConditionTarget`=0 AND `ConditionValue1`=8 AND `ConditionValue2`=0 AND `ConditionValue3`=0; -- cgit v1.2.3 From 2917c399946aa1893b52e8023fcb8eeb3b236d32 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:45:36 +0100 Subject: DB/Game_Event: Fix Boxey Boltspinner By Hitox closes #11409 --- sql/updates/world/2014_01_23_04_game_event_creature.sql | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sql/updates/world/2014_01_23_04_game_event_creature.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_04_game_event_creature.sql b/sql/updates/world/2014_01_23_04_game_event_creature.sql new file mode 100644 index 00000000000..5d350803f82 --- /dev/null +++ b/sql/updates/world/2014_01_23_04_game_event_creature.sql @@ -0,0 +1,6 @@ +-- Boxi (brewfest) +SET @GUID := '200002'; + +-- game event creature boxi +DELETE FROM `game_event_creature` WHERE `guid`=@GUID; +INSERT INTO `game_event_creature`(`eventEntry`,`guid`) values (24,@GUID); -- cgit v1.2.3 From b53d9a7caa9cec159122c0082425c12f6c7d2c38 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:48:29 +0100 Subject: DB/Creature: Fix for Tenebron Egg Controller By untaught closes #11321 --- sql/updates/world/2014_01_23_05_creature_template.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/world/2014_01_23_05_creature_template.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_05_creature_template.sql b/sql/updates/world/2014_01_23_05_creature_template.sql new file mode 100644 index 00000000000..a35a6191ea4 --- /dev/null +++ b/sql/updates/world/2014_01_23_05_creature_template.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128|2 WHERE `entry` IN (31138,31550); -- cgit v1.2.3 From f722d7e07625fbef3326a406a41295df3155ddad Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 10:51:44 +0100 Subject: DB/Creature: Fix Voidspawner By Kittnz, closes #11382 --- sql/updates/world/2014_01_23_06_creature.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 sql/updates/world/2014_01_23_06_creature.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_06_creature.sql b/sql/updates/world/2014_01_23_06_creature.sql new file mode 100644 index 00000000000..356db4fceb4 --- /dev/null +++ b/sql/updates/world/2014_01_23_06_creature.sql @@ -0,0 +1,4 @@ +-- Update creature (Voidspawner L) force to use modelid 18684 +UPDATE `creature` SET `modelid`=18684 WHERE `guid` IN (70169, 70170, 70171, 70172, 70173, 70174); +-- Update creature (Voidspawner XL) force to use modelid 18685 +UPDATE `creature` SET `modelid`=18685 WHERE `guid` IN (68919, 68918, 68917, 68920, 68921); -- cgit v1.2.3 From df90f5811f492af8e5a51b800988913e75a0fa8d Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 11:03:50 +0100 Subject: DB/Item Fix Living Ruby Pendant By Odyssey, fixes #11314 --- sql/updates/world/2014_01_23_07_spell_bonus_data.sql | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 sql/updates/world/2014_01_23_07_spell_bonus_data.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_07_spell_bonus_data.sql b/sql/updates/world/2014_01_23_07_spell_bonus_data.sql new file mode 100644 index 00000000000..1dfd35eac5a --- /dev/null +++ b/sql/updates/world/2014_01_23_07_spell_bonus_data.sql @@ -0,0 +1,3 @@ +-- Living Ruby Pendant (item 24110) shouldn't get SP bonuses +DELETE FROM `spell_bonus_data` WHERE `entry`=31024; +INSERT INTO `spell_bonus_data` (`entry`, `direct_bonus`, `dot_bonus`, `ap_bonus`, `ap_dot_bonus`, `comments`) VALUES (31024,0,0,0,0,'Living ruby pendant should not get bonuses'); -- cgit v1.2.3 From d22cd69f62436f55668058652e645a8004305c61 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 11:07:02 +0100 Subject: DB/Graveyard: gm island graveyard By Vincent-Michael, closes #9789 --- sql/updates/world/2014_01_23_08_graveyard.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 sql/updates/world/2014_01_23_08_graveyard.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_08_graveyard.sql b/sql/updates/world/2014_01_23_08_graveyard.sql new file mode 100644 index 00000000000..27cfc39647d --- /dev/null +++ b/sql/updates/world/2014_01_23_08_graveyard.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `game_graveyard_zone` WHERE `id`=589; +INSERT INTO `game_graveyard_zone` (`id`, `ghost_zone`, `faction`) VALUES +(589, 876, 0); -- cgit v1.2.3 From e619ec267d975b2a2d87f71b33bc5a3d5b20c7fa Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 11:12:12 +0100 Subject: DB/Vendor: Add Boots - Lesser Accurecy recipe By dr-j, closes #8113 --- sql/updates/world/2014_01_23_09_npc_trainer.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 sql/updates/world/2014_01_23_09_npc_trainer.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_09_npc_trainer.sql b/sql/updates/world/2014_01_23_09_npc_trainer.sql new file mode 100644 index 00000000000..3b44463b3da --- /dev/null +++ b/sql/updates/world/2014_01_23_09_npc_trainer.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `npc_trainer` WHERE `entry`=201009 AND `spell`=63746; +INSERT INTO `npc_trainer` (`entry`, `spell`, `spellcost`, `reqskill`, `reqskillvalue`, `reqlevel`) VALUES +(201009, 63746, 5000, 333, 225, 0); -- cgit v1.2.3 From 3871421d5a92fe8c84581a104a7a8b75b3dae881 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 11:28:30 +0100 Subject: DB/Loot:Icetouched Earthrager Remove Incorrectly dropping mote of earth, by dr-j closes #11216 --- sql/updates/world/2014_01_23_10_creature_loot_template.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/world/2014_01_23_10_creature_loot_template.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_10_creature_loot_template.sql b/sql/updates/world/2014_01_23_10_creature_loot_template.sql new file mode 100644 index 00000000000..f15bf25e5a8 --- /dev/null +++ b/sql/updates/world/2014_01_23_10_creature_loot_template.sql @@ -0,0 +1,2 @@ +-- Delete mote of earth from loot of Icetouched Earthrager +DELETE FROM `creature_loot_template` WHERE `entry`=29436 AND `item`=22573; -- cgit v1.2.3 From 17f11802889db0a974b36f7f2b7580ab494e352d Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 11:42:50 +0100 Subject: DB/Creature: Fix Rubble Stalker Kologarn By Vincent-Michael, closes #5507 --- sql/updates/world/2014_01_23_11_creature_template.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sql/updates/world/2014_01_23_11_creature_template.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_11_creature_template.sql b/sql/updates/world/2014_01_23_11_creature_template.sql new file mode 100644 index 00000000000..efb5c7871af --- /dev/null +++ b/sql/updates/world/2014_01_23_11_creature_template.sql @@ -0,0 +1,2 @@ +-- Rubble Stalker Kologarn +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128 WHERE `entry`=33809; -- cgit v1.2.3 From 40b9ea3eb2f09743183aff1624764f808048a0a5 Mon Sep 17 00:00:00 2001 From: Aokromes Date: Thu, 23 Jan 2014 12:34:23 +0100 Subject: DB/SAI Fix The Torch of Retribution By FireEmerald closes #11356 --- sql/updates/world/2014_01_23_12_sai.sql | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 sql/updates/world/2014_01_23_12_sai.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_23_12_sai.sql b/sql/updates/world/2014_01_23_12_sai.sql new file mode 100644 index 00000000000..a9935fd0c97 --- /dev/null +++ b/sql/updates/world/2014_01_23_12_sai.sql @@ -0,0 +1,8 @@ +-- The Torch of Retribution (3454) +SET @KALARAN := 8479; -- Kalaran Windblade +SET @QUEST := 3454; -- Quest: The Torch of Retribution + +DELETE FROM `smart_scripts` WHERE `entryorguid`=@KALARAN AND `id` IN (5,6); +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 +(@KALARAN,0,5,6,19,0,100,0,@QUEST,0,0,0,70,0,0,0,0,0,0,14,24166,149410,0,0,0,0,0,"Kalaran Windblade - On Quest Accept (4354) - Respawn Light of Retribution"), +(@KALARAN,0,6,0,61,0,100,0,0,0,0,0,70,0,0,0,0,0,0,14,16762,149047,0,0,0,0,0,"Kalaran Windblade - Linked with Previous Event - Respawn Torch of Retribution"); -- cgit v1.2.3 From f731116766268a38a58572e57cc8abbac400c5ca Mon Sep 17 00:00:00 2001 From: joschiwald Date: Thu, 23 Jan 2014 18:21:17 +0100 Subject: Scripts/AhnKahet: fix some issues on prince taldaram script --- sql/updates/world/2014_01_17_00_trinity_string.sql | 8 - .../world/2014_01_17_00_world_trinity_string.sql | 8 + sql/updates/world/2014_01_23_01_conditions.sql | 5 - .../world/2014_01_23_01_world_conditions.sql | 5 + sql/updates/world/2014_01_23_02_sai.sql | 2 - sql/updates/world/2014_01_23_02_world_sai.sql | 2 + sql/updates/world/2014_01_23_03_conditions.sql | 3 - .../world/2014_01_23_03_world_conditions.sql | 3 + .../world/2014_01_23_04_game_event_creature.sql | 6 - .../2014_01_23_04_world_game_event_creature.sql | 6 + .../world/2014_01_23_05_creature_template.sql | 2 - .../2014_01_23_05_world_creature_template.sql | 2 + sql/updates/world/2014_01_23_06_creature.sql | 4 - sql/updates/world/2014_01_23_06_world_creature.sql | 4 + .../world/2014_01_23_07_spell_bonus_data.sql | 3 - .../world/2014_01_23_07_world_spell_bonus_data.sql | 3 + sql/updates/world/2014_01_23_08_graveyard.sql | 4 - .../world/2014_01_23_08_world_graveyard.sql | 4 + sql/updates/world/2014_01_23_09_npc_trainer.sql | 4 - .../world/2014_01_23_09_world_npc_trainer.sql | 4 + .../world/2014_01_23_10_creature_loot_template.sql | 2 - .../2014_01_23_10_world_creature_loot_template.sql | 2 + .../world/2014_01_23_11_creature_template.sql | 2 - .../2014_01_23_11_world_creature_template.sql | 2 + sql/updates/world/2014_01_23_12_sai.sql | 8 - sql/updates/world/2014_01_23_12_world_sai.sql | 8 + sql/updates/world/2014_01_23_13_world_misc.sql | 13 + .../AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp | 389 +++++++++++++-------- 28 files changed, 303 insertions(+), 205 deletions(-) delete mode 100644 sql/updates/world/2014_01_17_00_trinity_string.sql create mode 100644 sql/updates/world/2014_01_17_00_world_trinity_string.sql delete mode 100644 sql/updates/world/2014_01_23_01_conditions.sql create mode 100644 sql/updates/world/2014_01_23_01_world_conditions.sql delete mode 100644 sql/updates/world/2014_01_23_02_sai.sql create mode 100644 sql/updates/world/2014_01_23_02_world_sai.sql delete mode 100644 sql/updates/world/2014_01_23_03_conditions.sql create mode 100644 sql/updates/world/2014_01_23_03_world_conditions.sql delete mode 100644 sql/updates/world/2014_01_23_04_game_event_creature.sql create mode 100644 sql/updates/world/2014_01_23_04_world_game_event_creature.sql delete mode 100644 sql/updates/world/2014_01_23_05_creature_template.sql create mode 100644 sql/updates/world/2014_01_23_05_world_creature_template.sql delete mode 100644 sql/updates/world/2014_01_23_06_creature.sql create mode 100644 sql/updates/world/2014_01_23_06_world_creature.sql delete mode 100644 sql/updates/world/2014_01_23_07_spell_bonus_data.sql create mode 100644 sql/updates/world/2014_01_23_07_world_spell_bonus_data.sql delete mode 100644 sql/updates/world/2014_01_23_08_graveyard.sql create mode 100644 sql/updates/world/2014_01_23_08_world_graveyard.sql delete mode 100644 sql/updates/world/2014_01_23_09_npc_trainer.sql create mode 100644 sql/updates/world/2014_01_23_09_world_npc_trainer.sql delete mode 100644 sql/updates/world/2014_01_23_10_creature_loot_template.sql create mode 100644 sql/updates/world/2014_01_23_10_world_creature_loot_template.sql delete mode 100644 sql/updates/world/2014_01_23_11_creature_template.sql create mode 100644 sql/updates/world/2014_01_23_11_world_creature_template.sql delete mode 100644 sql/updates/world/2014_01_23_12_sai.sql create mode 100644 sql/updates/world/2014_01_23_12_world_sai.sql create mode 100644 sql/updates/world/2014_01_23_13_world_misc.sql (limited to 'sql') diff --git a/sql/updates/world/2014_01_17_00_trinity_string.sql b/sql/updates/world/2014_01_17_00_trinity_string.sql deleted file mode 100644 index 698af0f56cb..00000000000 --- a/sql/updates/world/2014_01_17_00_trinity_string.sql +++ /dev/null @@ -1,8 +0,0 @@ -DELETE FROM trinity_string where entry in (11002, 11003, 11004, 11005, 11006, 11007); -INSERT INTO `trinity_string` VALUES -('11002', 'Server: %s has kicked %s, reason: %s', '', '', '', '', '', '', '', ''), -('11003', 'Server: %s has muted %s for %u minutes, reason: %s', '', '', '', '', '', '', '', ''), -('11004', 'Server: %s has banned character %s for %s, reason: %s', '', '', '', '', '', '', '', ''), -('11005', 'Server: %s has banned character %s permanetly, reason: %s', '', '', '', '', '', '', '', ''), -('11006', 'Server: %s has banned %s for %s, reason: %s', '', '', '', '', '', '', '', ''), -('11007', 'Server: %s has banned %s permanetly, reason: %s', '', '', '', '', '', '', '', ''); diff --git a/sql/updates/world/2014_01_17_00_world_trinity_string.sql b/sql/updates/world/2014_01_17_00_world_trinity_string.sql new file mode 100644 index 00000000000..698af0f56cb --- /dev/null +++ b/sql/updates/world/2014_01_17_00_world_trinity_string.sql @@ -0,0 +1,8 @@ +DELETE FROM trinity_string where entry in (11002, 11003, 11004, 11005, 11006, 11007); +INSERT INTO `trinity_string` VALUES +('11002', 'Server: %s has kicked %s, reason: %s', '', '', '', '', '', '', '', ''), +('11003', 'Server: %s has muted %s for %u minutes, reason: %s', '', '', '', '', '', '', '', ''), +('11004', 'Server: %s has banned character %s for %s, reason: %s', '', '', '', '', '', '', '', ''), +('11005', 'Server: %s has banned character %s permanetly, reason: %s', '', '', '', '', '', '', '', ''), +('11006', 'Server: %s has banned %s for %s, reason: %s', '', '', '', '', '', '', '', ''), +('11007', 'Server: %s has banned %s permanetly, reason: %s', '', '', '', '', '', '', '', ''); diff --git a/sql/updates/world/2014_01_23_01_conditions.sql b/sql/updates/world/2014_01_23_01_conditions.sql deleted file mode 100644 index 4afa30ee13d..00000000000 --- a/sql/updates/world/2014_01_23_01_conditions.sql +++ /dev/null @@ -1,5 +0,0 @@ --- -DELETE FROM `conditions` WHERE `SourceEntry` = 40817; -INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `Comment`) VALUES -(17,0,40817,0,0,23,0,3785,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Wrath'), -(17,0,40817,0,1,23,0,3784,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Terror'); diff --git a/sql/updates/world/2014_01_23_01_world_conditions.sql b/sql/updates/world/2014_01_23_01_world_conditions.sql new file mode 100644 index 00000000000..4afa30ee13d --- /dev/null +++ b/sql/updates/world/2014_01_23_01_world_conditions.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `conditions` WHERE `SourceEntry` = 40817; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `Comment`) VALUES +(17,0,40817,0,0,23,0,3785,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Wrath'), +(17,0,40817,0,1,23,0,3784,0,0,0,0,0,'Banishing Crystal requires Forge Camp: Terror'); diff --git a/sql/updates/world/2014_01_23_02_sai.sql b/sql/updates/world/2014_01_23_02_sai.sql deleted file mode 100644 index f55db997a4c..00000000000 --- a/sql/updates/world/2014_01_23_02_sai.sql +++ /dev/null @@ -1,2 +0,0 @@ --- -UPDATE `smart_scripts` SET `event_phase_mask`=1 WHERE `entryorguid`=2103 AND `event_phase_mask`=2; diff --git a/sql/updates/world/2014_01_23_02_world_sai.sql b/sql/updates/world/2014_01_23_02_world_sai.sql new file mode 100644 index 00000000000..f55db997a4c --- /dev/null +++ b/sql/updates/world/2014_01_23_02_world_sai.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `event_phase_mask`=1 WHERE `entryorguid`=2103 AND `event_phase_mask`=2; diff --git a/sql/updates/world/2014_01_23_03_conditions.sql b/sql/updates/world/2014_01_23_03_conditions.sql deleted file mode 100644 index df83d50fd51..00000000000 --- a/sql/updates/world/2014_01_23_03_conditions.sql +++ /dev/null @@ -1,3 +0,0 @@ --- -UPDATE `conditions` SET `ElseGroup`=1 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=5 AND `ConditionTarget`=0 AND `ConditionValue1`=54 AND `ConditionValue2`=128 AND `ConditionValue3`=0; -UPDATE `conditions` SET `ConditionValue1`=64 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=16 AND `ConditionTarget`=0 AND `ConditionValue1`=8 AND `ConditionValue2`=0 AND `ConditionValue3`=0; diff --git a/sql/updates/world/2014_01_23_03_world_conditions.sql b/sql/updates/world/2014_01_23_03_world_conditions.sql new file mode 100644 index 00000000000..df83d50fd51 --- /dev/null +++ b/sql/updates/world/2014_01_23_03_world_conditions.sql @@ -0,0 +1,3 @@ +-- +UPDATE `conditions` SET `ElseGroup`=1 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=5 AND `ConditionTarget`=0 AND `ConditionValue1`=54 AND `ConditionValue2`=128 AND `ConditionValue3`=0; +UPDATE `conditions` SET `ConditionValue1`=64 WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3186 AND `SourceEntry`=0 AND `SourceId`=0 AND `ElseGroup`=0 AND `ConditionTypeOrReference`=16 AND `ConditionTarget`=0 AND `ConditionValue1`=8 AND `ConditionValue2`=0 AND `ConditionValue3`=0; diff --git a/sql/updates/world/2014_01_23_04_game_event_creature.sql b/sql/updates/world/2014_01_23_04_game_event_creature.sql deleted file mode 100644 index 5d350803f82..00000000000 --- a/sql/updates/world/2014_01_23_04_game_event_creature.sql +++ /dev/null @@ -1,6 +0,0 @@ --- Boxi (brewfest) -SET @GUID := '200002'; - --- game event creature boxi -DELETE FROM `game_event_creature` WHERE `guid`=@GUID; -INSERT INTO `game_event_creature`(`eventEntry`,`guid`) values (24,@GUID); diff --git a/sql/updates/world/2014_01_23_04_world_game_event_creature.sql b/sql/updates/world/2014_01_23_04_world_game_event_creature.sql new file mode 100644 index 00000000000..5d350803f82 --- /dev/null +++ b/sql/updates/world/2014_01_23_04_world_game_event_creature.sql @@ -0,0 +1,6 @@ +-- Boxi (brewfest) +SET @GUID := '200002'; + +-- game event creature boxi +DELETE FROM `game_event_creature` WHERE `guid`=@GUID; +INSERT INTO `game_event_creature`(`eventEntry`,`guid`) values (24,@GUID); diff --git a/sql/updates/world/2014_01_23_05_creature_template.sql b/sql/updates/world/2014_01_23_05_creature_template.sql deleted file mode 100644 index a35a6191ea4..00000000000 --- a/sql/updates/world/2014_01_23_05_creature_template.sql +++ /dev/null @@ -1,2 +0,0 @@ --- -UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128|2 WHERE `entry` IN (31138,31550); diff --git a/sql/updates/world/2014_01_23_05_world_creature_template.sql b/sql/updates/world/2014_01_23_05_world_creature_template.sql new file mode 100644 index 00000000000..a35a6191ea4 --- /dev/null +++ b/sql/updates/world/2014_01_23_05_world_creature_template.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128|2 WHERE `entry` IN (31138,31550); diff --git a/sql/updates/world/2014_01_23_06_creature.sql b/sql/updates/world/2014_01_23_06_creature.sql deleted file mode 100644 index 356db4fceb4..00000000000 --- a/sql/updates/world/2014_01_23_06_creature.sql +++ /dev/null @@ -1,4 +0,0 @@ --- Update creature (Voidspawner L) force to use modelid 18684 -UPDATE `creature` SET `modelid`=18684 WHERE `guid` IN (70169, 70170, 70171, 70172, 70173, 70174); --- Update creature (Voidspawner XL) force to use modelid 18685 -UPDATE `creature` SET `modelid`=18685 WHERE `guid` IN (68919, 68918, 68917, 68920, 68921); diff --git a/sql/updates/world/2014_01_23_06_world_creature.sql b/sql/updates/world/2014_01_23_06_world_creature.sql new file mode 100644 index 00000000000..356db4fceb4 --- /dev/null +++ b/sql/updates/world/2014_01_23_06_world_creature.sql @@ -0,0 +1,4 @@ +-- Update creature (Voidspawner L) force to use modelid 18684 +UPDATE `creature` SET `modelid`=18684 WHERE `guid` IN (70169, 70170, 70171, 70172, 70173, 70174); +-- Update creature (Voidspawner XL) force to use modelid 18685 +UPDATE `creature` SET `modelid`=18685 WHERE `guid` IN (68919, 68918, 68917, 68920, 68921); diff --git a/sql/updates/world/2014_01_23_07_spell_bonus_data.sql b/sql/updates/world/2014_01_23_07_spell_bonus_data.sql deleted file mode 100644 index 1dfd35eac5a..00000000000 --- a/sql/updates/world/2014_01_23_07_spell_bonus_data.sql +++ /dev/null @@ -1,3 +0,0 @@ --- Living Ruby Pendant (item 24110) shouldn't get SP bonuses -DELETE FROM `spell_bonus_data` WHERE `entry`=31024; -INSERT INTO `spell_bonus_data` (`entry`, `direct_bonus`, `dot_bonus`, `ap_bonus`, `ap_dot_bonus`, `comments`) VALUES (31024,0,0,0,0,'Living ruby pendant should not get bonuses'); diff --git a/sql/updates/world/2014_01_23_07_world_spell_bonus_data.sql b/sql/updates/world/2014_01_23_07_world_spell_bonus_data.sql new file mode 100644 index 00000000000..1dfd35eac5a --- /dev/null +++ b/sql/updates/world/2014_01_23_07_world_spell_bonus_data.sql @@ -0,0 +1,3 @@ +-- Living Ruby Pendant (item 24110) shouldn't get SP bonuses +DELETE FROM `spell_bonus_data` WHERE `entry`=31024; +INSERT INTO `spell_bonus_data` (`entry`, `direct_bonus`, `dot_bonus`, `ap_bonus`, `ap_dot_bonus`, `comments`) VALUES (31024,0,0,0,0,'Living ruby pendant should not get bonuses'); diff --git a/sql/updates/world/2014_01_23_08_graveyard.sql b/sql/updates/world/2014_01_23_08_graveyard.sql deleted file mode 100644 index 27cfc39647d..00000000000 --- a/sql/updates/world/2014_01_23_08_graveyard.sql +++ /dev/null @@ -1,4 +0,0 @@ --- -DELETE FROM `game_graveyard_zone` WHERE `id`=589; -INSERT INTO `game_graveyard_zone` (`id`, `ghost_zone`, `faction`) VALUES -(589, 876, 0); diff --git a/sql/updates/world/2014_01_23_08_world_graveyard.sql b/sql/updates/world/2014_01_23_08_world_graveyard.sql new file mode 100644 index 00000000000..27cfc39647d --- /dev/null +++ b/sql/updates/world/2014_01_23_08_world_graveyard.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `game_graveyard_zone` WHERE `id`=589; +INSERT INTO `game_graveyard_zone` (`id`, `ghost_zone`, `faction`) VALUES +(589, 876, 0); diff --git a/sql/updates/world/2014_01_23_09_npc_trainer.sql b/sql/updates/world/2014_01_23_09_npc_trainer.sql deleted file mode 100644 index 3b44463b3da..00000000000 --- a/sql/updates/world/2014_01_23_09_npc_trainer.sql +++ /dev/null @@ -1,4 +0,0 @@ --- -DELETE FROM `npc_trainer` WHERE `entry`=201009 AND `spell`=63746; -INSERT INTO `npc_trainer` (`entry`, `spell`, `spellcost`, `reqskill`, `reqskillvalue`, `reqlevel`) VALUES -(201009, 63746, 5000, 333, 225, 0); diff --git a/sql/updates/world/2014_01_23_09_world_npc_trainer.sql b/sql/updates/world/2014_01_23_09_world_npc_trainer.sql new file mode 100644 index 00000000000..3b44463b3da --- /dev/null +++ b/sql/updates/world/2014_01_23_09_world_npc_trainer.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `npc_trainer` WHERE `entry`=201009 AND `spell`=63746; +INSERT INTO `npc_trainer` (`entry`, `spell`, `spellcost`, `reqskill`, `reqskillvalue`, `reqlevel`) VALUES +(201009, 63746, 5000, 333, 225, 0); diff --git a/sql/updates/world/2014_01_23_10_creature_loot_template.sql b/sql/updates/world/2014_01_23_10_creature_loot_template.sql deleted file mode 100644 index f15bf25e5a8..00000000000 --- a/sql/updates/world/2014_01_23_10_creature_loot_template.sql +++ /dev/null @@ -1,2 +0,0 @@ --- Delete mote of earth from loot of Icetouched Earthrager -DELETE FROM `creature_loot_template` WHERE `entry`=29436 AND `item`=22573; diff --git a/sql/updates/world/2014_01_23_10_world_creature_loot_template.sql b/sql/updates/world/2014_01_23_10_world_creature_loot_template.sql new file mode 100644 index 00000000000..f15bf25e5a8 --- /dev/null +++ b/sql/updates/world/2014_01_23_10_world_creature_loot_template.sql @@ -0,0 +1,2 @@ +-- Delete mote of earth from loot of Icetouched Earthrager +DELETE FROM `creature_loot_template` WHERE `entry`=29436 AND `item`=22573; diff --git a/sql/updates/world/2014_01_23_11_creature_template.sql b/sql/updates/world/2014_01_23_11_creature_template.sql deleted file mode 100644 index efb5c7871af..00000000000 --- a/sql/updates/world/2014_01_23_11_creature_template.sql +++ /dev/null @@ -1,2 +0,0 @@ --- Rubble Stalker Kologarn -UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128 WHERE `entry`=33809; diff --git a/sql/updates/world/2014_01_23_11_world_creature_template.sql b/sql/updates/world/2014_01_23_11_world_creature_template.sql new file mode 100644 index 00000000000..efb5c7871af --- /dev/null +++ b/sql/updates/world/2014_01_23_11_world_creature_template.sql @@ -0,0 +1,2 @@ +-- Rubble Stalker Kologarn +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|128 WHERE `entry`=33809; diff --git a/sql/updates/world/2014_01_23_12_sai.sql b/sql/updates/world/2014_01_23_12_sai.sql deleted file mode 100644 index a9935fd0c97..00000000000 --- a/sql/updates/world/2014_01_23_12_sai.sql +++ /dev/null @@ -1,8 +0,0 @@ --- The Torch of Retribution (3454) -SET @KALARAN := 8479; -- Kalaran Windblade -SET @QUEST := 3454; -- Quest: The Torch of Retribution - -DELETE FROM `smart_scripts` WHERE `entryorguid`=@KALARAN AND `id` IN (5,6); -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 -(@KALARAN,0,5,6,19,0,100,0,@QUEST,0,0,0,70,0,0,0,0,0,0,14,24166,149410,0,0,0,0,0,"Kalaran Windblade - On Quest Accept (4354) - Respawn Light of Retribution"), -(@KALARAN,0,6,0,61,0,100,0,0,0,0,0,70,0,0,0,0,0,0,14,16762,149047,0,0,0,0,0,"Kalaran Windblade - Linked with Previous Event - Respawn Torch of Retribution"); diff --git a/sql/updates/world/2014_01_23_12_world_sai.sql b/sql/updates/world/2014_01_23_12_world_sai.sql new file mode 100644 index 00000000000..a9935fd0c97 --- /dev/null +++ b/sql/updates/world/2014_01_23_12_world_sai.sql @@ -0,0 +1,8 @@ +-- The Torch of Retribution (3454) +SET @KALARAN := 8479; -- Kalaran Windblade +SET @QUEST := 3454; -- Quest: The Torch of Retribution + +DELETE FROM `smart_scripts` WHERE `entryorguid`=@KALARAN AND `id` IN (5,6); +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 +(@KALARAN,0,5,6,19,0,100,0,@QUEST,0,0,0,70,0,0,0,0,0,0,14,24166,149410,0,0,0,0,0,"Kalaran Windblade - On Quest Accept (4354) - Respawn Light of Retribution"), +(@KALARAN,0,6,0,61,0,100,0,0,0,0,0,70,0,0,0,0,0,0,14,16762,149047,0,0,0,0,0,"Kalaran Windblade - Linked with Previous Event - Respawn Torch of Retribution"); diff --git a/sql/updates/world/2014_01_23_13_world_misc.sql b/sql/updates/world/2014_01_23_13_world_misc.sql new file mode 100644 index 00000000000..627aa99d56b --- /dev/null +++ b/sql/updates/world/2014_01_23_13_world_misc.sql @@ -0,0 +1,13 @@ +UPDATE `creature_template` SET `ScriptName`='boss_prince_taldaram' WHERE `entry`=29308; + +UPDATE `creature_template` SET `scale`=1, `speed_walk`=2, `InhabitType`=4, `flags_extra`=128 WHERE `entry` IN (30106,31458,31686,31687); +UPDATE `creature_template` SET `ScriptName`='npc_prince_taldaram_flame_sphere' WHERE `entry` IN (30106,31686,31687); + +UPDATE `gameobject_template` SET `flags`=32, `ScriptName`='go_prince_taldaram_sphere' WHERE `entry` IN (193093,193094); + +DELETE FROM `spell_script_names` WHERE `spell_id` IN (55931, 55895, 59511, 59512); +INSERT INTO `spell_script_names` (`spell_id` ,`ScriptName`) VALUES +(55931, 'spell_prince_taldaram_conjure_flame_sphere'), +(55895, 'spell_prince_taldaram_flame_sphere_summon'), +(59511, 'spell_prince_taldaram_flame_sphere_summon'), +(59512, 'spell_prince_taldaram_flame_sphere_summon'); diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp index 77d3ce21d0c..efe439de440 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp @@ -17,76 +17,75 @@ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "SpellScript.h" #include "Player.h" #include "ahnkahet.h" enum Spells { - SPELL_BLOODTHIRST = 55968, // Trigger Spell + add aura - SPELL_CONJURE_FLAME_SPHERE = 55931, - SPELL_FLAME_SPHERE_SUMMON_1 = 55895, // 1x 30106 - H_SPELL_FLAME_SPHERE_SUMMON_1 = 59511, // 1x 31686 - H_SPELL_FLAME_SPHERE_SUMMON_2 = 59512, // 1x 31687 - SPELL_FLAME_SPHERE_SPAWN_EFFECT = 55891, - SPELL_FLAME_SPHERE_VISUAL = 55928, - SPELL_FLAME_SPHERE_PERIODIC = 55926, - SPELL_FLAME_SPHERE_DEATH_EFFECT = 55947, - SPELL_BEAM_VISUAL = 60342, - SPELL_EMBRACE_OF_THE_VAMPYR = 55959, - SPELL_VANISH = 55964, - CREATURE_FLAME_SPHERE = 30106, - H_CREATURE_FLAME_SPHERE_1 = 31686, - H_CREATURE_FLAME_SPHERE_2 = 31687, - SPELL_HOVER_FALL = 60425 + SPELL_BLOODTHIRST = 55968, // Trigger Spell + add aura + SPELL_CONJURE_FLAME_SPHERE = 55931, + SPELL_FLAME_SPHERE_SUMMON_1 = 55895, // 1x 30106 + SPELL_FLAME_SPHERE_SUMMON_2 = 59511, // 1x 31686 + SPELL_FLAME_SPHERE_SUMMON_3 = 59512, // 1x 31687 + SPELL_FLAME_SPHERE_SPAWN_EFFECT = 55891, + SPELL_FLAME_SPHERE_VISUAL = 55928, + SPELL_FLAME_SPHERE_PERIODIC = 55926, + SPELL_FLAME_SPHERE_DEATH_EFFECT = 55947, + SPELL_EMBRACE_OF_THE_VAMPYR = 55959, + SPELL_VANISH = 55964, + + NPC_FLAME_SPHERE_1 = 30106, + NPC_FLAME_SPHERE_2 = 31686, + NPC_FLAME_SPHERE_3 = 31687, + + SPELL_BEAM_VISUAL = 60342, + SPELL_HOVER_FALL = 60425 }; enum Misc { - DATA_EMBRACE_DMG = 20000, - H_DATA_EMBRACE_DMG = 40000, - DATA_SPHERE_DISTANCE = 15 + DATA_EMBRACE_DMG = 20000, + H_DATA_EMBRACE_DMG = 40000 }; -#define DATA_SPHERE_ANGLE_OFFSET 0.7f -#define DATA_GROUND_POSITION_Z 11.30809f +#define DATA_SPHERE_DISTANCE 25.0f +#define DATA_SPHERE_ANGLE_OFFSET M_PI / 2 +#define DATA_GROUND_POSITION_Z 11.30809f enum Yells { - SAY_1 = 0, - SAY_WARNING = 1, - SAY_AGGRO = 2, - SAY_SLAY = 3, - SAY_DEATH = 4, - SAY_FEED = 5, - SAY_VANISH = 6 + SAY_1 = 0, + SAY_WARNING = 1, + SAY_AGGRO = 2, + SAY_SLAY = 3, + SAY_DEATH = 4, + SAY_FEED = 5, + SAY_VANISH = 6 }; enum Events { - EVENT_CASTING_FLAME_SPHERES = 1, + EVENT_CONJURE_FLAME_SPHERES = 1, + EVENT_BLOODTHIRST, + EVENT_VANISH, EVENT_JUST_VANISHED, EVENT_VANISHED, EVENT_FEEDING, - EVENT_BLOODTHIRST, - EVENT_FLAME_SPHERE, - EVENT_VANISH -}; - -enum Phase -{ - PHASE_NORMAL = 1, - PHASE_SPECIAL = 2 + // Flame Sphere + EVENT_START_MOVE, + EVENT_DESPAWN }; -class boss_taldaram : public CreatureScript +class boss_prince_taldaram : public CreatureScript { public: - boss_taldaram() : CreatureScript("boss_taldaram") { } + boss_prince_taldaram() : CreatureScript("boss_prince_taldaram") { } - struct boss_taldaramAI : public BossAI + struct boss_prince_taldaramAI : public BossAI { - boss_taldaramAI(Creature* creature) : BossAI(creature, DATA_PRINCE_TALDARAM) + boss_prince_taldaramAI(Creature* creature) : BossAI(creature, DATA_PRINCE_TALDARAM) { me->SetDisableGravity(true); } @@ -94,6 +93,7 @@ class boss_taldaram : public CreatureScript void Reset() OVERRIDE { _Reset(); + _flameSphereTargetGUID = 0; _embraceTargetGUID = 0; _embraceTakenDamage = 0; } @@ -102,10 +102,24 @@ class boss_taldaram : public CreatureScript { _EnterCombat(); Talk(SAY_AGGRO); - events.SetPhase(PHASE_NORMAL); events.ScheduleEvent(EVENT_BLOODTHIRST, 10000); events.ScheduleEvent(EVENT_VANISH, urand(25000, 35000)); - events.ScheduleEvent(EVENT_FLAME_SPHERE, 5000); + events.ScheduleEvent(EVENT_CONJURE_FLAME_SPHERES, 5000); + } + + void JustSummoned(Creature* summon) + { + BossAI::JustSummoned(summon); + + switch (summon->GetEntry()) + { + case NPC_FLAME_SPHERE_1: + case NPC_FLAME_SPHERE_2: + case NPC_FLAME_SPHERE_3: + summon->AI()->SetGUID(_flameSphereTargetGUID); + default: + return; + } } void UpdateAI(uint32 diff) OVERRIDE @@ -122,80 +136,40 @@ class boss_taldaram : public CreatureScript { switch (eventId) { - if (events.IsInPhase(PHASE_NORMAL)) - { - case EVENT_BLOODTHIRST: - DoCast(me, SPELL_BLOODTHIRST); - events.ScheduleEvent(EVENT_BLOODTHIRST, 10000); - break; - case EVENT_FLAME_SPHERE: - DoCastVictim(SPELL_CONJURE_FLAME_SPHERE); - events.SetPhase(PHASE_SPECIAL); - events.ScheduleEvent(EVENT_CASTING_FLAME_SPHERES, 3000); - events.ScheduleEvent(EVENT_FLAME_SPHERE, 15000); - break; - case EVENT_VANISH: + case EVENT_BLOODTHIRST: + DoCast(me, SPELL_BLOODTHIRST); + events.ScheduleEvent(EVENT_BLOODTHIRST, 10000); + break; + case EVENT_CONJURE_FLAME_SPHERES: + // random target? + if (Unit* victim = me->GetVictim()) { - Map::PlayerList const& players = me->GetMap()->GetPlayers(); - uint32 targets = 0; - for (Map::PlayerList::const_iterator i = players.begin(); i != players.end(); ++i) - { - Player* player = i->GetSource(); - if (player && player->IsAlive()) - ++targets; - } - - if (targets > 2) - { - Talk(SAY_VANISH); - DoCast(me, SPELL_VANISH); - events.SetPhase(PHASE_SPECIAL); - events.ScheduleEvent(EVENT_JUST_VANISHED, 500); - if (Unit* embraceTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true)) - _embraceTargetGUID = embraceTarget->GetGUID(); - } - events.ScheduleEvent(EVENT_VANISH, urand(25000, 35000)); - break; + _flameSphereTargetGUID = victim->GetGUID(); + DoCast(victim, SPELL_CONJURE_FLAME_SPHERE); } - } - case EVENT_CASTING_FLAME_SPHERES: + events.ScheduleEvent(EVENT_CONJURE_FLAME_SPHERES, 15000); + break; + case EVENT_VANISH: { - events.SetPhase(PHASE_NORMAL); - Unit* sphereTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true); - if (!sphereTarget) - break; - - float angle, x, y; - - //DoCast(me, SPELL_FLAME_SPHERE_SUMMON_1); - if (Creature* sphere = DoSpawnCreature(CREATURE_FLAME_SPHERE, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10 * IN_MILLISECONDS)) + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + uint32 targets = 0; + for (Map::PlayerList::const_iterator i = players.begin(); i != players.end(); ++i) { - angle = sphere->GetAngle(sphereTarget); - x = sphere->GetPositionX() + DATA_SPHERE_DISTANCE * std::cos(angle); - y = sphere->GetPositionY() + DATA_SPHERE_DISTANCE * std::sin(angle); - sphere->GetMotionMaster()->MovePoint(0, x, y, sphere->GetPositionZ()); + Player* player = i->GetSource(); + if (player && player->IsAlive()) + ++targets; } - if (IsHeroic()) + if (targets > 2) { - //DoCast(me, H_SPELL_FLAME_SPHERE_SUMMON_1); - if (Creature* sphere = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_1, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10 * IN_MILLISECONDS)) - { - angle = sphere->GetAngle(sphereTarget) + DATA_SPHERE_ANGLE_OFFSET; - x = sphere->GetPositionX() + DATA_SPHERE_DISTANCE/2 * std::cos(angle); - y = sphere->GetPositionY() + DATA_SPHERE_DISTANCE/2 * std::sin(angle); - sphere->GetMotionMaster()->MovePoint(0, x, y, sphere->GetPositionZ()); - } - - //DoCast(me, H_SPELL_FLAME_SPHERE_SUMMON_2); - if (Creature* sphere = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_2, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10 * IN_MILLISECONDS)) - { - angle = sphere->GetAngle(sphereTarget) - DATA_SPHERE_ANGLE_OFFSET; - x = sphere->GetPositionX() + DATA_SPHERE_DISTANCE/2 * std::cos(angle); - y = sphere->GetPositionY() + DATA_SPHERE_DISTANCE/2 * std::sin(angle); - sphere->GetMotionMaster()->MovePoint(0, x, y, sphere->GetPositionZ()); - } + Talk(SAY_VANISH); + DoCast(me, SPELL_VANISH); + events.DelayEvents(500); + events.ScheduleEvent(EVENT_JUST_VANISHED, 500); + if (Unit* embraceTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100.0f, true)) + _embraceTargetGUID = embraceTarget->GetGUID(); } + events.ScheduleEvent(EVENT_VANISH, urand(25000, 35000)); break; } case EVENT_JUST_VANISHED: @@ -218,7 +192,6 @@ class boss_taldaram : public CreatureScript break; case EVENT_FEEDING: _embraceTargetGUID = 0; - events.SetPhase(PHASE_NORMAL); break; default: break; @@ -232,13 +205,12 @@ class boss_taldaram : public CreatureScript { Unit* embraceTarget = GetEmbraceTarget(); - if (events.IsInPhase(PHASE_SPECIAL) && embraceTarget && embraceTarget->IsAlive()) + if (embraceTarget && embraceTarget->IsAlive()) { _embraceTakenDamage += damage; if (_embraceTakenDamage > DUNGEON_MODE(DATA_EMBRACE_DMG, H_DATA_EMBRACE_DMG)) { _embraceTargetGUID = 0; - events.SetPhase(PHASE_NORMAL); me->CastStop(); } } @@ -255,12 +227,9 @@ class boss_taldaram : public CreatureScript if (victim->GetTypeId() != TYPEID_PLAYER) return; - Unit* embraceTarget = GetEmbraceTarget(); - if (events.IsInPhase(PHASE_SPECIAL) && embraceTarget && victim == embraceTarget) - { + if (victim->GetGUID() == _embraceTargetGUID) _embraceTargetGUID = 0; - events.SetPhase(PHASE_NORMAL); - } + Talk(SAY_SLAY); } @@ -289,76 +258,120 @@ class boss_taldaram : public CreatureScript me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), DATA_GROUND_POSITION_Z, me->GetOrientation()); DoCast(SPELL_HOVER_FALL); me->SetDisableGravity(false); - me->GetMotionMaster()->MovePoint(0, me->GetHomePosition()); + me->GetMotionMaster()->MoveLand(0, me->GetHomePosition()); Talk(SAY_WARNING); instance->HandleGameObject(instance->GetData64(DATA_PRINCE_TALDARAM_PLATFORM), true); } private: + uint64 _flameSphereTargetGUID; uint64 _embraceTargetGUID; uint32 _embraceTakenDamage; }; CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return GetAhnKahetAI(creature); + return GetAhnKahetAI(creature); } }; -class npc_taldaram_flamesphere : public CreatureScript +// 30106, 31686, 31687 - Flame Sphere +class npc_prince_taldaram_flame_sphere : public CreatureScript { public: - npc_taldaram_flamesphere() : CreatureScript("npc_taldaram_flamesphere") { } + npc_prince_taldaram_flame_sphere() : CreatureScript("npc_prince_taldaram_flame_sphere") { } - struct npc_taldaram_flamesphereAI : public ScriptedAI + struct npc_prince_taldaram_flame_sphereAI : public ScriptedAI { - npc_taldaram_flamesphereAI(Creature* creature) : ScriptedAI(creature) + npc_prince_taldaram_flame_sphereAI(Creature* creature) : ScriptedAI(creature) { } + + void Reset() OVERRIDE { + DoCast(me, SPELL_FLAME_SPHERE_SPAWN_EFFECT, true); + DoCast(me, SPELL_FLAME_SPHERE_VISUAL, true); + + _flameSphereTargetGUID = 0; + _events.Reset(); + _events.ScheduleEvent(EVENT_START_MOVE, 3 * IN_MILLISECONDS); + _events.ScheduleEvent(EVENT_DESPAWN, 13 * IN_MILLISECONDS); } - void Reset() OVERRIDE + void SetGUID(uint64 guid, int32 /*id = 0*/) OVERRIDE { - me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE); - //! HACK: Creature's can't have MOVEMENTFLAG_FLYING - me->AddUnitMovementFlag(MOVEMENTFLAG_FLYING); - me->setFaction(16); - me->SetObjectScale(1.0f); - DoCast(me, SPELL_FLAME_SPHERE_VISUAL); - DoCast(me, SPELL_FLAME_SPHERE_SPAWN_EFFECT); - DoCast(me, SPELL_FLAME_SPHERE_PERIODIC); - _despawnTimer = 10 * IN_MILLISECONDS; + _flameSphereTargetGUID = guid; } void EnterCombat(Unit* /*who*/) OVERRIDE { } void MoveInLineOfSight(Unit* /*who*/) OVERRIDE { } - void JustDied(Unit* /*killer*/) OVERRIDE - { - DoCast(me, SPELL_FLAME_SPHERE_DEATH_EFFECT); - } - void UpdateAI(uint32 diff) OVERRIDE { - if (_despawnTimer <= diff) - me->DisappearAndDie(); - else - _despawnTimer -= diff; + _events.Update(diff); + + while (uint32 eventId = _events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_START_MOVE: + { + DoCast(me, SPELL_FLAME_SPHERE_PERIODIC, true); + + /// @todo: find correct values + float angleOffset = 0.0f; + float distOffset = DATA_SPHERE_DISTANCE; + + switch (me->GetEntry()) + { + case NPC_FLAME_SPHERE_1: + break; + case NPC_FLAME_SPHERE_2: + angleOffset = DATA_SPHERE_ANGLE_OFFSET; + break; + case NPC_FLAME_SPHERE_3: + angleOffset = -DATA_SPHERE_ANGLE_OFFSET; + break; + default: + return; + } + + Unit* sphereTarget = ObjectAccessor::GetUnit(*me, _flameSphereTargetGUID); + if (!sphereTarget) + return; + + float angle = me->GetAngle(sphereTarget) + angleOffset; + float x = me->GetPositionX() + distOffset * std::cos(angle); + float y = me->GetPositionY() + distOffset * std::sin(angle); + + /// @todo: correct speed + me->GetMotionMaster()->MovePoint(0, x, y, me->GetPositionZ()); + break; + } + case EVENT_DESPAWN: + DoCast(me, SPELL_FLAME_SPHERE_DEATH_EFFECT, true); + me->DespawnOrUnsummon(1000); + break; + default: + break; + } + } } private: - uint32 _despawnTimer; + EventMap _events; + uint64 _flameSphereTargetGUID; }; CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new npc_taldaram_flamesphereAI(creature); + return new npc_prince_taldaram_flame_sphereAI(creature); } }; -class prince_taldaram_sphere : public GameObjectScript +// 193093, 193094 - Ancient Nerubian Device +class go_prince_taldaram_sphere : public GameObjectScript { public: - prince_taldaram_sphere() : GameObjectScript("prince_taldaram_sphere") { } + go_prince_taldaram_sphere() : GameObjectScript("go_prince_taldaram_sphere") { } bool OnGossipHello(Player* /*player*/, GameObject* go) OVERRIDE { @@ -369,7 +382,6 @@ class prince_taldaram_sphere : public GameObjectScript Creature* PrinceTaldaram = ObjectAccessor::GetCreature(*go, instance->GetData64(DATA_PRINCE_TALDARAM)); if (PrinceTaldaram && PrinceTaldaram->IsAlive()) { - // maybe these are hacks :( go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE); go->SetGoState(GO_STATE_ACTIVE); @@ -385,15 +397,88 @@ class prince_taldaram_sphere : public GameObjectScript break; } - CAST_AI(boss_taldaram::boss_taldaramAI, PrinceTaldaram->AI())->CheckSpheres(); + CAST_AI(boss_prince_taldaram::boss_prince_taldaramAI, PrinceTaldaram->AI())->CheckSpheres(); } return true; } }; +// 55931 - Conjure Flame Sphere +class spell_prince_taldaram_conjure_flame_sphere : public SpellScriptLoader +{ + public: + spell_prince_taldaram_conjure_flame_sphere() : SpellScriptLoader("spell_prince_taldaram_conjure_flame_sphere") { } + + class spell_prince_taldaram_conjure_flame_sphere_SpellScript : public SpellScript + { + PrepareSpellScript(spell_prince_taldaram_conjure_flame_sphere_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE + { + if (!sSpellMgr->GetSpellInfo(SPELL_FLAME_SPHERE_SUMMON_1) + || !sSpellMgr->GetSpellInfo(SPELL_FLAME_SPHERE_SUMMON_2) + || !sSpellMgr->GetSpellInfo(SPELL_FLAME_SPHERE_SUMMON_3)) + return false; + return true; + } + + void HandleScript(SpellEffIndex /*effIndex*/) + { + Unit* caster = GetCaster(); + caster->CastSpell(caster, SPELL_FLAME_SPHERE_SUMMON_1, true); + + if (caster->GetMap()->IsHeroic()) + { + caster->CastSpell(caster, SPELL_FLAME_SPHERE_SUMMON_2, true); + caster->CastSpell(caster, SPELL_FLAME_SPHERE_SUMMON_3, true); + } + } + + void Register() OVERRIDE + { + OnEffectHitTarget += SpellEffectFn(spell_prince_taldaram_conjure_flame_sphere_SpellScript::HandleScript, EFFECT_0, SPELL_EFFECT_DUMMY); + } + }; + + SpellScript* GetSpellScript() const OVERRIDE + { + return new spell_prince_taldaram_conjure_flame_sphere_SpellScript(); + } +}; + +// 55895, 59511, 59512 - Flame Sphere Summon +class spell_prince_taldaram_flame_sphere_summon : public SpellScriptLoader +{ + public: + spell_prince_taldaram_flame_sphere_summon() : SpellScriptLoader("spell_prince_taldaram_flame_sphere_summon") { } + + class spell_prince_taldaram_flame_sphere_summon_SpellScript : public SpellScript + { + PrepareSpellScript(spell_prince_taldaram_flame_sphere_summon_SpellScript); + + void SetDest(SpellDestination& dest) + { + Position offset = { 0.0f, 0.0f, 5.5f, 0.0f }; + dest.RelocateOffset(offset); + } + + void Register() OVERRIDE + { + OnDestinationTargetSelect += SpellDestinationTargetSelectFn(spell_prince_taldaram_flame_sphere_summon_SpellScript::SetDest, EFFECT_0, TARGET_DEST_CASTER); + } + }; + + SpellScript* GetSpellScript() const OVERRIDE + { + return new spell_prince_taldaram_flame_sphere_summon_SpellScript(); + } +}; + void AddSC_boss_taldaram() { - new boss_taldaram(); - new npc_taldaram_flamesphere(); - new prince_taldaram_sphere(); + new boss_prince_taldaram(); + new npc_prince_taldaram_flame_sphere(); + new go_prince_taldaram_sphere(); + new spell_prince_taldaram_conjure_flame_sphere(); + new spell_prince_taldaram_flame_sphere_summon(); } -- cgit v1.2.3