diff options
author | ZenoX92 <ZenoX92@users.noreply.github.com> | 2017-10-10 17:11:34 +0200 |
---|---|---|
committer | Killyana <morphone1@gmail.com> | 2017-10-10 17:11:34 +0200 |
commit | ef09ea484b492d8b1a38e7c6749e6e1c4a8cc0c4 (patch) | |
tree | 298ff9e8dbb52202869764a6cac6a4f2ae713077 | |
parent | 6fea15fefa539029a08f8a2861d90dd812534de2 (diff) |
Creature/Script: Convert Spitelash Naga cpp to SAI
Closes #20558
-rw-r--r-- | sql/updates/world/3.3.5/2017_10_10_01_world_335.sql | 122 | ||||
-rw-r--r-- | src/server/scripts/Kalimdor/zone_azshara.cpp | 99 |
2 files changed, 122 insertions, 99 deletions
diff --git a/sql/updates/world/3.3.5/2017_10_10_01_world_335.sql b/sql/updates/world/3.3.5/2017_10_10_01_world_335.sql new file mode 100644 index 00000000000..ef49228899b --- /dev/null +++ b/sql/updates/world/3.3.5/2017_10_10_01_world_335.sql @@ -0,0 +1,122 @@ +-- Spitelash Screamer +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=6193; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6193 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6193,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Spellhit 'Polymorph' - Run Script"), +(6193,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Spellhit 'Polymorph' - Run Script"), +(6193,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Spellhit 'Polymorph' - Run Script"), +(6193,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Spellhit 'Polymorph' - Run Script"), +(6193,0,4,0,0,0,100,0,7000,9000,12000,15000,11,3589,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - In Combat - Cast Deafening Screech"), +(6193,0,5,0,2,0,100,1,0,15,0,0,25,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - Between 0-15% Health - Flee For Assist (No Repeat)"); + +DELETE FROM `smart_scripts` WHERE `entryorguid`=619300 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 +(619300,9,0,0,0,0,100,0,4000,4000,0,0,11,28406,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Script - Cast Polymorph Backfire"), +(619300,9,1,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Script - root"), +(619300,9,2,0,0,0,100,0,0,0,0,0,3,0,11686,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Script - morph"), +(619300,9,3,0,0,0,100,0,0,0,0,0,11,60034,64,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Script - Cast smoke"), +(619300,9,4,0,0,0,100,0,1000,1000,0,0,41,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Screamer - On Script - Despawn"); +-- Spitelash Warrior +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=6190; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6190 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6190,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Warrior - On Spellhit 'Polymorph' - Run Script"), +(6190,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Warrior - On Spellhit 'Polymorph' - Run Script"), +(6190,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Warrior - On Spellhit 'Polymorph' - Run Script"), +(6190,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Warrior - On Spellhit 'Polymorph' - Run Script"), +(6190,0,4,0,0,0,100,0,6000,9000,11000,15000,11,6713,0,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Warrior - In Combat - Cast Disarm"); + +-- Spitelash Serpent Guard +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=6194; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6194 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6194,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Serpent Guard - On Spellhit 'Polymorph' - Run Script"), +(6194,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Serpent Guard - On Spellhit 'Polymorph' - Run Script"), +(6194,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Serpent Guard - On Spellhit 'Polymorph' - Run Script"), +(6194,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Serpent Guard - On Spellhit 'Polymorph' - Run Script"), +(6194,0,4,0,0,0,100,0,6000,8000,9000,13000,11,25710,0,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Serpent Guard - In Combat - Cast Heroic Strike"), +(6194,0,5,0,13,0,100,0,20000,30000,0,0,11,34783,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Serpent Guard - Target Casting - Cast Spell Reflection"); + +-- Spitelash Siren +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=6195; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6195 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6195,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - On Spellhit 'Polymorph' - Run Script"), +(6195,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - On Spellhit 'Polymorph' - Run Script"), +(6195,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - On Spellhit 'Polymorph' - Run Script"), +(6195,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - On Spellhit 'Polymorph' - Run Script"), +(6195,0,4,0,0,0,100,0,0,0,2300,3900,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Siren - In Combat - Cast Shoot"), +(6195,0,5,0,0,0,100,0,3000,5000,12000,16000,11,12551,0,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Siren - In Combat - Cast Frost Shot"), +(6195,0,6,0,9,0,100,0,0,8,13000,15000,11,11831,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - Within 0-8 Range - Cast Frost Nova"), +(6195,0,7,0,14,0,100,0,1200,40,12000,17000,11,11640,0,0,0,0,0,7,0,0,0,0,0,0,0,"Spitelash Siren - Friendly At 1200 Health - Cast Renew"), +(6195,0,8,0,2,0,100,1,0,15,0,0,25,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Siren - Between 0-15% Health - Flee For Assist (No Repeat)"); + +-- Spitelash Myrmidon +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=6196; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6196 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6196,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Myrmidon - On Spellhit 'Polymorph' - Run Script"), +(6196,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Myrmidon - On Spellhit 'Polymorph' - Run Script"), +(6196,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Myrmidon - On Spellhit 'Polymorph' - Run Script"), +(6196,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Myrmidon - On Spellhit 'Polymorph' - Run Script"), +(6196,0,4,0,0,0,100,0,5000,7000,6000,9000,11,11976,0,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Myrmidon - In Combat - Cast Strike"); + +-- Spitelash Battlemaster +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=7885; +DELETE FROM `smart_scripts` WHERE `entryorguid`=7885 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(7885,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Battlemaster - On Spellhit 'Polymorph' - Run Script"), +(7885,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Battlemaster - On Spellhit 'Polymorph' - Run Script"), +(7885,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Battlemaster - On Spellhit 'Polymorph' - Run Script"), +(7885,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Battlemaster - On Spellhit 'Polymorph' - Run Script"), +(7885,0,4,0,9,0,100,1,5,30,0,0,11,22120,0,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Battlemaster - Within 5-30 Range - Cast Charge (No Repeat)"); + +-- Spitelash Enchantress +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=7886; +DELETE FROM `smart_scripts` WHERE `entryorguid`=7886 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(7886,0,0,0,8,0,100,1,118,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - On Spellhit 'Polymorph' - Run Script"), +(7886,0,1,0,8,0,100,1,12824,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - On Spellhit 'Polymorph' - Run Script"), +(7886,0,2,0,8,0,100,1,12825,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - On Spellhit 'Polymorph' - Run Script"), +(7886,0,3,0,8,0,100,1,12826,0,0,0,80,619300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - On Spellhit 'Polymorph' - Run Script"), +(7886,0,4,0,0,0,100,0,0,0,2400,3800,11,15791,64,0,0,0,0,2,0,0,0,0,0,0,0,"Spitelash Enchantress - In Combat - Cast Arcane Missiles"), +(7886,0,5,0,0,0,100,0,5000,9000,18000,24000,11,3443,2,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - In Combat - Cast Enchanted Quickness"), +(7886,0,6,0,2,0,100,1,0,15,0,0,25,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Spitelash Enchantress - Between 0-15% Health - Flee For Assist (No Repeat)"); + +-- Polymorph Clone +UPDATE `creature_template` SET `AIName`="SmartAI", `ScriptName`="" WHERE `entry`=16479; +DELETE FROM `smart_scripts` WHERE `entryorguid`=16479 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(16479,0,0,1,1,0,100,1,0,0,0,0,8,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Polymorph Clone - OOC - React passif"), +(16479,0,1,0,61,0,100,1,0,0,0,0,89,10,0,0,0,0,0,1,0,0,0,0,0,0,0,"Polymorph Clone - OOC - Random movements"); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry` IN (6193, 6194, 6190, 6195, 6196, 7885, 7886); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(22,1,6193,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,6194,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,6190,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,6195,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,6196,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,7885,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,1,7886,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,6193,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,6194,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,6190,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,6195,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,6196,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,7885,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,2,7886,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,6193,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,6194,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,6190,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,6195,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,6196,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,7885,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,3,7886,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,6193,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,6194,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,6190,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,6195,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,6196,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,7885,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"), +(22,4,7886,0,0,9,0,9364,0,0,0,0,0,"","Execute SAI only if player has quest 'Fragmented Magic'"); diff --git a/src/server/scripts/Kalimdor/zone_azshara.cpp b/src/server/scripts/Kalimdor/zone_azshara.cpp index 0813b05705f..bea3ac7dd73 100644 --- a/src/server/scripts/Kalimdor/zone_azshara.cpp +++ b/src/server/scripts/Kalimdor/zone_azshara.cpp @@ -24,104 +24,6 @@ #include "ScriptedGossip.h" #include "SpellInfo.h" -/*###### -## npc_spitelashes -######*/ - -enum Spitelashes -{ - SPELL_POLYMORPH_RANK1 = 118, - SPELL_POLYMORPH_RANK2 = 12824, - SPELL_POLYMORPH_RANK3 = 12825, - SPELL_POLYMORPH_RANK4 = 12826, - SPELL_POLYMORPH = 29124, - SPELL_POLYMORPH_BACKFIRE = 28406, - SPELL_REMOVE_POLYMORPH = 6924 -}; - -class npc_spitelashes : public CreatureScript -{ -public: - npc_spitelashes() : CreatureScript("npc_spitelashes") { } - - struct npc_spitelashesAI : public ScriptedAI - { - npc_spitelashesAI(Creature* creature) : ScriptedAI(creature) - { - Initialize(); - } - - void Initialize() - { - morphtimer = 0; - spellhit = false; - } - - uint32 morphtimer; - bool spellhit; - - void Reset() override - { - Initialize(); - } - - void EnterCombat(Unit* /*who*/) override { } - - void SpellHit(Unit* unit, SpellInfo const* spell) override - { - if (spellhit) - return; - - switch (spell->Id) - { - case SPELL_POLYMORPH_RANK1: - case SPELL_POLYMORPH_RANK2: - case SPELL_POLYMORPH_RANK3: - case SPELL_POLYMORPH_RANK4: - if (Player* player = unit->ToPlayer()) - if (player->GetQuestStatus(9364) == QUEST_STATUS_INCOMPLETE) - { - spellhit = true; - DoCast(me, SPELL_POLYMORPH); - } - break; - default: - break; - } - } - - void UpdateAI(uint32 diff) override - { - // we mustn't remove the Creature in the same round in which we cast the summon spell, otherwise there will be no summons - if (spellhit && morphtimer >= 5000) - { - me->DespawnOrUnsummon(); - return; - } - // walk 5 seconds before summoning - if (spellhit && morphtimer < 5000) - { - morphtimer += diff; - if (morphtimer >= 5000) - { - DoCast(me, SPELL_POLYMORPH_BACKFIRE); // summon copies - DoCast(me, SPELL_REMOVE_POLYMORPH); // visual explosion - } - } - if (!UpdateVictim()) - return; - - /// @todo add abilities for the different creatures - DoMeleeAttackIfReady(); - } - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return new npc_spitelashesAI(creature); - } -}; - /*#### # npc_rizzle_sprysprocket ####*/ @@ -468,7 +370,6 @@ public: void AddSC_azshara() { - new npc_spitelashes(); new npc_rizzle_sprysprocket(); new npc_depth_charge(); } |