Guest User

Untitled

a guest
Dec 13th, 2018
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.68 KB | None | 0 0
  1. -- The Key of Warlord Zol'Maz (12712)
  2. -- spell 52669 triggers an event_script,but i'm not using that event at all(event table doesn't offer proper support)
  3.  
  4. SET @NPC_ZOLMAZ := 28902; -- Warlord Zol'Maz
  5. SET @NPC_TIKI_DERVISH := 28927; -- Enchanted Tiki Dervish
  6. SET @GO_TEMP := 300219; -- TEMP Warlord Zol'Maz present and unengaged in combat.
  7. SET @GO_LEVER := 190834; -- Gate Lever
  8. SET @GO_GATE := 190784; -- Zol'Maz Gate
  9. SET @SPELL_TIKI_CEREMONY := 52669; -- Tiki Dervish Ceremony
  10.  
  11. /*
  12. SET @EVENT := 18940;
  13. SET @GUID_GO_GATE := 57571;
  14. SET @ITEM := 39314;
  15. */
  16.  
  17. UPDATE `gameobject_template` SET `data1`=30 WHERE `entry`=@GO_TEMP; -- proper radius for focus object
  18. UPDATE `gameobject_template` SET `AIName`='SmartGameObjectAI' WHERE `entry`=@GO_GATE;
  19. UPDATE `gameobject_template` SET `AIName`='SmartGameObjectAI' WHERE `entry`=@GO_LEVER;
  20. UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@NPC_ZOLMAZ;
  21. UPDATE `creature_template` SET `minlevel`=77,`maxlevel`=77,`unit_class`=2,`unit_flags`=32776,`AIName`='SmartAI' WHERE `entry`=@NPC_TIKI_DERVISH;
  22.  
  23. DELETE FROM `creature_template_addon` WHERE `entry` IN (@NPC_ZOLMAZ,@NPC_TIKI_DERVISH);
  24. INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`auras`) VALUES
  25. (@NPC_ZOLMAZ,0,0x0,0x1,'52679'),
  26. (@NPC_TIKI_DERVISH,0,0x0,0x101,'52617 52670');
  27.  
  28. DELETE FROM `creature_equip_template` WHERE `entry` IN (@NPC_ZOLMAZ,@NPC_TIKI_DERVISH);
  29. INSERT INTO `creature_equip_template` (`entry`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
  30. (@NPC_ZOLMAZ,34638,0,0),
  31. (@NPC_TIKI_DERVISH,39312,0,0);
  32.  
  33. DELETE FROM `creature_text` WHERE `entry`=@NPC_ZOLMAZ;
  34. INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`) VALUES
  35. (@NPC_ZOLMAZ,0,0,'You have an enchanted tiki? YOU KILLED MY FAMILY!',14,0,100,15,0,6200,'Warlord Zol''Maz'),
  36. (@NPC_ZOLMAZ,1,0,'I WILL KILL YOU, $N!',14,0,100,0,0,0,'Warlord Zol''Maz'),
  37. (@NPC_ZOLMAZ,2,0,'%s becomes enraged!',16,0,100,0,0,0, 'Combat Enrage');
  38.  
  39. /*
  40. DELETE FROM `event_scripts` WHERE `id`=@EVENT;
  41. INSERT INTO `event_scripts` (`id`,`delay`,`command`,`datalong`,`datalong2`,`dataint`,`x`,`y`,`z`,`o`) VALUES
  42. (@EVENT,3,11,@GUID_GO_GATE,60,0,0,0,0,0); -- using guid of door
  43. */
  44.  
  45. DELETE FROM `smart_scripts` WHERE (`source_type`=1 AND `entryorguid`=@GO_LEVER) OR (`source_type`=1 AND `entryorguid`=@GO_GATE) OR (`source_type`=9 AND `entryorguid`=@GO_GATE*100) OR (`source_type`=0 AND `entryorguid`=@NPC_TIKI_DERVISH) OR (`source_type`=0 AND `entryorguid`=@NPC_ZOLMAZ);
  46. 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
  47. (@GO_LEVER,1,0,0,70,0,100,0,2,0,0,0,9,0,0,0,0,0,0,20,@GO_GATE,50,0,0,0,0,0,'Gate Lever - On use - Set state Gate'),
  48. -- ##
  49. (@GO_GATE,1,0,0,70,0,100,0,2,0,0,0,80,@GO_GATE*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz Gate - On activate - Run Script'),
  50. (@GO_GATE*100,9,0,0,0,0,100,0,60000,60000,60000,60000,32,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz Gate - Script - Reset go'),
  51. -- ##
  52. (@NPC_TIKI_DERVISH,0,0,1,54,0,100,0,0,0,0,0,9,0,0,0,0,0,0,20,@GO_GATE,50,0,0,0,0,0,'Tiki Dervish - Just summoned - Activate Gate'),
  53. (@NPC_TIKI_DERVISH,0,1,0,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,19,@NPC_ZOLMAZ,0,0,0,0,0,0,'Tiki Dervish - Just summoned - Set data on Zol''Maz'),
  54. -- ##
  55. (@NPC_ZOLMAZ,0,0,1,38,0,100,0,1,1,0,0,1,0,10000,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz - On data 1 1 - Talk'),
  56. (@NPC_ZOLMAZ,0,1,0,61,0,100,0,1,1,0,0,46,15,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz - On data - Move forward'),
  57. (@NPC_ZOLMAZ,0,2,0,52,0,100,0,0,@NPC_ZOLMAZ,0,0,19,256,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz - On text over - Remove flag 256'),
  58. (@NPC_ZOLMAZ,0,3,0,25,0,100,0,0,0,0,0,18,256,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz - On Reset - Set flag 256'),
  59. (@NPC_ZOLMAZ,0,4,0,4,0,100,0,0,0,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Zol''Maz - On aggro - Talk'),
  60. (@NPC_ZOLMAZ,0,5,0,0,0,100,0,9000,16000,12000,18000,11,54670,0,0,0,0,0,1,0,0,0,0,0,0,0,'Cast Decapitate'),
  61. (@NPC_ZOLMAZ,0,6,0,9,0,100,0,8,25,12000,21000,11,32323,0,0,0,0,0,2,0,0,0,0,0,0,0,'Cast Charge on Close'),
  62. (@NPC_ZOLMAZ,0,7,0,0,0,100,0,5000,12000,9000,16000,11,40546,0,0,0,0,0,1,0,0,0,0,0,0,0,'Cast Retaliation'),
  63. (@NPC_ZOLMAZ,0,8,0,2,0,100,1,0,30,0,0,11,8599,0,0,0,0,0,1,0,0,0,0,0,0,0,'Cast Enrage at 30% HP'),
  64. (@NPC_ZOLMAZ,0,9,0,2,0,100,1,0,30,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Say Text at 30% HP');
Add Comment
Please, Sign In to add comment