1. UPDATE `creature_template` SET `unit_flags`=32768 WHERE `entry`=24062; -- Wildervar Miner -- TambiƩn tenia: equipment_id`=53 - fijarse que tengan el pico los mineros
  2. UPDATE `creature_template` SET `unit_flags`=33536 WHERE `entry`=24178; -- Shatterhorn
  3. UPDATE `creature_model_info` SET `bounding_radius`=1.25,`combat_reach`=4.375,`gender`=0 WHERE `modelid`=22486; -- Shatterhorn
  4. DELETE FROM `creature_template_addon` WHERE `entry` IN (24062,24178);
  5. INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
  6. (24062,0,1,257,0, NULL), -- Wildervar Miner
  7. (24178,0,3,1,0, '6606'); -- Shatterhorn, Self Visual - Sleep Until Cancelled (DND)
  8. DELETE FROM `creature_addon` WHERE `guid` IN (120419,120422,106573);
  9. INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
  10. (120419,0,0,0,0,1,''), -- Wildervar Miner, talk
  11. (120422,0,0,0,0,1,''); -- Wildervar Miner, talk
  12. DELETE FROM `creature_ai_scripts` WHERE `creature_id`=@ENTRY;
  13. -- The ram meat spell may only be used if player is inside the mine
  14. DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=17 AND `SourceEntry`=43209 AND ConditionTypeOrReference=29;
  15. INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
  16. (17,0,43209,0,29,24178,13,0,0,'','Place Ram Meat can only be used near Shatterhorn 13yrds');
  17. -- Insert missing spell_target_position for Place Ram Meat spell
  18. DELETE FROM `spell_target_position` WHERE `id`=43209;
  19. INSERT INTO `spell_target_position` (`id`,`target_map`,`target_position_x`,`target_position_y`,`target_position_z`,`target_orientation`) VALUES
  20. (43209,571,2636.288086,-5050.891113,295.537445,5.374982);
  21. -- Shatterhorn SAI
  22. SET @ENTRY := 24178;
  23. SET @SPELL_GROUND_SMASH := 12734; -- Ground Smash
  24. UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@ENTRY;
  25. DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0;
  26. 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
  27. (@ENTRY,0,0,0,4,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Shatterhorn - On Aggro - Say Line 0'),
  28. (@ENTRY,0,1,0,0,0,100,0,3000,5000,12000,13000,11,@SPELL_GROUND_SMASH,1,0,0,0,0,2,0,0,0,0,0,0,0,'Shatterhorn - In Combat - Cast Ground Smash'),
  29. (@ENTRY,0,2,0,6,0,100,0,0,0,0,0,41,8000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Shatterhorn - Force Despawn 8 Seconds After Death'),
  30. (@ENTRY,0,3,0,8,0,0,0,43209,0,0,0,19,0x300,1,0,0,0,0,1,0,0,0,0,0,0,0,'Shatterhorn - On Place Meat spellhit remove unit flags'),
  31. (@ENTRY,0,4,0,8,0,0,0,43209,0,0,0,28,6606,1,0,0,0,0,1,0,0,0,0,0,0,0,'Shatterhorn - On Place Meat spellhit remove sleep aura'),
  32. (@ENTRY,0,5,0,8,0,0,0,43209,0,0,0,91,3,0,0,0,0,0,1,0,0,0,0,0,0,0,'Shatterhorn - On Place Meat spellhit remove byte1 3');
  33. -- Text
  34. DELETE FROM `creature_text` WHERE `entry`=@ENTRY;
  35. INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`) VALUES
  36. (@ENTRY,0,0,'%s wakes up from the smell of fresh meat!',16,0,100,15,0,0,'Shatterhorn on aggro line and roar at same time');

Q: The Yeti Next Door